We had a weird error yesterday morning. A client emailed us and told us that his Joomla website stopped working all of a sudden, and it was displaying a blank page. We checked his Joomla website and we checked the logs, and it didn’t take us long to discover that the problem was with the MySQL database server powering the client’s Joomla website. So, we ssh’d to the server and then we tried to restart MySQL using the following command:
/etc/init.d/mysql restart
But it didn’t work. What was odd is that it did stop the MySQL server (which wasn’t really technically running), but it threw the following error when trying to start it again:
The server quit without updating PID file
We wanted to fix this problem quickly (at the request of the client, as the website was down), and restarting MySQL from within WHM seemed to be the quickest solution. So, we tried to login to WHM, but, to our surprise, WHM was down. We felt we were on to something, we just didn’t know what it was!
We thought, OK, this might be because MySQL is down. So, we researched the MySQL problem a bit, and we discovered that we may solve the problem if we delete the ib_logfiles from the /var/lib/mysql folder and then restart MySQL, and so we did that (we moved the files to another location; we didn’t delete them). That didn’t solve the problem, but, this time MySQL threw a different error: it complained about disk space not being enough.
We quickly checked the disk space using the df -m shell command, and, you’ve guessed it, the disk space was full in the main partition. We deleted some temporary files, backup files, etc…, which quickly reduced the main disk usage in the main partition to about 68%. We attempted to restart MySQL and this time it worked! Hooray!
We hope you found this post useful. If you are having the same problem, where MySQL unexpectedly stops working, then it might be that your disk is full. If that’s not the case, or if you need help with implementing the fix, then please contact us. Our fees are affordable, our work is professional, and we are always dedicated to serving our clients!