Snow Leopard – Cannot connect to MySQL 4.1+ using old authentication

Snow Leopard upgraded php to 5.3, this means that passwords have to be changed – usually via SET password FOR ‘user’@'host’ = PASSWORD( ‘password’ ). This is fine, and can be verified by SELECT LENGTH( password ), user FROM mysql.user. The result should be 41.

I had inadvertently enabled old_password=1 in /etc/my.cnf, this caused both PASSWORD and OLD_PASSWORD to return the same value. To fix this, simply comment out the old_password=1 line in my.cnf and restart mysqld.

Hopefully this saves someone a few dozen google searches.

  1. No comments yet.

  1. No trackbacks yet.