Networking: Devices, Topologies & Protocols
🔒 Log in to trackOSI and TCP/IP reference models
🔒 Log in to trackOSI (Open Systems Interconnection) - 7 layers, top-down:
| # | Layer | Function | Works with |
|---|---|---|---|
| 7 | Application | User-facing network services | HTTP, FTP, SMTP, DNS |
| 6 | Presentation | Format, encryption, compression | JPEG, MP3, SSL/TLS concepts |
| 5 | Session | Opens/manages/closes dialogues | NetBIOS, RPC |
| 4 | Transport | End-to-end delivery, ports, reliability | TCP, UDP (data units: segments) |
| 3 | Network | Logical addressing, routing | IP, routers (packets) |
| 2 | Data Link | Framing, MAC addressing, error detect | Ethernet, switches/bridges (frames) |
| 1 | Physical | Raw bits on the medium | Cables, hubs, repeaters |
TCP/IP model compresses these into 4: Application (7+6+5), Transport (4), Internet (3), Network Access/Link (2+1) - it is what the real Internet runs.
Encapsulation journey: data -> segments (L4) -> packets (L3) -> frames (L2) -> bits (L1).
Why a reference model exists
Moving data from one machine to another needs many different jobs: signalling, framing, addressing, delivery, dialogue control, translation, and the user's service. The OSI (Open Systems Interconnection) model splits these into 7 layers, so each layer can be designed and replaced independently.
The 7 layers — bottom to top
| # | Layer | One-line job | Works with |
|---|---|---|---|
| 1 | Physical | raw bits on cables/signals | cables, hubs, repeaters |
| 2 | Data Link | frames, MAC addresses, error detection | switches, bridges, NIC |
| 3 | Network | IP addressing and routing | routers, IP |
| 4 | Transport | end-to-end delivery, segmentation, ports | TCP, UDP |
| 5 | Session | opens, manages, closes dialogues | session setup tokens |
| 6 | Presentation | translation, encryption, compression | formats, SSL/TLS |
| 7 | Application | the user-facing services | HTTP, FTP, SMTP, browsers |
Mnemonics, top-down: "All People Seem To Need Data Processing". Bottom-up: "Please Do Not Throw Sausage Pizza Away".
How the layers are tested
- Device-to-layer: hub/repeater = 1, switch/bridge = 2, router = 3.
- Function-to-layer: routing = Network (3); framing/MAC = Data Link (2); encryption and compression = Presentation (6); mail/web services = Application (7).
- Number questions: 7 layers (OSI) vs 4 layers (TCP/IP). The middle is Transport in both.
- Data flows DOWN the sender's stack (7 to 1), across the wire, and UP the receiver's stack (1 to 7).
The TCP/IP model — the practical cousin
| TCP/IP layer | OSI layers it swallows |
|---|---|
| Application | 5 + 6 + 7 (Session, Presentation, Application) |
| Transport | 4 |
| Internet | 3 (Network) |
| Network Access / Link | 1 + 2 (Physical, Data Link) |
The Internet actually runs on TCP/IP; OSI is the teaching map. "Which model has 4 layers?" — TCP/IP.
Reading a layer question in the exam
First decide what the question is really asking: a number (7 layers, 4 in TCP/IP), an order (which sits above which), a function (what does this layer do), or a worker (which device or protocol lives here). For function questions, test the planted option against its neighbour: routing is NOT Transport (Transport only delivers end to end after Network has found the path), and encryption is NOT Application (Application serves the user; Presentation prepares the data format for it).
Question types you will see
Each type: how to recognise it, the method step by step, and one question to try.
OSI layer count and order
'How many layers does the OSI model have?', correct ordering questions, or the layer that sits directly above/below another.
OSI = 7 layers: Physical, Data Link, Network, Transport, Session, Presentation, Application (bottom to top).
Mnemonic top-down: All People Seem To Need Data Processing.
Transport is the middle (4th); Application is 7th, Physical 1st.
How many layers are there in the OSI reference model?
Show solutionHide solution
7 — the TCP/IP model has only 4; the count mix-up is the standard trap.
Function-to-layer matching
'Routing is done at which layer?', 'encryption/compression is a ___ layer function', 'framing and MAC addressing belong to ___'.
Bits/cables = Physical (1); frames, MAC = Data Link (2); addressing and routing = Network (3); end-to-end delivery, ports = Transport (4); dialogues = Session (5); translation, encryption, compression = Presentation (6); user services = Application (7).
The planted traps: encryption at Application, routing at Transport.
Ports and TCP/UDP live in Transport, never Network.
Encryption and data compression are functions of which OSI layer?
Show solutionHide solution
Presentation (Layer 6) — it prepares data formats before the Application's services use them.
Device/protocol-to-layer matching
'A switch works at which layer', 'HTTP is a ___ layer protocol', 'TCP sits in which layer'.
Hub/repeater L1; switch/bridge L2; router L3; TCP/UDP L4.
HTTP, FTP, SMTP = Application (7); IP = Network (3).
Match the job before the name: a router routes (3), a switch switches frames (2).
TCP and UDP work at which layer of the OSI model?
Show solutionHide solution
Transport (Layer 4) — end-to-end delivery, segmentation and port numbers.
TCP/IP model vs OSI
'The TCP/IP model has how many layers', 'which OSI layers merge into TCP/IP Application', or mapping the four TCP/IP layers.
TCP/IP = 4 layers: Network Access (1+2), Internet (3), Transport (4), Application (5+6+7).
OSI's top three merge into TCP/IP's Application.
The Internet runs on TCP/IP; OSI is the reference map.
How many layers does the TCP/IP model have?
Show solutionHide solution
4 — Network Access, Internet, Transport and Application (the last swallowing OSI layers 5-7).
Shortcuts that save time
Bottom-up: "Please Do Not Throw Sausage Pizza Away" (Physical, Data link, Network, Transport, Session, Presentation, Application). Top-down: "All People Seem To Need Data Processing".
Which OSI layer comes directly above the Network layer?
Show solutionHide solution
Transport (P-D-N-T: layer 4).
Router = layer 3 (both R words rhyme with 'routing/IP'); Switch/Bridge = layer 2 (frames/MAC); Hub/Repeater = layer 1 (bits). Any 'works at which layer' question resolves by the device's address type: IP = 3, MAC = 2, no address = 1.
At which OSI layer does a router operate?
Show solutionHide solution
Layer 3 - Network.
Mistakes to avoid
Where most students lose marks on this subtopic.
Counting 4 or 5 OSI layers - the model has 7 (the TCP/IP model has 4).
Putting encryption at the Application layer - classic encryption/formatting sits in Presentation (6).
Saying the Session layer routes packets - routing is Network (3).
Quick revision
Read this the night before the exam.
OSI = 7 layers: Physical, Data Link, Network, Transport, Session, Presentation, Application.
Router L3, Switch L2, Hub L1; routing = Network; encryption/compression = Presentation.
Transport layer = TCP/UDP and ports; Session = dialogues.
TCP/IP model = 4 layers (Network Access, Internet, Transport, Application).
Practice: 15 questions
Sets of 10, mixed across the question types above. Every answer has a step-by-step explanation.
Topic test · 10 questions
Suggested time 5 min · wrong answers go to your mistake notebook automatically.