Skip to content

Instantly share code, notes, and snippets.

@xaprb

xaprb/qtt.sh Secret

Created December 14, 2013 19:45
Show Gist options
  • Save xaprb/bce5cd6dffc877f28c8b to your computer and use it in GitHub Desktop.
Save xaprb/bce5cd6dffc877f28c8b to your computer and use it in GitHub Desktop.
Shows Queries, Threads_connected, and Threads_running in incremental format.
#!/bin/sh
mysqladmin ext -i1 | awk '
/Queries/{q=$4-qp;qp=$4}
/Threads_connected/{tc=$4}
/Threads_running/{printf "%5d %5d %5d\n", q, tc, $4}'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment