[GRLUG] Mysql connection problem

Topher topher at wcsg.org
Thu Apr 10 17:35:27 EDT 2008


> I am able to connect to Mysql via command line using mysql client. I am 
> also able to connect to mysql via php if I run those php programs via 
> command line. However when I hit those php pages via the browser it 
> throws the error Can't connect to local MySQL server through socket 
> '/tmp/mysql.sock' (2). Please note that this is the same socket the 
> mysql client tries to connect to the server.

In your php, are you using localhost as the hostname, or an actual 
hostname?


More information about the grlug mailing list