Loading...
MySQL 9.5 Reference Manual 9.5의 29.15 Performance Schema System Variables의 한국어 번역본입니다.
아래의 경우에 피드백에서 신고해주신다면 반영하겠습니다.
감사합니다 :)
Performance Schema는 구성 정보를 제공하는 여러 시스템 변수를 구현합니다:
1mysql> SHOW VARIABLES LIKE 'perf%'; 2+----------------------------------------------------------+-------+ 3| Variable_name | Value | 4+----------------------------------------------------------+-------+ 5| performance_schema | ON | 6| performance_schema_accounts_size | -1 | 7| performance_schema_digests_size | 10000 | 8| performance_schema_error_size | 5377 | 9| performance_schema_events_stages_history_long_size | 10000 | 10| performance_schema_events_stages_history_size | 10 | 11| performance_schema_events_statements_history_long_size | 10000 | 12| performance_schema_events_statements_history_size | 10 | 13| performance_schema_events_transactions_history_long_size | 10000 | 14| performance_schema_events_transactions_history_size | 10 | 15| performance_schema_events_waits_history_long_size | 10000 | 16| performance_schema_events_waits_history_size | 10 | 17| performance_schema_hosts_size | -1 | 18| performance_schema_max_cond_classes | 150 | 19| performance_schema_max_cond_instances | -1 | 20| performance_schema_max_digest_length | 1024 | 21| performance_schema_max_digest_sample_age | 60 | 22| performance_schema_max_file_classes | 80 | 23| performance_schema_max_file_handles | 32768 | 24| performance_schema_max_file_instances | -1 | 25| performance_schema_max_index_stat | -1 | 26| performance_schema_max_memory_classes | 470 | 27| performance_schema_max_metadata_locks | -1 | 28| performance_schema_max_meter_classes | 30 | 29| performance_schema_max_metric_classes | 600 | 30| performance_schema_max_mutex_classes | 350 | 31| performance_schema_max_mutex_instances | -1 | 32| performance_schema_max_prepared_statements_instances | -1 | 33| performance_schema_max_program_instances | -1 | 34| performance_schema_max_rwlock_classes | 100 | 35| performance_schema_max_rwlock_instances | -1 | 36| performance_schema_max_socket_classes | 10 | 37| performance_schema_max_socket_instances | -1 | 38| performance_schema_max_sql_text_length | 1024 | 39| performance_schema_max_stage_classes | 175 | 40| performance_schema_max_statement_classes | 220 | 41| performance_schema_max_statement_stack | 10 | 42| performance_schema_max_table_handles | -1 | 43| performance_schema_max_table_instances | -1 | 44| performance_schema_max_table_lock_stat | -1 | 45| performance_schema_max_thread_classes | 100 | 46| performance_schema_max_thread_instances | -1 | 47| performance_schema_session_connect_attrs_size | 512 | 48| performance_schema_setup_actors_size | -1 | 49| performance_schema_setup_objects_size | -1 | 50| performance_schema_show_processlist | OFF | 51| performance_schema_users_size | -1 | 52+----------------------------------------------------------+-------+
Performance Schema 시스템 변수는 서버 시작 시 커맨드 라인 또는 옵션 파일에서 설정할 수 있으며, 많은 변수는 런타임에도 설정할 수 있습니다. 자세한 내용은 Section 29.13, “Performance Schema Option and Variable Reference”를 참조하십시오.
Performance Schema는 여러 파라미터 값이 명시적으로 설정되지 않은 경우 서버 시작 시 자동으로 크기를 조정합니다. 자세한 내용은 Section 29.3, “Performance Schema Startup Configuration”을 참조하십시오.
Performance Schema 시스템 변수는 다음과 같은 의미를 가집니다:
| Property | Value |
|---|---|
| Command-Line Format | `--performance-schema[={OFF |
| System Variable | performance_schema |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Boolean |
| Default Value | ON |
이 변수 값은 Performance Schema가 활성화되었는지를 나타내기 위해 ON 또는
OFF입니다. 기본값은
ON입니다. 서버 시작 시, 값을 지정하지 않거나 값으로 ON 또는
1을 지정하면 활성화되고, 값으로 OFF 또는 0을 지정하면 비활성화됩니다.
Performance Schema가 비활성화된 경우에도
global_variables,
session_variables,
global_status, 및
session_status 테이블을 계속 채웁니다. 이는
SHOW VARIABLES 및
SHOW STATUS 스테이트먼트의 결과를 해당 테이블에서 가져올 수 있도록 하기 위해 필요에 따라 발생합니다. Performance Schema는 비활성화된 경우에도 일부 레플리케이션 테이블을 채웁니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-accounts-size=# |
| System Variable | performance_schema_accounts_size |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autoscaling; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
accounts 테이블의 행 수입니다. 이 변수가 0이면, Performance Schema는
accounts 테이블에서 커넥션 통계를 유지하지 않으며
status_by_account 테이블의 상태 변수 정보도 유지하지 않습니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-digests-size=# |
| System Variable | performance_schema_digests_size |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autosizing; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
events_statements_summary_by_digest
테이블의 최대 행 수입니다. 이 최대값이 초과되어 다이제스트를 인스트루먼트할 수 없는 경우, Performance Schema는
Performance_schema_digest_lost
상태 변수를 증가시킵니다.
스테이트먼트 다이제스트에 대한 자세한 내용은 Section 29.10, “Performance Schema Statement Digests and Sampling”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-error-size=# |
| System Variable | performance_schema_error_size |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | number of server error codes |
| Minimum Value | 0 |
| Maximum Value | 1048576 |
인스트루먼트된 서버 에러 코드 수입니다. 기본값은 실제 서버 에러 코드 수입니다. 값은 0에서 최대값까지 설정할 수 있지만, 의도된 사용 방식은 기본값(모든 에러를 인스트루먼트하기 위해) 또는 0(어떤 에러도 인스트루먼트하지 않기 위해)으로 설정하는 것입니다.
에러 정보는 집계 테이블에 집계됩니다;
Section 29.12.20.11, “Error Summary Tables”을 참조하십시오. 인스트루먼트되지 않은 에러가 발생하면, 해당 발생에 대한 정보는 각 집계 테이블의 NULL 행에 집계됩니다. 즉,
ERROR_NUMBER=0,
ERROR_NAME=NULL,
SQLSTATE=NULL인 행에 집계됩니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-events-stages-history-long-size=# |
| System Variable | performance_schema_events_stages_history_long_size |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autosizing; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
events_stages_history_long 테이블의 행 수입니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-events-stages-history-size=# |
| System Variable | performance_schema_events_stages_history_size |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autosizing; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1024 |
events_stages_history 테이블에서 스레드당 행 수입니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-events-statements-history-long-size=# |
| System Variable | performance_schema_events_statements_history_long_size |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autosizing; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
events_statements_history_long
테이블의 행 수입니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-events-statements-history-size=# |
| System Variable | performance_schema_events_statements_history_size |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autosizing; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1024 |
events_statements_history 테이블에서 스레드당 행 수입니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-events-transactions-history-long-size=# |
| System Variable | performance_schema_events_transactions_history_long_size |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autosizing; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
events_transactions_history_long
테이블의 행 수입니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-events-transactions-history-size=# |
| System Variable | performance_schema_events_transactions_history_size |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autosizing; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1024 |
events_transactions_history
테이블에서 스레드당 행 수입니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-events-waits-history-long-size=# |
| System Variable | performance_schema_events_waits_history_long_size |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autosizing; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
events_waits_history_long 테이블의 행 수입니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-events-waits-history-size=# |
| System Variable | performance_schema_events_waits_history_size |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autosizing; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1024 |
events_waits_history 테이블에서 스레드당 행 수입니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-hosts-size=# |
| System Variable | performance_schema_hosts_size |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autoscaling; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
hosts
테이블의 행 수입니다. 이 변수가 0이면, Performance Schema는
hosts 테이블에서 커넥션 통계를 유지하지 않으며
status_by_host
테이블의 상태 변수 정보도 유지하지 않습니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-cond-classes=# |
| System Variable | performance_schema_max_cond_classes |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | 150 |
| Minimum Value | 0 |
| Maximum Value | 1024 |
컨디션 인스트루먼트의 최대 개수입니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는 Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-cond-instances=# |
| System Variable | performance_schema_max_cond_instances |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autoscaling; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
인스트루먼트된 컨디션 객체의 최대 개수입니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는 Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-digest-length=# |
| System Variable | performance_schema_max_digest_length |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | 1024 |
| Minimum Value | 0 |
| Maximum Value | 1048576 |
| Unit | bytes |
Performance Schema에서 정규화된 스테이트먼트 다이제스트 값을 계산하기 위해 스테이트먼트당 예약되는 메모리의 최대 바이트 수입니다. 이 변수는
max_digest_length와 관련이 있습니다. 해당 변수에 대한 설명은
Section 7.1.8, “Server System Variables”을 참조하십시오.
스테이트먼트 다이제스트에 대한 자세한 정보, 특히 메모리 사용과 관련된 고려 사항은 Section 29.10, “Performance Schema Statement Digests and Sampling”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-digest-sample-age=# |
| System Variable | performance_schema_max_digest_sample_age |
| Scope | Global |
| Dynamic | Yes |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | 60 |
| Minimum Value | 0 |
| Maximum Value | 1048576 |
| Unit | seconds |
이 변수는
events_statements_summary_by_digest
테이블에 대한 스테이트먼트 샘플링에 영향을 줍니다. 새로운 테이블 행이 삽입될 때, 해당 행의 다이제스트 값을 생성한 스테이트먼트는 다이제스트와 연관된 현재 샘플 스테이트먼트로 저장됩니다. 이후 서버가 동일한 다이제스트 값을 가진 다른 스테이트먼트를 볼 때마다, 새로운 스테이트먼트를 사용하여 현재 샘플 스테이트먼트를 교체할지(즉, 재샘플링할지) 여부를 결정합니다. 재샘플링 정책은 현재 샘플 스테이트먼트와 새로운 스테이트먼트의 대기 시간 비교 및 선택적으로 현재 샘플 스테이트먼트의 연령(age)에 기반합니다:
대기 시간 기반 재샘플링: 새로운 스테이트먼트의 대기 시간이 현재 샘플 스테이트먼트의 대기 시간보다 크면, 새로운 스테이트먼트는 현재 샘플 스테이트먼트가 됩니다.
연령 기반 재샘플링:
performance_schema_max_digest_sample_age
시스템 변수가 0보다 큰 값을 가지고 있고 현재 샘플 스테이트먼트가 그 값(초 단위)보다 오래된 경우, 현재 스테이트먼트는 “너무 오래됨(too old)”으로 간주되고 새로운 스테이트먼트가 이를 대체합니다. 이는 새로운 스테이트먼트의 대기 시간이 현재 샘플 스테이트먼트의 대기 시간보다 짧더라도 발생합니다.
스테이트먼트 샘플링에 대한 정보는 Section 29.10, “Performance Schema Statement Digests and Sampling”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-file-classes=# |
| System Variable | performance_schema_max_file_classes |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | 80 |
| Minimum Value | 0 |
| Maximum Value | 1024 |
파일 인스트루먼트의 최대 개수입니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는 Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-file-handles=# |
| System Variable | performance_schema_max_file_handles |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | 32768 |
| Minimum Value | 0 |
| Maximum Value | 1048576 |
오픈된 파일 객체의 최대 개수입니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는 Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
performance_schema_max_file_handles
값은
open_files_limit 값보다 커야 합니다:
open_files_limit는 서버가 지원할 수 있는 최대 오픈 파일 핸들 수에 영향을 미치고,
performance_schema_max_file_handles는 이들 파일 핸들 중 몇 개가 인스트루먼트될 수 있는지에 영향을 미칩니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-file-instances=# |
| System Variable | performance_schema_max_file_instances |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autoscaling; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
인스트루먼트된 파일 객체의 최대 개수입니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는 Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-index-stat=# |
| System Variable | performance_schema_max_index_stat |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autosizing; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
Performance Schema가 통계를 유지하는 인덱스의 최대 개수입니다. 이 최대값이 초과되어 인덱스 통계가 손실되면, Performance Schema는
Performance_schema_index_stat_lost
상태 변수를 증가시킵니다. 기본값은
performance_schema_max_table_instances
값을 사용하여 자동으로 계산됩니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-memory-classes=# |
| System Variable | performance_schema_max_memory_classes |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | 470 |
| Default Value | 450 |
| Minimum Value | 0 |
| Maximum Value | 1024 |
메모리 인스트루먼트의 최대 개수입니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는 Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-metadata-locks=# |
| System Variable | performance_schema_max_metadata_locks |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autoscaling; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 10485760 |
메타데이터 락 인스트루먼트의 최대 개수입니다. 이 값은
metadata_locks 테이블의 크기를 제어합니다. 이 최대값이 초과되어 메타데이터 락을 인스트루먼트할 수 없는 경우, Performance Schema는
Performance_schema_metadata_lock_lost
상태 변수를 증가시킵니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-meter-classes=# |
| System Variable | performance_schema_max_meter_classes |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | 30 |
| Minimum Value | 0 |
| Maximum Value | 64 |
생성될 수 있는 미터 인스트루먼트의 최대 개수입니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-metric-classes=# |
| System Variable | performance_schema_max_metric_classes |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | 600 |
| Minimum Value | 30 |
| Maximum Value | 11000 |
생성될 수 있는 메트릭 인스트루먼트의 최대 개수입니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-mutex-classes=# |
| System Variable | performance_schema_max_mutex_classes |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | 350 |
| Minimum Value | 0 |
| Maximum Value | 1024 |
뮤텍스 인스트루먼트의 최대 개수입니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는 Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-mutex-instances=# |
| System Variable | performance_schema_max_mutex_instances |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autoscaling; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 104857600 |
인스트루먼트된 뮤텍스 객체의 최대 개수입니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는 Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-prepared-statements-instances=# |
| System Variable | performance_schema_max_prepared_statements_instances |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autoscaling; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 4194304 |
prepared_statements_instances
테이블의 최대 행 수입니다. 이 최대값이 초과되어 프리페어드 스테이트먼트를 인스트루먼트할 수 없는 경우, Performance Schema는
Performance_schema_prepared_statements_lost
상태 변수를 증가시킵니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는
Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
이 변수의 기본값은
max_prepared_stmt_count
시스템 변수 값을 기반으로 자동으로 설정됩니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-rwlock-classes=# |
| System Variable | performance_schema_max_rwlock_classes |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | 100 |
| Minimum Value | 0 |
| Maximum Value | 1024 |
RWLock 인스트루먼트의 최대 개수입니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는 Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-program-instances=# |
| System Variable | performance_schema_max_program_instances |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autoscaling; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
Performance Schema가 통계를 유지하는 스토어드 프로그램의 최대 개수입니다. 이 최대값이 초과되면, Performance Schema는
Performance_schema_program_lost
상태 변수를 증가시킵니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는
Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-rwlock-instances=# |
| System Variable | performance_schema_max_rwlock_instances |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autosizing; do not assign this literal value) |
| Minimum Value | -1 (signifies autosizing; do not assign this literal value) |
| Maximum Value | 104857600 |
인스트루먼트된 RWLock 객체의 최대 개수입니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는 Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-socket-classes=# |
| System Variable | performance_schema_max_socket_classes |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | 10 |
| Minimum Value | 0 |
| Maximum Value | 1024 |
소켓 인스트루먼트의 최대 개수입니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는 Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-socket-instances=# |
| System Variable | performance_schema_max_socket_instances |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autoscaling; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
인스트루먼트된 소켓 객체의 최대 개수입니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는 Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-sql-text-length=# |
| System Variable | performance_schema_max_sql_text_length |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | 1024 |
| Minimum Value | 0 |
| Maximum Value | 1048576 |
| Unit | bytes |
SQL 스테이트먼트를 저장하는 데 사용되는 최대 바이트 수입니다. 이 값은 다음 컬럼에 필요한 스토리지에 적용됩니다:
스테이트먼트 이벤트 테이블인
events_statements_current,
events_statements_history,
events_statements_history_long
의 SQL_TEXT 컬럼.
집계 테이블인
events_statements_summary_by_digest
의 QUERY_SAMPLE_TEXT 컬럼.
performance_schema_max_sql_text_length를 초과하는 바이트는 버려지며 컬럼에 나타나지 않습니다. 처음 지정된 바이트 수 이후에서만 다른 스테이트먼트는 해당 컬럼에서 서로 구분할 수 없습니다.
performance_schema_max_sql_text_length
값을 줄이면 메모리 사용량이 감소하지만, 끝 부분에서만 다른 스테이트먼트는 서로 구분할 수 없게 됩니다. 값을 늘리면 메모리 사용량이 증가하지만 더 긴 스테이트먼트를 구분할 수 있습니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-stage-classes=# |
| System Variable | performance_schema_max_stage_classes |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | 175 |
| Minimum Value | 0 |
| Maximum Value | 1024 |
스테이지 인스트루먼트의 최대 개수입니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는 Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-statement-classes=# |
| System Variable | performance_schema_max_statement_classes |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Minimum Value | 0 |
| Maximum Value | 256 |
스테이트먼트 인스트루먼트의 최대 개수입니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는 Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
기본값은 클라이언트/서버 프로토콜의 커맨드 개수와 서버가 지원하는 SQL 스테이트먼트 타입 수를 기반으로 서버 빌드 시 계산됩니다.
이 변수는 0으로 설정하여 모든 스테이트먼트 인스트루먼테이션을 비활성화하고 관련된 모든 메모리를 절약하는 경우를 제외하고 변경해서는 안 됩니다. 기본값이 아닌 0이 아닌 값으로 설정하는 것은 이점이 없습니다. 특히, 기본값보다 큰 값으로 설정하면 필요 이상으로 더 많은 메모리가 할당됩니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-statement-stack=# |
| System Variable | performance_schema_max_statement_stack |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | 10 |
| Minimum Value | 1 |
| Maximum Value | 256 |
Performance Schema가 통계를 유지하는 중첩 스토어드 프로그램 호출의 최대 깊이입니다. 이 최대값이 초과되면, Performance Schema는 실행되는 각 스토어드 프로그램 스테이트먼트에 대해
Performance_schema_nested_statement_lost
상태 변수를 증가시킵니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-table-handles=# |
| System Variable | performance_schema_max_table_handles |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autoscaling; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
오픈된 테이블 객체의 최대 개수입니다. 이 값은
table_handles 테이블의 크기를 제어합니다. 이 최대값이 초과되어 테이블 핸들을 인스트루먼트할 수 없는 경우, Performance Schema는
Performance_schema_table_handles_lost
상태 변수를 증가시킵니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는
Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-table-instances=# |
| System Variable | performance_schema_max_table_instances |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autoscaling; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
인스트루먼트된 테이블 객체의 최대 개수입니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는 Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-table-lock-stat=# |
| System Variable | performance_schema_max_table_lock_stat |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autosizing; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
Performance Schema가 락 통계를 유지하는 테이블의 최대 개수입니다. 이 최대값이 초과되어 테이블 락 통계가 손실되면, Performance Schema는
Performance_schema_table_lock_stat_lost
상태 변수를 증가시킵니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-thread-classes=# |
| System Variable | performance_schema_max_thread_classes |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | 100 |
| Minimum Value | 0 |
| Maximum Value | 1024 |
스레드 인스트루먼트의 최대 개수입니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는 Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-max-thread-instances=# |
| System Variable | performance_schema_max_thread_instances |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autosizing; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
인스트루먼트된 스레드 객체의 최대 개수입니다. 이 값은
threads
테이블의 크기를 제어합니다. 이 최대값이 초과되어 스레드를 인스트루먼트할 수 없는 경우, Performance Schema는
Performance_schema_thread_instances_lost
상태 변수를 증가시킵니다. 이 변수를 설정하고 사용하는 방법에 대한 정보는
Section 29.7, “Performance Schema Status Monitoring”을 참조하십시오.
max_connections 시스템 변수는 서버에서 실행될 수 있는 스레드 수에 영향을 줍니다.
performance_schema_max_thread_instances는 이러한 실행 중인 스레드 중 몇 개가 인스트루먼트될 수 있는지에 영향을 줍니다.
variables_by_thread 및
status_by_thread 테이블은 포그라운드 스레드에 대한 시스템 및 상태 변수 정보만 포함합니다. 모든 스레드가 Performance Schema에 의해 인스트루먼트되지 않은 경우, 이 테이블에는 일부 행이 누락됩니다. 이 경우,
Performance_schema_thread_instances_lost
상태 변수는 0보다 큽니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-session-connect-attrs-size=# |
| System Variable | performance_schema_session_connect_attrs_size |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autosizing; do not assign this literal value) |
| Minimum Value | -1 (signifies autosizing; do not assign this literal value) |
| Maximum Value | 1048576 |
| Unit | bytes |
커넥션 속성 키-값 쌍을 보관하기 위해 스레드당 예약되는 사전 할당 메모리 양입니다. 클라이언트가 전송한 커넥션 속성 데이터의 전체 크기가 이 양보다 크면, Performance Schema는 속성 데이터를 잘라내고,
Performance_schema_session_connect_attrs_lost
상태 변수를 증가시키며,
log_error_verbosity 시스템 변수가 1보다 큰 경우 잘림이 발생했음을 나타내는 메시지를 에러 로그에 기록합니다. 또한, 속성 버퍼에 충분한 공간이 있는 경우, 손실된 바이트 수를 나타내는 값을 가진 _truncated
속성이 세션 속성에 추가됩니다. 이를 통해 Performance Schema는 커넥션 속성 테이블에서 커넥션 단위의 잘림 정보를 노출할 수 있으며, 에러 로그를 확인하지 않고도 이 정보를 검사할 수 있습니다.
performance_schema_session_connect_attrs_size
의 기본값은 서버 시작 시 자동으로 설정됩니다. 이 값은 작을 수 있으므로, 잘림이 발생한 경우
(Performance_schema_session_connect_attrs_lost
가 0이 아닌 값이 되는 경우),
performance_schema_session_connect_attrs_size를 더 큰 값으로 명시적으로 설정하는 것이 좋습니다.
허용되는 최대
performance_schema_session_connect_attrs_size
값은 1MB이지만, 서버는 허용하는 커넥션 속성 데이터 전체 크기에 64KB 제한을 두기 때문에 실제 최대값은 64KB입니다. 클라이언트가 64KB를 초과하는 속성 데이터를 전송하려고 하면, 서버는 커넥션을 거부합니다. 자세한 내용은
Section 29.12.9, “Performance Schema Connection Attribute Tables”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-setup-actors-size=# |
| System Variable | performance_schema_setup_actors_size |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autoscaling; do not assign this literal value) |
| Minimum Value | -1 (signifies autosizing; do not assign this literal value) |
| Maximum Value | 1048576 |
setup_actors 테이블의 행 수입니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-setup-objects-size=# |
| System Variable | performance_schema_setup_objects_size |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autoscaling; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
setup_objects 테이블의 행 수입니다.
| Property | Value |
|---|---|
| Command-Line Format | `--performance-schema-show-processlist[={OFF |
| Deprecated | Yes |
| System Variable | performance_schema_show_processlist |
| Scope | Global |
| Dynamic | Yes |
SET_VAR Hint Applies | No |
| Type | Boolean |
| Default Value | OFF |
SHOW PROCESSLIST 스테이트먼트는 모든 액티브 스레드에서 스레드 데이터를 수집하여 프로세스 정보를 제공합니다.
performance_schema_show_processlist
변수는 사용할 SHOW PROCESSLIST
구현을 결정합니다:
기본 구현은 글로벌 뮤텍스를 보유하는 동안 스레드 매니저 내부에서 액티브 스레드를 순회합니다. 이는 특히 바쁜 시스템에서 성능에 부정적인 영향을 줍니다.
대체 SHOW PROCESSLIST 구현은 Performance Schema의
processlist 테이블에 기반합니다. 이 구현은 스레드 매니저가 아니라 Performance Schema에서 액티브 스레드 데이터를 조회하며 뮤텍스를 필요로 하지 않습니다.
대체 구현을 활성화하려면,
performance_schema_show_processlist
시스템 변수를 활성화하십시오. 기본 구현과 대체 구현이 동일한 정보를 제공하도록 하려면 특정 구성 요구 사항을 충족해야 합니다. 자세한 내용은
Section 29.12.22.9, “The processlist Table”을 참조하십시오.
| Property | Value |
|---|---|
| Command-Line Format | --performance-schema-users-size=# |
| System Variable | performance_schema_users_size |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | -1 (signifies autoscaling; do not assign this literal value) |
| Minimum Value | -1 (signifies autoscaling; do not assign this literal value) |
| Maximum Value | 1048576 |
users
테이블의 행 수입니다. 이 변수가 0이면, Performance Schema는
users 테이블에서 커넥션 통계를 유지하지 않으며
status_by_user
테이블의 상태 변수 정보도 유지하지 않습니다.
| Property | Value |
|---|---|
| Command-Line Format | --performance_schema_max_logger_classes[=value] |
| System Variable | performance_schema_max_logger_classes |
| Scope | Global |
| Dynamic | No |
SET_VAR Hint Applies | No |
| Type | Integer |
| Default Value | 80 |
| Minimum Value | 0 |
| Maximum Value | 200 |
이 값은 생성될 수 있는 로거 클라이언트 인스트루먼트의 최대 개수를 나타냅니다. 이 설정을 변경하려면 서버 재시작이 필요합니다.
29.14 Performance Schema Command Options
29.16 Performance Schema Status Variables