找回密码
 立即注册

QQ登录

只需一步,快速开始

xiaoyu0699

注册会员

12

主题

28

帖子

182

积分

注册会员

积分
182
xiaoyu0699
注册会员   /  发表于:2023-11-22 11:31  /   查看:640  /  回复:3
1金币
提示:
[color=rgba(0, 0, 0, 0.88)]无法连接到数据库。

[color=rgba(0, 0, 0, 0.88)]Authentication method 'caching_sha2_password' failed. Either use a secure connection, specify the server's RSA public key with ServerRSAPublicKeyFile, or set AllowPublicKeyRetrieval=True.


环境:mysql8  winserver2022    服务器和数据库是一台机子

Navicat  可以正常访问  
ForguncyServer提示 “caching_sha2_password” 密码验证方式错误。

最佳答案

查看完整内容

也可以给配置文件添加下面一条记录,因为mysql从8开始,新创建的用户全部都使用新的验证方式了 [mysqld] default_authentication_plugin=mysql_native_password

3 个回复

倒序浏览
最佳答案
最佳答案
天之云活字格认证
中级会员   /  发表于:2023-11-22 11:31:26
来自 3#
也可以给配置文件添加下面一条记录,因为mysql从8开始,新创建的用户全部都使用新的验证方式了
[mysqld]
default_authentication_plugin=mysql_native_password

评分

参与人数 1金币 +5 收起 理由
Shawn.Liu + 5 赞一个!

查看全部评分

回复 使用道具 举报
xiaoyu0699
注册会员   /  发表于:2023-11-22 11:37:20
2#
搞定了

没开权限  %

Navicat 和 ForguncyServer 不是一个账号!


评分

参与人数 1金币 +5 收起 理由
Shawn.Liu + 5 赞一个!

查看全部评分

回复 使用道具 举报
Shawn.Liu活字格认证
超级版主   /  发表于:2023-11-22 15:28:56
4#
xiaoyu0699 发表于 2023-11-22 11:37
搞定了

没开权限  %

好的大佬,收到
回复 使用道具 举报
您需要登录后才可以回帖 登录 | 立即注册
返回顶部