Sample Zone file for a domain with 2 nameservers ns1.example.com and ns2.example.com for BIND9. You can use this template to define your own nameservers. Just do changes on the domain name and IP addresses.
Be sure to include the below statement in your named.conf
I am assuming that you are running Bind9 or later version in your VPS or dedicated server.
zone "example.com" {
type master;
file "example.com.db";
}
$TTL 14400
$ORIGIN example.com.
; Specify the primary nameserver ns1.example.com in SOA
@ 14400 IN SOA ns1.example.com. webmaster.example.com. (
2008092902 ; Serial in YYYYMMDDXX (XX is increment)
10800; refresh seconds
3600; retry
604800; expire
38400; minimum
);
; Website IP Address specified in A record
IN A 11.11.11.11
; TWO nameserver names
IN NS ns1.example.com.
IN NS ns2.example.com.
; Nameservers and their corresponding IPs
ns1 IN A 11.11.11.11
ns2 IN A 22.22.22.22
; Specify here any Aliases using CNAME record
www IN CNAME example.com.
ftp IN CNAME example.com.
; Set Mail Exchanger record with priority
mail IN MX 10 example.com.
How to test the DNS server?
Just goto the following sites, enter the domain name and you will see the test results.
http://www.intodns.com (free)
http://www.pingability.com (free)
http://www.dnsstuff.com (paid)
Good luck!
Similar Posts:
- Domain with WWW not resolving problem!
- Troubleshooting Common DNS Misconfiguration Errors
- DNS-Test :: Free dns checking tool script!
- Perl Net DNS Tutorial for Querying DNS Servers
- How to secure your DNS server
- Using Dig tool for DNS lookups and Nameserver query
- Registering DNS Nameserver with Godaddy
- bind /etc/named.conf missing
- Setup Postfix/Dovecot MailServer for Centos/RHEL
- What is Open DNS server?


June 23, 2009
Hi,
I have registerd private nameservers in my dedicated server for firstdomain.com and want to host a second domain at the same server. I went to godaddy.com and put the same nameservers for the firstdomain.com into second domain’s nameservers info. Now for nslookup seconddomain.com I get servfail response.
How the conf files in my dedicated server must be modified to host multiple domains using private nameservers for one domain?
Thanks.
Alex.