MySQL Forums
Forum List  »  Install & Repo

Re: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
Posted by: Lynn Etheredge
Date: September 24, 2008 09:46AM

$ mysql
Warning: World-writable config file '/etc/my.cnf' is ignored
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)

so I changed my /etc/my.cnf file to

[mysqld]
datadir=/var/lib/mysql
socket=/tmp/mysql.sock

[client]
socket=/tmp/mysql.sock
# Default to using old password format for compatibility with mysql 3.x
# clients (those using the mysqlclient10 compatibility package).
#old_passwords=1

now I am getting the following errors.
$ mysql
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
$ mysqld_safe
Starting mysqld daemon with databases from /var/lib/mysql
/usr/bin/mysqld_safe: line 380: /var/lib/mysql/something.com.err: No such file or directory
/usr/bin/mysqld_safe: line 388: /var/lib/mysql/something.com.err: No such file or directory
STOPPING server from pid file /var/run/mysqld/mysqld.pid
tee: /var/lib/mysql/something.com.err: Permission denied
080922 16:06:44 mysqld ended
tee: /var/lib/mysql/something.com.err: Permission denied

I have looked through the posts on this issue and haven't found a solution that I thought would fix my problem. Please help. Thank you.

Options: ReplyQuote


Subject
Written By
Posted
January 08, 2009 02:01PM
Re: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
September 24, 2008 09:46AM
April 15, 2009 11:56AM
October 21, 2009 06:18PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.