I have now a new MabBook with 10.8 and I am trying to set up all the Apache&MySQL etc. Apache successfully runs including vhosts.
in my /etc/hosts I have all the local hosts set including 127.0.0.1 localhost etc.
when I try to coennct to one of my local vhost, e.g. alpensonne, I can connect to MySQL without any troubles. if I try to have the MySQL host to be localhost, I get the follwoing error:
Database connection error (2): Could not connect to MySQL.
I know the error(2) means username or password incorrect, but they are fine. If I connect with
mysql -u root
SELECT password,host FROM user where user='root';
also I have just done to be double sure:
SET PASSWORD FOR 'root'@'localhost' = '';
Is it possible that localhost uses a different mysql socket? maybe it then tries to connect to a different mysql?
I hope someone can help me.