新开一个cmd窗口,登录mysql,刷新权限表
FLUSH PRIVILEGES;
ALTER USER 'root'@'localhost' IDENTIFIED BY '你要设置的密码‘; ``` 即可。 >[参考链接](https://blog.csdn.net/whimewcm/article/details/83621358) >[个人网站](http://47.101.51.245/)