标签:flush use nbsp and ant bsp mysqld -- pass
1.关闭mysql
killall mysqld
2.启动时加--skip-grant-tables 参数
mysqld_safe --defaults-file=/data/3306/my.cnf --skip-grant-table &
3.登录
mysql -uroot -p -S /data/3306/mysql.sock (登录时空密码)
4.修改密码:
update mysql.user set password=password(‘newpassword‘) where user=‘root‘ and host=‘localhost‘;
flush privileges;
标签:flush use nbsp and ant bsp mysqld -- pass
原文地址:http://www.cnblogs.com/shijiu520/p/6777854.html