An IP datagram 4000 bytes long with no options arrives at a router, which determ
ID: 3746786 • Letter: A
Question
An IP datagram 4000 bytes long with no options arrives at a router, which determines that the next destination has an MTU of 1,500 bytes. Complete the following questions, showing your calculations and reasoning.
As the router decides to fragment the packet into 3 fragments, determine an appropriate size for each fragment, and identify the starting byte and ending byte of each fragment (2.5 marks).
Calculate the fragmentation offset for each fragment (1.5 marks).
State whether the total number of bytes from all 4 fragments leaving the router will be greater than the initial datagram size that arrived, or less than the initial datagram size, and the reason (1 mark).
Explanation / Answer
The received IP datagram is of 4000 bytes i.e. 20 bytes (IP header) + 3980 bytes (Data). Therefore, data of 3980 bytes need to be fragmented into three in order to transmit this packet onto the link supports 1500 bytes MTU size.
1st Fragment : 1480 bytes + 20 bytes IP header (Total 1500 bytes), Starting Byte: 0, Ending byte: 1479 (Total 1480 bytes). It is represented in IP header by the offset i.e. fragment offset will be 0 in this case and end of data is calculated by the length of data specified in IP header
2nd Fragment : 1480 bytes + 20 bytes IP header (Total 1500 bytes), Starting Byte: 1480, Ending byte: 2959 (Total 1480 bytes). It is represented in IP header by the offset i.e. fragment offset will be 185 (It is number of octets) in this case and end of data is calculated by the length of data (offset*8 + length) specified in IP header
3rd Fragment : 1020 bytes + 20 bytes IP header (Total 1040 bytes), Starting Byte: 2960, Ending byte: 3979 (Total 1020 bytes). It is represented in IP header by the offset i.e. fragment offset will be 370 (It is number of octets) in this case and end of data is calculated by the length of data (offset*8 + length) specified in IP header
The total size transmitted is: 1500 + 1500 + 1040 = 4040 bytes.
The total number of bytes transmitted will be greater than the initial datagram because with each fragment IP header needs to be sent as it contains information of fragments and the last packet of fragments. So the additional 60 bytes (20 bytes with each fragment) will be transmitted.