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).
Detailed notes
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).
Quick revision
- 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).
Types of questions asked
Every way this subtopic shows up in exams — how to recognise it, the formula or logic to use, and a solved example.
Type 1: OSI layer count and ordervery common3 practice Q
'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.
Example: How many layers are there in the OSI reference model?
7 — the TCP/IP model has only 4; the count mix-up is the standard trap.
Type 2: Function-to-layer matchingvery common4 practice Q
'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.
Example: Encryption and data compression are functions of which OSI layer?
Presentation (Layer 6) — it prepares data formats before the Application's services use them.
Type 3: Device/protocol-to-layer matchingcommon3 practice Q
'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).
Example: TCP and UDP work at which layer of the OSI model?
Transport (Layer 4) — end-to-end delivery, segmentation and port numbers.
Type 4: TCP/IP model vs OSIcommon2 practice Q
'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.
Example: How many layers does the TCP/IP model have?
4 — Network Access, Internet, Transport and Application (the last swallowing OSI layers 5-7).
Shortcut tricks
⚡ OSI mnemonics
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".
Example: Which OSI layer comes directly above the Network layer?
Transport (P-D-N-T: layer 4).
⚡ Layer-device pairs
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.
Example: At which OSI layer does a router operate?
Layer 3 - Network.
Where students lose marks
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).
Practice sets — 15 questions
Sets of 10, mixed across the question types above. Each answer comes with a step-by-step explanation.
Topic test · 10 questions
Suggested time 5 min · wrong answers go to your mistake notebook automatically.