0% found this document useful (0 votes)
5 views

Fragmentation

Uploaded by

Noor Uddin
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views

Fragmentation

Uploaded by

Noor Uddin
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 20

IP Datagram Fragmentation

IP datagram fragmentation is the process of breaking down an IP datagram


into smaller pieces, called fragments, so that each fragment can be
transmitted through a network link with a smaller maximum transmission
unit (MTU) than the original datagram size.
The fragments are reassembled at the destination host.

Maximum Transmission Unit (MTU) refers to the largest size (in bytes) of a
data packet or frame that can be transmitted over a particular network or
link without being fragmented into smaller pieces.
• In every physical network, a Maximum
Transmission Unit (MTU) size is specified,
i.e. the maximum size of a data packet or
frame that can pass through.
• If, for example, a packet comes from a
network, say A, with a bigger MTU size
than the one the packet is transiting to,
say B, then the packet must be
fragmented.
• The fragmentation process here consists
of breaking down a larger IP packet into
smaller packets that can be transmitted
over the new network with a smaller
MTU size.
• With the identification, flags and Fragment offset fields, we can reassemble the fragments of the
datagram packet at the destination host.
• Identification
• Fragmentation Flags
• Fragmentation Offset
Identification

It is a 16 bits field that indicates a value that aids in identifying the


fragments of a fragmented IPv4 data packet.
It means that all the fragments of a fragmented datagram have the same
identification number, which will be used to identify IPv4 fragments on the
receiving side.
Fragmentation Flags
This three-bits field controls fragments and indicates fragmentation possibilities.
• 1st bit is reserved for future use (its value is always zero)
• 2nd bit (DF bit) if set to ‘0’ indicates that the datagram can be fragmented if necessary;
and when set to “1”, the datagram can not be fragmented even if required.
• 3rd bit (MF bit) if set to “1”, more fragments will follow the packet, and when set to “0”,
it means that either no more fragments will follow or the packet was not fragmented.
Fragmentation Offset
It is a 13-bit field that is used to identify the starting position of data in a fragment
concerning the start of the data in the whole datagram.
• The first fragment datagram has a fragment offset of zero.
• The fragment offset is measured in units of 8 octets (64 bits). So, in subsequent
fragments, the value is the offset of the data that the fragment contains from the
beginning of the data in the first fragment in 8 bytes blocks step.

• With the identification, flags and Fragment offset fields, we can reassemble the
full datagram packet at the destination host.
MTU Size 1500 bytes
(Data field +header)
(1480 + 20 )

2nd frag
Offset 1480/8 = 185

3rd frag.
Offset 185 + 1480/8 = 370
Positive aspect
Compatibility: In heterogeneous networks where various devices and
technologies with different MTUs are in use, fragmentation can help
bridge the gap. Routers can break down larger packets into smaller ones to
ensure compatibility with devices that support only smaller MTUs.
Legacy Support: Fragmentation can allow modern devices to
communicate with older or legacy devices that have smaller MTUs. This
backward compatibility is crucial in certain situations to maintain
connectivity.
Overcoming Inflexible MTU Sizes: In some cases, the MTU size of a
network segment might be relatively small, and changing it is not practical
due to technical limitations or network constraints. Fragmentation can
help data packets from larger MTU networks traverse such segments.
Negative aspect
Inefficiency: Fragmentation adds overhead to the network by breaking down larger
packets into smaller pieces. This results in the transmission of additional header
information for each fragment, reducing the overall efficiency of data transfer.
Increased Processing Overhead: Routers and devices must perform additional
processing to fragment and reassemble packets, which can consume CPU and
memory resources. This extra processing can impact the overall performance of
network devices.
Increased Latency: Fragmentation can lead to increased latency as devices spend
time breaking down and reassembling packets. This delay can be particularly
noticeable in real-time applications like video conferencing or online gaming.
Greater Risk of Packet Loss: Fragments may arrive out of order or experience
different routes and delays, increasing the risk of packet loss during transmission. If
any fragment is lost, the entire original packet needs to be retransmitted, further
impacting efficiency.
Negative aspect
Decreased Throughput: Fragmentation can reduce the overall throughput of a
network, as it may require the retransmission of incomplete or lost packets, leading
to congestion and slower data transfer rates.
Security Risks: In some cases, malicious actors may take advantage of fragmentation
to obscure or hide their activities. Security mechanisms may have difficulty inspecting
fragmented packets, potentially posing security risks.
Complexity: Managing fragmentation can be complex, especially in large and
dynamic network environments. It adds an additional layer of complexity to network
configuration and troubleshooting.
Protocol Overhead: Fragmentation requires additional protocol overhead, as devices
need to handle the fragmentation and reassembly process. This overhead can be a
significant concern in bandwidth-constrained networks.
How to avoid or minimize the negative
affect of fragmentation?
Path MTU Discovery (PMTUD):
Enable and use Path MTU Discovery on network devices. PMTUD dynamically determines the Path
MTU between the source and destination, helping to avoid sending packets that are too large for
intermediate network segments.
Packet Size Optimization:
When designing data packets, avoid creating unnecessarily large packets. Smaller packets are less
likely to require fragmentation. However, maintain an efficient packet size to minimize header
overhead.
Network Redesign:
Consider redesigning your network to use consistent MTU sizes throughout. This can prevent
fragmentation issues by ensuring uniform MTU settings across all network segments.
Compression technique can be used to reduce the size of packets, which can help to avoid
fragmentation. Moreover, tunneling can be used to encapsulate packets in a different protocol, which
can help to avoid fragmentation.
Question 1
Question. At the receiver, a packet has arrived with an MF bit value of 1.
Analyze if this is the first fragment, the last fragment, or a middle
fragment? What if the MF bit value is 0? How do we know if the packet was
fragmented?
Answer. If the MF bit is 1, it means that there is at least one more
fragment; the fragment is the first or the middle one.
If the MF bit is 0, it means there are no more fragments ; the fragment is
the last one.
However, we cannot say if the originated packet was fragmented or not. A
non-fragmented packet is considered the last fragment.
Question 2
Question. Consider a packet received with an MF bit value of 1
and a fragmentation offset value of 0. Analyze and reason if this
is the first fragment, the last fragment, or a middle fragment?

Answer. Because the MF bit is 1, it is either the first fragment or


a middle one, and because the offset value is 0, therefore it is the
first fragment.
Question 3

Question. Suppose we are sending a datagram of size 4000 bytes from A to B. The MTU
size between A and B is 1500 (1480 bytes data field + 20 bytes header field) bytes.
Applying fragmentation technique, how many fragments the datagram will have?
What are the MF and fragment offset values of each fragment?

Answer. The datagram will be divided into three fragments.

The MF value of first fragment is 1, and the fragment offset value is 0.


The MF value of second fragment is 1, and fragment offset value is 185
The MF value of third fragment is 0, and fragment offset value is 370
Question 3 (Explained)
Question. Suppose we are sending a datagram of size 4000 bytes from A to B. The MTU
size between A and B is 1500 (1480 bytes data field + 20 bytes header field) bytes.
Applying fragmentation technique, how many fragments the datagram will have?
What are the MF and fragment offset values of each fragment?

Answer. The datagram will be divided into three fragments of the sizes:
1500 = (1480+20)
1500 = (1480+20)
1060 = (1040+20) respectively.

The MF value of first fragment is 1, fragment offset value is 0.


The MF value of second fragment is 1, fragment offset value is 185 i.e., 0+(1480/8)
The MF value of third fragment is 0, fragment offset value is 370 i.e., 185 + (1480/8)
Question 4
Question. Imagine you are a network administrator responsible
for optimizing a network's performance. The situation is that
fragmentation has become a significant issue in the network.
What specific steps would you take to address and prevent
fragmentation-related problems, and how would your actions
improve the overall network efficiency and reliability?
Question 4 -Answer
To enhance overall network efficiency and reliability I would take the following steps.
MTU Audit: Conduct a comprehensive audit of the network to identify MTU settings on all
devices and network segments.
( I will conduct an MTU audit to identify MTU settings)
Standardize MTU Sizes: Establish a standard MTU size for the entire network.
(I will implement standard MTU size for the whole network)
Path MTU Discovery (PMTUD): Enable and encourage the use of Path MTU Discovery on all
network devices to dynamically determine the Path MTU, minimizing the chances of sending
oversized packets.
(To minimize the chances of sending oversized packets on a link, I will implement Path MTU
discovery on all devices to dynamically determine path MTU)
Network Redesign: Evaluate the network architecture and consider redesigning segments with
non-standard MTUs
(I will consider redesigning the network segment with non-standard MTUs)
Question 5
Question . You are a network architect tasked with designing a
network infrastructure for a global corporation with diverse
office locations and remote employees. The network is
expected to handle a wide range of traffic, including real-time
video conferencing, large file transfers, and critical business
applications.
Describe your approach to designing a network that minimizes
fragmentation and ensures optimal performance for all types of
traffic.
Question 5-Answer
To design a network infrastructure that minimizes fragmentation and ensures
optimal performance for diverse traffic types, I would:

• Implement network segmentation to isolate traffic types.


• Set standardized MTU sizes with adjustments for specific needs.
• Apply Quality of Service (QoS) for real-time traffic.
• Enable Path MTU Discovery (PMTUD) to dynamically determine the Path MTU
between source and destination
• Regularly monitor network performance to address fragmentation issues
proactively.

This approach ensures efficient, reliable network performance for various types of
traffic.

You might also like