–查看进程id,然后用kill id杀掉进程
show processlist;
SELECT * FROM information_schema.PROCESSLIST;
–查询正在执行的进程
SELECT * FROM information_schema.PROCESSLIST where length(info) >0 ;
//查询是否锁表
show OPEN TABLES where In_use > 0;
//查看被锁住的
SELECT * FROM INFORMATION_SCHEMA.INNODB_LOCKS;
//等待锁定
SELECT * FROM INFORMATION_SCHEMA.INNODB_LOCK_WAITS;
//杀掉锁表进程
kill 12041