One exchange, several layers
A network does not solve every problem at once.
An application knows what it wants to say. The transport layer manages a conversation or sends an independent datagram. The network layer identifies where the data should travel, while the link layer moves it across the next local connection.
These layers cooperate without needing to expose every detail to one another. This is why a router can forward an IP packet without understanding the meaning of the web request inside it.
Build the model
Four useful names for data
Data
The information an application wants to send, such as a web request or a message.
Segment or datagram
Transport data. TCP (Transmission Control Protocol) commonly uses segments; UDP (User Datagram Protocol) commonly uses datagrams.
Packet
Network-layer data carrying an IP source, destination, and transport payload.
Frame
Link-layer data used for one local hop, with addresses for the local connection.
Name the boundaries
The OSI model separates seven kinds of work.
The OSI (Open Systems Interconnection) model is a reference model for discussing network responsibilities. Real protocols can span more than one layer, but the model gives us a shared vocabulary for asking where a behavior belongs.
Provides network services and meaning directly to applications, such as web or name-resolution exchanges.
Example: HTTP or DNSThe OSI model is a reasoning tool. Do not assume that every modern protocol maps perfectly to exactly one layer.
Look inside the packet
An IP datagram carries delivery information.
The header tells routers how to move the payload across networks. The exact fields depend on whether the packet uses IPv4 or IPv6.
IPv4 uses TTL, a Protocol field, and a header checksum.
Mini experiment
Wrap the message
Add the layers one at a time, then remove them at the destination. Notice which layer is concerned with the local hop and which one survives across routers.
Application data is ready to be handed to a transport protocol.
Knowledge check
Test your layer model
Answer twelve questions. The answer order changes each time.