Wednesday, April 6, 2016

pt-stalk

Another extremely useful tool for troubleshooting and gathering forensic data on MySQL database servers is pt-stalk from the Percona Toolkit. It can run in the background and wait for a certain threshold to occur and then collect useful information about what was going on with the MySQL instances and the Linux server when the threshold was passed. This will help to find sick MySQL servers. 

Box.com has made a GUI tool based off of pt-stalk called "RainGaguge" which I also like (it hasn't seen much love in a coupe years though).  

Here are a couple examples or running pt-stalk using different variables to monitor:

pt-stalk --notify-by-email=me@me.com --function status --variable Threads_connected --threshold 300 --sleep=60 --daemonize --dest=/tmp/ptstalk/ --user=USER --password=xxxxxxx

pt-stalk --notify-by-email=me@me.com --function status --variable Threads_running --threshold 50 --sleep=60 --daemonize --dest=/tmp/ptstalk/ --user=USER --password=xxxxxxx

No comments:

Post a Comment