When i try to start mysql i get this problem RROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run /mysqld/mysqld.sock' (2)

Asked by useLinux

When i try to start mysql i get this problem RROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run /mysqld/mysqld.sock' (2) Ive tried using different versions of mysql AND ubuntu iv tried everything i can. It looks like the .sock file just deletes itself.. :S Why wont it work? Please help.

Question information

Language:
English Edit question
Status:
Answered
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Ralph Janke (txwikinger) said :
#1

Thanks for this question.

Check in your configuration file in /etc/mysql/ if the line

socket = /var/run/mysqld/mysqld.sock

is in both, the client as well as the mysqld section.

I hope this helps

Revision history for this message
useLinux (uselinux-hotmail) said :
#2

Sorry to be such a noob, but what do you mean aswell as in the client ? So its in the mysql.conf it has that mysqld.sock but whats the client?

Revision history for this message
useLinux (uselinux-hotmail) said :
#3

Oh i found it, its in the same config file, yes its all there, but it still doesnt work :(

Revision history for this message
Ralph Janke (txwikinger) said :
#4

Here is the guidance from mysql to this problem:

http://dev.mysql.com/doc/refman/5.0/en/can-not-connect-to-server.html

I presume you try to connect on the same computer, your mysqld database is running.

Can you help with this problem?

Provide an answer of your own, or ask useLinux for more information if necessary.

To post a message you must log in.