Johannes Nohl wrote:
I think you can use the 'sender_dependent_relayhost_maps' setting:

@domain1.com   smtp1:
@domain2.com   smtp2:

Hm, don't know. I'm not relaying I send directly to recipient. I tried
and mail returned with following error:

<[EMAIL PROTECTED]>: Host or domain name not found. Name service error
    for name=smtp2 type=AAAA: Host found but no data record of requested type

Your dns couldn't resolve the domain "domain2.com". Solve your dns setup problem. If you have the smtp client in a chroot (master.cf the fifth column must be "n" to disable chroot) make sure the dns configuration is accessible to the smtp client.

This is not a problem with sender based routing.

Further help is almost impossible without posting of the configuration (postconf -n, master.cf). My dns has no problem to resolve "domain2.com":

 dig domain2.com

; <<>> DiG 9.4.1-P1 <<>> domain2.com
;; global options:  printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 42970
;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 2, ADDITIONAL: 0

;; QUESTION SECTION:
;domain2.com.                   IN      A

;; ANSWER SECTION:
domain2.com.            86400   IN      A       211.106.65.110
domain2.com.            86400   IN      A       211.106.65.118

;; AUTHORITY SECTION:
domain2.com.            86400   IN      NS      ns.domainca.com.
domain2.com.            86400   IN      NS      ns2.domainca.com.

If this is an attempt to obfuscate the real domain, please use "example.com" or "example.org".

As far as I could read until now the sender_dependent_relayhost map
expects a domain as well on the right hand side, or? (like netxthop in
transport) E.g. smtp2:domainxy.com (it has to know to where to relay).

I'm somehow lost. I can't imagine that a used options is deprecated
and newer version don't substitute it...

I'm a bit lost as well. (^-^)
As far as I know, Postfix didn't support sender based routing before version 
2.3.

If you really need routing based on the sender address you could also use the FILTER action in a check_sender_access.

smtpd_sender_restrictions =
        check_sender_access hash:/etc/postfix/senderdomain_routing

/etc/postfix/senderdomain_routing:
example1.com    FILTER  domain1-smtp:
example2.com    FILTER  domain2-smtp:

By the way, did you execute "postfix reload" after making changes to master.cf or main.cf?


--
Sandy

List replies only please!
Please address PMs to: news-reply2 (@) japantest (.) homelinux (.) com
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to