Mac Navicat premium 12 连接mysql8.0.21出现 'caching_sha2_password' 解决方案

1.通过命令 select user,plugin from user where user='root'; 我们可以发现加密方式是caching_sha2_password。

2.  修改查看加密方式alter user 'root'@'%' identified with mysql_native_password by 'your password';your password这里填自己的mysql密码

3.

my.cnf文件添加:

default_authentication_plugin=mysql_native_password

4.重启服务

5.连接成功:

回忆滋润坚持
原文地址:https://www.cnblogs.com/james5d/p/13960194.html