MySQL server running, PHP can"t connect
am 08.04.2008 20:23:20 von scorpionbilliHi,
The local mysql server is running on my Macbook. I can access it
through the console client:
$ mysql -u root
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 4
Server version: 5.0.45 MySQL Community Server (GPL)
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql>
But when I launch a PHP script that tries to connect to it, I get an
error:
$link = mysql_connect("localhost", "root", "");
Warning: mysql_connect(): Can't connect to local MySQL server through
socket '/var/mysql/mysql.sock' (2)
Any ideas what's going on?