Log inStart free
LESSON 33.24 · 6 STAGES · 2 CONTROLS · 3 CHECKSPRO · PREVIEW

DNS resolution

Watch one name turn into an address, server by server, then from a cache.


Pro lesson. Stage 1 is free to watch. Pro opens all 6 stages, 2 controls and 3 checks, in this lesson and every other.

Go Pro · $8.25/mo
EXPLAINER · 33.24 · RESOLVER BAYLOOKUP 1 · ASKING · CACHE 0 ROWS
01
Stage 1 of 6 · Client asks
The client asks DNS for the IP address of api.llm.example. The query goes to a recursive resolver.
Explain it simply

A connection needs a number, the IP address, not a name. So the client asks a recursive resolver, a DNS server that searches for it. Its cache, the box below, starts empty.

Five lanes: client, resolver, root, TLD and authoritative server. One query arrow goes from the client to the resolver. The resolver cache is empty.

query, lookupreferral, TTLanswerstale, failed
clientK1 chat appresolverrecursiverootthe . zoneTLDexample.authoritativens1.llm.exampleA? api.llm.exampleresolver cacheemptyone lookup of api.llm.exampleT = 10 msclientK1 chat appresolverrecursiverootthe . zoneTLDexample.authoritativens1.llm.exampleA? api.llm.exampleresolver cacheemptyone lookup of api.llm.exampleT = 10 ms
Toy: the chat app's 15 lookups of one name in 30 s
STAGE 1 / 6
MATH · STAGE 1HOVER A SYMBOL OR A SHAPE
T=∑hRTTh\sy{t}{out}{T} = \sum_{h} \sy{r}{param}{\mathrm{RTT}_h}
RTTresolver=10 ms\mathrm{RTT}_{\text{resolver}} = 10\ \text{ms}

Each server asked adds its round trip.

Common mix-ups

MYTHEvery DNS lookup goes all the way to the root.

The fix, and 1 more mix-up with the diagram to show them, come with Pro.

Predict, then reveal
3 CHECKS · PRO
Q01With a 1 s TTL, how many of the 15 lookups ask the authoritative server?

Make your guess, then test it in the diagram. All 3 checks come with Pro.

PRO LESSON · YOU WATCHED STAGE 1 OF 6
Unlock the full explainer
  • 5 more stages and 2 live controls
  • 2 mix-up cards and 3 predict-then-reveal checks
  • Watch it as a narrated video, in three voices
  • Every Pro lesson and capstone · 656 in total

$99 a year, or $15 a month. Cancel any time.