What Is DNS? The Phonebook of the Internet

What Is DNS? The Phonebook of the Internet

You update a DNS record, test it on your laptop, and it works. A colleague clicks the same link and lands on the old server. You are both right: DNS is not one database. It is a hierarchy of caches that agree with each other eventually.

Four stops for every lookup

The analogy is a phonebook, but this phonebook has four desks:

  1. Resolver — your first call. Usually your ISP’s, or a public one such as 8.8.8.8 or 1.1.1.1. It does the walking for you.
  2. Root servers — do not hold your record; they point at the right top-level domain (.com, .org, .cn).
  3. TLD servers — point at the domain’s authoritative name servers.
  4. Authoritative name server — holds the actual record. Its answer is the one everyone else copies.

The resolver remembers the answer for a while, per the record’s TTL (time to live). That cache is why your fix appears on your machine first.

The record types that matter

Type Meaning
A Domain to IPv4 address — the classic entry
AAAA Domain to IPv6 address
CNAME Alias: this name is another name
MX Mail server for the domain
TXT Arbitrary text — email authentication and domain verification
NS Which servers are authoritative

What DNS does not do

  • It does not encrypt anything by default. Plain DNS queries are visible to your network; DNS over HTTPS encrypts the query path, but that protects the question, not the traffic that follows.
  • It does not hide who you are, and it does not route traffic. Once the name maps to an IP, your browser connects directly — or through whatever proxy you configured.
  • It does not tell you where a server physically is. Geolocation is a separate lookup with its own database. If you want to see whose network an address belongs to, the IP lookup maps an address to its ISP, ASN, and rough region.

When a change looks stuck

Check what the world sees with nslookup (Windows) or dig (Mac and Linux). If the authoritative server already has the new record while your machine shows the old one, you are waiting on a cache, not a broken configuration. Wait out the TTL; nothing you do to your own machine moves anyone else’s cache.

The practical move: drop the TTL a day before a planned change, then raise it again afterward. Future you, staring at a stale answer, will be grateful.