利用munin监控memcache

一.memcache监控点

'total_connections'  => 'conn/sec',
'total_items'    => 'items/sec',
'cmd_set'        => 'sets/sec',
'bytes_written'  => 'bytes/sec',
'evictions'      => 'evictions/sec',
'curr_items'     => 'curr_items/sec',
'cmd_get'        => 'gets/sec',
'get_hits'       => 'hits/sec',
'bytes_read'     => 'bytes/sec',
'get_misses'     => 'misses/sec',

'get_hit_rate'   => 'hit rate',


二.监控原理

memcache自带状态检测:stats

echo "status" | nc 127.0.0.1 11211


三.各监控点说明

1. total_connections/curr_connections

total_connections表示从memcache服务启动以来的连接总数量,可以用munin(RRD)的DERIVER标示记录

curr_connections表示当前实时的连接数,可以用munin(RRD)的GAUGE标示


2.total_items/curr_items同上

3.cmd_get/cmd_set为自启动以来的累加数目,使用DERIVER或者COUNTER

4.bytes_read/written_read同上

5.get_hits/get_misses同上

6.get_hit_rate由get_hits/cmd_get而来


四.munin插件脚本

https://github.com/liuzongqing/munin/tree/master/memcache

部署时注意脚本文件名格式(Category_Name_Port)



你可能感兴趣的:(memcache监控,memcachestats,memcachemunin,memcachemonitor)