#!/bin/sh # # pdns_recursor munin plugin. # Written by Sean Reifschneider 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 rec_control="/usr/bin/rec_control" if [ "$1" = "autoconf" ]; then if [ -e "$rec_control" ]; then echo yes exit 0 else echo "no (missing $rec_control)" exit 0 fi fi if [ "$1" = "config" ]; then echo 'graph_title PDNS Recursor Throttling' echo 'graph_order throttled' echo 'graph_vlabel queries' echo 'graph_info Throttled queries' echo 'graph_category dns' echo 'throttled.label throttled' echo 'throttled.min 0' echo 'throttled.type COUNTER' echo 'throttled.info Throttled queries' exit 0 fi echo throttled.value "$($rec_control get throttled-out)" exit 0