大家好,又见面了,我是你们的朋友全栈君。
net stop mysql
mysqld --defaults-file="F:\WorkSoftWare\mysql\mysql-5.7.23-winx64\bin\my.ini" --console --skip-grant-tables
mysql -u root -p
use mysql
7. 修改密码输入:update mysql.user set authentication_string = password(“新设置的密码”) where user=“root”;(我这里mysql的版本是5.7,其中密码列的属性叫做authentication_string;5.1的是password);
update mysql.user set authentication_string = password("123456") where user="root";
8. 刷新权限:flush privileges;
flush privileges;
quit;
发布者:全栈程序员栈长,转载请注明出处:https://javaforall.cn/139536.html原文链接:https://javaforall.cn