mysql,show processlist,查询一直sending data,影响查询性能

MariaDB [(none)]> show processlist;

+--------+--------+------------------+---------+-------------+---------+---------------+----------------------+--------

| Id     | User   | Host             | db      | Command     | Time    | State         | Info                 | Progre

| 287662 | root   | localhost:41583  | finance | Query       |  665767 | Sending data  | SELECT COUNT(*) FROM `cash_beorder` INNER JOIN `cash_account` ON ( `cash_beorder`.`account_id` = `ca |    0.00


| 287663 | root   | localhost:41626  | finance | Query       |  665766 | Sending data   | SELECT COUNT(*) FROM `cash_beorder` INNER JOIN `cash_account` ON ( `cash_beorder`.`account_id` = `ca |    0.00


| 287664 | root   | localhost:41990  | finance | Query       |  665751 | Sending data   | SELECT COUNT(*) FROM `cash_beorder` INNER JOIN `cash_account` ON ( `cash_beorder`.`account_id` = `ca |    0.00


| 287665 | root    | localhost:42153  | finance | Query       |  665744 | Sending data   | SELECT COUNT(*) FROM `cash_beorder` INNER JOIN `cash_account` ON ( `cash_beorder`.`account_id` = `ca |    0.0


mysql的查询,一直处于sending data状态,查询卡死,影响mysql查询性能,time显示该查询语句一直执行的时间。


解决:杀死相应卡死的查询id

>kill id



你可能感兴趣的:(mysql,show,processlist)