Multi-domains under one IP

Barry Margolin barmar at bbnplanet.com
Fri Mar 3 16:28:00 UTC 2000


In article <38BF1523.AB78D56C at cisco.com>,
Michael Voight  <mvoight at cisco.com> wrote:
>Can't both domains share the same zone file in BIND 8??
>You can do it in BIND 4

Yes.  That will work if *all* records in both domains should be identical.
But if he wants the same IP's for www.domain1.com and www.domain2.com, but
different IP's for mail.domain1.com and mail.domain2.com, they need their
own files.  So I posted the configuration that allows for the more general
solution.

>
>Michael Voight
>Cisco TAC
>
>Barry Margolin wrote:
>> 
>> In article <89lqqc$35s$1 at news0.skynet.be>,
>> Masure David <masure.david at ccim.be> wrote:
>> >Is it possible for someone to send a config example of let's 2 domains names
>> >running on the same IP.
>> >
>> >I'd like to have all the file : named.boot, named.conf, reverse, local, and
>> >the two zones.
>> 
>> I'll assume you want www.domain1.com and www.domain2.com to both point to
>> IP address 1.2.3.4.
>> 
>> named.conf:
>> 
>> zone "domain1.com" {
>>   type master;
>>   file "db.domain1.com";
>> }
>> 
>> zone "domain2.com" {
>>   type master;
>>   file "db.domain2.com";
>> }
>> 
>> zone "3.2.1.in-addr.arpa" {
>>   type master;
>>   file "db.3.2.1.in-addr.arpa";
>> }
>> 
>> db.domain1.com:
>> 
>> @ SOA ns1.yourdomain.com. hostmaster.yourdomain.com. (
>>   ... ) ; all the usual SOA parameters
>>   NS  ns1.yourdomain.com.
>>   NS  ns2.yourdomain.com.
>> 
>> www A 1.2.3.4
>> 
>> db.domain2.com:
>> 
>> @ SOA ns1.yourdomain.com. hostmaster.yourdomain.com. (
>>   ... ) ; all the usual SOA parameters
>>   NS  ns1.yourdomain.com.
>>   NS  ns2.yourdomain.com.
>> 
>> www A 1.2.3.4
>> 
>> db.3.2.1.in-addr.arpa:
>> 
>> @ SOA ns1.yourdomain.com. hostmaster.yourdomain.com. (
>>   ... ) ; all the usual SOA parameters
>>   NS  ns1.yourdomain.com.
>>   NS  ns2.yourdomain.com.
>> 
>> 4 PTR www.domain1.com.
>> 
>> --
>> Barry Margolin, barmar at bbnplanet.com
>> GTE Internetworking, Powered by BBN, Burlington, MA
>> *** DON'T SEND TECHNICAL QUESTIONS DIRECTLY TO ME, post them to newsgroups.
>> Please DON'T copy followups to me -- I'll assume it wasn't posted to the group.
>
>
>


-- 
Barry Margolin, barmar at bbnplanet.com
GTE Internetworking, Powered by BBN, Burlington, MA
*** DON'T SEND TECHNICAL QUESTIONS DIRECTLY TO ME, post them to newsgroups.
Please DON'T copy followups to me -- I'll assume it wasn't posted to the group.



More information about the bind-users mailing list