/etc/rc.d/init.d/mysql status
/etc/rc.d/init.d/mysql stop
mysqld_safe --skip-grant-tables&
mysql -u root mysql
mysql> UPDATE user SET password=PASSWORD("new password") WHERE user='root';
mysql> FLUSH PRIVILEGES;
/etc/rc.d/init.d/mysql start
本文共 294 字,大约阅读时间需要 1 分钟。
/etc/rc.d/init.d/mysql status
/etc/rc.d/init.d/mysql stop
mysqld_safe --skip-grant-tables&
mysql -u root mysql
mysql> UPDATE user SET password=PASSWORD("new password") WHERE user='root';
mysql> FLUSH PRIVILEGES;
/etc/rc.d/init.d/mysql start
转载于:https://www.cnblogs.com/linn/p/4518035.html