• edited by
37,328 views
70 70 votes

A TCP message consisting of $2100$  $bytes$ is passed to IP for delivery across two networks. The first network can carry a maximum payload of $1200$ $bytes$ per frame and the second network can carry a maximum payload of $400$ $bytes$ per frame, excluding network overhead. Assume that IP overhead per packet is $20$ $bytes$. What is the total IP overhead in the second network for this transmission?

  1. $\text{40 bytes}$
  2. $\text{80 bytes}$
  3. $\text{120 bytes}$
  4. $\text{160 bytes}$

8 Answers

Best answer
94 94 votes

At source : TCP passes $2100B$ to IP layer. IP appends $20$B header and sends it to DLL and so on. ( We are interested in IP overhead, So lets consider DLL header to be negligible)

A router on the way has highest layer as Network Layer, So, complete TCP segment is fragmented. And in question $1200$ and $400$ are given as maximum payload without network overhead, means we are directly given the amount of data part of IP datagram a Frame can hold. [1200 doesn't contain IP header]

Router-1: $2120$B reach $R_1's$ network layer. It removes original IP header, fragments data part at IP and then appends IP header to all fragments and forwards. So, it divides $2100$ Bytes into two fragments of  size $1200$ and $900$.And  Both fragments are sent to $R_2$.

Router-2: Both fragments that reach $R_2$ exceed MTU at $R_2$. So, both are fragmented. First packet of $1200$B is fragmented into $3$ packets of $400$, $400$ and  $400$ Bytes respectively and Second packet of $900$B is fragmented into three fragments of $400$, $400$ and $100$ Bytes respectively.

Original data during fragmentation should not change. Only additional IP headers are added. So totally $6\;packets$ reach destination. And IP header is also an overhead because our main aim is to send data only.

Total IP Overhead $ = 6*20 = 120$B 

Hence, (C) is correct answer.



http://quiz.geeksforgeeks.org/gate-gate-it-2004-question-87/

• edited by
42 42 votes

Maximum Payload of  1200 B per frame is given ,i.e , as the above picture says Payload = MSS, hence, it is different from packet size.

Answer is C). 

Question says TCP message is of size = 2100 B, hence header is encapsulated with the frame and send to IP layer, and IP layer when receives this message thinks it as complete data to be send .

To be send across the first network, It is fragmented into 2 payloads of sizes 1200 and 900 .

No need to add IP Header size with 2100B, as fragmentation acts on data/Payload and not the packet.

Now, since, IP thinks 2100B as the data so, it will directly fragment it and hence, no need to add any header.

Payload / Fragment 1: 1200 B  {1200 / 8 = 150, Except last fragment all the fragments should be divisible by 8}

Payload 2: 900 B

At the second network, 1200 B is fragmented into 400 B,400 B and 400 B .

Similarly, 900 B is fragmented into 400, 400 and 100 B.

Since, 2100 B is fragmented into 6 data payloads and Header is attached to all the payloads when they will be forwared to DLL layer. So, Total Overhead = 6 * 20 = 120 B


Hence, DLL layer will receive total Data = 2100 + 120 = 2220 B and DLL will treat it as a complete data to be sent and DLL header will be encapsulated in DLL frame.

• edited by
37 37 votes

It is written in the question maximum payload 1200 bytes/ frame and 400/bytes per frame excluding n/w overhead it means i/p header added by n/w layer is not considered. answer will be (C).

$Remark:$ MTU are 1220 bytes and 420 Bytes for the networks A and B respectively. 

3 3 votes
As per question Ip overhead is 20 bytes. so for 1st network the 2100 bytes will be divided into <packet size,Ip overhead> =<1180,20> and <920,20> as capacity for 1st network 1200 bytes .. and for 2nd network it will be <380,20>,<380,20>,<380,20>,<380,20>,<380,20>,<280,20> as the MSS for 2nd network is  20 Bytes ... so total overhead for 2nd network is 20*6= 120 bytes ..

so option c... correct me if i am wrong ...
• edited by
2 2 votes

Easy Approach:-

TCP msg = $2100$ B → When passed to IP gets an IP Header of $20$ B → $2120$ B

The Routers delete the original IP header so fragmentation is done only on $2100$ B. 

We know the bottleneck MTU is 400B. So anyhow the fragments will be divided so that it can pass through the bottleneck MTU. Now $400B$ MTU → $380B$ data and $20B$ IP Header. Again $380$ is not divisible by $8$, so the required number is $376B$ of data. Hence the number of packets will be $\lceil \frac{2100}{376}\rceil$ = 6 packets.

Therefore total overhead = $6*20$ = $120B$.

0 0 votes

It does not bother how data reaches Router B

 

A-------------------------------------------B-------------------------------------------C

2100                                             2120

 

                                                    20 Bytes removed as IP header

So data becomes 2100 B

Now as C has MTU of 400 so number of Packets = 2100/380 = 5.5

Take ceil

So answer is 6

What is the total IP overhead in the second network for this transmission?

6 packets

Per packet overhead = 20B

For 6 packets

120B

 

Try to visualise things

So answer becomes easier,

Many answers say 2110 is divided into 1200 and 900

But it hardly matters. We still have to send those 3 packets of 400B each at C so be it divided or 2100 as a data whole together.

But C will need  6 packets in the best, worst case.

Answer:
Position:
Show:

Related questions

62 62 votes
4 answers 4 answers
21.1k
21.1k views
Ishrat Jahan asked Nov 2, 2014
21,136 views
In a data link protocol, the frame delimiter flag is given by $0111$. Assuming that bit stuffing is employed, the transmitter sends the data sequence $01110110$ as:$01101...
87 87 votes
15 answers 15 answers
42.4k
42.4k views
Ishrat Jahan asked Nov 2, 2014
42,374 views
Suppose that the maximum transmit window size for a TCP connection is $12000$ $\text{bytes}$. Each packet consists of $2000$ $\text{bytes}$. At some point in time, the co...
95 95 votes
9 answers 9 answers
30.9k
30.9k views
Ishrat Jahan asked Nov 2, 2014
30,902 views
Consider a simplified time slotted MAC protocol, where each host always has data to send and transmits with probability $p$ = $0.2$ in every slot. There is no backoff and...
49 49 votes
8 answers 8 answers
30.0k
30.0k views
Ishrat Jahan asked Nov 2, 2014
29,998 views
Consider a parity check code with three data bits and four parity check bits. Three of the Code Words are $0101011, 1001101$ and $1110001.$ Which of the following are als...