[Techtalk] at wit's end with PHP to MySQL

Tjorva tjorva at dystopic.org
Thu Jan 31 13:22:49 EST 2002

>To help me develop PHP scripts, I installed Apache and MySQL 
>using the RPMs that came with RedHat. I built the PHP RPM from 
>source files.

>Apache and PHP works together, but when I try to use PHP to 
>connect to MySQL, I get the error message "Can't connect to local 
>MySQL server on socket /tmp/mysql.sock"

I had a similar problem when I installed MySQL on 
RH 7.0 some time ago.
I had made the MySQL username and password correct but
still got the mysql.sock error.

My question is, have you looked at the permission and the 
owner of the file. In my case mysql.sock had owner 'root' 
and it should be 'mysql'.
Also check other files that belong to MySQL, they should all
have mysql as owner.


More information about the Techtalk mailing list