Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How can I re-create "mysql.sock" file?

Status
Not open for further replies.

DeepDiverMom

Programmer
Jul 28, 2003
122
US
When I attempt to connect to my MySQL instance, I have been receiving the error:

"ERROR 2002: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)"

I checked and there is no "mysql.sock" file in the directory "/var/lib/mysql" where it should be.

How can I re-create the mysql.sock file?
 
I believe the file is created when the mysql server is started. Restart the server and if the file is not where you expect it to be try looking for it using find. If you cannot find it, there is something wrong - look through error logs.
 
That's the normaly place. Check my.cnf and see if it's specifying it somewhere else.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top