Forum Moderators: open

Message Too Old, No Replies

ERROR 2002: Can't connect to local MySQL server through socket

mysql socket problem

         

jpl80

3:41 pm on Jan 10, 2006 (gmt 0)

10+ Year Member



I cannot get MySQL working. Can someone please help? I have changed permissions on the /var/lib/msql directory and I still can't get it started.

Running Suse Linux Enterprise Server 9

# mysql -V
mysql Ver 12.22 Distrib 4.0.18, for suse-linux (i686)

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

I have checked /var/lib/mysql and there is no mysql.sock.

my.cnf
-------------------------------------
# The following options will be passed to all MySQL clients
[client]
password = password
port = 3306
socket = /var/lib/mysql/mysql.sock

# Here follows entries for some specific programs

# The MySQL server
[mysqld]
port = 3306
socket = /var/lib/mysql/mysql.sock
skip-locking
key_buffer = 16M
max_allowed_packet = 1M
table_cache = 64
sort_buffer_size = 512K
net_buffer_length = 8K
myisam_sort_buffer_size = 8M

mack

4:48 am on Jan 11, 2006 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



Was the Mysql server workign then stopped, or have you never had it running?

If the latter is the case you may want to try

mysql_install_db

then

Safe_mysqld --User=root &

Mack.

jpl80

1:40 pm on Jan 11, 2006 (gmt 0)

10+ Year Member



I simply uninstalled MySQL then reinstalled the using the client and server rpm and everything works fine. Thanks for the reply.