Navicat for MySQL连接出错:1251

平台:window10 x64+mysql-8.0.15-winx64+navicat_trial_11.1.20.0(PatchNavicat破解)

错误提示:1251-Client does not support authentication protocol requested by server; consider upgrading MySQL client

解决步骤:

 

用管理员身份打开cmd,

1.输入"mysql -u root -p [-h locahost -P 3306]"(中括号内是默认内容)回车输入root用户密码(初次安装mysql的要求更改后输入的密码)进入MySQL客户端,然后:

2.然后输入:alter user root@localhost identified by 'password' password expire never;    #修改加密规则

3.然后输入:alter user root@localhost identified with mysql_native_password by 'password';  #更新一下用户的密码

4.最后输入:flush privileges;   #刷新权限

如下:

 

mysql> alter user root@localhost identified by 'password' password expire never;

mysql> alter user root@localhost identified with mysql_native_password by 'password';

mysql> flush privileges;

 

其中,"password"是root用户密码。
此时,Navicat可以连接成功,

附:Navicat连接属性-例如:

连接名:wang

主机名或IP地址:localhost

端口号:3306

用户名:root

密码:password

 

posted on 2019-03-23 10:26  Alliswell_WP  阅读(430)  评论(0编辑  收藏  举报

导航