If you have aliased IP Address, all connection made from your server will be seen as you main IP Address by the outside world, unless of course, stated otherwise.
In this case, one of my server have around 5 usable IP Address, and only two are effectively in use, one for the the web server and the other is for inbound Mail Server IP Address. I am using postfix MTA which by default listen to all IP Address(es) in your server including the loopback (localhost).
If you want to use a dedicated IP Address to send emails to the outside world, in postfix, you can either;
- Set the inet_interfaces into one spesific IP Address, e.g. inet_interfaces = 117.103.xx.xx, the IP Address can’t be loopback address.
- Or, use the smtp_bind_address parameter
SMTP Bind Address
I need postfix to listen on loopback address, so option one is no go, so I try using option smtp_bind_address, which according to the manual can be configured either through main.cf, or master.cf.
I try master.cf first so I can use different IP Address from the one use by inbound mail, but was not successful, so I try to put the parameter in the main.cf.
smtp_bind_address = 117.103.xx.xx
Where 117.103.xx.xx is the same IP Address used by mx host name stated in the DNS config. I am still experimenting with the master.cf, and intend to update this post when successful.


One Trackback
[...] Read more here: Setup Outbound Mail IP Address for Postfix [...]