Re: [EXIM] Delaying DNS lookups for smart host

Kezdőlap
Üzenet törlése
Válasz az üzenetre
Szerző: Kevin P. Fleming
Dátum:  
Címzett: jhazan
CC: exim-users
Tárgy: Re: [EXIM] Delaying DNS lookups for smart host
Probably the best thing to do would be to put a caching name server on that
gateway host, so that it will only look up the ISP mailhost once, then hold
it in cache for 24-48 hours until the record expires... Then it will query
the ISP again. If the ISP is going to do this, they'll cut the time-to-live
on that record down beforehand so you won't cache it as long, change it, put
it back, then put the TTL back to normal.

jhazan@??? wrote:
>
> I have an e-mail gateway machine which relays e-mail to a machine on our
> internal network and also relays e-mail from this machine to our ISP's
> smart host. I have the gateway machine set up with a dial-on-demand
> connection to our ISP so, to minimise the amount of connection time, I have
> exim set up to hold all remote mail in the queue, which is then run every
> half hour. Mail is held in the queue using hold_domains_except, so that
> inbound e-mail is not held in the queue but is relayed on immediately.
>
> The problem I had was that my smart_route router had its route_list
> attribute set to "* post.demon.co.uk bydns". This meant that every time
> someone from within our organisation sent some external e-mail, it was
> correctly held in the queue, but exim used DNS to look up post.demon.co.uk,
> meaning that the gateway machine had to dial out to do a DNS lookup. This
> was obviously unsatisfactory, so I put post.demon.co.uk in /etc/hosts and
> changed bydns to byname. This works OK until the ISP temporarily changes
> the IP address of its smart host in order to do maintenance work, and we
> are refused a connection to the original smart host.
>
> So what is the correct way to do what I am trying to do, i.e. stop exim
> trying to resolve post.demon.co.uk at the time that it receives the e-mail
> for relaying, but still uses DNS at the time that the queue is run?
>
> Thanks,
>
> Jonathan Hazan
> Datix Business Systems Ltd
> London, UK
>
> --
> *** Exim information can be found at http://www.exim.org/ ***


--
*** Exim information can be found at http://www.exim.org/ ***