Added on Jul 31st, 2012 and marked as mail quarantine spam

To clean up the quarantine folder old quarantined spam or virus messages can be removed. Add the following lines to the crontab to remove each day messages older than 30 days:

# Remove old quarantined messages (>30 days).
# - Spam
0 3 * * * find /var/lib/amavis/virusmails/ -name "spam-*.gz" -mtime +30 -exec rm {} ; >> /var/log/quarantine_cleanup.log 2>&1
# - Bad headers
0 3 * * * find /var/lib/amavis/virusmails/ -name "badh-*" -mtime +30 -exec rm {} ; >> /var/log/quarantine_cleanup.log 2>&1
# - Banned files
0 3 * * * find /var/lib/amavis/virusmails/ -name "banned-*" -mtime +30 -exec rm {} ; >> /var/log/quarantine_cleanup.log 2>&1
# - Virus
0 3 * * * find /var/lib/amavis/virusmails/ -name "virus-*" -mtime +30 -exec rm {} ; >> /var/log/quarantine_cleanup.log 2>&1