If you have many connections, use a standard SELECT to find specific slow queries:
This will terminate the query with ID 123 .
Tells you if it's "Sending data," "Locked," or "Waiting for table metadata lock". Info: The actual SQL text being executed.
The output reveals:
MySQL offers two variants:
Once you've identified the query you want to kill, you can terminate it with: