Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

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 want to do some changes to the BIND source code. In order to test those changes I want to be able to post queries to my local BIND server and for it to use only the local zone files.
I know how to make the zone files and somewhat the named.conf file but what should i put in /etc/resolv.conf?

In resolv.conf currently there is the line
witch i guess is my router IP address and the queries go through the router to my ISP.

I want those queries to go to the local BIND server and to look for answers in the zone files i provided.

Is there a way for this using resolf.conf file or should i do something else?

share|improve this question

migrated from Feb 16 '11 at 13:57

This question came from our site for professional and enthusiast programmers.

up vote 0 down vote accepted

Also make sure your test BIND is set to listen on (and only by changing the appropriate option in /etc/bind/named.conf.options (if you are using Debian Linux, as an example).

You can also use the nslookup command to query a specific nameserver, as in nslookup example.invalid

To make it use only local zone files you want to make sure that /etc/bind/named.conf.options has no forwarders stanzas and that none of your zone files reference an external DNS server.

share|improve this answer

You could use:


in /etc/resolv.conf.

However, a better idea is to use dig to test your configuration as it will not break your existing setup.

For instance if you use the command

dig @

It will query the nameserver at for the address of

share|improve this answer
Thanks Phil, i did try this before,but with no success. I guess I am doing something else wrong. Never the less this is helpfull a lot. – Anonymous Feb 16 '11 at 13:42

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.