Skip to content

Instantly share code, notes, and snippets.

@kodie
Created August 21, 2020 17:51
Show Gist options
  • Save kodie/909a09afeebbf38c2961a2b77b6be0b2 to your computer and use it in GitHub Desktop.
Save kodie/909a09afeebbf38c2961a2b77b6be0b2 to your computer and use it in GitHub Desktop.
A MySQL command to kill all processes
# Run this on a MySQL server and it will echo out a command for you to copy, paste, and run to kill all currently running MySQL processes
SELECT GROUP_CONCAT(CONCAT('KILL ',id,';') SEPARATOR ' ') 'Paste the following query to kill all processes' FROM information_schema.processlist WHERE user<>'system user'\G
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment