mirror of
https://github.com/munin-monitoring/contrib.git
synced 2018-11-08 00:59:34 +01:00
Category Tree: Collect all postfix plugins in category mail
This commit is contained in:
parent
db240286ab
commit
cc3622d96c
@ -103,7 +103,7 @@ case $1 in
|
||||
cat <<'EOF'
|
||||
graph_title Postfix Queue Size
|
||||
graph_vlabel KB in Queue
|
||||
graph_category postfix
|
||||
graph_category mail
|
||||
graph_total Total
|
||||
active.label active
|
||||
deferred.label deferred
|
@ -36,10 +36,10 @@ fi
|
||||
if [ "$1" = "config" ]; then
|
||||
|
||||
echo 'graph_title Postfix Mail Counter'
|
||||
echo 'graph_category postfix'
|
||||
echo 'graph_args --base 1000 -l 0'
|
||||
echo 'graph_vlabel Hourly Messages'
|
||||
echo 'recieved.label Delivered'
|
||||
echo 'graph_category mail'
|
||||
echo 'received.label Delivered'
|
||||
echo 'sent.label Outgoing'
|
||||
echo 'rejecthelo.label Invalid HELO'
|
||||
echo 'rejectsenderdomain.label need FQDN'
|
||||
@ -49,21 +49,21 @@ if [ "$1" = "config" ]; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
echo -en "recieved.value "
|
||||
echo $(grep "postfix/lmtp\[" $LOGFILE | grep "$DATE" -c)
|
||||
echo -en "received.value "
|
||||
echo $(grep "status=sent (delivered" $LOGFILE | grep "$DATE" | wc -l)
|
||||
echo -n
|
||||
echo -en "sent.value "
|
||||
echo $(grep "postfix/smtp\[" $LOGFILE | grep "$DATE" -c)
|
||||
echo $(grep "status=sent (250" $LOGFILE | grep "$DATE" | wc -l)
|
||||
echo -en "rejecthelo.value "
|
||||
echo $(grep "Helo command rejected: need fully-qualified hostname" $LOGFILE | grep "$DATE" -c)
|
||||
echo $(grep "Helo command rejected: need fully-qualified hostname" $LOGFILE | grep "$DATE" | wc -l)
|
||||
echo -en "rejectsenderdomain.value "
|
||||
echo $(grep "Sender address rejected: Domain not found" $LOGFILE | grep "$DATE" -c)
|
||||
echo $(grep "Sender address rejected: Domain not found" $LOGFILE | grep "$DATE" | wc -l)
|
||||
|
||||
|
||||
echo -en "denyrelay.value "
|
||||
echo $(grep "Relay access denied" $LOGFILE | grep "$DATE" -c)
|
||||
echo $(grep "Relay access denied" $LOGFILE | grep "$DATE" | wc -l)
|
||||
echo -en "spamhaus.value "
|
||||
echo $(grep "blocked using sbl-xbl.spamhaus.org" $LOGFILE | grep "$DATE" -c)
|
||||
echo $(grep "blocked using sbl-xbl.spamhaus.org" $LOGFILE | grep "$DATE" | wc -l)
|
||||
echo -en "spamcop.value "
|
||||
echo $(grep "blocked using bl.spamcop.net" $LOGFILE | grep "$DATE" -c)
|
||||
echo $(grep "blocked using bl.spamcop.net" $LOGFILE | grep "$DATE" | wc -l)
|
||||
|
||||
|
@ -36,10 +36,10 @@ fi
|
||||
if [ "$1" = "config" ]; then
|
||||
|
||||
echo 'graph_title Postfix Mail Counter'
|
||||
echo 'graph_category postfix'
|
||||
echo 'graph_args --base 1000 -l 0'
|
||||
echo 'graph_vlabel Hourly Messages'
|
||||
echo 'graph_category mail'
|
||||
echo 'received.label Delivered'
|
||||
echo 'recieved.label Delivered'
|
||||
echo 'sent.label Outgoing'
|
||||
echo 'rejecthelo.label Invalid HELO'
|
||||
echo 'rejectsenderdomain.label need FQDN'
|
||||
@ -49,21 +49,21 @@ if [ "$1" = "config" ]; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
echo -en "received.value "
|
||||
echo $(grep "status=sent (delivered" $LOGFILE | grep "$DATE" | wc -l)
|
||||
echo -en "recieved.value "
|
||||
echo $(grep "postfix/lmtp\[" $LOGFILE | grep "$DATE" -c)
|
||||
echo -n
|
||||
echo -en "sent.value "
|
||||
echo $(grep "status=sent (250" $LOGFILE | grep "$DATE" | wc -l)
|
||||
echo $(grep "postfix/smtp\[" $LOGFILE | grep "$DATE" -c)
|
||||
echo -en "rejecthelo.value "
|
||||
echo $(grep "Helo command rejected: need fully-qualified hostname" $LOGFILE | grep "$DATE" | wc -l)
|
||||
echo $(grep "Helo command rejected: need fully-qualified hostname" $LOGFILE | grep "$DATE" -c)
|
||||
echo -en "rejectsenderdomain.value "
|
||||
echo $(grep "Sender address rejected: Domain not found" $LOGFILE | grep "$DATE" | wc -l)
|
||||
echo $(grep "Sender address rejected: Domain not found" $LOGFILE | grep "$DATE" -c)
|
||||
|
||||
|
||||
echo -en "denyrelay.value "
|
||||
echo $(grep "Relay access denied" $LOGFILE | grep "$DATE" | wc -l)
|
||||
echo $(grep "Relay access denied" $LOGFILE | grep "$DATE" -c)
|
||||
echo -en "spamhaus.value "
|
||||
echo $(grep "blocked using sbl-xbl.spamhaus.org" $LOGFILE | grep "$DATE" | wc -l)
|
||||
echo $(grep "blocked using sbl-xbl.spamhaus.org" $LOGFILE | grep "$DATE" -c)
|
||||
echo -en "spamcop.value "
|
||||
echo $(grep "blocked using bl.spamcop.net" $LOGFILE | grep "$DATE" | wc -l)
|
||||
echo $(grep "blocked using bl.spamcop.net" $LOGFILE | grep "$DATE" -c)
|
||||
|
@ -106,7 +106,7 @@ case $1 in
|
||||
echo "graph_title Postfix Mailqueue $CONFIG";
|
||||
cat <<'EOF'
|
||||
graph_vlabel Mails in queue
|
||||
graph_category postfix
|
||||
graph_category mail
|
||||
graph_total Total
|
||||
active.label active
|
||||
deferred.label deferred
|
||||
|
@ -144,7 +144,7 @@ if ($ARGV[0] and $ARGV[0] eq "config")
|
||||
print "graph_vlabel Mails in Queue log\n";
|
||||
print "graph_scale no\n"; # so we do not print "micro, milli, kilo, etc"
|
||||
# print "graph_total Total\n";
|
||||
print "graph_category postfix\n";
|
||||
print "graph_category mail\n";
|
||||
foreach my $i (@status_list)
|
||||
{
|
||||
if ($descriptions{$i})
|
||||
|
@ -72,7 +72,7 @@ sub config
|
||||
print "graph_vlabel mails / \${graph_period}\n";
|
||||
print "graph_scale no\n";
|
||||
print "graph_total Total\n";
|
||||
print "graph_category postfix\n";
|
||||
print "graph_category mail\n";
|
||||
print "delivered.label delivered\n";
|
||||
print "delivered.type ABSOLUTE\n";
|
||||
print "delivered.draw AREA\n";
|
@ -145,7 +145,7 @@ if ( $ARGV[0] and $ARGV[0] eq "config" )
|
||||
print "graph_vlabel mails / \${graph_period}\n";
|
||||
print "graph_scale no\n";
|
||||
print "graph_total Total\n";
|
||||
print "graph_category postfix\n";
|
||||
print "graph_category mail\n";
|
||||
print "delivered.label delivered\n";
|
||||
print "delivered.type DERIVE\n";
|
||||
print "delivered.draw AREA\n";
|
||||
|
@ -158,7 +158,7 @@ if ($ARGV[0] and $ARGV[0] eq "config")
|
||||
print "graph_args --base 1000 -l 0\n";
|
||||
print "graph_vlabel bytes / \${graph_period}\n";
|
||||
print "graph_scale yes\n";
|
||||
print "graph_category postfix\n";
|
||||
print "graph_category mail\n";
|
||||
print "graph_total Throughput sum\n";
|
||||
# loop through the postfix names and create per config an entry
|
||||
foreach $syslog_name (@postfix_syslog_name)
|
||||
|
Loading…
Reference in New Issue
Block a user