lunes, 20 de marzo de 2017

Solución a cannot connect to MySQL 4.1+ using the old insecure authentication.


How to solve that? /Como resolver ?

SQLSTATE[HY000] [2000] mysqlnd cannot connect to MySQL 4.1+ using the old insecure authentication. Please use an administration tool to reset your password with the command SET PASSWORD = PASSWORD('your_existing_password'). This will store a new, and more secure, hash value in mysql.user. If this user is used in other scripts executed by PHP 5.2 or earlier you might need to remove the old-passwords flag from your my.cnf file 

1- Go to file my.ini (windows) or my.cnf (linux), and go to the line / Ve al archivo my.cnf en linux o a my.ini en windos:
[mysqld]
Set old_passwords to false belongs to the mysqld section, if you can't find it there, just add it:[mysqld]
old_passwords = 0
2- Restart you server/ Reinicia tu servidor.
3-Run that comand / Corre el siguiente comando:
mysql> SHOW VARIABLES LIKE 'old_passwords'
+---------------+-------+| Variable_name | Value |+---------------+-------+| old_passwords | OFF |+---------------+-------+

And old_passwords must appear like OFF.

4-Update your users passwords with :
UPDATE mysql.user SET password= PASSWORD(¨NEW PASSWORD¨);

And you password must look like :
*6BB4837EB74329105EE4568DDA7DC67ED2CA2AD9

Solved/ Resuelto

No hay comentarios.:

Publicar un comentario