The dreaded CNAME

Mark_Andrews at isc.org Mark_Andrews at isc.org
Wed Aug 29 02:35:17 UTC 2001


> 
> > What is the proper method for setting up a basic domain as a CNAME
> > record in bind 8.2.4?
> >
> > Prior to bind 8.2.3, I was using something similar to the following:
> >
> > foo.com.   IN   SOA  ns.mydomain.net. hostmaster.mydomain.net. (
> >                 99072719 86400 7200 3600000 28800 )
> > foo.com.        IN      NS      ns.mydomain.net.
> > foo.com.        IN      NS      ns2.mydomain.net.
> > foo.com.        IN      CNAME   bar.com.
> >
> > However, since 8.2.3, I can no longer get away with this.
> >
> > What is the proper manner for pointing foo.com to bar.com, as an alias
> > or CNAME?
> >
> > (And before you ask why I don't just use A records--In my situation, it
> > is not an option.)
> 
> You cannot CNAME a domain.  To do so violates the rule that CNAME
> records shall have no other resource records applied to them; setting the
> domain as a CNAME would nullify the SOA, NS, and any other records
> you have set up for the domain.  I can't quote the RFC, but if you check
> the bind-users archive, I am confident that you will find a plethora of
> similar questions answered as I and Kevin Darcy have.
> 
> In short, if you can't use A records, you don't realistically have a lot of
> 
> other options.
> 
> 

	It sounds like you want map the name to different addresses
	depending upon the protocol used.  This is what the SRV
	record was designed for.

	Unfortunately not many clients look for SRV records yet.
	One web browser is currently being modified to support
	SRV records.  Hopefully more will follow shortly.  In the
	mean time lobby for SRV support in the clients of the
	protocol in question.

	Also note there are sometimes protocol specific tricks than
	can be used to get around situations like this.

	Mark
--
Mark Andrews, Internet Software Consortium
1 Seymour St., Dundas Valley, NSW 2117, Australia
PHONE: +61 2 9871 4742                 INTERNET: Mark.Andrews at isc.org


More information about the bind-users mailing list