Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I m Testing a DNS Server . The Following things i have done with my dnd server

  1. I am using DDNS (not DNS)
  2. I have configure DDNS name as domain name (as shown in pics below )
  3. DMZ to ( dns server )
  4. I use open-DNS DNS (as my isp dns)
  5. is my DNS Server



pwd = 1

DNS Non-Authoritative nslookup


dig local dns server did 127 dig

cat ao have i dont correctly ? cat have i dont correctly ? hosts file /etc/hosts route route host 192 correctly ? my zone file

zone file




pwd = 1

share|improve this question

migrated from Nov 17 '11 at 21:57

This question came from our site for Ubuntu users and developers.

up vote 1 down vote accepted

There are many errors in this setup. It appears that there is a lack of understanding of how DNS works. Which is fine, we all start there. ;-)

I also think that you may be trying to set up a DNS server when you don't need one. Unless you want to add your own DNS records, you don't need one -- if all you want is to use DNS, just use your ISP's DNS servers and you'll be fine. If you want the computers on your network to be able to talk to each other by name, I recommend you look into enabling "DNSMasq" on whatever your broadband router may be (or buy one that supports it; they're cheap).

Alternatively, you may be trying to set up a reverse DNS so that, for instance, a mail server doesn't get blacklisted. In which case, you need to go through your ISP (, because they control the reverse DNS ( zones) for the IPs they provide, not you or your DNS provider ( You typically need a static IP and a nice ISP for that. A call to them should answer many questions.

However, I'm going to assume that you do want a DNS server, and answer the stated question.

In order to have the world use your own dns server for a domain, you need the dns server at the "parent" level to have nameserver (NS) records pointing to your server. In this example, you would need there to be NS records in's name server. In short, you'd need dig to report something that looks like this (THE FOLLOWING IS FORGED FOR EDUCATION PURPOSES):

zanfur@laptop:~$ dig NS

; <<>> DiG 9.7.3 <<>> NS
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 55890
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 0

;     IN  NS

;; ANSWER SECTION:      86400   IN  NS      86400   IN  NS

;; ADDITIONAL SECTION:      66570   IN  A      66570   IN  A

;; Query time: 43 msec
;; WHEN: Thu Nov 17 02:19:35 2011
;; MSG SIZE  rcvd: 99

In this (fictional) example, the servers would have "NS" records in their zone files, to point to your server. Then, any requests for * (or just itself) would be sent to your DNS server, and the records in your DNS server would be used. You also need at least two NS records, although (as in this fictional example) they can both point to the same IP.

I'm pretty sure won't do this for you, so I think you're out of luck there. Sorry. There are DNS providers that do; you may have to switch.

If all you want is to have your network use your name server, then that's easy, and it looks like you're already configured your host to use your nameserver, so I won't explain that here. However, your zone files are quite incorrect. Looking at the zone file, we have the following problems:

  1. It has NS records for the domain it's serving, which should be in the's zone file, as I explained above.
  2. Even if it was used to look up the NS records, it would return localhost,, and ::1 for the address, meaning the client computers would try to connect to themselves in order to query DNS, which is almost certainly not what you intended.

The db.192 zone file also has issues:

  1. It also has name server records for the domain it's serving.
  2. It claims the, a non-sensical IP, has a reverse DNS of localhost ( It looks like you modified the db.127 example file incorrectly.

And I think that's the best I can do as an answer, with the information given.

With respect, setting up a DNS server is not a simple matter, and requires a lot of knowledge about a lot of things. From your examples above, it appears that you don't have much experience with networking on linux, and while I respect you for tackling the task of setting up a DNS server, please don't expect it to be quick or simple. If you would like to continue, your first step should be to research what DNS is and how it works. The Domain Name System article at Wikipedia is an excellent start, as is the Zone file article. Both of those articles contain links to the various specifications, if you ever need to know more. Make sure you understand the following before trying to implement a name server of your own:

  1. How a DNS lookup works
  2. What a root name server is
  3. What the A, CNAME, NS, and PTR record types mean (and MX if you run a mail server)
share|improve this answer
Thank you very much ... its not that i need dns server ..the thing is that i m studding linux & unix . so its my 1st project to make a dns server .so i m just testing .. – Muhammad Qasim Nov 17 '11 at 11:40
Thanks again the things u said ..i will learn then again ...& next time i will make a correct dns server – Muhammad Qasim Nov 17 '11 at 11:41

You must log in to answer this question.