命令行连接mysql时出现Authentication plugin 'caching_sha2_password' cannot be loaded: 找不到指定的模块。
- 通过如下命令进入数据库
mysql -uroot -p
2.之后执行如下命令
ALTER USER 'root'@'localhost' IDENTIFIED BY 'abc@123' PASSWORD EXPIRE NEVER;
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'abc@123';
FLUSH PRIVILEGES;
ALTER USER 'root'@'localhost' IDENTIFIED BY 'abc@123';
FLUSH PRIVILEGES;
将abc@123换成自己的密码
之后关闭命令行,再次连接mysql即可