Skip to content

Instantly share code, notes, and snippets.

@eckelon
Forked from daniDLL/show-queries-real-time
Created November 26, 2019 12:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save eckelon/a72712a7ff66f74e058a468920e92a74 to your computer and use it in GitHub Desktop.
Save eckelon/a72712a7ff66f74e058a468920e92a74 to your computer and use it in GitHub Desktop.
Show executed queries in real time
## Show real-time
watch -n1 'mysql -u root -ppassword --execute="SHOW FULL PROCESSLIST"'
## Show real-time and pipe all info to file
watch -t -n1 '(mysql -u root -ppassword --execute="SHOW FULL PROCESSLIST") | tee -a mysql-process-list.log'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment