mirror of
https://github.com/munin-monitoring/contrib.git
synced 2018-11-08 00:59:34 +01:00
Initial version
This commit is contained in:
parent
a6eb89e7f4
commit
7e1661a7b8
45
plugins/other/pdns_rec_cache_size
Executable file
45
plugins/other/pdns_rec_cache_size
Executable file
@ -0,0 +1,45 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# pdns_recursor munin plugin.
|
||||
# Written by Sean Reifschneider <jafo@tummy.com> 2009-12-03
|
||||
# Placed in the public domain
|
||||
#
|
||||
# Requires running as root:
|
||||
#
|
||||
# echo '[pdns_rec_*]' >/etc/munin/plugin-conf.d/pdns_rec
|
||||
# echo 'user root' >>/etc/munin/plugin-conf.d/pdns_rec
|
||||
|
||||
if [ "$1" = "autoconf" ]; then
|
||||
if [ -e /usr/bin/rec_control ]; then
|
||||
echo yes
|
||||
exit 0
|
||||
else
|
||||
echo no
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ "$1" = "config" ]; then
|
||||
echo 'graph_title PDNS Cache Size'
|
||||
echo 'graph_order entries negative'
|
||||
echo 'graph_vlabel entries'
|
||||
echo 'graph_info Size of the cache'
|
||||
echo 'graph_category pdns'
|
||||
|
||||
echo 'entries.label Entries'
|
||||
echo 'entries.min 0'
|
||||
echo 'entries.type GAUGE'
|
||||
echo 'entries.info Cache entries'
|
||||
|
||||
echo 'negative.label Negative entries'
|
||||
echo 'negative.min 0'
|
||||
echo 'negative.type GAUGE'
|
||||
echo 'negative.info Cache negative entries'
|
||||
|
||||
exit 0
|
||||
fi
|
||||
|
||||
echo entries.value `rec_control get cache-entries`
|
||||
echo negative.value `rec_control get negcache-entries`
|
||||
|
||||
exit 0
|
Loading…
Reference in New Issue
Block a user