Octet

How does the TCP/IP model differ from the OSI model?

Show the answer

Say this first

The TCP/IP model is the one the internet actually runs. RFC 1122 defines four layers: link, internet, transport and application. OSI splits the link layer into physical and data link, and splits the top into session, presentation and application. Many textbooks use a five-layer hybrid: physical, data link, network, transport, application. OSI is the vocabulary we use; TCP/IP is the protocol suite that won.

Go deeper

Side by side

OSITCP/IP (RFC 1122)Protocols
7 Application, 6 Presentation, 5 SessionApplicationHTTP, DNS, DHCP, SSH, TLS, BGP
4 TransportTransportTCP, UDP
3 NetworkInternetIPv4, IPv6, ICMP
2 Data link, 1 PhysicalLinkEthernet, Wi-Fi, PPP

Why the difference matters

  • OSI was designed first as a model, then protocols were written to fit it. TCP/IP grew from working protocols, and the model describes what was built.
  • In TCP/IP the application handles what OSI calls session and presentation. TLS, for example, is a library the application calls.
  • When engineers say "layer 2", "layer 3", "layer 4" or "layer 7" they borrow OSI numbers even though they run TCP/IP. Nobody says "layer 5 problem" in practice.

Traps

  • Saying TCP/IP has seven layers. It has four (or five in the teaching variant).
How did you do?Book 1.3 Architecture