DNS issues with CNAME


#1

I’ve got a domain registered with DH and I’m going to host it elsewhere. So I want to point example.com and www.example.com at another domain, example2.com. I can setup www.example.com to point to example2.com and that works fine. But when I try to point example.com to example2.com, the web panel gives me an error saying “CNAME records may only be used on sub-domains.”

I did a little research and have been told there’s no restriction within the DNS spec that should prevent me from pointing a tld to another tld. So is this a bug in the web panel? Is there some other way around it?

Thanks.


#2

I add a Redirect domain so that example.com redirects to www.example.com, which then follows the CNAME. For those who try the wildcard approach, like *.example.com, that won’t cover it when there’s no “subdomain” for example.com, as there’s no prefix to wildcard.


#3

There is a restriction which keeps you from using a CNAME on the top level of a domain: CNAME records cannot exist at the same name as any other record. Since there are always some bookkeeping records at the top level of a domain (SOA and NS records, for instance), a CNAME cannot be placed there.

The relevant standard here is RFC 1034, under section 3.6.2:

[quote]… If a CNAME RR is present at a node, no other data should be
present; this ensures that the data for a canonical name and its aliases
cannot be different. This rule also insures that a cached CNAME can be
used without checking with an authoritative server for other RR types.
[/quote]


#4

I’m not trying to setup a redirect, so the redirect domain suggestion doesn’t seem to work here.

The RFC seems to say “if a CNAME RR”… meaning it is possible.

I’ve dug and asked around with DNS experts and they all seem to agree I should be able to use a CNAME with the second level of the domain.

Is this something that DH just wants to enforce as to avoid possible conflicts?

What I’m trying to do is point a domain to a WordPress MU/MS install that has domain mapping setup. It seems strange to me they would list instructions there on pointing a second level domain to the install using a CNAME if it wasn’t possible.