技术支持 2022年11月27日
1.打开命令窗口cmd,输入命令:net stop mysql,停止MySQL服务,
2.开启跳过密码验证登录的MySQL服务,输入命令 mysqld –console –skip-grant-tables –shared-memory
3.再打开一个新的cmd,无密码登录MySQL,输入登录命令:mysql -u root -p ,跳过输入密码》 回车
4.执行命令更新密码为123 update user set authentication_string=password(‘123′) where user=’root’;
5.退出quit;