Friday, December 21, 2012

adventures in exim or mail apocalypse

whoopsies!
i renumbered a range of systems, but failed to edit my exim conf file to allow relaying from the new subnet... the messages were first bounced when i failed to add the interface. and then frozen when i failed to add the new network.

hoo hum.

those relays are defined here:
dc_relay_nets='net/20;net/24'
another interface added:
dc_local_interfaces='127.0.0.1:ww.xx.yy.zz:ww.xx.yy.zz'
and now the good stuff...

unfreeze a single message:
exim -Mt messageid
unfreeze the entire queue and resend:
exim4 -qff
unfreeze the entire queue and force resend:
mailq | grep frozen | awk '{print $3}' | xargs exim -v -M 
remove all frozen messages:
exiqgrep -z -i | xargs exim -Mrm
to watch the fun, open up another terminal and
tail -f -n 20 /var/log/exim4/mainlog 
corrupt database:
/usr/sbin/exim_tidydb -t 1d /var/spool/exim retry > /dev/null 
/usr/sbin/exim_tidydb -t 1d /var/spool/exim reject > /dev/null 
/usr/sbin/exim_tidydb -t 1d /var/spool/exim wait-remote_smtp > /dev/null

No comments: