Error starting mySQL: pid-file quit without updating file
I'm getting the following error in Centos 6.5 when trying to start mySQL:
ERROR! Manager of pid-file quit without updating file
How do I resolve this?
1 Reply
This is a fairly generic error message that can have several potential solutions. I would recommend the following steps to attempt to resolve this. Please note that I am assuming you are running these commands as root. If not, please use sudo as necessary:
- Check to see if MySQL is already running.
ps -aux | grep mysql
If mySQL is running, you'll need to kill the processes by hand:
kill -9 PID // where PID is the process ID of the MySQL processes.
- Check that /var/lib/mysql/ is owned by mysql
ls -la /var/lib/mysql
If this directory is not owned by mysql, or your user for mysql, you'll want to change it.
chown mysql:mysql -R /var/lib/mysql
- Take backup of mysql.sock file and remove it. To achieve this, fire following commands:
cp /var/lib/mysql.sock /var/lib/mysql.sock_bkp
rm -rf /var/lib/mysql.sock
Now try to start mySQL and check its status
service mysqld start
service mysqld status
Check for error files in /var/lib/mysql/ These files end in .err
You can try to remove this files, and then restart MySQL using the above commands.Check for any changes to /etc/my.cnf Ideally, before making changes to this file, you would have made a backup. Try restoring your previous changing and starting MySQL again.
Sometimes MySQL has trouble writing to the ib_logfile, which can prevent it from starting. Make a backup, remove the ib_logfile, and then start MySQL again using the following commands:
cd /var/lib/mysql
mv ib_logfile0 ib_logfile0.bak
mv ib_logfile1 ib_logfile1.bak
mv /var/lib/mysql/ib_logfile* /tmp/
service mysqld start