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

This is for bind9.

Is there a way to add a DNS record without too much mucking with zone files and named.conf?

I need to test some web servers before we migrate from the old servers to the new ones. Instead of asking everyone to put entries into /etc/hosts for, is there a way to get the local DNS server to reply with the new IP for that host?

Yes, I know, this is essentially a DNS hijack. Not that many test machines are involved, so editing /etc/hosts was feasible, but I was wondering if I can do this through DNS.

share|improve this question
up vote 2 down vote accepted

It's quite easy - add a zone for that contains a single A or AAAA record with the appropriate IP address.

share|improve this answer

/etc/hosts or zone files are your choices. Poisoning DNS seems like a real bad idea and may not work depending on the DNS config

share|improve this answer

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.