SHOW FULL PROCESSLIST; #线程分析 SELECT * FROM information_schema.innodb_trx; #查询 正在执行的事务 SHOW OPEN TABLES WHERE in_use >0 OR name_locked >0; #查询 锁定中的表 SHOW GLOBAL STATUS LIKE '%lock%'; SHOW VARIABLES LIKE '%query_cache%'; SHOW GLOBAL VARIABLES LIKE '%timeout'; SHOW VARIABLES LIKE '%max_connections%';