List:General Discussion« Previous MessageNext Message »
From:Christian Mack Date:June 8 1999 6:46pm
Subject:Re: Mysql Connection failed HELP!
View as plain text  
Ritschie wrote:
> Hi everyone!
> I have just finished installing Apache and PHP3 and MySQL.
> I have compiled PHP3 with the mysql support which should work fine, it
> knows the mysql functions. PHP3 works fine with Apache.
> I have written a test program which selects everything in a table.
> But I have recieved the following error message during mysql_connect().
> Is it possible that the user information in mysql_connect() function is
> wrong?
> The error message:
> ------------------
> Warning: MySQL Connection Failed: Can't connect to local MySQL server
> through socket '/var/lib/mysql/mysql.sock' (111) in
> /home/user/public_html/index.php3 on line 7
> I don't have any mysql.sock files in /var/lib/mysql.
> What is this mysql.sock good for?
> Help me please!
> Thanks!
> Ritschie

Hi Ritschie

Do you have a running MySQL on this machine?
This mysql.sock is used to make a direct socket connection to the MySQL server running on
the same machine as the client.
This sort of connection is faster than connecting via TCP/IP, but is only available within
one machine.

If you don't have a running MySQL server, start one with the "safe_mysqld" script.


Mysql Connection failed HELP!Ritschie8 Jun
  • Re: Mysql Connection failed HELP!Sasha Pachev8 Jun
    • Re: Mysql Connection failed HELP!Ritschie9 Jun
    • Re: Mysql Connection failed HELP!Ritschie10 Jun
  • Re: Mysql Connection failed HELP!Christian Mack8 Jun
    • Re: Mysql Connection failed HELP!Ritschie9 Jun
      • Re: Mysql Connection failed HELP!Christian Mack9 Jun