Re: [Exim] pass_on_timeout option

Etusivu
Poista viesti
Vastaa
Lähettäjä: Dean Brooks
Päiväys:  
Vastaanottaja: Leonardo Boselli
Kopio: exim-users
Aihe: Re: [Exim] pass_on_timeout option
On Sat, Mar 27, 2004 at 11:02:31AM +0100, Leonardo Boselli wrote:

> lookuphost:
> driver = lookuphost
> transport = remote_smtp
> self = fail
> pass_on_timeout = true
>
> The problem is number 3: althopught reading in the exim documentation
> looks as if pass_on_timeout works either on any connection problem i
> keep having these lines in my log:
>
> 2004-03-27 10:11:38 1B75Cb-00085x-00 == aqhcqstmc@???
> T=remote_smtp defer (101): Network is unreachable


pass_on_timeout handles timeouts in *routing*, not in the transport
final delivery. Examples would be DNS timeouts (i.e. remote DNS
server is not responding, DNS connectivity is down, etc.).

To help you save some time, here is a well-tested example of dealing
with many (if not all) of your issues at once:

  remote_domains:
    driver = dnslookup
    ignore_target_hosts = 127.0.0.0/8
    self = fail
    pass_on_timeout
    transport = remote_smtp
    fallback_hosts = fallbackhost.yourdomain.com
    no_more


  send_to_fallback:
    driver = manualroute
    route_data = fallbackhost.yourdomain.com
    transport = remote_smtp


Benefits of this configuration:

  1. The first router will handle any remote deliveries.  If routing
     succeeds, it hands it off to remote_smtp for direct remote delivery.
     If the transport cannot connect to the remote server for any reason,
     the "fallback_hosts" options tells the transport to send it on
     to your fallback host of "fallbackhost.yourdomain.com".


  2. If the routing determines that the MX records point to you, the "self"
     option will catch it and fail the message (since it was supposed to
     be a remote delivery)


  3. If the DNS lookups timeout (i.e. DNS nameservers unreachable for
     the remote site), the "pass_on_timeout" option will cause it to
     go on to the next router, which manualroutes the message specifically
     to the fallback host.  This is the only way to get DNS timeouts to
     immediately send to your fallback rather than sit on the queue.  The
     fallback_hosts option on the router will NOT catch DNS timeouts, which
     is why two routers are required here.


  4. The "no_more" option on the first router is required to keep
     routing failures from falling through to the send_to_fallback router.


Hope this helps.

--
Dean Brooks
dean@???