Created
September 3, 2013 21:14
-
-
Save davidbehan/6429701 to your computer and use it in GitHub Desktop.
Some atmail/exim commands for searching and managing the message queue
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
# start/stop/restart atmail | |
/etc/init.d/atmailserver start | |
/etc/init.d/atmailserver stop | |
/etc/init.d/atmailserver restart | |
# count of messages in queue | |
/usr/local/atmail/mailserver/bin/exim -bpc | |
# list of messages in queue | |
/usr/local/atmail/mailserver/bin/exim -bp | |
# Freeze message | |
/usr/local/atmail/mailserver/bin/exim -Mf 1UQh1e-00071v-Q5 | |
# Remove messages older than 86400 (1 day) | |
/usr/local/atmail/mailserver/bin/exiqgrep -o 86400 -i | xargs /usr/local/atmail/mailserver/bin/exim -Mrm | |
# Delete message that contain 'a certain string' | |
grep -lr 'a certain string' /usr/local/atmail/mailserver/spool/input/ | \sed -e 's/^.*\/\([a-zA-Z0-9-]*\)-[DH]$/\1/g' | xargs /usr/local/atmail/mailserver/bin/exim -Mrm | |
# View body of message | |
/usr/local/atmail/mailserver/bin/exim -Mvb 1UQh1e-00071v-Q5 | |
# View headers of message | |
/usr/local/atmail/mailserver/bin/exim -Mvh 1UQh1e-00071v-Q5 | |
# List of message ids on the queue | |
/usr/local/atmail/mailserver/bin/exim -i | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment