|
Troubleshooting DNS Issues |
Top Previous Next |
|
DNS Issues can be tricky to troubleshoot. Sometimes it is difficult to determine whether a server is actually "down" or whether there is another issue at play such as a DNS problem. A more detailed explanation of how DNS works is beyond the scope of this documentation, but a good article on DNS appears in Linux Journal called "Digging Up Dirt in the DNS Hierarchy" A good first step is to find your DNS server - using the command below:
1) Check DNS service from Windows: The command sequence below shows an example of using the nslookup command to determine whether DNS lookups are working - note that simply typing nslookup with no arguments returns the IP address of our default DNS name-server (192.168.0.1 in this example) Next we can ask for more detail using nslookup commands '>' The 'd2' command in nslookup turns on verbose debugging. The 'set recurse' command ensures that nslookup can look beyond the immediate name server if 192.168.0.1 cannot provide an authoritative response for the queried domain. Next we simply type the domain to be queried - in this case 'demo.neatclubs.com' With debugging turned on, we see that the query resulted in four authoritative records being returned from the four name-servers serving the domain - this is evidence that all is working well - all name-servers provided the same IP address for demo.neatclubs.com - 72.55.156.169.
If this does not work, it means we have DNS trouble! - you can prove we have DNS trouble by hard-coding an IP address in c:\Windows\System32\drivers\etc\hosts in Windows XP or Windows Vista. If you can access the web-site with a hard-coded ip address, but not via a DNS lookup, this means that DNS records are not propagating properly from the server, or critical servers are unreachable and records have been aged out of the cache of your DNS server. To get to the next level of troubleshooting, Linux or UNIX become the more capable platforms - the commands below can be done via an internet connected Linux or UNIX host or from a guest VM. 2) Further Troubleshooting from Linux a) From Linux, enter the 'dig' command by itself.
This tells us that the server 209.172.41.2092 responded with name-server records for the 13 top level name servers in the internet. Next we verify that these top level servers are reachable using another DIG command below. (we'll arbitrarily choose one of the 13 top level name servers) # dig @j.root-servers.net. www,neatworx.com
Now we have found the available name-servers for the 'com.' top level domain along with the 'A' records providing the addresses of servers that serve these records in IPv4 and IPv6 format. Let's now re-query the problem domain against these name servers for "com.". # dig @j.gtld-servers.net. www,neatworx.com
No we see the name servers that can authoritatively answer for the neatworx.com. domain - we also see the address for these servers. Finally we can determine that these name-servers are answering properly: # dig @ns4.servage.net. www,neatworx.com
And finally we see the correct 'A' record come back for www.neatworx.com Using the technique above, we can isolate example where a problem with DNS name resolution might be occurring by querying each name server in sequence from the root domain down.
|