Table_locks_immediate

Table_locks_immediate表示立即释放表锁数,Table_locks_waited表示需要等待的表锁数,
如果Table_locks_immediate / Table_locks_waited > 5000,最好采用InnoDB引擎,
因为InnoDB是行锁而MyISAM是表锁,对于高并发写入的应用InnoDB效果会好些。

 



 

 

 

 

 

MySQL Exporter 是一个监控 MySQL 数据库的工具,可以将 MySQL 的监控指标暴露为 Prometheus 可以抓取的格式。以下是 MySQL Exporter 可以监控的指标列表: - mysql_active_threads - mysql_bytes_received - mysql_bytes_sent - mysql_commands_total - mysql_connections_aborted - mysql_connections_total - mysql_created_tmp_disk_tables - mysql_created_tmp_files - mysql_created_tmp_tables - mysql_flush_commands - mysql_innodb_active_transactions - mysql_innodb_buffer_pool_bytes_data - mysql_innodb_buffer_pool_bytes_dirty - mysql_innodb_buffer_pool_pages_data - mysql_innodb_buffer_pool_pages_dirty - mysql_innodb_buffer_pool_pages_flushed - mysql_innodb_buffer_pool_pages_free - mysql_innodb_buffer_pool_pages_misc - mysql_innodb_buffer_pool_pages_total - mysql_innodb_buffer_pool_read_ahead - mysql_innodb_buffer_pool_read_ahead_evicted - mysql_innodb_buffer_pool_read_requests - mysql_innodb_buffer_pool_reads - mysql_innodb_buffer_pool_wait_free - mysql_innodb_buffer_pool_write_requests - mysql_innodb_checkpoint_age - mysql_innodb_current_row_locks - mysql_innodb_data_fsyncs - mysql_innodb_data_pending_fsyncs - mysql_innodb_data_pending_reads - mysql_innodb_data_pending_writes - mysql_innodb_data_read - mysql_innodb_data_reads - mysql_innodb_data_written - mysql_innodb_dblwr_pages_written - mysql_innodb_dblwr_writes - mysql_innodb_deadlocks - mysql_innodb_history_list_length - mysql_innodb_ibuf_free_list - mysql_innodb_ibuf_merged - mysql_innodb_ibuf_merges - mysql_innodb_ibuf_size - mysql_innodb_log_waits - mysql_innodb_log_write_requests - mysql_innodb_log_writes - mysql_innodb_lsn_current - mysql_innodb_lsn_flushed - mysql_innodb_lsn_last_checkpoint - mysql_innodb_mem_adaptive_hash - mysql_innodb_mem_dictionary - mysql_innodb_mem_total - mysql_innodb_mutex_os_waits - mysql_innodb_mutex_spin_rounds - mysql_innodb_mutex_spin_waits - mysql_innodb_num_open_files - mysql_innodb_num_open_files_hist - mysql_innodb_os_log_fsyncs - mysql_innodb_os_log_pending_fsyncs - mysql_innodb_os_log_pending_writes - mysql_innodb_os_log_written - mysql_innodb_pages_created - mysql_innodb_pages_read - mysql_innodb_pages_written - mysql_innodb_pending_aio_log_ios - mysql_innodb_pending_aio_sync_ios - mysql_innodb_pending_buffer_pool_flushes - mysql_innodb_pending_checkpoint_writes - mysql_innodb_pending_ibuf_aio_reads - mysql_innodb_pending_log_flushes - mysql_innodb_pending_log_writes - mysql_innodb_pending_normal_aio_reads - mysql_innodb_pending_normal_aio_writes - mysql_innodb_queries_inside - mysql_innodb_queries_queued - mysql_innodb_read_views - mysql_innodb_rows_deleted - mysql_innodb_rows_inserted - mysql_innodb_rows_read - mysql_innodb_rows_updated - mysql_innodb_s_lock_os_waits - mysql_innodb_s_lock_spin_rounds - mysql_innodb_s_lock_spin_waits - mysql_innodb_sem_waits - mysql_innodb_sem_wait_time_ms - mysql_innodb_tables_in_use - mysql_innodb_x_lock_os_waits - mysql_innodb_x_lock_spin_rounds - mysql_innodb_x_lock_spin_waits - mysql_max_used_connections - mysql_open_files - mysql_open_streams - mysql_open_tables - mysql_opened_tables - mysql_prepared_stmt_count - mysql_qcache_free_blocks - mysql_qcache_free_memory - mysql_qcache_hits - mysql_qcache_inserts - mysql_qcache_lowmem_prunes - mysql_qcache_not_cached - mysql_qcache_queries_in_cache - mysql_qcache_total_blocks - mysql_queries - mysql_questions - mysql_select_full_join - mysql_select_full_range_join - mysql_select_range - mysql_select_range_check - mysql_select_scan - mysql_slave_lag_seconds - mysql_slow_queries - mysql_sort_merge_passes - mysql_sort_range - mysql_sort_rows - mysql_sort_scan - mysql_table_locks_immediate - mysql_table_locks_waited - mysql_table_open_cache_hits - mysql_table_open_cache_misses - mysql_table_open_cache_overflows - mysql_threadpool_idle_threads - mysql_threadpool_threads - mysql_threads_cached - mysql_threads_connected - mysql_threads_created - mysql_threads_running 上述指标可以帮助你监控 MySQL 数据库的性能和状态,例如连接数、查询数、缓存命中率、锁等待情况、InnoDB 的缓存和 IO 操作等。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值