Server Fault is a question and answer site for system and network administrators. 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 have a BIND DNS Setup with several closely similar, yet different zone files with custom 'views' enabled. Is there a way I can log or find from which zone file [in the hundreds of zone files] has the query been answered?

share|improve this question

From none of them; all zone data is in memory.

Once the zones are loaded (on startup and/or reload), the files are no longer referenced.

Of course, BIND logs both the query source address (the client) and the response source address (the view's IP) - you could conceivably correlate these with your knowledge of the zone and view layout.

share|improve this answer
I understand what you said, but the problem is when I am querying for a particular domain, I am getting incorrect data though the zone file has the right content. So, I would like to know from which zone ile is it fetching that particular answer from. Is there a way to do this? – deppfx Jul 26 '12 at 13:17
What does "getting incorrect data" mean ? BIND will serve the data you request. – adaptr Jul 26 '12 at 13:27
For example, I have IP for a domain, BIND is returning for some reason. It could be that BIND is forwarding the request or getting the information by recursion, etc. I just want to track what bind is doing when I run the query. I have enabled 'debug' in named.conf which doesn't seem to be of much help as the data from the logs is vague. Can you suggest some other logging token? – deppfx Jul 26 '12 at 13:36
Logging is not optional if you want to understand what BIND is doing. Spend some time learning how to set it up properly, then study its output. – adaptr Jul 27 '12 at 8:55

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.