Kevin Long: > > Hello, > > I have a single postfix server servicing my company?s domain and > several customer domains. All outbound mail is first received by > postfix, then sent to the same barracuda email service to go on > to it?s final destination. > > I want Postfix to use a specific local IPv4 address when it connects > to the barracuda relay, depending on which domain the email is > from. This will ultimately show up in the email headers for the > recipient, and I need to separate my company from the customers.
Configure an SMTP client in master.cf: /etc/postfix/master.cf: barracuda-1.2.3.4 ... . .. .. .. .. smtp -o smtp_bind_address=1.2.3.4 barracuda-1.2.3.5 ... . .. .. .. .. smtp -o smtp_bind_address=1.2.3.5 /etc/postfix/main.cf: sender_dependent_default_transport_maps = hash:/etc/postfix/sender_transport /etc/postfix/sender_transport: example.com barracuda-1.2.3.4: example.net barracuda-1.2.3.5: This requires Postfix 2.7 or later. Not saying that postfix->barracura->internet is a good idea, though. You could instead do postfix-barracuda-postfix(*) and use the same trick to set the IP address on the internet-facing Postfix SMTP client. That is the IP address that remote receivers will use for their IP-based reputation rankings. They don't care about some IP address on your internal network behind an outbound relay. Wietse