Domain Name System (DNS) Protocol

2 mins read

Internet is a computer network consisting of all the computers in the world which are interconnected to each other by way of certain protocols. All devices on a network have IP addresses assigned to them by way of which they are able to communicate with other devices on the network. That is the only way, i.e. IP addresses, by which computers are able to interact with each other. But since it would be difficult for humans to IP addresses of websites which is made up of numbers, there are Domain Names which correspond to IP-Addresses (e.g. an IP address of www.google.com is 172.217.160.206). This mapping is always working seamlessly in the background through something called Domain Name System (DNS) which helps computers convert human readable domain names to IP addresses.

DNS may be compared to the phone-book of the internet. It bridges the gap between human readable domain names to computer-understandable IP addresses. So whenever a user requests for a website ,e.g. www.google.com, the user’s computer sends a request to the DNS server which has been configured in the user’s computer either automatically by the user’s Internet Service Provider or manually by the user. This request contains the name of the website that the user wants to open (i.e. www.google.com). Now, the DNS server will revert back to the user’s computer with the IP address of the required website and the user’s web browser will open the same for user to work upon.

How DNS works?

DNS Query

The exact steps in which a DNS query works are as follows:

  1. The user’s computer search for corresponding record in the local cache of the computer, i.e. locally stored records of previously done DNS queries. If a record is found there, it is used.
  2. If the record is not found in the local cache, a query is sent to what is called a Recursive DNS Server/Resolver which is generally provided by your Internet Service Provider. If a record is found there, it is used.
  3. If a record is not found in the Recursive DNS Server/Resolver, a query is sent by the Recursive DNS Server/Resolver to a Root Name Server. If the Root Name Server has the required record, it is sent back to the Recursive DNS Server/Resolver which sends it back to the user’s computer.
  4. If a record is not found in the Root Name Server, they Root Name Server directs the Recursive DNS Server/Resolver to ask the query to a specified Top Level Domain (TLD) Name Server. If the TLD Name Server has the required record, it is sent back to the Recursive DNS Server/Resolver which sends it back to the user’s computer.
  5. If a record is not found in the TLD Name Server, they TLD Name Server directs the Recursive DNS Server/Resolver to ask the query to a specified Authoritative DNS Server. If the Authoritative Name Server has the required record, it sends the required record back to the Recursive DNS Server/Resolver which sends it to the user’s computer. Then the website with the specified domain is opened using the obtained IP address.
  6. If no record is found, then the user is trying to open a non-existing domain.

Here, in case the Recursive DNS Server/Resolver did not have the required record with itself in the first instance, it saves the retrieved record from the TLD Name Server or the Authoritative DNS Server for future use.

For Wikipedia entry on DNS, click here.

For Wikipedia entry on Internet, click here.

For more posts on Internet, click here.

For more posts in The Cyber Cops project, click here.

1 Comment

  1. Undeniably imagine that that you said. Your favorite reason appeared to be at the net the simplest thing to take into account of. I say to you, I certainly get irked even as other folks consider issues that they just do not recognise about. You controlled to hit the nail upon the top and outlined out the entire thing with no need side-effects , folks could take a signal. Will likely be again to get more. Thanks

Comments are closed.