status_by_host 详解

Posted by 道行尚浅 on October 25, 2021

系统表介绍

status_by_host 按主机汇总状态信息

列名 含义
HOST 客户端IP
VARIABLE_NAME 变量名
VARIABLE_VALUE 变量值

实例


mysql> select * from  status_by_host ;
+-----------+-------------------------------+----------------+
| HOST      | VARIABLE_NAME                 | VARIABLE_VALUE |
+-----------+-------------------------------+----------------+
| NULL      | Bytes_received                | 164            |
| NULL      | Bytes_sent                    | 157            |
| NULL      | Com_stmt_reprepare            | 0              |
| NULL      | Created_tmp_disk_tables       | 0              |
| NULL      | Created_tmp_tables            | 0              |
| NULL      | Handler_commit                | 0              |
| NULL      | Handler_delete                | 0              |
| NULL      | Handler_discover              | 0              |
| NULL      | Handler_external_lock         | 0              |
| NULL      | Handler_mrr_init              | 0              |
| NULL      | Handler_prepare               | 0              |
| NULL      | Handler_read_first            | 0              |
| NULL      | Handler_read_key              | 0              |
| NULL      | Handler_read_last             | 0              |
| NULL      | Handler_read_next             | 0              |
| NULL      | Handler_read_prev             | 0              |
| NULL      | Handler_read_rnd              | 0              |
| NULL      | Handler_read_rnd_next         | 0              |
| NULL      | Handler_rollback              | 0              |
| NULL      | Handler_savepoint             | 0              |
| NULL      | Handler_savepoint_rollback    | 0              |
| NULL      | Handler_update                | 0              |
| NULL      | Handler_write                 | 0              |
| NULL      | Max_execution_time_exceeded   | 0              |
| NULL      | Max_execution_time_set        | 0              |
| NULL      | Max_execution_time_set_failed | 0              |
| NULL      | Opened_table_definitions      | 0              |
| NULL      | Opened_tables                 | 0              |
| NULL      | Questions                     | 0              |
| NULL      | Select_full_join              | 0              |
| NULL      | Select_full_range_join        | 0              |
| NULL      | Select_range                  | 0              |
| NULL      | Select_range_check            | 0              |
| NULL      | Select_scan                   | 0              |
| NULL      | Slow_queries                  | 0              |
| NULL      | Sort_merge_passes             | 0              |
| NULL      | Sort_range                    | 0              |
| NULL      | Sort_rows                     | 0              |
| NULL      | Sort_scan                     | 0              |
| NULL      | Table_open_cache_hits         | 0              |
| NULL      | Table_open_cache_misses       | 0              |
| NULL      | Table_open_cache_overflows    | 0              |
| localhost | Bytes_received                | 3537           |
| localhost | Bytes_sent                    | 185067         |
| localhost | Com_stmt_reprepare            | 0              |
| localhost | Created_tmp_disk_tables       | 2              |
| localhost | Created_tmp_tables            | 4              |
| localhost | Handler_commit                | 0              |
| localhost | Handler_delete                | 0              |
| localhost | Handler_discover              | 0              |
| localhost | Handler_external_lock         | 11             |
| localhost | Handler_mrr_init              | 0              |
| localhost | Handler_prepare               | 0              |
| localhost | Handler_read_first            | 2              |
| localhost | Handler_read_key              | 2              |
| localhost | Handler_read_last             | 0              |
| localhost | Handler_read_next             | 0              |
| localhost | Handler_read_prev             | 0              |
| localhost | Handler_read_rnd              | 0              |
| localhost | Handler_read_rnd_next         | 434            |
| localhost | Handler_rollback              | 0              |
| localhost | Handler_savepoint             | 0              |
| localhost | Handler_savepoint_rollback    | 0              |
| localhost | Handler_update                | 0              |
| localhost | Handler_write                 | 92             |
| localhost | Max_execution_time_exceeded   | 0              |
| localhost | Max_execution_time_set        | 0              |
| localhost | Max_execution_time_set_failed | 0              |
| localhost | Opened_table_definitions      | 0              |
| localhost | Opened_tables                 | 87             |
| localhost | Questions                     | 100            |
| localhost | Select_full_join              | 0              |
| localhost | Select_full_range_join        | 0              |
| localhost | Select_range                  | 0              |
| localhost | Select_range_check            | 0              |
| localhost | Select_scan                   | 10             |
| localhost | Slow_queries                  | 0              |
| localhost | Sort_merge_passes             | 0              |
| localhost | Sort_range                    | 0              |
| localhost | Sort_rows                     | 0              |
| localhost | Sort_scan                     | 0              |
| localhost | Table_open_cache_hits         | 8              |
| localhost | Table_open_cache_misses       | 87             |
| localhost | Table_open_cache_overflows    | 0              |
+-----------+-------------------------------+----------------+
84 rows in set (0.00 sec)