数据库锁表问题

时间:2019-07-07 12:19:14   收藏:0   阅读:80
-- 查询数据库最大连接数

show variables like "max_connections";
-- 
show full processlist;

show processlist;


select *from performance_schema.events_statements_current;

-- 查询上锁的语句
SELECT * FROM information_schema.innodb_trx;

-- 锁等待查询
select * from information_schema.innodb_lock_waits G;

select * from information_schema.innodb_locks G;

找到锁表的语句直接kill掉该进程ID

原文:https://www.cnblogs.com/gcixx/p/11145434.html

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!