Aliasing a domain

Mark.Andrews at nominum.com Mark.Andrews at nominum.com
Mon May 21 05:03:12 UTC 2001


> Hi,
> 
> I'm a DNS newbie, using bind 8.2.3 on Linux and doing all my DNS 
> configuration through Webmin. Appologies if what I ask is trivial or 
> nonsense.
> 
> I have a server which provides DNS, mail and web services for domain 
> foo.com (real domain names changed to protect the innocent). I have a 
> second domain, bar.com, which I want to serve from the same server.
> 
> I created a new zone for bar.com:
> 
> bar.com.   IN SOA   ns.foo.com. admin.foo.com. (
>          990048653
>          10800
>          3600
>          604800
>          86400 )
> bar.com.      IN    NS ns.foo.com.
> bar.com.      IN    NS ns2.foo.com.
> www.bar.com.  IN    CNAME foo.com.
> 
> This works fine. The problem is that I also want to be able to send mail 
> to user at bar.com. Trying to add "bar.com. IN CNAME foo.com." results in 
> the following named errors:
> 
> named[444]: bar.com has CNAME and other data (invalid)
> named[444]: /var/named/bar.com.hosts:10:bar.com: CNAME and OTHER data 
> error

	Well use a MX record.  This is what they were invented for.
	
		bar.com MX 0 foo.com

	If fact any domain that is expecting to receive email should
	have a MX record as it reduces the load on the net as a whole.
	Not all nameservers cache negative responses, just about all
	cache positive responses.

> 
> So obviously I can't alias the top of a domain. I don't want to create 
> an A entry for bar.com pointing to the IP address of foo.com, because 
> the reverse lookup from that IP will then point to two domains.

	This is not obvious.

	Also you don't need a PTR record for every A record.  Some
	sites require that you have a A record for a reverse PTR
	record or else they assume that you are trying to spoof
	the name.

	The following is quite common.

	real.com	A 	1.2.3.4
	virtual1.com	A 	1.2.3.4
	virtual2.com	A 	1.2.3.4
	virtual3.com	A 	1.2.3.4
	virtual4.com	A 	1.2.3.4
	virtual5.com	A 	1.2.3.4
	...
	virtual6000.com	A 	1.2.3.4
	4.3.2.1.in-addr.arpa PTR real.com

	Mark
> 
> Is there any way to achieve this (hopefully without manually editing the 
> config files - I prefer to keep everything inside Webmin).
> 
> TIA, Itai
> 
--
Mark Andrews, Nominum Inc.
1 Seymour St., Dundas Valley, NSW 2117, Australia
PHONE: +61 2 9871 4742                 INTERNET: Mark.Andrews at nominum.com


More information about the bind-users mailing list