DEV Community

Shreya Princy
Shreya Princy

Posted on

blog on how DNS resolver is happening.

Step-by-Step DNS Resolution Process

  1. The user enters a domain name (e.g.,www.abc.com) in the browser.

  2. The browser checks its cache to see if it already knows the IP address.

  3. If not found, the request moves to the operating system cache.

  4. If still not found, the request is sent to a recursive DNS resolver.

  5. The resolver checks its own cached records.

  6. If the record is cached, it immediately returns the IP address to the client.

  7. If not, the resolver begins querying the DNS.

  8. First, it contacts a Root DNS Server.

  9. The root server does not know the exact IP but directs the resolver to a Top-Level Domain (TLD) server.

  10. The resolver then queries the TLD server.

  11. The TLD server responds with the address of the Authoritative Name Server for that domain.

  12. The resolver sends a request to the authoritative server.

  13. The authoritative server contains the actual DNS records (A, AAAA, CNAME, etc.).

  14. It returns the correct IP address for the domain.

  15. The resolver receives the IP address.

  16. The resolver stores this result for future use.

  17. The IP address is sent back to the user’s device (browser).

  18. The browser receives the IP address.

  19. The browser initiates a connection to the server using this IP.

  20. The request is sent to the web server.

  21. The server processes the request.

  22. The server sends back a response to webpage.

  23. The browser renders the webpage for the user.

  24. Future requests to the same domain are faster due to caching.

  25. The entire process typically completes within milliseconds.

Top comments (0)