I got caught by that already :-O
My server bounced two mails from the list (having relay_recipient_maps
set up wrongly) - and i have no idea if that was already an answer ...
So, if somebody answered to my last mail, please send it again.
:)
Sorry for that!
postfix-us...@tja-server.de schrieb:
Thank you, Noel!
I got that running - mostly :)
Server A (MX, SMTP: smtp.example.com) has:
relay_domains = $myhostname, localhost.$mydomain, localhost,
/etc/postfix/mydomains
relay_transport = smtp:[smtp.example.com]
mynetworks = [ip.ad.dr.es], ...
Where /etc/postfix/mydomains lists all domains to be relayed and the
relay_transport is the IP of Server B:
Server B (IMAP, imap.example.com) has:
relayhost = [smtp.example.com]
mydestination = $myhostname, localhost.$mydomain, localhost,
/etc/postfix/mydomains
mynetworks = [ip.ad.dr.es], ...
This setup works for me - beside one problem:
The /etc/aliases of Server A will not be honored, which means that all
mail to any of the domains will be transported to Server B, which in
turn will bounce the mail.
I would like to let already Server A bounce those mails!
Using a relay_recipient_maps as you wrote, seems to be the right way,
but i cannot get it running.
Like in a /etc/aliases file, i want to accept certain users for all
domains.
I tried to create the file as follows:
awk -F: '{print $1}' /etc/aliases | egrep -v "^(#|$)" | awk '{print $1"@
OK"}' | sort -u > relay_recipient_map
So, for example, it contains lines like:
user1@ OK
user2@ OK
But this does not work :-(
I would not like to list all users for all domains, but just accept mail
to the existing users for ALL domains (as shown in my example above).
Is there a way to reach that goal?
Or do i need to add one line for each user in every domain?
Thank you!
:)