Projet

Général

Profil

Révision db4ed002

IDdb4ed0029db45874a2ea7499666fb3f9066c4941
Parent 9521d76f
Enfant af3fb33d

Ajouté par Sean Reifschneider il y a presque 14 ans

Initial version

Voir les différences:

plugins/other/pdns_rec_outqueries
1
#!/bin/sh
2
#
3
#  pdns_recursor munin plugin.
4
#  Written by Sean Reifschneider <jafo@tummy.com> 2009-12-03
5
#  Placed in the public domain
6
#
7
#  Requires running as root:
8
#
9
#    echo '[pdns_rec_*]' >/etc/munin/plugin-conf.d/pdns_rec
10
#    echo 'user root' >>/etc/munin/plugin-conf.d/pdns_rec
11

  
12
if [ "$1" = "autoconf" ]; then
13
	if [ -e /usr/bin/rec_control ]; then
14
		echo yes
15
		exit 0
16
	else
17
		echo no
18
		exit 1
19
	fi
20
fi
21

  
22
if [ "$1" = "config" ]; then
23
	echo 'graph_title PDNS Outbound Queries'
24
	echo 'graph_order all tcp'
25
	echo 'graph_vlabel queries'
26
	echo 'graph_info Outbound queries'
27
	echo 'graph_category pdns'
28

  
29
	echo 'all.label all'
30
	echo 'all.min 0'
31
	echo 'all.max 100000'
32
	echo 'all.type COUNTER'
33
	echo 'all.info All queries'
34

  
35
	echo 'tcp.label tcp'
36
	echo 'tcp.min 0'
37
	echo 'tcp.max 100000'
38
	echo 'tcp.type COUNTER'
39
	echo 'tcp.info TCP queries'
40

  
41
	exit 0
42
fi
43

  
44
echo all.value `rec_control get all-outqueries`
45
echo tcp.value `rec_control get tcp-outqueries`
46

  
47
exit 0

Formats disponibles : Unified diff