mysql: Client does not support authentication protocol requested by server; 解决方案
程序员文章站
2022-03-25 21:11:55
...
/**
使用node.js操作数据库的时候如果遇到
{
code: 'ER_NOT_SUPPORTED_AUTH_MODE',
errno: 1251,
sqlMessage: 'Client does not support authentication protocol requested by server; consider upgrading MySQL client',
sqlState: '08004',
fatal: true
}
这种问题,也可使用下面的命令解决
先检查数据库服务器有没有启动
然后在命令行依次输入以下命令即可重新连接数据库
********' 为新密码,也可以使用旧密码,但是要把下面的命令走一遍
*/
1、use mysql;
2、alter user 'root'@'localhost' identified with mysql_native_password by '********';
3、flush privileges;
上一篇: php二维码程序的实现代码
推荐阅读
-
MYSQL出现" Client does not support authentication "的解决方法
-
MYSQL出现" Client does not support authentication "的解决方法
-
mysql4.1以上版本连接时出现Client does not support authentication protocol问题解决办法
-
mysql 8.0 错误The server requested authentication method unknown to the client解决方法
-
本地安装Mysql后,navicat链接异常:Clinet dose not support authentication protocol request by server ; consider upgrading MySQL client
-
mysql Client does not support authentication protocol requested by server; consider upgrading MySQL
-
解决Navicat连接MySQL时“Client does not support authentication protocol requested by server; consider upgrading MySQL client”的问题
-
MYSQL出现" Client does not support authentication "
-
mysql4.1以上版本连接时出现Client does not support authentication protocol问题解决办法_php技巧
-
连接8.0.15mysql 报错 client does not support authentication protocol requested by server ,consider upgra