Check high CPU usage on Apache [dump to file]

Posted one year ago

mysql -e "show full processlist\G" > /root/processlist-`date +%F-%T`.txt

This will dump the query list to a file in /root beginning with processlist, with the date and time, ending in txt.