Running a Public DNS Server

You’re running mail, web, or other public servers, and you want to control your DNS server yourself. You’re tired of waiting on third-party service providers, and why should you pay them for something you can do yourself? You want the flexibility to set up your network however you please—maybe you want to own only a single public routable IP address and put all your servers behind a NAT firewall, or maybe you want to put workstations and internal servers behind NAT and put your public servers outside the firewall. However you elect to set up your network, you want control of the name services.

So you’re ready to take the plunge and set up your own public DNS server.

You need five things:

  • A static, public, routable IP address
  • A registered name server
  • A permanent Internet connection
  • An ISP account that permits running servers
  • Your actual server

A DNS server doesn’t need much in the way of hardware or bandwidth. DNS requests are very low-bandwidth; after all, a single UDP packet is all it takes to satisfy a request. Ideally, you’ll have enough RAM to keep all zone and cache data in memory. If you run your DNS server on a Linux server without X, and without any other services, something like an old P300 with 128 MB of RAM will handle a couple hundred BIND zones just fine, and many hundreds of djbdns hosts. So, if you were only managing the DNS for the little network, you could easily piggyback onto a machine running other services.