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

Is there any way I can set up a nameserver to process ALL DNS requests that come to my server and pass them on to backend servers regardless of whether I have a DNS entry for the target domain?

For example, even if I don't have a DNS entry for, as long as a request for comes to my server, it gets processed.

Currently, I have a a server running bind, which resolves all requests to its own IP. I have a load-balancer set up which forwards all the HTTP requests to one of many back-end servers. All my backend servers run apache2. Right now, I also have DNS entries on ALL my backend servers for all the domains I want them to process (because they're my backup nameservers). But I'm adding new domains all the time and don't want to add more DNS entries to ALL my servers each time each time I add a new domain...

I just want to get around having to add any DNS entries at all. ANY method of doing this would be appreciated.


share|improve this question
You say you want the request for to be processed... processed how? if it's going to return something, where should it get the something from? A caching nameserver would just look it up in global DNS. A proxy could forward the request to another nameserver and return whatever it gets back. Need more info. – pjz Jul 8 '09 at 6:36
I think you need to clarify what you mean by "as long as a request for comes to my server, it gets processed". – John Gardeniers Jul 8 '09 at 7:28

If you have a primary and set of "backup" nameservers, then why aren't you using DNS zone transfers (possibly with notification) to ensure that when you add an entry on the master DNS, the secondaries pick it up immediately?

share|improve this answer

In theory you should be able to setup com as the domain, and setup a DNS entry for * to point to the correct public IP.

share|improve this answer
But first read this: – kubanczyk Jul 8 '09 at 7:21
Figured it wasn't the best idea in the world. – mrdenny Jul 8 '09 at 8:19

"Caching nameserver" is what you're looking for, I assume. Just add a Forward instruction to your bind configuration, as explained in many tutorials and setup instructions, and you'll be fine.

share|improve this answer

I know what you want and I want it too. For those who are confused about this question, i think it means this:

Say I have 100 domain names. All have the same NS records: NSX.EXAMPLE.COM

  • I'm in charge of NSX.EXAMPLE.COM
  • I have just one zone file, with A record pointing to
  • I want ANY request that comes to NSX.EXAMPLE.COM to return data from that record.

Now, the main purpose of this question is to come up with a system that works when I decide to add another domain WITHOUT ANY MODIFICATION to the DNS server configuration.

I now register FOO.COM and point it to NSX.EXAMPLE.COM. This should be enough to make FOO.COM resolve to

Another way of looking at this would be like this: If you BY MISTAKE query NSX.EXAMPLE.COM for any domain, it will respond with

share|improve this answer

I think, what you really want is a PowerDNS authoritative and recursor setup. But I'm not sure if the authoritative server will forward requests to the zones that it's authoritative for.

Just refer to the PowerDNS documentation at:

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.