bounceHammer has been EOL'ed on February 29, 2016

EOL on February 29, 2016

bounceHammer have been downloaded and used by many users and companies since the first release on March 2010 and has been EOL: End Of Life on February 29, 2016. Thanks for using bounceHammer for a long time. We are now providing Sisimai (the successor of bounceHammer, more faster, more higher precision of analysis) as a bounce mail parser library in BSD 2-Clause License.

14. Periodically run by crontab


Run periodically through crontab

Like the figure in Internal Flow page, You want to run bounceHammer(pasing, logging, inserting to the db, and so on.) periodically, You may use crontab.

Sample configuration of crontab have been installed as INSTALL-DESTINATION/etc/crontab-example.

Setting up crontab

There is /etc/crontab in generic Linux/UNIX hosts, but If /etc/crontab does not exist, Run the command crontab -e as root user.

In this section, bounced emails have been saved in /var/mail/bouncedemail as a mailbox, and have been saved in /home/postmaster/Maildir/new .

Edit cronta as with root privileges
# crontab -e
# bounceHammer PARSE | UPDATE | INSERT
BHROOT = '/usr/local/bouncehammer'
BMBOX = '/var/mail/bouncemail'
BMDIR = '/home/postmaster/Maildir/new'

# Run mailboxparser(parsing) every 10 minutes
0-59/10 * * * * ${BHROOT}/bin/mailboxparser -g --log ${BMBOX} --remove
0-59/10 * * * * ${BHROOT}/bin/mailboxparser -g --log ${BMDIR} --remove

# Run logger every 15 minutes
0-59/15 * * * * ${BHROOT}/bin/logger -c --remove

# Insert today's parsed log into the database an hour
00 * * * * ${BHROOT}/bin/databasectl --update --today

# 3 a.m., Insert yesterday's parsed log into the database
00 03 * * * ${BHROOT}/bin/databasectl --update --yesterday

After you have set the crontab, bounceHammer will run periodically.