Could not connect to MySQL 4.1+ using old insecure authentication Could not connect to MySQL 4.1+ using old insecure authentication php php

Could not connect to MySQL 4.1+ using old insecure authentication


"SET PASSWORD" is deprecated in MySQL server 5.7.6.

The syntax to be followed for servers below 5.7.6 is,

SET PASSWORD [FOR user] = password_optionpassword_option: {    PASSWORD('auth_string')  | OLD_PASSWORD('auth_string')  | 'hash_string'}

The syntax to be followed for servers 5.7.6 and above is,

SET PASSWORD [FOR user] = password_optionpassword_option: {    PASSWORD('auth_string')  | 'auth_string'}

Also refer-> http://dev.mysql.com/doc/refman/5.7/en/set-password.html


Please try this solution

http://laravel.io/forum/04-16-2014-solving-mysqlnd-cannot-connect-to-mysql-41

As per the solution you just need to set the password again and specify that it be saved in the new format.

mysql> SET @@session.old_passwords = 0;Query OK, 0 rows affected (0.00 sec)SET PASSWORD FOR 'existinguser'@'localhost' = PASSWORD('existingpass');Query OK, 1 rows affected (0.00 sec);