damian@wong:~$ ./portfolio

loading portfolio...

0%
damian@wong:~/blog/understanding-dns$ cat understanding-dns.mdx

Understanding DNS by Following One Query

Tracing a single query from resolver to root and back, by hand.

Sep 08, 2026 · 1 min read

DNS feels invisible until it breaks. This note follows one lookup from a browser through a recursive resolver, root nameserver, TLD server, and authoritative record.

The useful mental model

A resolver is not searching one giant database. It is asking a chain of increasingly specific questions, caching useful answers along the way. The important detail is that each answer points to the next place to ask.

That small detail explains why TTL matters, why stale records linger, and why a typo in a nameserver setting can produce a failure that looks unrelated to the change.

CODE
client -> recursive resolver -> root -> TLD -> authoritative server

The rest of the post will eventually include command output, diagrams, and the edge cases that make the simple model more interesting.