DEV Community

loading...

Discussion on: Behind the scenes: From the moment you enter a URL

Collapse
salyadav profile image
Saloni Yadav Author • Edited

I was asked some interesting questions on linkedin, which I would like to post here as well:

1) Where is the DNS resolver located? Is it in our machine?

2) Does every request, after reaching the DNS resolver, follow the sequence of going to root server, then TLD server and then ANS?

TL;DR

  1. DNS Resolver is in fact only a software service that can run even on your computer, but most often it is provided by your Internet Service Provider(ISP). This DNS Resolver service sends requests to the wider hierarchy of DNS Servers out in the world on behalf of your Operating system.
    Now, let's assume the most common case- that is, the DNS resolver is hosted by your ISP, that means, it is common for a bunch of local computers/devices connected to this network. Needless to say, DNS resolvers are distributed anywhere and everywhere across the internet.
    Note: You can even configure your DNS resolver setting from Control Panel -> Network and Internet Settings. But by default, it is taken as that of your ISP (which ever WiFi or Ethernet you are connected to).

  2. As to whether the whole DNS Root server to ANS resolution happens every time the request reaches the resolver- No.
    As I mentioned above, a resolver is shared by a bunch of local clients in a network. The resolver has its own cache to maintain the bunch of resolved domains. So if you one client on that network accessed a domain, and then another client (say your phone) tries to access the same domain, it will be picked up from the cache.

Additional FYI:
Why do we maintain so much hierarchy to fetch a domain instead of having it in our system?
When you go and buy a domain, say from #GoDaddy, it is their responsibility to update the IP Address of the servers they are alloting over to the whole network (TLD, ANS). Imagine if this weren't so centralized, it would be an odious task to update every client with this info.
On the contrary, we have only a total of 13 Root Servers across the world (named from 'A' to 'M' - So unimaginative! :D), maintained by #ICANN (Internet Corporation for Assigned Names and Numbers), which are responsible for the world of DNS! PFA the list of organizations that host these root servers.
For the list of Root servers across the world-
ionos.com/digitalguide/server/know...