MySQL 5.7 - You must reset your password using ALTER USER statement before executing this statement

感谢“冬日”。

CentOS 7 系统,安装了mysql 5.7。

现象:用mysql客户端sql查询,如列出数据库,提示 You must reset your password using ALTER USER statement before executing this statement
mysql-57-password-1.png

处理:执行sql语句 - ALTER USER 'root'@'localhost' IDENTIFIED BY 'CNnet!9283'; 更新root用户密码
mysql-57-password-2.png

参考:https://stackoverflow.com/questions/33467337/reset-mysql-root-password-using-alter-user-statement-after-install-on-mac

标签: mysql

添加新评论