Linux 环境下 安装 MySQL 查看临时密码出现 Access denied for user‘root‘@‘localhost‘ (using password: NO)

毅会

关注

阅读 160

2022-04-13

Linux 环境下 安装 MySQL 查看临时密码出现 Access denied for user’root’@‘localhost’ (using password: NO)

一、关闭当前 MySQL 服务

systemctl stop mysqld    # 停止mysql服务

二、修改 my.cnf 文件 新增一行 skip-grant-tables

vi /etc/my.cnf
# For advice on how to change settings please see
# http://dev.mysql.com/doc/refman/5.7/en/server-configuration-defaults.html

[mysqld]
skip-

精彩评论(0)

0 0 举报