MostlyChris

Thoughts that are my own.

Forcing Mail Out a Different IP on a Server

If you need to force outbound mail out a different IP address on the server, you can do this using iptables with the following rule:

iptables -t nat -A POSTROUTING -p tcp -s ! 127.0.0.1 --dport 25 -j SNAT --to-source

Comments