Postfix local relay.
Doe anyone know if there is a way to relay internal and external mail for one domain hosted on my postfix server.. example;
userA@domainA.com -> smtp relay -> userB@domainA.com
Right now postfix will only use the smtp relay if the send to address is an external address. I need Postfix to route all mail regardless of the destination through the smtp relay. I only need to do this on a per domain basis.
Thanks for your help.
An smtp relay....sends messages to another smtp server because the local mail domain doesn't match the destination domain in the e-mail.
Your example says domainA > domainA ??? If you are *forwarding* mail from one account to another, you are not looking for an "smtp relay."
You may want to look at creating aliases so that mail is forwarded...
Let me clear this up.
Currently I am using the sender_dependent_relayhost_maps to mail sure all email sent from domainA is routed through Postini archive services. example;
sender_dependent_relayhost_maps = pcre:/opt/zimbra/postfix/conf/sender_relay.pcre
[zimbra@mail conf]$ more sender_relay.pcre
This works great if the email is sent to an external address ie... not hosted on the postfix system. If someone at domainA sends to another person on domainA the email is not routed using the above map.. instead Postfix used the lmtp(local) because both accounts are hosted on the same Postfix server.
I could use the relayhost param and this would send everything including mail from other domains that are not going to be using Postini Services. I'm looking for a way to have the lmtp to ignore the fact that these 2 users are on the same server and send them off to be archived regardless.