安装成功mysq,打开navicat MySql链接不成功,显示Authentication plugin ‘caching_sha2_password’ cannot be loaded: dlopen(/usr/local/mysql/lib/plugin/caching_sha2_password.so, 2): image not found。
解决方法如下:
1.运行管理员身份,登录mysql
mysql -u root -p 进入mysql
2.修改账户密码加密规则并且更新用户和密码
ALTER USER 'root'@'localhost' IDENTIFIED BY 'password' PASSWORD EXPIRE NEVER; #修改加密规则
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'password'; #更新一下用户的密码
3.刷新
FLUSH PRIVILEGES; #刷新权限
4.重置密码:
alter user 'root'@'localhost' identified by '123456';