Noticed MySQL server CPU was running at almost 100%, checked process list, etc. nothing unusual. Turned to Google and found the issue + solution:
http://blog.mozilla.org/it/2012/06/30/m ... d-the-fix/
Basically, UTC has to compensate for the slowing rotation of the earth due to tidal changes by adding a leap second, MySQL doesn't like this. After stopping ntp, running date -s "`date`" and restarting ntp, MySQL CPU came back to normal within 5 mins.
Hopefully this will help someone else fix the problem quickly.
MySQL High CPU?
Re: MySQL High CPU?
we've been lucky in that we've seen no probs on any of our systems. I was expecting at least one to go nuts, and if not a system then something with an embedded linux and ntpd (e.g. 10+ wifi access points).
--------------------------------
<advert>
If you want to rent a UK-based VPS that comes with friendly advice and support from a fellow ART fan, please get in touch.
</advert>
<advert>
If you want to rent a UK-based VPS that comes with friendly advice and support from a fellow ART fan, please get in touch.
</advert>
Re: MySQL High CPU?
We just had MySQL causing high CPU.
So basically, would something like
I only reached this thread after we had restarted our server.
It wasn't so clear what the cause was, apart from the fact it's MySql and issues with system time.
Is it possible for some process - perhaps an activity on a hosted domain to have triggered this?
If so, is there a log I should be looking?
Pretty sure it's not in /var/ossec/logs/alerts/alerts.log
Choji
So basically, would something like
supposed to fix it, when it happens?date -s 'date -u'
I only reached this thread after we had restarted our server.
It wasn't so clear what the cause was, apart from the fact it's MySql and issues with system time.
Is it possible for some process - perhaps an activity on a hosted domain to have triggered this?
If so, is there a log I should be looking?
Pretty sure it's not in /var/ossec/logs/alerts/alerts.log
Choji
-
- Atomicorp Staff - Site Admin
- Posts: 8355
- Joined: Wed Dec 31, 1969 8:00 pm
- Location: earth
- Contact:
Re: MySQL High CPU?
Theres no log for that exactly, its just something you observe. That being said, have you observed it?
Re: MySQL High CPU?
It was visible that using the 'top' command that mysql (command mysqld) was using up CPU percentage.
Other than that I saw as I tried to get on the plesk control page, some "ERROR: Zend_Db_Table_Row_Exception".
Of course, I wasn't able to go into any domains we hosted.
Everything was slow on command line and eventually the network connection was interrupted and I couldn't get back in, at which point I had to restart the server.
Anything I should have checked?
Other than that I saw as I tried to get on the plesk control page, some "ERROR: Zend_Db_Table_Row_Exception".
Of course, I wasn't able to go into any domains we hosted.
Everything was slow on command line and eventually the network connection was interrupted and I couldn't get back in, at which point I had to restart the server.
Anything I should have checked?
-
- Atomicorp Staff - Site Admin
- Posts: 8355
- Joined: Wed Dec 31, 1969 8:00 pm
- Location: earth
- Contact:
Re: MySQL High CPU?
mysqltuner is a good place to start there