How sleepy is your MySQL serve …

How sleepy is your MySQL server?
Here’s a simple way to find out:

$ mysqladmin pro \
| awk '/Sleep/ {a+=$12} END {print a/NR}' \
| sed 's/\.[0-9]*$//'

This will print out a single figure, the average time sleeping MySQL processes spend asleep.
If that figure is high then maybe it’s time to follow some of the hints Jeremy posted, and linked to below and reduce the number of idle processes on your server!


Leave Your Comment

Your email will not be published or shared. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>


Holy Shmoly! is Stephen Fry proof thanks to caching by WP Super Cache