Sometime, as sysadmin we need export “Show Processlist;
” in mysql prompt mode. This easiest method mysql export show processlist.
As usual, for showing processlist we just type “show processlist;
” in mysql. But for analyzed and troubleshooting time query we need to export it to another file.
mysql -u root -p -e "show processlist" > /srv/name-file-export.txt
Just it, is very simple right? ๐