Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have installed mysql and phpmyadmin via, yum. I get the message

#2002 - Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
The server is not responding (or the local server's socket is not correctly configured).

The problem though, is with mysql itself.

# service mysqld start
Redirecting to /bin/systemctl  start mysqld.service
Job failed. See system logs and 'systemctl status' for details.

/var/log/mysql/mysql.log is empty, but I'm unsure where to look next?

Any ideas?

share|improve this question
ps -ef | grep syslog? grep log-error /path/to/my.cnf? – quanta Aug 4 '12 at 14:19
@quanta the log file is /var/log/mysql.log from my.cnf but that file doesn't exist? – Adam Aug 4 '12 at 14:28
touch /var/log/mysql.log && chown mysql:mysql /var/log/mysql.log, restart MySQL to see what does it say. – quanta Aug 4 '12 at 14:39
@quanta still empty, sometimes the service mysqld start command hangs – Adam Aug 4 '12 at 16:07
The log file you should look at is /var/log/messages. – Michael Hampton Aug 4 '12 at 18:04

I remember once I fixed this problem with folowing solution:


yum -enablerepo=remi install mysql-libs mysql.x86_64 mysql-devel.x86_64 mysql-server php-mysql


Mysql -u root -p
share|improve this answer
Thanks, but I'm getting Error getting repository data for remi, repository not found – Adam Aug 4 '12 at 18:31
up vote 0 down vote accepted

I solved this with help from this site, seemed to do the trick.

## Remi Dependency on Fedora 17, 16
rpm -Uvh 
rpm -Uvh

## Fedora 17 ##
rpm -Uvh
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.