MYSQL出现" Client does not support authentication "的解决方法
程序员文章站
2023-01-03 15:28:39
mysql 帮助:
a.2.3 client does not support authentication protocol
mysql 4.1 and up use...
mysql 帮助:
a.2.3 client does not support authentication protocol
mysql 4.1 and up uses an authentication protocol based on a password hashing algorithm that is incompatible with that used by older clients. if you upgrade the server to 4.1, attempts to connect to it with an older client may fail with the following message:
shell> mysql client does not support authentication protocol requested by server; consider upgrading mysql client
to solve this problem, you should use one of the following approaches:
- upgrade all client programs to use a 4.1.1 or newer client library.
- when connecting to the server with a pre-4.1 client program, use an account that still has a pre-4.1-style password.
- reset the password to pre-4.1 style for each user that needs to use a pre-4.1 client program. this can be done using the
set password
statement and theold_password()
function:mysql> set password for -> 'some_user'@'some_host' = old_password('newpwd');
alternatively, useupdate
andflush privileges
:mysql> update mysql.user set password = old_password('newpwd') -> where host = 'some_host' and user = 'some_user'; mysql> flush privileges;
substitute the password you want to use for ``newpwd'' in the preceding examples. mysql cannot tell you what the original password was, so you'll need to pick a new one. - tell the server to use the older password hashing algorithm:
- start
mysqld
with the--old-passwords
option. - assign an old-format password to each account that has had its password updated to the longer 4.1 format. you can identify these accounts with the following query:
mysql> select host, user, password from mysql.user -> where length(password) > 16;
for each account record displayed by the query, use thehost
anduser
values and assign a password using theold_password()
function and eitherset password
orupdate
, as described earlier.
- start
for additional background on password hashing and authentication, see section 5.5.9 password hashing in mysql 4.1.
推荐阅读
-
MYSQL出现" Client does not support authentication "的解决方法
-
mysql4.1以上版本连接时出现Client does not support authentication protocol问题解决办法
-
mysql Client does not support authentication protocol requested by server; consider upgrading MySQL
-
用root用户登陆PHPmyAdmin出现Client does not support authentication ...
-
解决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
-
nodejs连接mysql报错:Client does not support authentication protocol requested by server; consider upgrad
-
MySQL8.0报错Client does not support authentication protocol requested by server; consider upgrading My