Subject: | Check failure when Cache Hit Ratio = 0 |
When running the plugin against an idle memcached the Cache Hit Ratio is
actually 0, the script fails. Their is probably a divide by zero problem.
This is the error you get:
[nagios@SJVP00MON001 objects]$ /usr/local/nagios/libexec/check_memcached
-H sjvp00mch001 --hit-warning 4 --hit-critical 1
MEMCACHED OK - OK, Hit checked: OK - stats cmd_get is zero at
sjvp00mch001:11211
Similarly, if you specify the hit-critical threshold, it also fails in a
different way:
[nagios@SJVP00MON001 objects]$ /usr/local/nagios/libexec/check_memcached
-H sjvp00mch001 --hit-warning 4 --hit-critical 0
MEMCACHED OK - OK
[nagios@SJVP00MON001 objects]$ perl -v
This is perl, v5.10.0 built for x86_64-linux