Created
January 21, 2011 11:19
-
-
Save bngsudheer/789548 to your computer and use it in GitHub Desktop.
Postfix bounce count for the day by domains
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
domains="aol\.com yahoo\.com gmail\.com hotmail\.com" | |
datepart=`date "+%b %d"` | |
for domain in $domains | |
do | |
echo $domain | |
egrep "${datepart}.*${domain}.*bounced" /var/log/maillog | wc -l | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment