Sending emails through another ip address [SOLVED]

Discuss your pilot or production implementation with other Zimbra admins or our engineers.
Klug
Ambassador
Ambassador
Posts: 2774
Joined: Mon Dec 16, 2013 11:35 am
Location: France - Drôme
ZCS/ZD Version: All of them
Contact:

Re: Sending emails through another ip address [SOLVED]

Post by Klug »

Zimbra -> VPS running postfix (not part of Zimbra, with multiple IPs) -> internet
This way you can do exactly what you want and it survives any kind of Zimbra upgrade.

On the VPS running postfix, you can use the sender_dependent_relayhost_maps.
https://stackoverflow.com/questions/304 ... -output-ip
loocek
Advanced member
Advanced member
Posts: 64
Joined: Sat Sep 13, 2014 1:14 am
Contact:

Re: Sending emails through another ip address [SOLVED]

Post by loocek »

Unbelivable but it works!! :)
For reminder: on Zimbra 8.8.15 FOSS.

Let me show to all what exactly I configured:
1. Getting back to orig value of:
zmprov ms `zmhostname` zimbraMtaTransportMaps "proxy:ldap:/opt/zimbra/conf/ldap-transport.cf"

2. As root adding last line to /opt/zimbra/common/conf/main.cf
sender_dependent_default_transport_maps = lmdb:/opt/zimbra/common/conf/sender_transport_sdata

3. Filling out sender_transport_sdata file:
@lk.com.eu martel12:

4. As Zimbra user postmaping file:
cd /opt/zimbra/common/conf/
postmap lmdb:/opt/zimbra/common/conf/sender_transport_sdata

4. Adding lines to /opt/zimbra/common/conf/master.cf.in
martel12 unix - - n - - smtp
-o smtp_bind_address=81.124.33.12
-o smtp_helo_name=lk.com.eu
-o syslog_name=postfix/martel12

5. zmcontrol restart

And thats it !

Cheers to all and thanks Klug for helping out.
Good hosting:
https://sdata.net.pl
Klug
Ambassador
Ambassador
Posts: 2774
Joined: Mon Dec 16, 2013 11:35 am
Location: France - Drôme
ZCS/ZD Version: All of them
Contact:

Re: Sending emails through another ip address [SOLVED]

Post by Klug »

The problem with that is that it will disappear on next upgrade of zimbra-mta.
Post Reply