MX TTL syntax

David Botham DBotham at OptimusSolutions.com
Tue Feb 17 15:28:17 UTC 2004


bind-users-bounce at isc.org wrote on 02/17/2004 10:14:08 AM:
> hi,
> 
> 
> i want to keep the records of two domains syncronous.
> For this reason i configured the same zone data file 
> for both domains in the named.conf.
> 
> example
> 
> zone "doamina.mydomain.do" {
>         type master;
>         file "zone-file";
> };
> 
> 
> zone "doaminb.mydomain.do" {
>         type master;
>         file "zone-file";
> };
> 
> 
> in the zone file i keept the left sides
> non fully qualified, so that the records are made fully
> qualified by adding the ORIGIN.
> 
> Works so far, i only have problems with the MX Records.
> 
> Obviously this does not work, because a mx querey for 
> domainb.mydomain.do cannot be answered.
> 
> domaina.mydomain.do 3600 IN A 10 mailserver.domainc.do
> 
> can someone tell me about the correct syntax, specifieing
> a mx record for a whole domain without having to specify
> the domain fully qualified and also adding a ttl to that record.


yes, do this:

@       3600    IN      A       10      mailserver.domainc.do.

> 
> of course i could write 
> 
> domaina.mydomain.do 3600 IN A 10 mailserver.domainc.do
> domainb.mydomain.do 3600 IN A 10 mailserver.domainc.do

This would not work for a few reasons.

1)  You are missing the trailing dot '.' at the end of the line.

2)  Assuming that the zones in question are:

domaina.mydomain.do.
domainb.mydomain.do.

Then, one of the RR's above would always be rejected as out of zone data 
in one of the zones.  Specifically:

domaina.mydomain.do 3600 IN A 10 mailserver.domainc.do

is out of zone in the domainb.mydomain.do zone.

and

domainb.mydomain.do 3600 IN A 10 mailserver.domainc.do

would be out of zone in the domaina.mydomain.do zone.

3) If my assumption regarding the zone names is incorrect, then, both of 
the RR's above designate mail exchangers for two different hosts in the 
same zone and you are not specifying any MX RR's for the other zone.


To make a long story short, which I haven't, use the "@" shorthand for the 
zone name as I showed in the example above and all should work fine.


Hope this helps.


Dave...

> 
> in the same file, but this would be redundant.
> 
> many thanks
> -- 
> Timo
> 
> 
> 




More information about the bind-users mailing list