2

I'm having a problem while trying to remotely connect to my database server from my other server. I receive the following error when i try to make a connection:

ERROR 2049 (HY000): Connection using old (pre-4.1.1) authentication protocol ref used (client option 'secure_auth' enabled)

I've checked the secure_auth option on the database server, and it is off, and my client seems to have this option activated as the message says. Is there any way to fix this by only modifying the settings on the database server?

4

2 回答 2

1

我遇到了同样的问题,这终于对我有用:

我卸载了我的本地 mysql 客户端(我运行的是 MySQL 5.6)并安装了 MySQL 5.5,然后重新启动了我的计算机。

我在我的 Mac 上使用 Homebrew,所以我这样做了:

brew uninstall mysql
brew tap homebrew/versions
brew install mysql55
brew link --force mysql55
ln -sfv /usr/local/opt/mysql55/*.plist ~/Library/LaunchAgents
launchctl unload ~/Library/LaunchAgents/homebrew.mxcl.mysql55.plist
launchctl load ~/Library/LaunchAgents/homebrew.mxcl.mysql55.plist

显然,我的 5.6 客户端不想使用我公司服务器使用的安全性较低的密码,即使我曾尝试在本地关闭 secure_auth。MySQL 5.5 不会抱怨密码安全性较低,但 5.6 会。

于 2014-04-08T18:06:41.890 回答
0

发生这种情况是因为您的用户帐户的密码使用了古老的散列算法。使用新式哈希创建一个新用户,现在可以毫无问题地使用该新用户。在这里查看相关信息

于 2013-11-13T10:10:24.430 回答