Computer Networks · M2 · read

Optional fragmentation · example 1

IP packet details · supporting practice

Unit 4 support · header comparison; fragmentation is additional practice

Optional worked extension. This calculation format was not found in the supplied December 2025 final or February 2026 re-exam. The numbers and practice marks are authored. Study the core concept and actual-paper questions first; this is extra explanation, not a TEE prediction.

Practice question. An unfragmented IPv4 packet is 4000 bytes including a 20-byte header. It crosses a link of MTU 1500 bytes. DF=0 and every fragment repeats the same header. Find each fragment’s payload length, total length, offset and MF flag. [3 practice marks]

Answer

Given

Total=4000; H=20; MTU=1500 bytes; DF=0.

To find

All fragments and their header-related values.

Formula and why

P=T-HLaTeX: P=T-H
P_{\max}=8\left\lfloor\frac{\mathrm{MTU}-H}{8}\right\rfloorLaTeX: P_{\max}=8\left\lfloor\frac{\mathrm{MTU}-H}{8}\right\rfloor
\mathrm{offset}=\mathrm{preceding\ payload\ bytes}/8LaTeX: \mathrm{offset}=\mathrm{preceding\ payload\ bytes}/8

Subtract the header before splitting the original payload. Round non-final fragment payload capacity down to a multiple of eight.

Step-by-step solution

Step 1. Original payload

4000−20=3980 bytes.

Step 2. Non-final payload capacity

MTU−H=1500−20=1480. Floor((1480)/8)×8=1480 bytes.

Step 3. Allocate each fragment

FragmentPayload bytesTotal bytesStarting byteOffset /8MF
114801500001
21480150014801851
31020104029603700

Step 4. Verify no payload is lost

1480+1480+1020=3980 bytes. Every total length is at most 1500.

Final answer: 3 fragments; lengths, offsets and MF are listed in the table.