How to test this server code?

How do I set up a test server, making it a DNS server?

  • I am trying to set up a DNS server on Ubuntu 11.04. The main reason I want to have this DNS server is so I can create a server specifically for testing before making the code live. Creating this DNS server would allow the code to be run on this test server on those computers in our lab that have changed their resolv.conf file. I have a lot of direct links in the code, so this would make things easier. I have gone through the documentation and I believe I have set up the zone correctly, but I think I am not setting the db.example.com file correctly. (I am using my own website here, not example.com) this is what I have: Also, There exists a roots.example.com (again, insert a website in place of example.com), but I am not sure there exists a root.roots.example.com like the documentation. @ IN SOA roots.example.com. root.roots.example.com. ( @ IN NS roots.example.com. roots.example.com IN A 0.0.0.0 (the ip address) Thanks in advance!

  • Answer:

    The root.roots.example.com is just the DNS way of expressing the email address [email protected], it's not a machine name. You can use the dig utility to check out what your DNS server is telling the world, something like "dig -t a roots.example.com @0.0.0.0" (insert your DNS server's IP address instead of 0.0.0.0) should return your server's IP address. If what you are doing is masking an existing domain (I'm guessing here) you have to make sure that the machines you are testing from have only your test-DNS-server in resolv.conf. Also make sure their DNS caches are cleared before testing, or you may have (real) information that the machines looked up before you changed resolv.conf, masking your test addresses. Most lookup errors have to do with either syntax errors in the configuration files, timing (TTL and negative TTL) or missing trailing dots (giving you interesting stuff like roots.example.com.example.com :). Check and double-check your logfiles.

Will at Server Fault Visit the source

Was this solution helpful to you?

Related Q & A:

Just Added Q & A:

Find solution

For every problem there is a solution! Proved by Solucija.

  • Got an issue and looking for advice?

  • Ask Solucija to search every corner of the Web for help.

  • Get workable solutions and helpful tips in a moment.

Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.