DNS (Domain Name System)

The Domain Name System is the part of the internet that turns a name a person can remember, like example.com, into the numeric IP address a machine needs in order to make a connection. Before DNS, every host kept a single flat file mapping names to addresses (HOSTS.TXT), copied around by hand. That approach could not keep up with a growing network. Paul Mockapetris designed DNS as the replacement, first in RFC 882 and RFC 883 in November 1983, then in the revised and definitive pair RFC 1034 and RFC 1035 in November 1987.

RFC 1034, “Domain Names - Concepts and Facilities,” lays out the core idea. The design surveyed earlier proposals and found “a common thread was the idea of a hierarchical name space, with the hierarchy roughly corresponding to organizational structure.” Instead of one central file, the namespace is a tree, and authority over each branch can be delegated to the organization that owns it. This is what makes DNS both distributed and scalable: no single party has to know every name, only how to refer a query to the part of the tree responsible for it.

The system has three main kinds of moving part. The namespace and its resource records hold the data. Name servers are programs that hold information about some part of the tree and answer queries about it, often referring the asker onward to a server with more specific authority. Resolvers are the client-side programs that take an application’s request, walk the tree by talking to name servers, and return an answer. A typical lookup starts at the root, is referred to a top-level domain server, then to the authoritative server for the specific domain.

RFC 1035, “Domain Names - Implementation and Specification,” defines the wire protocol. It states that “all communications inside of the domain protocol are carried in a single format called a message,” and divides that message into header, question, answer, authority, and additional sections. The answers themselves are resource records, each carrying a name, a type, a class, a time-to-live, and type-specific data. The time-to-live value is what lets answers be cached across the network, so that a popular name does not have to be looked up from scratch every time.

DNS has proven remarkably durable. The two 1987 RFCs remain the foundation decades later, extended rather than replaced by additions for security (DNSSEC), internationalized names, and new record types. Nearly every action on the internet begins with a DNS lookup, which is why the system is sometimes called the internet’s phone book, though the tree-shaped, delegated design is what truly sets it apart.