Try
↑ ↓ move↵ openesc close

Interview prep / DNS and traffic steering

Junior · DNS and traffic steering · System design interview question

What is a DNS TTL, and what do short and long values trade off?

Sketch your own answer first, then compare it with the one below.

A strong answer

The TTL is the number of seconds a cache may reuse a record. After that it must ask again.

A long TTL means fewer queries to the authoritative servers, faster lookups for users, and slower spread of a change. A short TTL means a change reaches users sooner and costs more queries and more lookup waits.

You choose the value before you need to change the record, because a cached answer cannot be recalled.

Sources

Learn it by running it

The dns and traffic steering lesson explains the mechanism behind this question, and its lab lets you change the parameters and watch the effect.

Your progress is saved in this browser. Sign in to keep it on every device. Privacy · Terms