Skip to content

Domain Name System (DNS)

Scope

The system for translating human-readable domain names into machine-readable IP addresses, and its role in global traffic routing.

Why This Topic Exists

DNS is the phonebook of the internet. It’s a foundational, distributed system that makes the web navigable. Beyond simple name-to-address translation, it is a powerful lever for directing traffic, enabling load balancing, and improving service availability.

Core Tradeoffs

  • Caching TTL (Time-to-Live): A shorter TTL allows for faster changes but increases the load on DNS servers. A longer TTL reduces load but slows down propagation of updates.
  • Routing Policy Complexity: Simple round-robin is easy to implement, but more complex strategies like latency-based or geolocation-based routing can improve user experience at the cost of added complexity and potential for misconfiguration.
  • Centralization vs. Decentralization: Using a single DNS provider is simple, but diversifying providers can increase resilience against provider-specific outages.

Common Failure Modes

  • DNS Propagation Delays: Changes to DNS records are not instantaneous, leading to periods where traffic is sent to old and new endpoints simultaneously.
  • DDoS Attacks: Volumetric attacks against DNS servers can render services unreachable even if the services themselves are healthy.
  • Cache Poisoning: Malicious actors can corrupt DNS caches to redirect users to fraudulent sites.
  • Mismatched Records: A CNAME record cannot coexist with other records for the same name, a common source of configuration errors.

Interview Signals

A strong candidate can trace the entire lifecycle of a DNS query, from a user’s browser to the authoritative nameserver. They should be able to discuss various record types (A, CNAME, etc.) and explain how to use DNS for load balancing, failover, and CDN integration.

  • CDN
  • Load Balancing
  • Communication
  • Security