check_mysql_health
Options:–hostname
the database server’s hostname
–port
the database’s port. (default: 3306)
–socket
the database’s unix socket.
–username
the mysql db user
–password
the mysql db user’s password
–database
the database’s name. (default: information_schema)
–warning
the warning range
–critical
the critical range
–mode
the mode of the plugin. select one of the following keywords:
connection-time 连接到服务器上的时间
uptime 服务器运行的时间
threads-connected 当前连接到数据库的连接数
threadcache-hitrate 线程缓存命中率
slave-lag slave落后master多少时间
slave-io-running slave复制是否正常
slave-sql-running slave复制是否正常
qcache-hitrate 查询缓存命中率 //这个命中率越高,表明服务器的select查询性能越好。
qcache-lowmem-prunes (Query cache entries pruned because of low memory:由于内存较小从缓存中删除的查询量)// 增大query_cache_size的值,以减小lowmem,增加缓存命中率。
keycache-hitrate (MyISAM key cache hitrate :key缓存命中率)如果命中率过低,则调大key_buffer_size
bufferpool-hitrate (InnoDB buffer pool hitrate:innodb缓冲池命中率)
bufferpool-wait-free (InnoDB buffer pool waits for clean page available:innodb的缓存池等等清理页。)
log-waits (InnoDB log waits because of a too small log buffer:因为太小log缓冲区导致innodb log等待。)
tablecache-hitrate 表缓存命中率
table-lock-contention 表锁率
table_locks_waited;不能立即获得的表的锁表次数。
table_locak_waited;立即获得的表的锁表次数。
小于1%较优,如果1%需要引起注意,大于3%性能有问题。
index-usage 索引使用情况
tmp-disk-tables (Percent of temp tables created on disk:建立的临时表)
slow-queries 慢查询
long-running-procs 长时间运行的进程
cluster-ndbd-running ndb节点运行状况
sql 返回一个数字的任何SQL语句
页:
[1]