plugins-qmailqueue-virus: virus

File virus, 0.7 kB (added by david@cryptix.de, 6 years ago)

Plugin to count the daily amount of Virii (qmailscan)

Line 
1 #!/bin/sh
2 #
3 # Plugin to count the daily amount of Virii (qmailscan)
4 #
5 # Contributed by David Obando (david@cryptix.de) - 23.11.2005
6 #
7 #
8 # Magic markers - optional - used by installation scripts and
9 # munin-config:
10 #
11 #%# family=manual
12 #%# capabilities=autoconf
13
14 if [ "$1" = "autoconf" ]; then
15         echo yes
16         exit 0
17 fi
18
19 if [ "$1" = "config" ]; then
20
21         echo 'graph_title Virus amount'
22         echo 'graph_args --base 1000 -l 0 '
23         echo 'graph_vlabel Daily Virus Amount'
24         echo 'graph_category Mail'
25         echo 'virus.label Virus'
26         echo 'virus.draw AREA'
27         exit 0
28 fi
29
30 echo -n "virus.value " && grep "`date +%d\ %b\ %Y`" /var/spool/qmailscan/quarantine.log /var/spool/qmailscan/quarantine.log.1 |wc -l
31