Models

Layered Network Models

The principle of dividing complex communication tasks into manageable layers.

The Problem of Complexity

Sending data between two computers involves several tasks: passing data from an application to an Ethernet interface, finding a path to a remote host, detecting and handling errors, and reconciling data formats used by different computers. Layer boundaries define responsibilities, services, and data interfaces between adjacent parts of the stack.

Solving all of these tasks in one monolithic module would make development and replacement of individual functions harder. A layered architecture divides network communication into smaller parts, each with a defined responsibility and services exchanged across adjacent layers. A higher layer uses a lower-layer service through an interface without knowing its implementation details.

An analogy: two philosophers

A simplified example of two philosophers, one in London and one in Paris, shows how layers separate responsibilities during communication.

  • Layer 3 (The Idea Layer): The philosophers focus on discussing philosophy. This role corresponds to a user application, such as a web browser or email client. The London philosopher has an idea to share.
  • Layer 2 (The Language Layer): The London philosopher speaks English and the Paris philosopher speaks French. Each uses a translator. The London translator converts the text into a common, agreed-upon language, such as Latin, that the other translator understands. This corresponds to the .
  • Layer 1 (The Logistics Layer): Each translator gives the message to a secretary. The secretary puts it into an envelope, writes the addresses, may add a tracking number for delivery confirmation, and hands it to the postal service. This corresponds to the and the .
  • The physical medium (the post office): Royal Mail picks up the letter and transports it by truck or plane to France, where La Poste takes over and delivers it to the address. This corresponds to the .

At the receiving end in Paris, these steps occur in reverse: the post office delivers the letter, the secretary opens it and checks it, the translator converts the Latin message back to French, and the Paris philosopher receives the idea.

Principles of layered architecture

The philosopher analogy shows the core rules of layered networking:

  • Peer-to-peer communication: In the model, each layer communicates logically with its corresponding peer layer on the other machine. The London translator communicates with the Paris translator. They use a shared set of rules, known as a .
  • Interface services: Each layer provides services to the layer directly above it through a well-defined . The London philosopher does not need to know the details of translation or mail services; they hand the idea to the translator. In the model, data is processed down the stack on the sending side and up the stack on the receiving side.
  • Layer independence: An implementation change in one layer should not require changes in the others if the interface and service provided to the layer above remain the same. The requirement concerns the exposed interface and service; implementations may differ. In the analogy, the way letters are transported can change if their delivery remains compatible. This supports modularity and technological development across systems.

Related articles