欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页

MySql 链接报错“Client does not support authentication protocol requested by server; consider upgradin”

程序员文章站 2022-06-12 22:30:27
...

Navicat 链接 Mysql 提示:

client does not support authentication protocol requested by server,consider upgrading mysql client。

VS Code 链接 Mysql 提示:

client does not support authentication protocol requested by server,consider upgrading mysql client。

解决方法:

修改加密规则为普通模式,默认是严格加密模式

  1. 进入mysql控制面板,输入mysql -uroot -p,输入密码

  2. 在控制面板上依次输入一下内容:
    1). 修改加密规格:

    ALTER USER ‘root’@‘localhost’ IDENTIFIED BY ‘password’ PASSWORD EXPIRE
    NEVER;

    2).更新用户密码:

    ALTER USER ‘root’@‘localhost’ IDENTIFIED WITH mysql_native_password BY
    ‘password’;

    3).刷新权限

    FLUSH PRIVILEGES;

3.输入刚刚修改的密码,再次测试连接即可。

参考:mysql8.0版本 报错:Error: ER_NOT_SUPPORTED_AUTH_MODE: Client does not support authentication protocol…