关于mysql连接出错:Client does not support authentication protocol requested by server

  1. 执行mysql -u root -p数据密码,如果没配置过全局变量则需进入到Mysql的bin目录里;
    first.png

2.依次输入:
(1)ALTER USER 'root'@'%' IDENTIFIED BY 'password' PASSWORD EXPIRE NEVER; (修改加密规则)
(2)ALTER USER 'root'@'%' IDENTIFIED WITH mysql_native_password BY 'password'; (更新用户密码 )
(3)FLUSH PRIVILEGES; (刷新权限,也可以不输入)

3.重新连接,大功告成。

你可能感兴趣的:(关于mysql连接出错:Client does not support authentication protocol requested by server)