Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

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 am not able to start MySQL , i am gettting this error

[root@server scripts]# service mysql start
Starting MySQL.The server quit without updating PID file (/[FAILED]mysql/

what should i do

I dont have any my.cnf file anywhere

only have these

share|improve this question
what error you are getting in mysql error log tail 100f /var/log/mysqld.log ? – Abhishek Anand Amralkar Jul 17 '13 at 5:05
up vote 2 down vote accepted

In CentOS you need to copy /usr/share/doc/MySQL-server-5.6.10/my-default.cnf to /etc/my.cnf and you have to make changes in my.cnf as per your server configuration,after every changes in my.cnf to get reflect you need to restart you mysql server.

It seems you have issue with you permission on mysql datadir. Run below command


This command will check your mysql configuration and find out the errors . Once this is done

  chown -R mysql:mysql /path to your mysql data dir ( default is /var/lib/mysql)

  service mysql restart
share|improve this answer
I had the error that my /tmp permission gets changed , i have made that 777 an dnow that worked. Can i still now do that mysql_install_db. because i think i am currently using default conf file – MOtaro Site Jul 17 '13 at 5:52
if mysql is working for you and you are not in mood to play around it with than you can leave it. – Abhishek Anand Amralkar Jul 17 '13 at 5:53
But i want to chnage the default config and want that so that mysql should write pid in different folder not in /tmp folder – MOtaro Site Jul 17 '13 at 6:02
So copy /usr/share/doc/MySQL-server-5.6.10/my-default.cnf to /etc as my.cnf and define your own custom paramaters for mysql . – Abhishek Anand Amralkar Jul 17 '13 at 6:14
i checked from here but could not find pid_file parameter there. – MOtaro Site Jul 17 '13 at 6:30

I had this same issue on CentOS 6. Abhishek Anand Amralkar has a good suggestion because the /etc/my.cnf installed by CentOS on my system (due to mysql-libs as an dependency package installed by anaconda) had the following:

# Disabling symbolic-links is recommended to prevent assorted security risks


The pid-file parameter was referencing a directory and file that did not exist on my system and even if it did, the mysql:mysql user:group needs to be granted permissions to edit it.

So the bottom-line is make sure you know where your real my.cnf file is (cd / ; nice find . -name "my.cnf"), that it is the actual one that mysql is using when it runs, and that it has the correct configuration for the installation you created. I think a lot of CentOS users are getting tripped up by this default my.cnf in /etc.

A quick solution is to simply:

mv /etc/my.cnf /etc/my.cnf.old
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.