> On Oct 7, 2019, at 6:09 PM, Jaroslaw Rafa <[email protected]> wrote:
>
> I found in the documentation that I have to add the parameter
> "smtp_host_lookup=native" to main.cf to make Postfix use system configured
> name resolution instead of trying to resolve names by itself.
Unless your system sends all mail to statically configured
relays listed in /etc/hsots, you MUST NOT set:
smtp_host_lookup = native
for all destinations. Instead, create a second transport
in master.cf:
nativesmtp unix ... smtp
-o smtp_host_lookup=native
And then use "nativesmtp:[nativehost]" in the transport table
for all destinations that need to avoid DNS.
You could set:
smtp_host_lookup = dns, native
but then all your native names will still trigger DNS lookups
first, and that's not ideal when the name is a priori known
to be native.
--
Viktor.