Maatkit’s
mk-loadavg
tool is a helpful way to
gather information about infrequent conditions on your database
server (or any other server, really). We wrote it at Percona to
help with those repeated cases of things like “every two weeks,
my database stops processing queries for 30 seconds, but it’s not
locked up and during this time there is nothing happening.”
That’s pretty much impossible to catch in action, and these
conditions can take months to resolve without the aid of good
tools.
In this blog post I’ll illustrate a very simple usage of
mk-loadavg
to help in solving a much smaller
problem: find out what is happening on the database server during
periods of CPU spikes that happen every so often.
First, set everything up.
- Start a screen session: …