You go to a web page and enter “www.mysite.com”.

  • Q: Describe in detail what happens when you do this.
  • What we are looking for when discussing troubleshooting:
    • beginner DNS – hostname to IP translation, nslookup/dig
    • intermediate DNS – root servers, authoritative sources, local cache (where is this in linux?), TTL expiration
    • beginner web – requests, virtual host/redirection, HTTP protocol (POST, GET), server logs, basic response codes

Part 1: The local resolver

The following figure shows an overview of the complete DNS query process.

the local resolver

 

Part 2: Querying a DNS server

Part 2 Querying a DNS server

 

 

 

Other example

A visual explanation of how DNS lookups work

A visual explanation of how DNS lookups work

 

THE CHAIN OF EVENTS TO GET THE IP ADDRESS FOR WWW.ABC.COM:
First your computer queries the name server (DNS server) it is set up to use. This is the recursive name server shown above.

The name server doesn’t know the IP address for www.abc.com, so it will start the following chain of queries before it can report back the IP address to your computer (the numbers below correspond to the numbers in the image).

Query the Internet root servers to get the name servers for the .com TLD.
Query the .com TLD name servers to get the authoritative name servers for abc.com.
Query the authoritative name servers for abc.com to finally get the IP address for the host www.abc.com, then return that IP address to your computer.
Done! Now that your computer has the IP address for www.abc.com, it can access that host.