mysql - How to fix java.sql.SQLException: Server is running in --secure-auth mode, but 'user'@'host' has a password in the old format; (...)? -
after upgrading mysql 5.1 5.6, trying start jboss failed exception:
java.sql.sqlexception: server running in --secure-auth mode, 'user'@'localhost' has password in old format; please change password new format
how fix issue?
first, need locate my.cnf
file, should @ following path:
mysql server 5.6\my.cnf
next find line says old_passwords=0
, change old_passwords=1
. tell mysql use password hashing algorithm compatible going way version 4.0, covers use case.
now when start server, password problem should go away. if want upgrade passwords latest version, can use set password
each user with flag old_passwords=0
.
please keep in mind mysql upgraded password algorithm security reasons, should not view setting old_passwords=1
long term solution.
see here more information.