28 lines
507 B
Bash
Executable File

#!/bin/sh
# Unbound statistics
# (c) 2012, Tom Laermans for Observium (www.observium.org)
# Required server configuration:
#
# statistics-cumulative: yes
# extended-statistics: yes
if [[ -x '/usr/sbin/unbound-control' ]];
then
unboundctl='/usr/sbin/unbound-control'
elif [[ -x '/usr/local/sbin/unbound-control' ]];
then
unboundctl='/usr/local/sbin/unbound-control'
else
unboundctl=`which unbound-control`
fi
if [ $? -eq 0 ]
then
echo '<<<app-unbound>>>'
$unboundctl stats
fi