[Hien Duy Nguyen <[EMAIL PROTECTED]>]
> From:             [EMAIL PROTECTED]
> Operating system: RH7.1
> PHP version:      4.0 Latest CVS (03/05/2001)
> PHP Bug Type:     MySQL related
> Bug description:  can't make connection to Mysql DB
> Warning: MySQL Connection Failed: Can't connect to local MySQL server
> through socket '/var/lib/mysql/mysql.sock' (111) in
> /home/hdn/public_html/test.html on line 11
> Couldn't connect to MySQL
> Mysql server is up and running, I can connect to it with shell command.

The MySQL client that comes with PHP has a different default mysql
socket configured than the RedHat-installed MySQL.  Run as root:

echo 'ln -s /var/lib/mysql/mysql.sock /tmp/mysql.sock' >> /etc/rc.d/rc.local
eval `tail -1 /etc/rc.d/rc.local`

 - Stig

  Stig Sæther Bakken <[EMAIL PROTECTED]>
  Fast Search & Transfer ASA, Trondheim, Norway

PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to