Re: [Exim] Exim4, where has the "bydns_mx" option gone ?

Top Page
Delete this message
Reply to this message
Author: Philip Hazel
Date:  
To: Dave C.
CC: Oliver Egginger, Exim Users
Subject: Re: [Exim] Exim4, where has the "bydns_mx" option gone ?
On Wed, 3 Jul 2002, Dave C. wrote:

> For instance, if your 'smarthost MX record" looks like:
>
> blah.com    IN    MX    10 server.foo.com

>
>
> Then what you really have is a smarthost at server.foo.com - Its silly
> to have to lookup the MX every time, when its the host thats providing
> the smarthosting for you anyway. Instead of saying 'blah.com bydns_mx',
> just use 'server.foo.com byname'


I think the point is that it actually looks like

blah.com.   IN    MX   10  server1.foo.com.
                       10  server2.foo.com.
                       ...


and the poster has no control over the DNS, so has to keep watching it
in case the ISP changes the list of smarthosts, unless he uses the MX
record.[*]

Now, many other ISPs (etc.) do it more efficiently with A records:

blah.com.   A    10.2.3.4
            A    10.4.5.6
            ...


where the IP addresses are actually different hosts. Then "blah.com"
really is a (virtual) "smarthost" (implemented by a number of different
boxes). Personally, I would recommend that way, since it potentially
uses fewer DNS lookups. But here we're dealing with a fait accompli.

[*] Incidentally, if you happen to know that all the MX preferences are
the same, you can simulate the bydns_mx functionality by looking up the
MX records yourself using a dnsdb lookup, and then using ${sg...
expansions to remove the preference values and turn the rest into a
colon-separated list of hosts. Getting the syntax of this right is left
as an exercise (exim -be is your friend).

--
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.