mysql 问题全集
登陆报错问题:
问题现象:
[root@node02 ~]# mysql -uroot -p123 -h127.0.0.1
ERROR 2059 (HY000): Authentication plugin 'caching_sha2_password' cannot be loaded: /usr/lib64/mysql/plugin/caching_sha2_password.so: cannot open shared object file: No such file or directory
解决方法:
1、#ALTER USER 'root'@'%' IDENTIFIED WITH mysql_native_password BY 'root'; //在mysql中执行后即可解决!
2、则需要在my.ini的[mysqld]下添加一行:
default_authentication_plugin = mysql_native_password
在重新初始化MySQL服务即可!!!