From c0955538b07db9ad532fd44f4c21276812fc34b6 Mon Sep 17 00:00:00 2001 From: Sean Reifschneider Date: Thu, 10 Dec 2009 13:54:48 +0100 Subject: [PATCH] Initial version --- plugins/other/pdns_rec_concurrent | 39 +++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100755 plugins/other/pdns_rec_concurrent diff --git a/plugins/other/pdns_rec_concurrent b/plugins/other/pdns_rec_concurrent new file mode 100755 index 00000000..86eb4ab5 --- /dev/null +++ b/plugins/other/pdns_rec_concurrent @@ -0,0 +1,39 @@ +#!/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 + +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 Recursor Concurrent Queries' + echo 'graph_order concurrent' + echo 'graph_vlabel queries' + echo 'graph_info Concurrent queries' + echo 'graph_category pdns' + + echo 'concurrent.label queries' + echo 'concurrent.min 0' + echo 'concurrent.type GAUGE' + echo 'concurrent.info Concurrent queries' + + exit 0 +fi + +echo concurrent.value `rec_control get concurrent-queries` + +exit 0