All subjects · Computer Science · WCP03 Advanced Principles of Computer Science

Packet switching and internet routers

Edexcel IAL Computer Science · WCP03 Advanced Principles of Computer Science

The internet sends data as many small, independent packets that can each take a different route. This is packet switching, and it is why the internet keeps working when parts of it fail.

Practise this in the app: instant marking and a fix for every mistake. Free, no email needed to start.

Practise this lesson

Packets

A message is split into packets. Each packet has:

How packet switching works

1. The data is split into packets, each labelled.

2. Each packet is sent to the nearest router.

3. Each router reads the destination IP address, looks in its routing table and forwards the packet to the next router on the best available path (fewest hops, least congestion). Routers talk to each other with routing protocols to keep tables up to date.

4. Packets may take different routes and arrive out of order.

5. At the destination, packets are reassembled in order using sequence numbers; missing or corrupt packets are requested again.

6. Each router reduces the TTL by 1; a packet whose TTL reaches 0 is discarded, so lost packets do not circle forever.

Benefits and drawbacks

Benefits: links are shared by many users, so bandwidth is used efficiently; packets can be rerouted around failures or congestion, giving resilience; no dedicated line is needed, so it is cheaper; errors only need one packet resent.

Drawbacks: headers add overhead; packets can be delayed, lost or arrive out of order, so reassembly takes time; delay varies (jitter), which can affect real-time video calls; more processing at routers and at the receiver.

Worked example

A packet's TTL starts at 64. It passes through 9 routers. What is its TTL when it arrives, and why does TTL exist?

  1. Each router reduces TTL by 1: 64 - 9 = 55.
  2. If a routing error made it loop, TTL would reach 0 and the packet would be discarded instead of travelling forever.

Answer: TTL = 55; it prevents packets circulating endlessly.

Key idea: Packet switching: split into packets with headers (IPs, sequence number, TTL); routers forward each packet independently using routing tables; reassemble in order; request missing packets. Efficient and resilient, but with overhead and variable delay.

Check yourself

  1. Which item is found in a packet header?
    • The full message
    • The user's password
    • Destination IP address
    • The router's routing table
    Show answer

    Destination IP address. The header carries addressing and control information.

  2. What does a router do with an incoming packet?
    • Reads the destination IP address and forwards it to the next hop using its routing table
    • Reassembles the whole message
    • Translates the domain name into an IP address
    • Encrypts the payload
    Show answer

    Reads the destination IP address and forwards it to the next hop using its routing table. Routers make a forwarding decision for each packet.

  3. Why can packets of the same message arrive in a different order?
    • The sender sends them in random order
    • Routers sort packets by size
    • Each packet may travel by a different route with different delays
    • TTL changes the order
    Show answer

    Each packet may travel by a different route with different delays. Independent routing means different paths and delays.

  4. A packet leaves with a TTL of 32 and passes through 14 routers. What is its TTL on arrival?
    Show answer

    18. Each router subtracts 1: 32 - 14 = 18.

  5. Why is packet switching resilient?
    • Every packet uses the same fixed line
    • Packets cannot be lost
    • It does not use routers
    • If a link fails, packets can be routed around it
    Show answer

    If a link fails, packets can be routed around it. Routers adapt to failures and congestion.

  6. What is the sequence number in a packet used for?
    • Choosing the route
    • Putting packets back in the correct order at the destination
    • Setting the packet's priority
    • Encrypting the packet
    Show answer

    Putting packets back in the correct order at the destination. It records each packet's position in the message.

  7. Which is a drawback of packet switching for a live video call?
    • It cannot carry video data
    • It needs a dedicated line for each call
    • It never resends lost data
    • Packets can be delayed by varying amounts, causing jitter
    Show answer

    Packets can be delayed by varying amounts, causing jitter. Real-time traffic needs steady timing.

Practise with instant feedback

Sources

Last updated 8 November 2026. Spotted a mistake? Tell us.