22.12 Performance Schema System Variables
성능 스키마 구성 정보를 제공하는 일부 시스템 변수를 구현하고 있습니다.
mysql> SHOW VARIABLES LIKE 'perf%';
+--------------------------------------------------------+---------+
| Variable_name | Value |
+--------------------------------------------------------+---------+
| performance_schema | ON |
| performance_schema_accounts_size | 100 |
| performance_schema_digests_size | 200 |
| performance_schema_events_stages_history_long_size | 10000 |
| performance_schema_events_stages_history_size | 10 |
| performance_schema_events_statements_history_long_size | 10000 |
| performance_schema_events_statements_history_size | 10 |
| performance_schema_events_waits_history_long_size | 10000 |
| performance_schema_events_waits_history_size | 10 |
| performance_schema_hosts_size | 100 |
| performance_schema_max_cond_classes | 80 |
| performance_schema_max_cond_instances | 1000 |
| performance_schema_max_file_classes | 50 |
| performance_schema_max_file_handles | 32768 |
| performance_schema_max_file_instances | 10000 |
| performance_schema_max_mutex_classes | 200 |
| performance_schema_max_mutex_instances | 1000000 |
| performance_schema_max_rwlock_classes | 30 |
| performance_schema_max_rwlock_instances | 1000000 |
| performance_schema_max_socket_classes | 10 |
| performance_schema_max_socket_instances | 1000 |
| performance_schema_max_stage_classes | 150 |
| performance_schema_max_statement_classes | 165 |
| performance_schema_max_table_handles | 10000 |
| performance_schema_max_table_instances | 1000 |
| performance_schema_max_thread_classes | 50 |
| performance_schema_max_thread_instances | 1000 |
| performance_schema_session_connect_attrs_size | 512 |
| performance_schema_setup_actors_size | 100 |
| performance_schema_setup_objects_size | 100 |
| performance_schema_users_size | 100 |
+--------------------------------------------------------+---------+
성능 스키마 시스템 변수는 명령 행 또는 옵션 파일에서 서버를 시작할 때 설정할 수 많은 런타임에 설정할 수 있습니다. 섹션 22.10 "성능 스키마 옵션 및 변수 참조" 를 참조하십시오. MySQL 5.6.6 이후 성능 스키마는 매개 변수의 일부 값을 그들이 명시 적으로 설정되어 있지 않은 경우, 서버 시작시 자동으로 크기 설정합니다. 자세한 내용은 섹션 22.2.2 "성능 스키마 시작 구성" 을 참조하십시오.
성능 스키마 시스템 변수는 다음과 같은 의미가 있습니다.
performance_schemaCommand-Line Format --performance_schema=#System Variable Name performance_schemaVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type booleanDefault OFFPermitted Values (>= 5.6.6) Type booleanDefault ON이 변수의 값은
ON또는OFF로 성능 스키마가 활성화되어 있는지 여부를 나타냅니다. 기본적으로이 값은 MySQL 5.6.6 이후ON에서 이전에OFF합니다. 서버가 시작될 때이 변수를 값없이 또는 그것을 사용하려면ON또는 1의 값 또는 그것을 해제하는OFF또는 0의 값으로 지정할 수 있습니다.performance_schema_accounts_sizeIntroduced 5.6.3 Command-Line Format --performance_schema_accounts_size=#System Variable Name performance_schema_accounts_sizeVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 10Min Value 0Max Value 1048576Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)Min Value -1 (autosized)Max Value 1048576accounts테이블의 행 수. 이 변수가 0이면 성능 스키마는accounts테이블의 연결 통계를 유지하지 않습니다. 이 변수는 MySQL 5.6.3에서 추가되었습니다.performance_schema_digests_sizeIntroduced 5.6.5 Command-Line Format --performance_schema_digests_size=#System Variable Name performance_schema_digests_sizeVariable Scope Global Dynamic Variable No Permitted Values Type integerDefault -1 (autosized)Min Value -1Max Value 1048576events_statements_summary_by_digest테이블의 최대 행수. 이 변수는 MySQL 5.6.5에서 추가되었습니다. 이 최대를 초과하여 다이제스트를 instrument 수없는 경우 성능 스키마는Performance_schema_digest_lost상태 변수를 증가시킵니다.performance_schema_events_stages_history_long_sizeIntroduced 5.6.3 Command-Line Format --performance_schema_events_stages_history_long_size=#System Variable Name performance_schema_events_stages_history_long_sizeVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 10000Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)events_stages_history_long테이블의 행 수. 이 변수는 MySQL 5.6.3에서 추가되었습니다.performance_schema_events_stages_history_sizeIntroduced 5.6.3 Command-Line Format --performance_schema_events_stages_history_size=#System Variable Name performance_schema_events_stages_history_sizeVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 10Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)events_stages_history테이블의 스레드 당 행. 이 변수는 MySQL 5.6.3에서 추가되었습니다.performance_schema_events_statements_history_long_sizeIntroduced 5.6.3 Command-Line Format --performance_schema_events_statements_history_long_size=#System Variable Name performance_schema_events_statements_history_long_sizeVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 10000Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)events_statements_history_long테이블의 행 수. 이 변수는 MySQL 5.6.3에서 추가되었습니다.performance_schema_events_statements_history_sizeIntroduced 5.6.3 Command-Line Format --performance_schema_events_statements_history_size=#System Variable Name performance_schema_events_statements_history_sizeVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 10Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)events_statements_history테이블의 스레드 당 행. 이 변수는 MySQL 5.6.3에서 추가되었습니다.performance_schema_events_waits_history_long_sizeCommand-Line Format --performance_schema_events_waits_history_long_size=#System Variable Name performance_schema_events_waits_history_long_sizeVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 10000Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)events_waits_history_long테이블의 행 수.performance_schema_events_waits_history_sizeCommand-Line Format --performance_schema_events_waits_history_size=#System Variable Name performance_schema_events_waits_history_sizeVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 10Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)events_waits_history테이블의 스레드 당 행.performance_schema_hosts_sizeIntroduced 5.6.3 Command-Line Format --performance_schema_hosts_size=#System Variable Name performance_schema_hosts_sizeVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 10Min Value 0Max Value 1048576Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)Min Value -1 (autosized)Max Value 1048576hosts테이블의 행 수. 이 변수가 0이면 성능 스키마는hosts테이블의 연결 통계를 유지하지 않습니다. 이 변수는 MySQL 5.6.3에서 추가되었습니다.performance_schema_max_cond_classesCommand-Line Format --performance_schema_max_cond_classes=#System Variable Name performance_schema_max_cond_classesVariable Scope Global Dynamic Variable No Permitted Values Type integerDefault 80조건 instruments의 최대 수.
performance_schema_max_cond_instancesCommand-Line Format --performance_schema_max_cond_instances=#System Variable Name performance_schema_max_cond_instancesVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 1000Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)instrument 된 조건 개체의 최대수.
performance_schema_max_file_classesCommand-Line Format --performance_schema_max_file_classes=#System Variable Name performance_schema_max_file_classesVariable Scope Global Dynamic Variable No Permitted Values Type integerDefault 50파일instrument의 최대 수.performance_schema_max_file_handles열린 파일 객체의 최대 수.Command-Line Format --performance_schema_max_file_handles=#System Variable Name performance_schema_max_file_handlesVariable Scope Global Dynamic Variable No Permitted Values Type integerDefault 32768performance_schema_max_file_handles값은open_files_limit값보다 커야합니다.open_files_limit서버가 지원 가능한 열린 파일 핸들의 최대 수에 영향을performance_schema_max_file_handles는 이러한 파일 핸들 중 instrument 가능한 수에 영향을줍니다.performance_schema_max_file_instancesCommand-Line Format --performance_schema_max_file_instances=#System Variable Name performance_schema_max_file_instancesVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 10000Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)instrument되는 파일 객체의 최대 수.
performance_schema_max_mutex_classesCommand-Line Format --performance_schema_max_mutex_classes=#System Variable Name performance_schema_max_mutex_classesVariable Scope Global Dynamic Variable No Permitted Values Type integerDefault 200상호 배타 락 instrument의 최대 수.
performance_schema_max_mutex_instancesCommand-Line Format --performance_schema_max_mutex_instances=#System Variable Name performance_schema_max_mutex_instancesVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 1000Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)instrument되는 상호 배타 락 객체의 최대 수.
performance_schema_max_rwlock_classesCommand-Line Format --performance_schema_max_rwlock_classes=#System Variable Name performance_schema_max_rwlock_classesVariable Scope Global Dynamic Variable No Permitted Values (5.6.0) Type integerDefault 20Permitted Values (>= 5.6.1, <= 5.6.14) Type integerDefault 30Permitted Values (>= 5.6.15) Type integerDefault 40rwlock instrument의 최대 수.
performance_schema_max_rwlock_instancesCommand-Line Format --performance_schema_max_rwlock_instances=#System Variable Name performance_schema_max_rwlock_instancesVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 1000Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)instrument되는 rwlock 개체의 최대 수.
performance_schema_max_socket_classesIntroduced 5.6.3 Command-Line Format --performance_schema_max_socket_classes=#System Variable Name performance_schema_max_socket_classesVariable Scope Global Dynamic Variable No Permitted Values Type integerDefault 10소켓 instrument의 최대 수. 이 변수는 MySQL 5.6.3에서 추가되었습니다.
performance_schema_max_socket_instancesIntroduced 5.6.3 Command-Line Format --performance_schema_max_socket_instances=#System Variable Name performance_schema_max_socket_instancesVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 1000Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)instrument되는 소켓 객체의 최대 수. 이 변수는 MySQL 5.6.3에서 추가되었습니다.
performance_schema_max_stage_classesIntroduced 5.6.3 Command-Line Format --performance_schema_max_stage_classes=#System Variable Name performance_schema_max_stage_classesVariable Scope Global Dynamic Variable No Permitted Values Type integerDefault 150stage instrument의 최대 수. 이 변수는 MySQL 5.6.3에서 추가되었습니다.
performance_schema_max_statement_classes문 instrument의 최대 수. 기본값은 서버 구축시 클라이언트 / 서버 프로토콜 명령 수와 서버에서 지원되는 SQL 문의 유형의 수에 따라 계산됩니다.Introduced 5.6.3 Command-Line Format --performance_schema_max_statement_classes=#System Variable Name performance_schema_max_statement_classesVariable Scope Global Dynamic Variable No Permitted Values Type integerDefault -1 (autosized)이 변수는 그것을 0으로 설정하여 모든 문 계측을 무효로하고, 그와 관련된 모든 메모리를 절약하지 않는 한 변경해서는 없습니다. 변수를 기본값이 아닌 0이 아닌 값으로 설정해도 이점은 없습니다. 특히 기본보다 큰 값은 필요 이상의 메모리가 할당됩니다.
이 변수는 MySQL 5.6.3에서 추가되었습니다.
performance_schema_max_table_handlesCommand-Line Format --performance_schema_max_table_handles=#System Variable Name performance_schema_max_table_handlesVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 100000Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)열려있는 테이블 오브젝트의 최대 수.
performance_schema_max_table_instancesCommand-Line Format --performance_schema_max_table_instances=#System Variable Name performance_schema_max_table_instancesVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 50000Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)instrument되는 테이블 오브젝트의 최대 수.
performance_schema_max_thread_classesCommand-Line Format --performance_schema_max_thread_classes=#System Variable Name performance_schema_max_thread_classesVariable Scope Global Dynamic Variable No Permitted Values Type integerDefault 50스레드 instrument의 최대 수.
performance_schema_max_thread_instancesinstrument되는 스레드 개체의 최대 수. 이 값은Command-Line Format --performance_schema_max_thread_instances=#System Variable Name performance_schema_max_thread_instancesVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 1000Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)threads테이블의 크기를 제어합니다. 이 최대를 초과하여 스레드를 instrument 수없는 경우 성능 스키마는Performance_schema_thread_instances_lost상태 변수를 증가시킵니다.max_connections시스템 변수는 서버에서 실행되는 스레드 수에 영향을줍니다.performance_schema_max_thread_instances는 이러한 실행중인 스레드 중 instrument 가능한 스레드 수에 영향을줍니다.performance_schema_max_thread_instances의 기본값은max_connections의 값에 따라 자동 크기 설정됩니다.performance_schema_session_connect_attrs_sizeIntroduced 5.6.6 Command-Line Format --performance_schema_session_connect_attrs_size=#System Variable Name performance_schema_session_connect_attrs_sizeVariable Scope Global Dynamic Variable No Permitted Values Type integerDefault -1 (autosized)Min Value -1Max Value 1048576연결 속성 문자열을 유지하기 위해 사용되는 스레드마다 사전 할당되는 메모리의 양입니다. 연결 속성 문자열이 예약 된 스토리지보다 큰 경우,
Performance_schema_session_connect_attrs_lost상태 변수가 증가됩니다. 이 변수는 MySQL 5.6.7에서 추가되었습니다.performance_schema_setup_actors_sizeIntroduced 5.6.1 Command-Line Format --performance_schema_setup_actors_size=#System Variable Name performance_schema_setup_actors_sizeVariable Scope Global Dynamic Variable No Permitted Values Type integerDefault 100setup_actors테이블의 행 수.performance_schema_setup_objects_sizeIntroduced 5.6.1 Command-Line Format --performance_schema_setup_objects_size=#System Variable Name performance_schema_setup_objects_sizeVariable Scope Global Dynamic Variable No Permitted Values Type integerDefault 100setup_objects테이블의 행 수.performance_schema_users_sizeIntroduced 5.6.3 Command-Line Format --performance_schema_users_size=#System Variable Name performance_schema_users_sizeVariable Scope Global Dynamic Variable No Permitted Values (<= 5.6.5) Type integerDefault 10Min Value 0Max Value 1048576Permitted Values (>= 5.6.6) Type integerDefault -1 (autosized)Min Value -1 (autosized)Max Value 1048576users테이블의 행 수. 이 변수가 0이면 성능 스키마는users테이블에 연결 통계를 유지하지 않습니다. 이 변수는 MySQL 5.6.3에서 추가되었습니다.