Pranaam to all bhai ji _/\_
First of all, warm hugs to Hardeep singh (without whom this Tutorial was not possible :') )
In this post we will discuss, how to setup DNS server for more then one domains
already we have done with DNS server basic configuration in tutorial http://www.mannulinux.org/2013/12/dns-serverbind-server-installation-and.html .
in last tutorial we configured DNS server for single domain
lets start ;)
my hostname is ica.indishell.in
IP of DNS machine is 192.168.0.211 and nameserver is already defined in /etc/resolve.conf file
i am going to setup DNS for domains
zero.cool
hardeep.rocks
billu.you
configure named.conf file:-
/etc/named.conf file is the configuration file for DNS server
open file and configure it according to your requirement
i am configuring DNS for 3 domains (zero.cool hardeep.rocks billu.you)
so my /etc/named.conf file is like this ........
domain "zero.cool" is on serial number 1, domain number 2 is "hardeep.rocks" and billu.you domain is on number 3 in my named.conf file
forward zone file for zero.cool domain is cool.zone
forward zone file for hardeep.rocks domain is rocks.zone
and for domain billu.you, forward zone file is billu.zone
ok now configure them one by one :)
cool.zone file content is
; Zone file for zero.cool
$TTL 14400
@ 86400 IN SOA ica.indishell.in. root.zero.cool. (
0001 ; serial,
86400 ; refresh, seconds
7200 ; retry, seconds
3600000 ; expire, seconds
86400 ) ; minimum, seconds
zero.cool. 86400 IN NS ica.indishell.in.
zero.cool. IN A 192.168.0.211
take care of following thing in zone file
hostname
domain name for which we are creating zone file
serial number (domain serial in named.conf file )
domain entry for name server as well as for IP
here , in my case ,
hostname is ica.indisell.in
domain name is zero.cool
serial number for domain zero.cool is 1(in named.conf file)
zone file for domain hardeep.rocks
content of rocks.zone(zone file for domain hardeep.rocks)
; Zone file for hardeep.rocks
$TTL 14400
@ 86400 IN SOA ica.indishell.in. root.hardeep.rocks. (
0002 ; serial,
86400 ; refresh, seconds
7200 ; retry, seconds
3600000 ; expire, seconds
86400 ) ; minimum, seconds
hardeep.rocks. 86400 IN NS ica.indishell.in.
hardeep.rocks. IN A 192.168.0.211
for domain hardeep.rocks, serial number is 2 (in named.conf file)
name server is ica.indishell.in
ip address for domain is 192.168.0.211
zone file for domain billu.you:-
content of file billu.zone is
; Zone file for billu.zone
$TTL 14400
@ 86400 IN SOA ica.indishell.in. root.billu.you. (
0003 ; serial,
86400 ; refresh, seconds
7200 ; retry, seconds
3600000 ; expire, seconds
86400 ) ; minimum, seconds
billu.you. 86400 IN NS ica.indishell.in.
billu.you. IN A 192.168.0.211
serial number for domain name is 3 (it comes on number 3 in named.conf file )
name server is ica.indishell.in
ip address is 192.168.0.211
okkkkkkkkkkkk.
we have done with zone files too
so lets test our new DNS server ;)
restart DNS server
command is
service named restart
now test DNS server ;)
nslookup to domain that you setup
DNS is working XD
now test with dig command
testing domain hardeep.rocks
ok now testing zero.cool
yes yes :D DNS is working fine 8-)
This was tutorial on setting up DNS server for more then one domains
Again, for this useful and easy tutorial on DNS , big hands for Hardeep singh
Thank you
Love to :-
zero cool , Team INDISHELL , Mannu, Viki , Hardeep bhai and AR AR bhai ji
0 comments