Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
kill process sleep mysql
mysql -u root -p -e "select concat('KILL ',id,';') into outfile '/var/lib/mysql-files/a.txt' from information_schema.processlist where Command = 'Sleep'"
mysql -u root -p -e "source /var/lib/mysql-files/a.txt"
rm -rf /var/lib/mysql-files/a.txt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment