Use of the @-symbol in zone files.

Joseph S D Yao jsdy at cospo.osis.gov
Wed Aug 8 21:14:23 UTC 2001


On Wed, Aug 08, 2001 at 04:10:43PM +0100, Bjorn Johansson wrote:
> In message <20010808103204.P18500 at washington.cospo.osis.gov>, Joseph S D
> Yao <jsdy at cospo.osis.gov> writes
> >Note, of course, that the "@" value changes if you use a "$ORIGIN"
> >directive.
> >
> If by this you mean, that if we have multiple records in our named.conf
> file, say for domain1.dom and domain2.dom, which all point to the same
> zone file.

No, you are making up a meaning for me; I did not mean that at all.  I
meant what I said.  I do try to do that!

If you have something like this:

www	IN A	1.2.3.4

; the following is a "$ORIGIN" directive!
$ORIGIN		funky

@	IN A	1.2.3.4

and you use this in a zone file for zone "quux.invalid", then the "@"
symbol refers to "funky.quux.invalid".  If you say:

$ORIGIN		otherzone.invalid.

then, instead of the "@" referring to "otherzone.invalid.", it will
just be rejected as not part of the "quux.invalid." zone.

However, if in zone file "zone.common" I have:

$TTL	1d
@	IN SOA	...
	IN NS	...
	IN NS	...

www	IN A	1.2.3.4
@	IN A	1.2.3.4

and you had in your /etc/named.conf file:

zone "quux.invalid."	{
	type master;
	file "zone.common";
};

zone "otherdomain.invalid."	{
	type master;
	file "zone.common";
};

then in the first invocation, "@" would refer to "quux.invalid.", and
in the second invocation, "@" would refer to "otherdomain.invalid.".

Is this clearer?

-- 
Joe Yao				jsdy at cospo.osis.gov - Joseph S. D. Yao
OSIS Center Computer Support					EMT-B
-----------------------------------------------------------------------
This message is not an official statement of COSPO policies.


More information about the bind-users mailing list