2024 03 11 0.6122554500679145
2024 03 11 0.6122554500679145
2024 03 11 0.6122554500679145
Suppose a router receives an IP packet containing 600 data bytes and has to forward
the packet to a network with a maximum transmission unit of 200 bytes. Assume that the
IP header is 20 bytes long. What are fragment offset values for divided packets?
Answer:(C)
Explanation:
Given, MTU size of the destination network = 200 bytes, IP header length = 20
Maximum amount of data that can be sent in one fragment = 200 – 20 = 180 bytes.
The amount of data sent in a fragment must be a multiple of 8.
So, the maximum data sent that can be in one fragment = 176 bytes.
Thus, 4 fragments are created-
1st fragment contains 176 bytes of data.
2nd fragment contains 176 bytes of data.
3rd fragment contains 176 bytes of data.
4th fragment contains 72 bytes of data
Fragment offset value for 1st fragment = 0
Fragment offset value for 2nd fragment = 176 / 8 = 22
Fragment offset value for 3rd fragment = (176+176) / 8 = 44
Fragment offset value for 4th fragment = (176 + 176 + 176) / 8 = 66
Thus, Option (C) is correct.
Answer:(A)
Explanation:
Fragmentation is done at intermediate routers(if any) and reassembly only at the destination
host.
3. Host X sends a message to host Y, which has two intermediate networks in between
them. A TCP message consisting of 2100 bytes is passed to IP for delivery across two
hosts. The first network has an MTU of 1200 bytes, and the second network has an MTU
of 400 bytes, excluding network overhead. Assume that the IP overhead per packet is 20
bytes. What is the fragmentation offset for the Last fragment that reaches the
destination?
Answer:(A)
Explanation:
File size = 2100; when it goes to the network layer, 20 bytes are added, becoming 2120B.
This is for understanding as we can solve it without considering IP overhead because
fragmentation is done on data, not headers.
At sender S: 2100 B to intermediate router P(1200 bytes without header) to intermediate router
Q(400 B w/o header) to destination D.
S to P: fragment 1: 1200 B fragment 2: 900 B to P
P to Q: for 1200 B fragment
F1 : 400(data length in bytes) offset : 0
F2: 400 offset: 400/8=50
F3: 400 offset: 100
for 900 B fragment
F4: 400 offset: 150
F5: 400 offset: 200
F6: 100 offset: 250 last fragment
In other way, 250 x 8 = 2000 bytes ahead of this last fragment (from 0 to 1999), and the
sequence number of the last fragment is 2000.
So 250 is the last fragment offset.
3. Consider the following statements about the functionality of an IP-based router. Which
is/are True? [MSQ]
C) A router should reassemble IP fragments if the MTU of the outgoing link is larger than the
size of the incoming IP packet.
Answer:(B,D)
Explanation:
A. False. A router modifies the IP packets during forwarding because TTL (Time to Live)
changes.
B. True. A router does not need to implement any routing protocol. It can just forward packets in
all directions without doing any routing.
C. False. The router does not assemble the packets. Assembling is done only in the destination
system.
D.True. Fragmentation is done at intermediate routers.
4. An IP router with a Maximum Transmission Unit (MTU) of 1500 bytes has received an
IP packet of size 4404 bytes with an IP header of length 20 bytes. The values of the
relevant fields in the header of the third IP fragment generated by the router for this
packet are
Answer:(A)
Explanation:
Number of packet fragments = ⌈ (total size of packet)/(MTU) ⌉
So, the Datagram with data 4404 bytes fragmented into 3 fragments.
5. The intermediate routers between the source and destination need the following
information in the IP header_____?[MSQ]
A) Version B) Protocol
Answer:(A,B,C,D)
Explanation:
The version field indicates the version of IP used. This information is required to process the
packet appropriately based on its version.
The protocol field indicates the next level of protocol. The router requires this information to
accept or discard the packet if its buffer is full. Based on the priority, the router takes its
decision.
The identification number field identifies the fragments of the same datagram. This information
is required while reassembling the datagram fragments.
The source IP Address field indicates the IP Address of the source. The router requires this
information to send an ICMP packet to the source. ICMP packet informs the source that its
packet has been discarded.
A) 13
B) 14
C) 15
D) 16
Answer:(A)
Explanation:
Answer:(C)
Explanation:
Fragment offset, Flags (like MF), and Identification (Identifier) are related to fragmentation.
A) 10 B) 11 C) 12 D) 13
Answer:(A)
Explanation:
TTL stands for Time to Live. This field specifies the life of the IP packet based on the number of
hops it makes (Number of routers it goes through). TTL field is decremented by one each time
the datagram is processed by a router. When the value is 0, the packet is automatically
destroyed.
A) 0 B) 1 C) -1 D) 2
Answer:(A)
Explanation:
The Flag field in the IP header is used to control and identify the fragments. It contains three
bits: reserved, don’t fragment and more fragments. If the bit of more fragments is 0, the
fragment is the last.
Answer:(A)
Explanation:
The Fragment Offset field specifies where the fragment fits in the original datagram. The offset
of the first fragment will always be 0. The size of the field (13 bits) is 3 bits shorter than the size
of the total length field (16 bits).
11. Consider two hosts, P and Q, connected through a router R. The maximum transfer
unit (MTU) value of the link between P and R is 1500 bytes, and between R and Q is 820
bytes. A TCP segment of size 1400 bytes was transferred from P to Q through R, with an
IP identification value of 0×1234. Assume that the IP header size is 20 bytes. Further, the
packet can be fragmented, i.e., the Don’t Fragment (DF) flag in the IP header is not set by
P. Which of the following statements is/are correct? [MSQ]
A) TCP destination port can be determined by analysing only the second fragment.
B) If the second fragment is lost, P must resend the whole TCP segment.
C) Two fragments are created at R, and the IP datagram size of the second fragment is 620
bytes.
D) If the second fragment is lost, R will resend the fragment with the IP identification value
0×1234.
Answer:(B,C)
Explanation:
A- FLASE: The TCP destination port can be determined by analyzing only the second fragment.
This option is incorrect, as the Destination Port Number can be identified by looking at any
packet or Fragment. Not just only from the Second Fragment.
B-TRUE: If the second fragment is lost, P must resend the whole TCP segment. This is correct.
If any of the Fragments is lost, then the entire packet/TCP segment has to be retransmitted; this
is one of the drawbacks of fragmentation.
C- TRUE: Two fragments are created at R, and the IP datagram size of the second fragment is
620 bytes.
D - FALSE: If the second fragment is lost, R will resend the fragment with the IP identification
value 0 × 1234. This option is false. If any of the Fragments is lost, then the entire packet/TCP
segment has to be retransmitted.
12. Fragmentation and Reassembly happen at ____ layer?
Answer:(A)
Explanation:
13. In an IPv4 datagram, the M bit is 0, the value of HLEN is 10, the total length is 400, and
the fragment offset value is 300. The position of the datagram and the sequence numbers
of the first and the last bytes of the payload, respectively, are_____?
Answer:(C)
Explanation:
A) By using the identification number, we can determine which fragment belongs to which
packet
B) By using the offset, we can determine the sequence of the fragments of that particular packet
C) By using the identification number, we can determine the sequence of the fragments of that
particular packet
D) By using the offset, we can determine which fragment belongs to which packet
Answer:(A,B)
Explanation:
A - TRUE, by using the identification number, we can determine which fragment belongs to
which packet
B- TRUE: by using the offset, we can determine the sequence of the fragments of that particular
packet.
15. If a datagram of size 4000 bytes from the transport layer arrives at the network layer,
it has to be forwarded through a link with a maximum capacity of 800 bytes. Then,
calculate the number of fragments needed if the header size is 20 bytes. Also, calculate
the data size of the last fragment.
Answer:(B)
Explanation: