PDA

View Full Version : Force postfix to send on specific IP


Noodles25
5th September 2008, 04:48
I have a server with multiple IPs, I can't work out how to force postfix to send via one of our virtual IPs rather than the main IP. (For example main IP is 1.2.3.4, virtual IP is 4.3.2.1)

I've tried this in main.cf:
inet_interfaces = 4.3.2.1

I've tried this in master.cf

4.3.2.1:smtp inet n - n - - smtpd


Using Postfix 2.3.3 on RHEL5

Can anyone tell me how to force postfix to send on 4.3.2.1 ?

kalinix
5th September 2008, 13:52
you may want to use smtp_bind_address. man 5 postconf and look for it

Noodles25
8th September 2008, 00:47
I've tried that and it looks like it should bind to inet_interfaces. Neither of which seem to work.

topdog
8th September 2008, 09:58
If it does not work then use NAT to rewrite the source address of the smtp packets before they leave your server.