Navicat 连接Mysql 8.0以上版本报错1251
Navicat 连接Mysql 8.0以上版本报错1251
1251-Client does not support authentication protocol requested by server;
解决办法: 更改加密方式:
ALTER USER 'root'@'localhost' IDENTIFIED BY 'xxxxxxJ';
set global validate_password.policy=0;
update mysql.user set host = '%' where user = 'root';
set global validate_password.length=4;
ALTER USER 'root'@'%' IDENTIFIED BY 'xxxxxxxJ' PASSWORD EXPIRE NEVER;
ALTER USER 'root'@'%' IDENTIFIED WITH mysql_native_password BY 'xxxxxxxJ';
flush privileges;
create user 'abcd'@'localhost' identified by 'abcdddd';
grant all privileges on dbname.* to 'abcd'@'localhost';