I use a VPS as my main hub for all of my work. That is: openvpn, routing and forwarding for facebook callbacks to my machine, hosting dev/staging apps, and so on and so forth.
As I was trying to set up some forwarding over the VPN that this server hosts, I mangled up IPTables (wrong forward ip or something) and locked myself out of ssh access. Luckily Linode can help with that. But the thing I did not notice before locking myself out was that I was no longer getting my mail forwarded. Postfix was blocked by IPTables… and thus I lost a day of email (It DID seem odd that I would get no email for a whole day when I usually get upwards from 20 emails).
Moral: be careful with IPTables… any rule you add from the console is cumulative. More is not better … you want to block evil, but alow good, and not forward the wrong thing.
Keep a backup:
/etc/iptables/rules.backup
Restore the backup with:
iptables-restore < /etc/iptables/rules.backup
Save the settings after you’ve set new rules from the console with:
iptables-save
If you see any duplicate rules (I like nano!):
nano /etc/iptables/rules
and remove the offending lines.
In retrospect I don’t know if this experience was so destructive as I initially though… some emails that I was aware of before the blackout have come through once I fixed the setup. Postfix must have a queue. Despite my repeated rebooting of the server all seems good! I love it when things work even when they break!
Good luck!