Mysql 8.0 1251 client does no support authentic的错误解决方式

报错弹框:

mysqlclient命令:

USE mysql; 
ALTER USER ‘root’@’localhost’ IDENTIFIED WITH mysql_native_password BY ‘mysql’; 
FLUSH PRIVILEGES;

解决方式:

1.查看用户信息

select host,user,plugin,authentication_string from mysql.user;

插入截图: 

Mysql 8.0 1251 client does no support authentic的错误解决方式_第1张图片 

备注: host为 % 表示不限制ip    localhost表示本机使用    plugin非mysql_native_password 则需要修改密码。

修改用户密码:

更新user为root,host为% 的密码为 mysql

ALTER USER 'root'@'%' IDENTIFIED WITH mysql_native_password BY 'mysql';

更新user为root,host为localhost 的密码为mysql

ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'mysql;

处理结果: 

Mysql 8.0 1251 client does no support authentic的错误解决方式_第2张图片

最终: 

 Mysql 8.0 1251 client does no support authentic的错误解决方式_第3张图片

你可能感兴趣的:(Mysql 8.0 1251 client does no support authentic的错误解决方式)