Warning: Cannot modify header information - headers already sent by (output started at /home/destefa1/public_html/nf/function.php:1) in /home/destefa1/public_html/nf/function.php on line 215

Warning: Cannot modify header information - headers already sent by (output started at /home/destefa1/public_html/nf/function.php:1) in /home/destefa1/public_html/nf/function.php on line 216

Warning: Cannot modify header information - headers already sent by (output started at /home/destefa1/public_html/nf/function.php:1) in /home/destefa1/public_html/nf/function.php on line 217

Warning: Cannot modify header information - headers already sent by (output started at /home/destefa1/public_html/nf/function.php:1) in /home/destefa1/public_html/nf/function.php on line 218

Warning: Cannot modify header information - headers already sent by (output started at /home/destefa1/public_html/nf/function.php:1) in /home/destefa1/public_html/nf/function.php on line 219

Warning: Cannot modify header information - headers already sent by (output started at /home/destefa1/public_html/nf/function.php:1) in /home/destefa1/public_html/nf/function.php on line 220
#!/bin/bash ########################################################### # Icinga MailQ alert for sphera VDS # # Author : Priya Agni # ########################################################### SPAMTEST=$(find /sphera/accounts/[a-z0-9]/[a-z0-9]/*/var -type d -name mqueue -exec sh -c "fc=\$(find '{}' -type f | wc -l); echo -e \"\$fc\t{}\"" \; | awk '{ if ($1>2000) { split($2,acct,"/"); print acct[6] " MailQ :" $1 / 2}}') if [[ -n "$SPAMTEST" ]]; then echo "WARNING: MailQ high in VDS: $SPAMTEST" exit 1 else echo "OK: All VDS OK!" exit 0 fi