Information Schema INNODB_METRICS Table
The Information Schema INNODB_METRICS
table contains a list of useful InnoDB performance metrics. Each row in the table represents an instrumented counter that can be stopped, started and reset, and which can be grouped together by module.
The PROCESS
privilege is required to view the table.
It has the following columns:
Column | Description |
---|---|
NAME |
Unique counter name. |
SUBSYSTEM |
InnoDB subsystem. See below for the matching module to use to enable/disable monitoring this subsytem with the innodb_monitor_enable and innodb_monitor_disable system variables. |
COUNT |
Count since being enabled. |
MAX_COUNT |
Maximum value since being enabled. |
MIN_COUNT |
Minimum value since being enabled. |
AVG_COUNT |
Average value since being enabled. |
COUNT_RESET |
Count since last being reset. |
MAX_COUNT_RESET |
Maximum value since last being reset. |
MIN_COUNT_RESET |
Minimum value since last being reset. |
AVG_COUNT_RESET |
Average value since last being reset. |
TIME_ENABLED |
Time last enabled. |
TIME_DISABLED |
Time last disabled |
TIME_ELAPSED |
Time since enabled |
TIME_RESET |
Time last reset. |
STATUS |
Whether the counter is currently enabled to disabled. |
TYPE |
Item type; one of counter , value , status_counter , set_owner , set_member . |
COMMENT |
Counter description. |
Enabling and Disabling Counters
Most of the counters are disabled by default. To enable them, use the innodb_monitor_enable system variable. You can either enable a variable by its name, for example:
SET GLOBAL innodb_monitor_enable = icp_match;
or enable a number of counters grouped by module. The SUBSYSTEM
field indicates which counters are grouped together, but the following module names need to be used:
Module Name | Subsytem Field |
---|---|
module_metadata |
metadata |
module_lock |
lock |
module_buffer |
buffer |
module_buf_page |
buffer_page_io |
module_os |
os |
module_trx |
transaction |
module_purge |
purge |
module_compress |
compression |
module_file |
file_system |
module_index |
index |
module_adaptive_hash |
adaptive_hash_index From MariaDB 10.6.2, if innodb_adaptive_hash_index is disabled (the default), adaptive_hash_index will not be updated. |
module_ibuf_system |
change_buffer |
module_srv |
server |
module_ddl |
ddl |
module_dml |
dml |
module_log |
recovery |
module_icp |
icp |
There are four counters in the icp
subsystem:
SELECT NAME, SUBSYSTEM FROM INNODB_METRICS WHERE SUBSYSTEM='icp'; +------------------+-----------+ | NAME | SUBSYSTEM | +------------------+-----------+ | icp_attempts | icp | | icp_no_match | icp | | icp_out_of_range | icp | | icp_match | icp | +------------------+-----------+
To enable them all, use the associated module name from the table above, module_icp
.
SET GLOBAL innodb_monitor_enable = module_icp;
The %
wildcard, used to represent any number of characters, can also be used when naming counters, for example:
SET GLOBAL innodb_monitor_enable = 'buffer%'
To disable counters, use the innodb_monitor_disable system variable, using the same naming rules as described above for enabling.
Counter status is not persistent, and will be reset when the server restarts. It is possible to use the options on the command line, or the innodb_monitor_enable
option only in a configuration file.
Resetting Counters
Counters can also be reset. Resetting sets all the *_COUNT_RESET
values to zero, while leaving the *_COUNT
values, which perform counts since the counter was enabled, untouched. Resetting is performed with the innodb_monitor_reset (for individual counters) and innodb_monitor_reset_all (for all counters) system variables.
Simplifying from MariaDB 10.6
From MariaDB 10.6, the interface was simplified by removing the following:
- buffer_LRU_batches_flush
- buffer_LRU_batch_flush_pages
- buffer_LRU_batches_evict
- buffer_LRU_batch_evict_pages
and by making the following reflect the status variables:
- buffer_LRU_batch_flush_total_pages: innodb_buffer_pool_pages_LRU_flushed
- buffer_LRU_batch_evict_total_pages: innodb_buffer_pool_pages_LRU_freed
The intention is to eventually remove the interface entirely (see MDEV-15706).
Examples
Until MariaDB 10.5:
SELECT name,subsystem,type,comment FROM INFORMATION_SCHEMA.INNODB_METRICS; +--------------------------------------------+---------------------+----------------+------------------------------------------------------------------------------------------------------------------+ | name | subsystem | type | comment | +--------------------------------------------+---------------------+----------------+------------------------------------------------------------------------------------------------------------------+ | metadata_table_handles_opened | metadata | counter | Number of table handles opened | | metadata_table_handles_closed | metadata | counter | Number of table handles closed | | metadata_table_reference_count | metadata | counter | Table reference counter | | lock_deadlocks | lock | counter | Number of deadlocks | | lock_timeouts | lock | counter | Number of lock timeouts | | lock_rec_lock_waits | lock | counter | Number of times enqueued into record lock wait queue | | lock_table_lock_waits | lock | counter | Number of times enqueued into table lock wait queue | | lock_rec_lock_requests | lock | counter | Number of record locks requested | | lock_rec_lock_created | lock | counter | Number of record locks created | | lock_rec_lock_removed | lock | counter | Number of record locks removed from the lock queue | | lock_rec_locks | lock | counter | Current number of record locks on tables | | lock_table_lock_created | lock | counter | Number of table locks created | | lock_table_lock_removed | lock | counter | Number of table locks removed from the lock queue | | lock_table_locks | lock | counter | Current number of table locks on tables | | lock_row_lock_current_waits | lock | status_counter | Number of row locks currently being waited for (innodb_row_lock_current_waits) | | lock_row_lock_time | lock | status_counter | Time spent in acquiring row locks, in milliseconds (innodb_row_lock_time) | | lock_row_lock_time_max | lock | value | The maximum time to acquire a row lock, in milliseconds (innodb_row_lock_time_max) | | lock_row_lock_waits | lock | status_counter | Number of times a row lock had to be waited for (innodb_row_lock_waits) | | lock_row_lock_time_avg | lock | value | The average time to acquire a row lock, in milliseconds (innodb_row_lock_time_avg) | | buffer_pool_size | server | value | Server buffer pool size (all buffer pools) in bytes | | buffer_pool_reads | buffer | status_counter | Number of reads directly from disk (innodb_buffer_pool_reads) | | buffer_pool_read_requests | buffer | status_counter | Number of logical read requests (innodb_buffer_pool_read_requests) | | buffer_pool_write_requests | buffer | status_counter | Number of write requests (innodb_buffer_pool_write_requests) | | buffer_pool_wait_free | buffer | status_counter | Number of times waited for free buffer (innodb_buffer_pool_wait_free) | | buffer_pool_read_ahead | buffer | status_counter | Number of pages read as read ahead (innodb_buffer_pool_read_ahead) | | buffer_pool_read_ahead_evicted | buffer | status_counter | Read-ahead pages evicted without being accessed (innodb_buffer_pool_read_ahead_evicted) | | buffer_pool_pages_total | buffer | value | Total buffer pool size in pages (innodb_buffer_pool_pages_total) | | buffer_pool_pages_misc | buffer | value | Buffer pages for misc use such as row locks or the adaptive hash index (innodb_buffer_pool_pages_misc) | | buffer_pool_pages_data | buffer | value | Buffer pages containing data (innodb_buffer_pool_pages_data) | | buffer_pool_bytes_data | buffer | value | Buffer bytes containing data (innodb_buffer_pool_bytes_data) | | buffer_pool_pages_dirty | buffer | value | Buffer pages currently dirty (innodb_buffer_pool_pages_dirty) | | buffer_pool_bytes_dirty | buffer | value | Buffer bytes currently dirty (innodb_buffer_pool_bytes_dirty) | | buffer_pool_pages_free | buffer | value | Buffer pages currently free (innodb_buffer_pool_pages_free) | | buffer_pages_created | buffer | status_counter | Number of pages created (innodb_pages_created) | | buffer_pages_written | buffer | status_counter | Number of pages written (innodb_pages_written) | | buffer_index_pages_written | buffer | status_counter | Number of index pages written (innodb_index_pages_written) | | buffer_non_index_pages_written | buffer | status_counter | Number of non index pages written (innodb_non_index_pages_written) | | buffer_pages_read | buffer | status_counter | Number of pages read (innodb_pages_read) | | buffer_index_sec_rec_cluster_reads | buffer | status_counter | Number of secondary record reads triggered cluster read | | buffer_index_sec_rec_cluster_reads_avoided | buffer | status_counter | Number of secondary record reads avoided triggering cluster read | | buffer_data_reads | buffer | status_counter | Amount of data read in bytes (innodb_data_reads) | | buffer_data_written | buffer | status_counter | Amount of data written in bytes (innodb_data_written) | | buffer_flush_batch_scanned | buffer | set_owner | Total pages scanned as part of flush batch | | buffer_flush_batch_num_scan | buffer | set_member | Number of times buffer flush list flush is called | | buffer_flush_batch_scanned_per_call | buffer | set_member | Pages scanned per flush batch scan | | buffer_flush_batch_total_pages | buffer | set_owner | Total pages flushed as part of flush batch | | buffer_flush_batches | buffer | set_member | Number of flush batches | | buffer_flush_batch_pages | buffer | set_member | Pages queued as a flush batch | | buffer_flush_neighbor_total_pages | buffer | set_owner | Total neighbors flushed as part of neighbor flush | | buffer_flush_neighbor | buffer | set_member | Number of times neighbors flushing is invoked | | buffer_flush_neighbor_pages | buffer | set_member | Pages queued as a neighbor batch | | buffer_flush_n_to_flush_requested | buffer | counter | Number of pages requested for flushing. | | buffer_flush_n_to_flush_by_age | buffer | counter | Number of pages target by LSN Age for flushing. | | buffer_flush_adaptive_avg_time | buffer | counter | Avg time (ms) spent for adaptive flushing recently. | | buffer_flush_adaptive_avg_pass | buffer | counter | Number of adaptive flushes passed during the recent Avg period. | | buffer_LRU_get_free_loops | buffer | counter | Total loops in LRU get free. | | buffer_LRU_get_free_waits | buffer | counter | Total sleep waits in LRU get free. | | buffer_flush_avg_page_rate | buffer | counter | Average number of pages at which flushing is happening | | buffer_flush_lsn_avg_rate | buffer | counter | Average redo generation rate | | buffer_flush_pct_for_dirty | buffer | counter | Percent of IO capacity used to avoid max dirty page limit | | buffer_flush_pct_for_lsn | buffer | counter | Percent of IO capacity used to avoid reusable redo space limit | | buffer_flush_sync_waits | buffer | counter | Number of times a wait happens due to sync flushing | | buffer_flush_adaptive_total_pages | buffer | set_owner | Total pages flushed as part of adaptive flushing | | buffer_flush_adaptive | buffer | set_member | Number of adaptive batches | | buffer_flush_adaptive_pages | buffer | set_member | Pages queued as an adaptive batch | | buffer_flush_sync_total_pages | buffer | set_owner | Total pages flushed as part of sync batches | | buffer_flush_sync | buffer | set_member | Number of sync batches | | buffer_flush_sync_pages | buffer | set_member | Pages queued as a sync batch | | buffer_flush_background_total_pages | buffer | set_owner | Total pages flushed as part of background batches | | buffer_flush_background | buffer | set_member | Number of background batches | | buffer_flush_background_pages | buffer | set_member | Pages queued as a background batch | | buffer_LRU_batch_scanned | buffer | set_owner | Total pages scanned as part of LRU batch | | buffer_LRU_batch_num_scan | buffer | set_member | Number of times LRU batch is called | | buffer_LRU_batch_scanned_per_call | buffer | set_member | Pages scanned per LRU batch call | | buffer_LRU_batch_flush_total_pages | buffer | set_owner | Total pages flushed as part of LRU batches | | buffer_LRU_batches_flush | buffer | set_member | Number of LRU batches | | buffer_LRU_batch_flush_pages | buffer | set_member | Pages queued as an LRU batch | | buffer_LRU_batch_evict_total_pages | buffer | set_owner | Total pages evicted as part of LRU batches | | buffer_LRU_batches_evict | buffer | set_member | Number of LRU batches | | buffer_LRU_batch_evict_pages | buffer | set_member | Pages queued as an LRU batch | | buffer_LRU_single_flush_failure_count | Buffer | counter | Number of times attempt to flush a single page from LRU failed | | buffer_LRU_get_free_search | Buffer | counter | Number of searches performed for a clean page | | buffer_LRU_search_scanned | buffer | set_owner | Total pages scanned as part of LRU search | | buffer_LRU_search_num_scan | buffer | set_member | Number of times LRU search is performed | | buffer_LRU_search_scanned_per_call | buffer | set_member | Page scanned per single LRU search | | buffer_LRU_unzip_search_scanned | buffer | set_owner | Total pages scanned as part of LRU unzip search | | buffer_LRU_unzip_search_num_scan | buffer | set_member | Number of times LRU unzip search is performed | | buffer_LRU_unzip_search_scanned_per_call | buffer | set_member | Page scanned per single LRU unzip search | | buffer_page_read_index_leaf | buffer_page_io | counter | Number of Index Leaf Pages read | | buffer_page_read_index_non_leaf | buffer_page_io | counter | Number of Index Non-leaf Pages read | | buffer_page_read_index_ibuf_leaf | buffer_page_io | counter | Number of Insert Buffer Index Leaf Pages read | | buffer_page_read_index_ibuf_non_leaf | buffer_page_io | counter | Number of Insert Buffer Index Non-Leaf Pages read | | buffer_page_read_undo_log | buffer_page_io | counter | Number of Undo Log Pages read | | buffer_page_read_index_inode | buffer_page_io | counter | Number of Index Inode Pages read | | buffer_page_read_ibuf_free_list | buffer_page_io | counter | Number of Insert Buffer Free List Pages read | | buffer_page_read_ibuf_bitmap | buffer_page_io | counter | Number of Insert Buffer Bitmap Pages read | | buffer_page_read_system_page | buffer_page_io | counter | Number of System Pages read | | buffer_page_read_trx_system | buffer_page_io | counter | Number of Transaction System Pages read | | buffer_page_read_fsp_hdr | buffer_page_io | counter | Number of File Space Header Pages read | | buffer_page_read_xdes | buffer_page_io | counter | Number of Extent Descriptor Pages read | | buffer_page_read_blob | buffer_page_io | counter | Number of Uncompressed BLOB Pages read | | buffer_page_read_zblob | buffer_page_io | counter | Number of First Compressed BLOB Pages read | | buffer_page_read_zblob2 | buffer_page_io | counter | Number of Subsequent Compressed BLOB Pages read | | buffer_page_read_other | buffer_page_io | counter | Number of other/unknown (old version of InnoDB) Pages read | | buffer_page_written_index_leaf | buffer_page_io | counter | Number of Index Leaf Pages written | | buffer_page_written_index_non_leaf | buffer_page_io | counter | Number of Index Non-leaf Pages written | | buffer_page_written_index_ibuf_leaf | buffer_page_io | counter | Number of Insert Buffer Index Leaf Pages written | | buffer_page_written_index_ibuf_non_leaf | buffer_page_io | counter | Number of Insert Buffer Index Non-Leaf Pages written | | buffer_page_written_undo_log | buffer_page_io | counter | Number of Undo Log Pages written | | buffer_page_written_index_inode | buffer_page_io | counter | Number of Index Inode Pages written | | buffer_page_written_ibuf_free_list | buffer_page_io | counter | Number of Insert Buffer Free List Pages written | | buffer_page_written_ibuf_bitmap | buffer_page_io | counter | Number of Insert Buffer Bitmap Pages written | | buffer_page_written_system_page | buffer_page_io | counter | Number of System Pages written | | buffer_page_written_trx_system | buffer_page_io | counter | Number of Transaction System Pages written | | buffer_page_written_fsp_hdr | buffer_page_io | counter | Number of File Space Header Pages written | | buffer_page_written_xdes | buffer_page_io | counter | Number of Extent Descriptor Pages written | | buffer_page_written_blob | buffer_page_io | counter | Number of Uncompressed BLOB Pages written | | buffer_page_written_zblob | buffer_page_io | counter | Number of First Compressed BLOB Pages written | | buffer_page_written_zblob2 | buffer_page_io | counter | Number of Subsequent Compressed BLOB Pages written | | buffer_page_written_other | buffer_page_io | counter | Number of other/unknown (old version InnoDB) Pages written | | os_data_reads | os | status_counter | Number of reads initiated (innodb_data_reads) | | os_data_writes | os | status_counter | Number of writes initiated (innodb_data_writes) | | os_data_fsyncs | os | status_counter | Number of fsync() calls (innodb_data_fsyncs) | | os_pending_reads | os | counter | Number of reads pending | | os_pending_writes | os | counter | Number of writes pending | | os_log_bytes_written | os | status_counter | Bytes of log written (innodb_os_log_written) | | os_log_fsyncs | os | status_counter | Number of fsync log writes (innodb_os_log_fsyncs) | | os_log_pending_fsyncs | os | status_counter | Number of pending fsync write (innodb_os_log_pending_fsyncs) | | os_log_pending_writes | os | status_counter | Number of pending log file writes (innodb_os_log_pending_writes) | | trx_rw_commits | transaction | counter | Number of read-write transactions committed | | trx_ro_commits | transaction | counter | Number of read-only transactions committed | | trx_nl_ro_commits | transaction | counter | Number of non-locking auto-commit read-only transactions committed | | trx_commits_insert_update | transaction | counter | Number of transactions committed with inserts and updates | | trx_rollbacks | transaction | counter | Number of transactions rolled back | | trx_rollbacks_savepoint | transaction | counter | Number of transactions rolled back to savepoint | | trx_active_transactions | transaction | counter | Number of active transactions | | trx_rseg_history_len | transaction | value | Length of the TRX_RSEG_HISTORY list | | trx_undo_slots_used | transaction | counter | Number of undo slots used | | trx_undo_slots_cached | transaction | counter | Number of undo slots cached | | trx_rseg_current_size | transaction | value | Current rollback segment size in pages | | purge_del_mark_records | purge | counter | Number of delete-marked rows purged | | purge_upd_exist_or_extern_records | purge | counter | Number of purges on updates of existing records and updates on delete marked record with externally stored field | | purge_invoked | purge | counter | Number of times purge was invoked | | purge_undo_log_pages | purge | counter | Number of undo log pages handled by the purge | | purge_dml_delay_usec | purge | value | Microseconds DML to be delayed due to purge lagging | | purge_stop_count | purge | value | Number of times purge was stopped | | purge_resume_count | purge | value | Number of times purge was resumed | | log_checkpoints | recovery | counter | Number of checkpoints | | log_lsn_last_flush | recovery | value | LSN of Last flush | | log_lsn_last_checkpoint | recovery | value | LSN at last checkpoint | | log_lsn_current | recovery | value | Current LSN value | | log_lsn_checkpoint_age | recovery | value | Current LSN value minus LSN at last checkpoint | | log_lsn_buf_pool_oldest | recovery | value | The oldest modified block LSN in the buffer pool | | log_max_modified_age_async | recovery | value | Maximum LSN difference; when exceeded, start asynchronous preflush | | log_pending_log_flushes | recovery | value | Pending log flushes | | log_pending_checkpoint_writes | recovery | value | Pending checkpoints | | log_num_log_io | recovery | value | Number of log I/Os | | log_waits | recovery | status_counter | Number of log waits due to small log buffer (innodb_log_waits) | | log_write_requests | recovery | status_counter | Number of log write requests (innodb_log_write_requests) | | log_writes | recovery | status_counter | Number of log writes (innodb_log_writes) | | log_padded | recovery | status_counter | Bytes of log padded for log write ahead | | compress_pages_compressed | compression | counter | Number of pages compressed | | compress_pages_decompressed | compression | counter | Number of pages decompressed | | compression_pad_increments | compression | counter | Number of times padding is incremented to avoid compression failures | | compression_pad_decrements | compression | counter | Number of times padding is decremented due to good compressibility | | compress_saved | compression | counter | Number of bytes saved by page compression | | compress_pages_page_compressed | compression | counter | Number of pages compressed by page compression | | compress_page_compressed_trim_op | compression | counter | Number of TRIM operation performed by page compression | | compress_pages_page_decompressed | compression | counter | Number of pages decompressed by page compression | | compress_pages_page_compression_error | compression | counter | Number of page compression errors | | compress_pages_encrypted | compression | counter | Number of pages encrypted | | compress_pages_decrypted | compression | counter | Number of pages decrypted | | index_page_splits | index | counter | Number of index page splits | | index_page_merge_attempts | index | counter | Number of index page merge attempts | | index_page_merge_successful | index | counter | Number of successful index page merges | | index_page_reorg_attempts | index | counter | Number of index page reorganization attempts | | index_page_reorg_successful | index | counter | Number of successful index page reorganizations | | index_page_discards | index | counter | Number of index pages discarded | | adaptive_hash_searches | adaptive_hash_index | status_counter | Number of successful searches using Adaptive Hash Index | | adaptive_hash_searches_btree | adaptive_hash_index | status_counter | Number of searches using B-tree on an index search | | adaptive_hash_pages_added | adaptive_hash_index | counter | Number of index pages on which the Adaptive Hash Index is built | | adaptive_hash_pages_removed | adaptive_hash_index | counter | Number of index pages whose corresponding Adaptive Hash Index entries were removed | | adaptive_hash_rows_added | adaptive_hash_index | counter | Number of Adaptive Hash Index rows added | | adaptive_hash_rows_removed | adaptive_hash_index | counter | Number of Adaptive Hash Index rows removed | | adaptive_hash_rows_deleted_no_hash_entry | adaptive_hash_index | counter | Number of rows deleted that did not have corresponding Adaptive Hash Index entries | | adaptive_hash_rows_updated | adaptive_hash_index | counter | Number of Adaptive Hash Index rows updated | | file_num_open_files | file_system | value | Number of files currently open (innodb_num_open_files) | | ibuf_merges_insert | change_buffer | status_counter | Number of inserted records merged by change buffering | | ibuf_merges_delete_mark | change_buffer | status_counter | Number of deleted records merged by change buffering | | ibuf_merges_delete | change_buffer | status_counter | Number of purge records merged by change buffering | | ibuf_merges_discard_insert | change_buffer | status_counter | Number of insert merged operations discarded | | ibuf_merges_discard_delete_mark | change_buffer | status_counter | Number of deleted merged operations discarded | | ibuf_merges_discard_delete | change_buffer | status_counter | Number of purge merged operations discarded | | ibuf_merges | change_buffer | status_counter | Number of change buffer merges | | ibuf_size | change_buffer | status_counter | Change buffer size in pages | | innodb_master_thread_sleeps | server | counter | Number of times (seconds) master thread sleeps | | innodb_activity_count | server | status_counter | Current server activity count | | innodb_master_active_loops | server | counter | Number of times master thread performs its tasks when server is active | | innodb_master_idle_loops | server | counter | Number of times master thread performs its tasks when server is idle | | innodb_background_drop_table_usec | server | counter | Time (in microseconds) spent to process drop table list | | innodb_log_flush_usec | server | counter | Time (in microseconds) spent to flush log records | | innodb_dict_lru_usec | server | counter | Time (in microseconds) spent to process DICT LRU list | | innodb_dict_lru_count_active | server | counter | Number of tables evicted from DICT LRU list in the active loop | | innodb_dict_lru_count_idle | server | counter | Number of tables evicted from DICT LRU list in the idle loop | | innodb_dblwr_writes | server | status_counter | Number of doublewrite operations that have been performed (innodb_dblwr_writes) | | innodb_dblwr_pages_written | server | status_counter | Number of pages that have been written for doublewrite operations (innodb_dblwr_pages_written) | | innodb_page_size | server | value | InnoDB page size in bytes (innodb_page_size) | | innodb_rwlock_s_spin_waits | server | status_counter | Number of rwlock spin waits due to shared latch request | | innodb_rwlock_x_spin_waits | server | status_counter | Number of rwlock spin waits due to exclusive latch request | | innodb_rwlock_sx_spin_waits | server | status_counter | Number of rwlock spin waits due to sx latch request | | innodb_rwlock_s_spin_rounds | server | status_counter | Number of rwlock spin loop rounds due to shared latch request | | innodb_rwlock_x_spin_rounds | server | status_counter | Number of rwlock spin loop rounds due to exclusive latch request | | innodb_rwlock_sx_spin_rounds | server | status_counter | Number of rwlock spin loop rounds due to sx latch request | | innodb_rwlock_s_os_waits | server | status_counter | Number of OS waits due to shared latch request | | innodb_rwlock_x_os_waits | server | status_counter | Number of OS waits due to exclusive latch request | | innodb_rwlock_sx_os_waits | server | status_counter | Number of OS waits due to sx latch request | | dml_reads | dml | status_counter | Number of rows read | | dml_inserts | dml | status_counter | Number of rows inserted | | dml_deletes | dml | status_counter | Number of rows deleted | | dml_updates | dml | status_counter | Number of rows updated | | dml_system_reads | dml | status_counter | Number of system rows read | | dml_system_inserts | dml | status_counter | Number of system rows inserted | | dml_system_deletes | dml | status_counter | Number of system rows deleted | | dml_system_updates | dml | status_counter | Number of system rows updated | | ddl_background_drop_indexes | ddl | counter | Number of indexes waiting to be dropped after failed index creation | | ddl_background_drop_tables | ddl | counter | Number of tables in background drop table list | | ddl_online_create_index | ddl | counter | Number of indexes being created online | | ddl_pending_alter_table | ddl | counter | Number of ALTER TABLE, CREATE INDEX, DROP INDEX in progress | | ddl_sort_file_alter_table | ddl | counter | Number of sort files created during alter table | | ddl_log_file_alter_table | ddl | counter | Number of log files created during alter table | | icp_attempts | icp | counter | Number of attempts for index push-down condition checks | | icp_no_match | icp | counter | Index push-down condition does not match | | icp_out_of_range | icp | counter | Index push-down condition out of range | | icp_match | icp | counter | Index push-down condition matches | +--------------------------------------------+---------------------+----------------+------------------------------------------------------------------------------------------------------------------+ 234 rows in set (0.001 sec)
From MariaDB 10.6
SELECT name,subsystem,type,comment FROM INFORMATION_SCHEMA.INNODB_METRICS; +--------------------------------------------+---------------------+----------------+------------------------------------------------------------------------------------------------------------------+ | name | subsystem | type | comment | +--------------------------------------------+---------------------+----------------+------------------------------------------------------------------------------------------------------------------+ | metadata_table_handles_opened | metadata | counter | Number of table handles opened | | lock_deadlocks | lock | value | Number of deadlocks | | lock_timeouts | lock | value | Number of lock timeouts | | lock_rec_lock_waits | lock | counter | Number of times enqueued into record lock wait queue | | lock_table_lock_waits | lock | counter | Number of times enqueued into table lock wait queue | | lock_rec_lock_requests | lock | counter | Number of record locks requested | | lock_rec_lock_created | lock | counter | Number of record locks created | | lock_rec_lock_removed | lock | counter | Number of record locks removed from the lock queue | | lock_rec_locks | lock | counter | Current number of record locks on tables | | lock_table_lock_created | lock | counter | Number of table locks created | | lock_table_lock_removed | lock | counter | Number of table locks removed from the lock queue | | lock_table_locks | lock | counter | Current number of table locks on tables | | lock_row_lock_current_waits | lock | status_counter | Number of row locks currently being waited for (innodb_row_lock_current_waits) | | lock_row_lock_time | lock | status_counter | Time spent in acquiring row locks, in milliseconds (innodb_row_lock_time) | | lock_row_lock_time_max | lock | value | The maximum time to acquire a row lock, in milliseconds (innodb_row_lock_time_max) | | lock_row_lock_waits | lock | status_counter | Number of times a row lock had to be waited for (innodb_row_lock_waits) | | lock_row_lock_time_avg | lock | value | The average time to acquire a row lock, in milliseconds (innodb_row_lock_time_avg) | | buffer_pool_size | server | value | Server buffer pool size (all buffer pools) in bytes | | buffer_pool_reads | buffer | status_counter | Number of reads directly from disk (innodb_buffer_pool_reads) | | buffer_pool_read_requests | buffer | status_counter | Number of logical read requests (innodb_buffer_pool_read_requests) | | buffer_pool_write_requests | buffer | status_counter | Number of write requests (innodb_buffer_pool_write_requests) | | buffer_pool_wait_free | buffer | status_counter | Number of times waited for free buffer (innodb_buffer_pool_wait_free) | | buffer_pool_read_ahead | buffer | status_counter | Number of pages read as read ahead (innodb_buffer_pool_read_ahead) | | buffer_pool_read_ahead_evicted | buffer | status_counter | Read-ahead pages evicted without being accessed (innodb_buffer_pool_read_ahead_evicted) | | buffer_pool_pages_total | buffer | value | Total buffer pool size in pages (innodb_buffer_pool_pages_total) | | buffer_pool_pages_misc | buffer | value | Buffer pages for misc use such as row locks or the adaptive hash index (innodb_buffer_pool_pages_misc) | | buffer_pool_pages_data | buffer | value | Buffer pages containing data (innodb_buffer_pool_pages_data) | | buffer_pool_bytes_data | buffer | value | Buffer bytes containing data (innodb_buffer_pool_bytes_data) | | buffer_pool_pages_dirty | buffer | value | Buffer pages currently dirty (innodb_buffer_pool_pages_dirty) | | buffer_pool_bytes_dirty | buffer | value | Buffer bytes currently dirty (innodb_buffer_pool_bytes_dirty) | | buffer_pool_pages_free | buffer | value | Buffer pages currently free (innodb_buffer_pool_pages_free) | | buffer_pages_created | buffer | status_counter | Number of pages created (innodb_pages_created) | | buffer_pages_written | buffer | status_counter | Number of pages written (innodb_pages_written) | | buffer_index_pages_written | buffer | status_counter | Number of index pages written (innodb_index_pages_written) | | buffer_non_index_pages_written | buffer | status_counter | Number of non index pages written (innodb_non_index_pages_written) | | buffer_pages_read | buffer | status_counter | Number of pages read (innodb_pages_read) | | buffer_index_sec_rec_cluster_reads | buffer | status_counter | Number of secondary record reads triggered cluster read | | buffer_index_sec_rec_cluster_reads_avoided | buffer | status_counter | Number of secondary record reads avoided triggering cluster read | | buffer_data_reads | buffer | status_counter | Amount of data read in bytes (innodb_data_reads) | | buffer_data_written | buffer | status_counter | Amount of data written in bytes (innodb_data_written) | | buffer_flush_batch_scanned | buffer | set_owner | Total pages scanned as part of flush batch | | buffer_flush_batch_num_scan | buffer | set_member | Number of times buffer flush list flush is called | | buffer_flush_batch_scanned_per_call | buffer | set_member | Pages scanned per flush batch scan | | buffer_flush_batch_total_pages | buffer | set_owner | Total pages flushed as part of flush batch | | buffer_flush_batches | buffer | set_member | Number of flush batches | | buffer_flush_batch_pages | buffer | set_member | Pages queued as a flush batch | | buffer_flush_neighbor_total_pages | buffer | set_owner | Total neighbors flushed as part of neighbor flush | | buffer_flush_neighbor | buffer | set_member | Number of times neighbors flushing is invoked | | buffer_flush_neighbor_pages | buffer | set_member | Pages queued as a neighbor batch | | buffer_flush_n_to_flush_requested | buffer | counter | Number of pages requested for flushing. | | buffer_flush_n_to_flush_by_age | buffer | counter | Number of pages target by LSN Age for flushing. | | buffer_flush_adaptive_avg_time | buffer | counter | Avg time (ms) spent for adaptive flushing recently. | | buffer_flush_adaptive_avg_pass | buffer | counter | Number of adaptive flushes passed during the recent Avg period. | | buffer_LRU_get_free_loops | buffer | counter | Total loops in LRU get free. | | buffer_LRU_get_free_waits | buffer | counter | Total sleep waits in LRU get free. | | buffer_flush_avg_page_rate | buffer | counter | Average number of pages at which flushing is happening | | buffer_flush_lsn_avg_rate | buffer | counter | Average redo generation rate | | buffer_flush_pct_for_dirty | buffer | counter | Percent of IO capacity used to avoid max dirty page limit | | buffer_flush_pct_for_lsn | buffer | counter | Percent of IO capacity used to avoid reusable redo space limit | | buffer_flush_sync_waits | buffer | counter | Number of times a wait happens due to sync flushing | | buffer_flush_adaptive_total_pages | buffer | set_owner | Total pages flushed as part of adaptive flushing | | buffer_flush_adaptive | buffer | set_member | Number of adaptive batches | | buffer_flush_adaptive_pages | buffer | set_member | Pages queued as an adaptive batch | | buffer_flush_sync_total_pages | buffer | set_owner | Total pages flushed as part of sync batches | | buffer_flush_sync | buffer | set_member | Number of sync batches | | buffer_flush_sync_pages | buffer | set_member | Pages queued as a sync batch | | buffer_flush_background_total_pages | buffer | set_owner | Total pages flushed as part of background batches | | buffer_flush_background | buffer | set_member | Number of background batches | | buffer_flush_background_pages | buffer | set_member | Pages queued as a background batch | | buffer_LRU_batch_scanned | buffer | set_owner | Total pages scanned as part of LRU batch | | buffer_LRU_batch_num_scan | buffer | set_member | Number of times LRU batch is called | | buffer_LRU_batch_scanned_per_call | buffer | set_member | Pages scanned per LRU batch call | | buffer_LRU_batch_flush_total_pages | buffer | status_counter | Total pages flushed as part of LRU batches | | buffer_LRU_batch_evict_total_pages | buffer | status_counter | Total pages evicted as part of LRU batches | | buffer_LRU_single_flush_failure_count | Buffer | counter | Number of times attempt to flush a single page from LRU failed | | buffer_LRU_get_free_search | Buffer | counter | Number of searches performed for a clean page | | buffer_LRU_search_scanned | buffer | set_owner | Total pages scanned as part of LRU search | | buffer_LRU_search_num_scan | buffer | set_member | Number of times LRU search is performed | | buffer_LRU_search_scanned_per_call | buffer | set_member | Page scanned per single LRU search | | buffer_LRU_unzip_search_scanned | buffer | set_owner | Total pages scanned as part of LRU unzip search | | buffer_LRU_unzip_search_num_scan | buffer | set_member | Number of times LRU unzip search is performed | | buffer_LRU_unzip_search_scanned_per_call | buffer | set_member | Page scanned per single LRU unzip search | | buffer_page_read_index_leaf | buffer_page_io | counter | Number of Index Leaf Pages read | | buffer_page_read_index_non_leaf | buffer_page_io | counter | Number of Index Non-leaf Pages read | | buffer_page_read_index_ibuf_leaf | buffer_page_io | counter | Number of Insert Buffer Index Leaf Pages read | | buffer_page_read_index_ibuf_non_leaf | buffer_page_io | counter | Number of Insert Buffer Index Non-Leaf Pages read | | buffer_page_read_undo_log | buffer_page_io | counter | Number of Undo Log Pages read | | buffer_page_read_index_inode | buffer_page_io | counter | Number of Index Inode Pages read | | buffer_page_read_ibuf_free_list | buffer_page_io | counter | Number of Insert Buffer Free List Pages read | | buffer_page_read_ibuf_bitmap | buffer_page_io | counter | Number of Insert Buffer Bitmap Pages read | | buffer_page_read_system_page | buffer_page_io | counter | Number of System Pages read | | buffer_page_read_trx_system | buffer_page_io | counter | Number of Transaction System Pages read | | buffer_page_read_fsp_hdr | buffer_page_io | counter | Number of File Space Header Pages read | | buffer_page_read_xdes | buffer_page_io | counter | Number of Extent Descriptor Pages read | | buffer_page_read_blob | buffer_page_io | counter | Number of Uncompressed BLOB Pages read | | buffer_page_read_zblob | buffer_page_io | counter | Number of First Compressed BLOB Pages read | | buffer_page_read_zblob2 | buffer_page_io | counter | Number of Subsequent Compressed BLOB Pages read | | buffer_page_read_other | buffer_page_io | counter | Number of other/unknown (old version of InnoDB) Pages read | | buffer_page_written_index_leaf | buffer_page_io | counter | Number of Index Leaf Pages written | | buffer_page_written_index_non_leaf | buffer_page_io | counter | Number of Index Non-leaf Pages written | | buffer_page_written_index_ibuf_leaf | buffer_page_io | counter | Number of Insert Buffer Index Leaf Pages written | | buffer_page_written_index_ibuf_non_leaf | buffer_page_io | counter | Number of Insert Buffer Index Non-Leaf Pages written | | buffer_page_written_undo_log | buffer_page_io | counter | Number of Undo Log Pages written | | buffer_page_written_index_inode | buffer_page_io | counter | Number of Index Inode Pages written | | buffer_page_written_ibuf_free_list | buffer_page_io | counter | Number of Insert Buffer Free List Pages written | | buffer_page_written_ibuf_bitmap | buffer_page_io | counter | Number of Insert Buffer Bitmap Pages written | | buffer_page_written_system_page | buffer_page_io | counter | Number of System Pages written | | buffer_page_written_trx_system | buffer_page_io | counter | Number of Transaction System Pages written | | buffer_page_written_fsp_hdr | buffer_page_io | counter | Number of File Space Header Pages written | | buffer_page_written_xdes | buffer_page_io | counter | Number of Extent Descriptor Pages written | | buffer_page_written_blob | buffer_page_io | counter | Number of Uncompressed BLOB Pages written | | buffer_page_written_zblob | buffer_page_io | counter | Number of First Compressed BLOB Pages written | | buffer_page_written_zblob2 | buffer_page_io | counter | Number of Subsequent Compressed BLOB Pages written | | buffer_page_written_other | buffer_page_io | counter | Number of other/unknown (old version InnoDB) Pages written | | os_data_reads | os | status_counter | Number of reads initiated (innodb_data_reads) | | os_data_writes | os | status_counter | Number of writes initiated (innodb_data_writes) | | os_data_fsyncs | os | status_counter | Number of fsync() calls (innodb_data_fsyncs) | | os_pending_reads | os | counter | Number of reads pending | | os_pending_writes | os | counter | Number of writes pending | | os_log_bytes_written | os | status_counter | Bytes of log written (innodb_os_log_written) | | os_log_fsyncs | os | status_counter | Number of fsync log writes (innodb_os_log_fsyncs) | | os_log_pending_fsyncs | os | status_counter | Number of pending fsync write (innodb_os_log_pending_fsyncs) | | os_log_pending_writes | os | status_counter | Number of pending log file writes (innodb_os_log_pending_writes) | | trx_rw_commits | transaction | counter | Number of read-write transactions committed | | trx_ro_commits | transaction | counter | Number of read-only transactions committed | | trx_nl_ro_commits | transaction | counter | Number of non-locking auto-commit read-only transactions committed | | trx_commits_insert_update | transaction | counter | Number of transactions committed with inserts and updates | | trx_rollbacks | transaction | counter | Number of transactions rolled back | | trx_rollbacks_savepoint | transaction | counter | Number of transactions rolled back to savepoint | | trx_rseg_history_len | transaction | value | Length of the TRX_RSEG_HISTORY list | | trx_undo_slots_used | transaction | counter | Number of undo slots used | | trx_undo_slots_cached | transaction | counter | Number of undo slots cached | | trx_rseg_current_size | transaction | value | Current rollback segment size in pages | | purge_del_mark_records | purge | counter | Number of delete-marked rows purged | | purge_upd_exist_or_extern_records | purge | counter | Number of purges on updates of existing records and updates on delete marked record with externally stored field | | purge_invoked | purge | counter | Number of times purge was invoked | | purge_undo_log_pages | purge | counter | Number of undo log pages handled by the purge | | purge_dml_delay_usec | purge | value | Microseconds DML to be delayed due to purge lagging | | purge_stop_count | purge | value | Number of times purge was stopped | | purge_resume_count | purge | value | Number of times purge was resumed | | log_checkpoints | recovery | counter | Number of checkpoints | | log_lsn_last_flush | recovery | value | LSN of Last flush | | log_lsn_last_checkpoint | recovery | value | LSN at last checkpoint | | log_lsn_current | recovery | value | Current LSN value | | log_lsn_checkpoint_age | recovery | value | Current LSN value minus LSN at last checkpoint | | log_lsn_buf_pool_oldest | recovery | value | The oldest modified block LSN in the buffer pool | | log_max_modified_age_async | recovery | value | Maximum LSN difference; when exceeded, start asynchronous preflush | | log_pending_log_flushes | recovery | value | Pending log flushes | | log_pending_checkpoint_writes | recovery | value | Pending checkpoints | | log_num_log_io | recovery | value | Number of log I/Os | | log_waits | recovery | status_counter | Number of log waits due to small log buffer (innodb_log_waits) | | log_write_requests | recovery | status_counter | Number of log write requests (innodb_log_write_requests) | | log_writes | recovery | status_counter | Number of log writes (innodb_log_writes) | | log_padded | recovery | status_counter | Bytes of log padded for log write ahead | | compress_pages_compressed | compression | counter | Number of pages compressed | | compress_pages_decompressed | compression | counter | Number of pages decompressed | | compression_pad_increments | compression | counter | Number of times padding is incremented to avoid compression failures | | compression_pad_decrements | compression | counter | Number of times padding is decremented due to good compressibility | | compress_saved | compression | counter | Number of bytes saved by page compression | | compress_pages_page_compressed | compression | counter | Number of pages compressed by page compression | | compress_page_compressed_trim_op | compression | counter | Number of TRIM operation performed by page compression | | compress_pages_page_decompressed | compression | counter | Number of pages decompressed by page compression | | compress_pages_page_compression_error | compression | counter | Number of page compression errors | | compress_pages_encrypted | compression | counter | Number of pages encrypted | | compress_pages_decrypted | compression | counter | Number of pages decrypted | | index_page_splits | index | counter | Number of index page splits | | index_page_merge_attempts | index | counter | Number of index page merge attempts | | index_page_merge_successful | index | counter | Number of successful index page merges | | index_page_reorg_attempts | index | counter | Number of index page reorganization attempts | | index_page_reorg_successful | index | counter | Number of successful index page reorganizations | | index_page_discards | index | counter | Number of index pages discarded | | adaptive_hash_searches | adaptive_hash_index | status_counter | Number of successful searches using Adaptive Hash Index | | adaptive_hash_searches_btree | adaptive_hash_index | status_counter | Number of searches using B-tree on an index search | | adaptive_hash_pages_added | adaptive_hash_index | counter | Number of index pages on which the Adaptive Hash Index is built | | adaptive_hash_pages_removed | adaptive_hash_index | counter | Number of index pages whose corresponding Adaptive Hash Index entries were removed | | adaptive_hash_rows_added | adaptive_hash_index | counter | Number of Adaptive Hash Index rows added | | adaptive_hash_rows_removed | adaptive_hash_index | counter | Number of Adaptive Hash Index rows removed | | adaptive_hash_rows_deleted_no_hash_entry | adaptive_hash_index | counter | Number of rows deleted that did not have corresponding Adaptive Hash Index entries | | adaptive_hash_rows_updated | adaptive_hash_index | counter | Number of Adaptive Hash Index rows updated | | file_num_open_files | file_system | value | Number of files currently open (innodb_num_open_files) | | ibuf_merges_insert | change_buffer | status_counter | Number of inserted records merged by change buffering | | ibuf_merges_delete_mark | change_buffer | status_counter | Number of deleted records merged by change buffering | | ibuf_merges_delete | change_buffer | status_counter | Number of purge records merged by change buffering | | ibuf_merges_discard_insert | change_buffer | status_counter | Number of insert merged operations discarded | | ibuf_merges_discard_delete_mark | change_buffer | status_counter | Number of deleted merged operations discarded | | ibuf_merges_discard_delete | change_buffer | status_counter | Number of purge merged operations discarded | | ibuf_merges | change_buffer | status_counter | Number of change buffer merges | | ibuf_size | change_buffer | status_counter | Change buffer size in pages | | innodb_master_thread_sleeps | server | counter | Number of times (seconds) master thread sleeps | | innodb_activity_count | server | status_counter | Current server activity count | | innodb_master_active_loops | server | counter | Number of times master thread performs its tasks when server is active | | innodb_master_idle_loops | server | counter | Number of times master thread performs its tasks when server is idle | | innodb_log_flush_usec | server | counter | Time (in microseconds) spent to flush log records | | innodb_dict_lru_usec | server | counter | Time (in microseconds) spent to process DICT LRU list | | innodb_dict_lru_count_active | server | counter | Number of tables evicted from DICT LRU list in the active loop | | innodb_dict_lru_count_idle | server | counter | Number of tables evicted from DICT LRU list in the idle loop | | innodb_dblwr_writes | server | status_counter | Number of doublewrite operations that have been performed (innodb_dblwr_writes) | | innodb_dblwr_pages_written | server | status_counter | Number of pages that have been written for doublewrite operations (innodb_dblwr_pages_written) | | innodb_page_size | server | value | InnoDB page size in bytes (innodb_page_size) | | dml_reads | dml | status_counter | Number of rows read | | dml_inserts | dml | status_counter | Number of rows inserted | | dml_deletes | dml | status_counter | Number of rows deleted | | dml_updates | dml | status_counter | Number of rows updated | | dml_system_reads | dml | status_counter | Number of system rows read | | dml_system_inserts | dml | status_counter | Number of system rows inserted | | dml_system_deletes | dml | status_counter | Number of system rows deleted | | dml_system_updates | dml | status_counter | Number of system rows updated | | ddl_background_drop_indexes | ddl | counter | Number of indexes waiting to be dropped after failed index creation | | ddl_online_create_index | ddl | counter | Number of indexes being created online | | ddl_pending_alter_table | ddl | counter | Number of ALTER TABLE, CREATE INDEX, DROP INDEX in progress | | ddl_sort_file_alter_table | ddl | counter | Number of sort files created during alter table | | ddl_log_file_alter_table | ddl | counter | Number of log files created during alter table | | icp_attempts | icp | counter | Number of attempts for index push-down condition checks | | icp_no_match | icp | counter | Index push-down condition does not match | | icp_out_of_range | icp | counter | Index push-down condition out of range | | icp_match | icp | counter | Index push-down condition matches | +--------------------------------------------+---------------------+----------------+------------------------------------------------------------------------------------------------------------------+ 216 rows in set (0.000 sec)
© 2021 MariaDB
Licensed under the Creative Commons Attribution 3.0 Unported License and the GNU Free Documentation License.
https://mariadb.com/kb/en/information-schema-innodb_metrics-table/