25.16 性能架构状态变量
Performance Schema 实现了几个状态变量,这些变量提供有关由于内存限制而无法加载或创建的检测的信息:
mysql> SHOW STATUS LIKE 'perf%';
+-------------------------------------------+-------+
| Variable_name | Value |
+-------------------------------------------+-------+
| Performance_schema_accounts_lost | 0 |
| Performance_schema_cond_classes_lost | 0 |
| Performance_schema_cond_instances_lost | 0 |
| Performance_schema_file_classes_lost | 0 |
| Performance_schema_file_handles_lost | 0 |
| Performance_schema_file_instances_lost | 0 |
| Performance_schema_hosts_lost | 0 |
| Performance_schema_locker_lost | 0 |
| Performance_schema_mutex_classes_lost | 0 |
| Performance_schema_mutex_instances_lost | 0 |
| Performance_schema_rwlock_classes_lost | 0 |
| Performance_schema_rwlock_instances_lost | 0 |
| Performance_schema_socket_classes_lost | 0 |
| Performance_schema_socket_instances_lost | 0 |
| Performance_schema_stage_classes_lost | 0 |
| Performance_schema_statement_classes_lost | 0 |
| Performance_schema_table_handles_lost | 0 |
| Performance_schema_table_instances_lost | 0 |
| Performance_schema_thread_classes_lost | 0 |
| Performance_schema_thread_instances_lost | 0 |
| Performance_schema_users_lost | 0 |
+-------------------------------------------+-------+
有关使用这些变量检查性能架构状态的信息,请参见第 25.7 节“性能模式状态监视”。
性能架构状态变量具有以下含义:
由于行已满,无法将其添加到accountstable 中的次数。
无法加载多少个条件仪 table。
不能创建多少条件仪器实例。
无法在events_statements_summary_by_digesttable 中检测的摘要实例的数量。如果performance_schema_digests_size的值太小,则该值可以为非零。
无法加载多少个文件乐器。
无法打开多少个文件工具实例。
无法创建多少个文件工具实例。
由于行已满,无法将其添加到hoststable 中的次数。
丢失统计信息的索引数。如果performance_schema_max_index_stat的值太小,则该值可以为非零。
由于以下情况,“丢失”或未记录多少事件:
-
事件是递归的(例如,awaitA 导致对 B 的 await,从而导致对 C 的 await)。
- 嵌套事件堆栈的深度大于实现所施加的限制。
性能架构记录的事件不是递归的,因此此变量应始终为 0.
无法加载存储乐器的次数。
无法在metadata_lockstable 中检测到的元数据锁的数量。如果performance_schema_max_metadata_locks的值太小,则该值可以为非零。
无法加载多少个互斥乐器。
不能创建多少个互斥乐器实例。
丢失统计信息的已存储程序语句的数量。如果performance_schema_max_statement_stack的值太小,则该值可以为非零。
无法在prepared_statements_instancestable 中检测到的准备好的语句数。如果performance_schema_max_prepared_statements_instances的值太小,则该值可以为非零。
统计信息丢失的存储程序数。如果performance_schema_max_program_instances的值太小,则该值可以为非零。
无法加载多少个 rwlock 乐器。
无法创建多少个 rwlock 仪器实例。
发生连接属性截断的连接数。对于给定的连接,如果 Client 端发送连接属性键/值对,其聚合大小大于performance_schema_session_connect_attrs_size系统变量的值所允许的保留存储,则性能架构将截断属性数据并递增Performance_schema_session_connect_attrs_lost。如果该值不为零,则可能希望将performance_schema_session_connect_attrs_size设置为更大的值。
有关连接属性的更多信息,请参见第 25.12.9 节“性能架构连接属性 table”。
无法加载多少个 socket 乐器。
不能创建多少个套接字仪器实例。
无法加载多少台乐器。
无法加载多少个语句工具。
有多少个 table 乐器实例无法打开。如果performance_schema_max_table_handles的值太小,则该值可以为非零。
不能创建多少个 table 工具实例。
丢失锁统计信息的 table 数。如果performance_schema_max_table_lock_stat的值太小,则该值可以为非零。
无法加载多少个螺纹乐器。
threadstable 中无法检测的线程实例数。如果performance_schema_max_thread_instances的值太小,则该值可以为非零。
由于行已满,无法将其添加到userstable 中的次数。