Computer Networks and Internet Basics (9hrs) · Computer Fundamentals & Emerging Technologies

Data Transmission in a Network

Watch lectures

Data Transmission in a Network

1. From Message to Bits — the Journey and the Wrapping

A message does not travel as one solid block. It is broken into pieces and each piece is wrapped in headers as it descends the protocol stack:

   application data                     (HTTP request: "GET /index.html")
        │  + TCP header
        ▼
   segment   ┌────────┬──────────────────────┐
             │ TCP    │ data                 │
             └────────┴──────────────────────┘
        │  + IP header
        ▼
   packet    ┌────────┬────────┬─────────────┐
             │ IP     │ TCP    │ data        │
             └────────┴────────┴─────────────┘
        │  + Ethernet header/trailer
        ▼
   frame     ┌───────┬────────┬────────┬─────┬─────┐
             │ Frame │ IP     │ TCP    │data │ FCS │
             └───────┴────────┴────────┴─────┴─────┘
        │
        ▼
   BITS  →  signal over the medium (copper / fibre / radio)

This process is called encapsulation; the reverse process at the receiver is decapsulation. Each layer only reads the header meant for it — which is exactly what makes a network of completely different machines work.

2. Why Layering?

A layered model divides a complex job into smaller, independent tasks: each layer offers a service to the layer above and uses the services of the layer below, and a change in one layer does not break the others. This gives modularity, easier troubleshooting and standard interfaces (so any vendor's hardware and software can interoperate).

3. The OSI Model (7 layers) and TCP/IP Stack

# OSI layer Function PDU Devices/protocols
7 Application User services: web, mail, file transfer Data HTTP, FTP, SMTP, DNS
6 Presentation Translation, encryption, compression Data SSL/TLS, JPEG, MPEG
5 Session Establish, manage, synchronise dialogues Data RPC, NetBIOS, sockets
4 Transport End-to-end delivery, segmentation, flow/error control Segment TCP, UDP
3 Network Logical addressing and routing between networks Packet IP, ICMP, ARP, routers
2 Data link Framing, MAC addressing, error detection on a link Frame Ethernet, Wi-Fi, switches
1 Physical Bits on the medium: voltages, pins, cables, radio Bit UTP, fibre, hubs, RJ-45

TCP/IP mapping: Application (OSI 5-7) · Transport (4) · Internet/Network (3) · Network access/Link (1-2). The Internet uses this four/five-layer practical model, and the OSI model remains the teaching/reference model. Mnemonic for OSI top-down: All People Seem To Need Data Processing.

4. Addressing at Each Layer

Layer Address Size Identifies Example
Application URL / domain name variable A resource https://pyqdeck.com/paper
Transport Port number 16 bits A process/service on a host 80 (HTTP), 443 (HTTPS), 53 (DNS), 25 (SMTP)
Network IP address 32 bits (IPv4) / 128 bits (IPv6) A host on the internet 142.250.192.46
Data link MAC address 48 bits A network interface on the LAN 00:1A:2B:3C:4D:5E
Physical — — — Signals/pins

A frame on a LAN carries all three: MAC to reach the next hop, IP to reach the final host, port to reach the right process on that host.

5. Switching Techniques

Basis Circuit switching Message switching Packet switching (datagram)
Path Dedicated physical path set up first No path; whole message stored and forwarded No path; message split into packets, each routed independently
Bandwidth use Wasted while silent Efficient, but long messages block links Very efficient — links shared statistically
Delay Fixed setup delay, then low delay High (store-and-forward per hop) Variable (jitter), but low average
Failure handling Call drops Retransmit message Route around failure, packet by packet
Example Traditional telephone (PSTN) Old telegraph/telex networks The Internet (IP), most modern data

Virtual circuit packet switching (Frame Relay, ATM, MPLS) is a middle ground: packets follow a pre-established logical path with labels, giving predictable ordering (used by ISPs and enterprise WANs).

6. The Journey of a Web Request (worked end-to-end example)

 1. User types https://pyqdeck.com in the browser
 2. DNS resolves the name → IP address (say 142.250.192.46)      [DNS query]
 3. TCP three-way handshake with the server: SYN → SYN-ACK → ACK [Transport]
 4. TLS handshake establishes encryption                        [Presentation]
 5. HTTP GET /index.html sent; the packet is built            [Application]
 6. The packet is placed in an Ethernet/Wi-Fi frame with the
    default-gateway (router) MAC address as the destination     [Data link]
 7. The router forwards it hop by hop: each router looks at the IP
    address, consults its routing table, decrements TTL, and
    rewraps the packet in a NEW frame for the next link         [Network]
 8. The server's reply travels back along the chosen route
 9. Frames are unwrapped bottom-up; the browser renders the page
10. Lost segments are retransmitted; the connection closes (FIN/ACK)

7. Control Mechanisms That Make It Work

  • Framing — packet boundaries marked so the receiver knows where one ends and the next begins.
  • Error detection — checksums and CRC in the frame trailer; corrupted frames are dropped (Ethernet) or retransmitted (TCP).
  • Flow control — the receiver advertises a window so a fast sender cannot swamp a slow receiver.
  • Error/retransmission control — sequence numbers plus acknowledgements; timeouts trigger retransmission.
  • Congestion control — TCP slow start, congestion avoidance and detection (packet loss) slow the sender when the network is overloaded.
  • Ordering — sequence numbers let the receiver reassemble packets that arrive out of order.
  • Routing — routers choose paths using static routes or dynamic protocols (RIP, OSPF, BGP).
  • Multiplexing — many applications/connections share one link (many ports over one IP, many IPs over one cable).
  • TTL (Time To Live) — a hop counter that prevents packets from looping forever; TTL 0 → packet discarded and ICMP "time exceeded" returned.

8. LAN vs WAN Transmission Path

In a LAN, delivery is one or two hops: source → switch → destination, using MAC addresses within one broadcast domain. In a WAN/internet, the same data crosses a dozen or more routers, each making an independent forwarding decision, with higher latency (milliseconds, not microseconds), possible reordering, and paths that may change mid-transfer.

9. Exam Points

  • Why is layering used? Explain encapsulation with a diagram — 5-7 marks, very frequent.
  • Draw the OSI reference model and state the function of each layer — 7-10 marks, almost certain.
  • Map the OSI layers onto the TCP/IP model — 5 marks.
  • Explain the addressing used at each layer (port, IP, MAC) with sizes — 5 marks.
  • Differentiate circuit switching, message switching and packet switching — 5 marks, very frequent.
  • Trace the steps of loading a web page through the layers — 5-7 marks.
  • Explain flow control, error control and congestion control — 5 marks.
  • What is TTL and why is it needed? — 3 marks.
Official AppAndroid App

PYQDeck for Android

Solve BEU previous-year exam papers anywhere, anytime. Fast search, offline paper viewing, and step-by-step solutions designed specifically for your phone.

← All Computer Fundamentals & Emerging Technologies modules