欢迎访问我的独立博客

mysql reset password重置密码

安全模式启动

chown -R mysql.mysql /var/run/mysqld/

mysqld_safe --skip-grant-tables &

 

 

无密码root帐号登陆

mysql -uroot -p //要求输入密码的时候,直接回车

或直接输入mysql

 

 

FLUSH PRIVILEGES;

select Host,User from user \G;

看看localhost这个是否存在,

ALTER USER 'root'@'localhost' IDENTIFIED BY 'test@com888';

posted @ 2018-08-13 17:12  github.com/starRTC  阅读(1296)  评论(0编辑  收藏  举报