mysql5.7 找回root密码

[root@166087 mysql]# /usr/local/mysql/bin/mysqld_safe --defaults-file=/etc/my.cnf --datadir=/data/mysql --skip-grant-tables
mysql> update user set authentication_string=password('123456') where user='root';


你可能感兴趣的:(mysql5.7 找回root密码)