can @ be CNAME?

Matthew Seaman m.seaman at infracaninophile.co.uk
Tue Nov 23 08:56:50 UTC 2010


On 23/11/2010 08:07, Tech W. wrote:
> --- On Tue, 23/11/10, Matus UHLAR - fantomas <uhlar at fantomas.sk> wrote:
>> From: Matus UHLAR - fantomas <uhlar at fantomas.sk>

>>> can I set @ to a cname type? like:
>>>
>>> @  IN  CNAME  www.example.com.
>>
>> Certainly not. for a domain you have you need SOA and NS
>> records, and CNAME
>> is incompatible with both of them.
>>
> 
> But why @ can have an A RR?
> 
> @ IN A 12.34.56.78
> 
> This seems OK for us.

CNAME records are special.  You can't have any other records for a label
where you have a CNAME record (well, with the exception of RRSIG records
if you're using DNSSEC).  This is covered in great detail in any
introductory text on DNS.

The principle reason to want to have a CNAME record at the apex of a
zone is to make http://example.com/ be a synonym for
http://www.example.com/.  The way to deal with that is to turn it round
and make www.example.com be the CNAME record, and have the A record at
example.com.  Or just have A or AAAA records at both example.com and
www.example.com

	Cheers,

	Matthew

-- 
Dr Matthew J Seaman MA, D.Phil.                   7 Priory Courtyard
                                                  Flat 3
PGP: http://www.infracaninophile.co.uk/pgpkey     Ramsgate
JID: matthew at infracaninophile.co.uk               Kent, CT11 9PW

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 267 bytes
Desc: OpenPGP digital signature
URL: <https://lists.isc.org/pipermail/bind-users/attachments/20101123/0d3e19bb/attachment.bin>


More information about the bind-users mailing list