retagged by
21,208 views
32 votes
32 votes
Consider a long-lived $\text{TCP}$ session with an end-to-end bandwidth of $1\; \text{Gbps}\; (=10^9$ bits-per-second$).$ The session starts with a sequence number of $1234$. The minimum time (in seconds, rounded to the closet integer) before this sequence number can be used again is _________.
retagged by

6 Answers

Best answer
46 votes
46 votes

The question is asking to find the Wrap-around time

$T_{\text{minimum}}=T_{\text{wrap-around}} = \frac{2^{32}\ast 8}{10^9}=34.35\;\text{s}$

rounding to closest integer, we will get 34

Note: Answer has been Modified in the Final Answer Key from GATE officials and now it is in Range from $34$ to $35.$ 

edited by
57 votes
57 votes

Since TCP is a byte stream protocol, every byte is numbered using a sequence number.

Every packet can loop around the internet for some period of time, which is the life time of the packet. Therefore, to ensure that there are no conflicting sequence numbers, we have to find out the Wrap Around Time of the sequence numbers after which the number is used again. 

Now this Wrap Around Time $T_{WAT}$ should be greater than LifeTime of the packet $T_{LT}$, i.e $T_{WAT} > T_{LT}$

We have $32$ bits for sequence number field in the TCP header.

Given Bandwidth = $10^9$ bps(bits per second)

$\therefore 10^9$ bits  can be sent out in  $1$ second

$\therefore 2^{32} * 8 $ bits  can be sent out in  $x$ seconds ($\because$ TCP is byte streamed)

$\therefore x = \frac{2^{32} * 8}{10^9} = 34.359 $ seconds

Since they have asked the closest integer, answer is $34$

P.S Initially I was convinced that answer should be $34$, however, if we consider the statement "The minimum time (in seconds, rounded to the closet integer) before this sequence number can be used again", then I might incline towards $35$, although official key says $34$.

5 votes
5 votes
`remember tcp is byte(not bit) stream protocol

sequence number field of tcp header is 32bit, so only (2^32=4G) sequence number available so wrap time is after how much time we use same sequence number

bandwidth = 1Gbps = 10^9 / 8 Byte per second

10^9/8 sequence no. consume - 1 sec ( since bandwidth=10^9/8)

1 seq no. consume - 8 / 10^9 sec

2^32 seq no. consume - 2 ^ 32 * (8 / 10^9)  sec = 34.35  sec (approx 34 sec)
edited by
Answer:

Related questions

23 votes
23 votes
5 answers
2
gatecse asked Feb 14, 2018
10,245 views
Match the following:$$\begin{array}{|l|l|}\hline \textbf{Field} & \textbf{Length in bits} \\\hline \text{P. UDP Header's Port Number} & \text{I. 48} \\ \text{Q. Ethern...
41 votes
41 votes
9 answers
4