PluginOutdatedCatalog: freeradius.2

File freeradius.2, 1.1 KB (added by lkarsten@…, at 2006-06-07T15:42:13+02:00)

shinyer!

Line 
1#!/bin/sh
2#
3# Plugin to count the daily amount of freeradius logins.
4#
5# Freeradius must be configured to log to syslog for this to
6# work.
7#
8# Written by Lasse Karstensen <lkarsten@hyse.org> june 2006.
9# Based on 'virus' -plugin.
10#
11# Magic markers - optional - used by installation scripts and
12# munin-config:
13#
14#%# family=manual
15#%# capabilities=autoconf
16
17if [ "$1" = "autoconf" ]; then
18        echo yes
19        exit 0
20fi
21
22if [ "$1" = "config" ]; then
23        echo 'graph_title freeradius requests'
24        echo 'graph_args --base 1000 -l 0 '
25        echo 'graph_vlabel requests / ${graph_period}'
26        echo 'graph_category Other'
27        echo 'success.label successful auths'
28        echo 'success.info Successful radius auths'
29        echo 'success.type DERIVE'
30        echo 'success.min 0'
31        echo 'failed.label failed auths'
32        echo 'failed.info Failed radius auths'
33        echo 'failed.type DERIVE'
34        echo 'failed.min 0'
35        exit 0
36fi
37
38echo -n "success.value " && egrep "`date +%b\ %e`.*radiusd.*Login OK"        /var/log/messages|wc -l
39echo -n "failed.value "  && egrep "`date +%b\ %e`.*radiusd.*Login incorrect" /var/log/messages|wc -l
40