Backup restore error

winger

Verified User
Joined
Oct 5, 2004
Messages
183
Location
Rio de Janeiro - Brasil
hello,

I get this error when I try to restore a backup in a new server:

Domain Created Successfully

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

any help to fix that?

thanks!
 
From SSH

Code:
/etc/init.d/mysqld status

If it shows something like:

SUCCESS! MySQL running (1070)

MySQL is at least running, so you might want to check your mysql logs (usually in /var/log/mysqld.log).

If it does not, you could try:

Code:
/etc/init.d/mysqld restart

And try the status step again. If it shows MySQL is running, try adding the domain again.
 
hello,

[root@srv8 /]# /etc/init.d/mysqld status
ERROR! MySQL is not running, but lock exists

[root@srv8 /]# /etc/init.d/mysqld restart
ERROR! MySQL manager or server PID file could not be found!
 
Code:
lsof | grep mysql

In addition, could you post your /etc/my.cnf as an .txt attachement?

You might also want to try and remove the lock

Code:
rm -rf /var/lock/subsys/mysql
 
Last edited:
I just add to the /etc/my.cnf file with the following data:

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

now I get:

[root@srv8 etc]# /etc/init.d/mysqld status
SUCCESS! MySQL running (11425)
 
Back
Top