The Gateway to Computer Science Excellence

+42 votes

Assume that the bandwidth for a $TCP$ connection is $1048560$ bits/sec. Let $\alpha$ be the value of RTT in milliseconds (rounded off to the nearest integer) after which the $TCP$ window scale option is needed. Let $\beta$ be the maximum possible window size with window scale option. Then the values of $\alpha$ and $\beta$ are

- $63$ milliseconds, $65535$ $\times $2$^{14}$
- $63$ milliseconds, $65535$ $\times $2$^{16}$
- $500$ milliseconds, $65535$ $\times $2$^{14}$
- $500$ milliseconds, $65535$ $\times $2$^{16}$

+2

sir round trip time is time of data from sender to receiver+ and time of ack from sender to receiver, since nothing is said about propagation time, u took transfer time only while counting turn around time but sir why have u not multiply it by 2. and for the second part the window size if generally 16 bits but it can be increased by 14 bits making it 30 bits. So sir answer should be 2^30 which is 65536*2^14, why 65536 *2^14

+12

Following Link can be useful for understanding the concept of window scaling quite well.

http://packetlife.net/blog/2010/aug/4/tcp-windows-and-window-scaling/

+71 votes

Best answer

In TCP when the **bandwidth delay product** increases beyond $64$K receiver window scaling is needed.

The bandwidth delay product is the maximum amount of data on the network circuit at any time and is measured as RTT * Bandwidth. This is not the time for sending data rather just the time for sending data without acknowledgement.

So, here, we have bandwidth delay product = ($1048560$ / $8$) B * α = $64$ K

α = ($64$ K * $8$ ) / $1048560$ = $0.5$ s = $500$ milliseconds.

When window scaling happens, a $14$ bit shift count is used in $TCP$ header. So, the maximum possible window size gets increased from $2$^{16}-$1$ to ($2$^{16}-$1$) * $2$^{14} or from $65535$ to $65535$ * $2$^{14}

+6

When window scaling happens, a 14 bit shift count is used in TCP header.

sir why 14 bit only ?? any reason or just an assumption ??

sir why 14 bit only ?? any reason or just an assumption ??

+1

arjun sir in RFC its mentioned that max window size after scaling is 2^30 - 1 that is aroung 1GB. Why you took it as (2^16-1)*2^14. It evaluates to 2^30-2^14 which is much less than 1G??

+1

@Arjun

Sir, Bandwidth is given in Bits/Second and alpha is in milliseconds. So while multiplying why they are not converted to a common unit ?

Sir, Bandwidth is given in Bits/Second and alpha is in milliseconds. So while multiplying why they are not converted to a common unit ?

+3

One practical significance why window scale factor is limited to value of 14 because, then final window size would be

$2^{16}.2^{14}=2^{30}\,Bytes$ and maximum sequence numbers we can have is $2^{32}$.

$2^{16}.2^{14}=2^{30}\,Bytes$ and maximum sequence numbers we can have is $2^{32}$.

+5

The reason why maximum value is 14 is because (2^16)*(2^14) = 1,073,741,824. If it increases beyond this then it will surpass the Sequence no#. Sequence no# is 4 bytes (2^32) and the size of the window can't go beyond the maximum value of the sequence no#.

+18 votes

answer is C.

because TCP window scale option is needed when size increases more than 65535 B. it means alpha (RTT) should be the time taken to send 65535 B to the receiver.

Time to send 65535 B = 65535 * 8/1048560 *1000 = 500 ms.

**so alpha will be 500. **

maximum window size with window scale option is possible in TCP is 1073725440 B which is **65535*2^14** .

0

**PLEASE CHECK CALCULATION ONCE:**

because TCP window scale option is needed when size increases more than 65535 B. it means alpha (RTT) should be the time taken to send 65535 B to the receiver.

**Time to send 65535 B = 65535 * 8/1048560 *1000 = 500 ms. **

IT SHOULD BE: // **Time to send 65535 B = 65535 * 8*1000/1048560 = 500 ms. **

**so alpha will be 500.**

maximum window size with window scale option is possible in TCP is 1073725440 B which is **65535*2^14** .

+6 votes

Lets talk about concept first..

Basically We are not utilizing the given bandwidth at its fullest. Sticking to the question, it causes due to the delay caused in sending the data.

(You can consider the example of satellite link , It causes much delay for acknowledgement to arrived after sending data equal to current window size)

One of the solution is we can consider upgrading window size that will pack the data , utilizing maximum of the given bandwidth.

The units we consider for data is in Bytes and delay in "ms"

Lets have a look at our Question.

Given,

B = (1048560/8) B/s

RTT ( alpha ) = X ms ( say)

Current ( default) window size, RWIN = 65535 B

( RWIN = Reciver window )

Using Bandwidth * Delay product ,

B * X = 65535 ,

X = 500 ms.

To use the given Bandwidth to ita fullest , we can scale our window upto 1GB ( fixed standard)

i.e with scaling factor of 2^14 B

(i.e Shifting 14 bits to left )

So, scaled window size becomes,

65535 * 2^ 14.

(2^16 * 2^ 14 = 2^30 , i.e 1GB )

https://www.speedguide.net/faq/what-is-the-bandwidth-delay-product-185

https://networklessons.com/cisco/ccnp-route/bandwidth-delay-product/

+5 votes

The **TCP window scale option** is an option to increase the receiver window size allowed in Transmission Control Protocol above its former maximum value of 65,535 bytes.

65,535 bytes = 64KB = $2^{16}$ B

`The scaling option allows us to increase the window size from 64KB to 1 GB!`

- When is scaling used?

When the bandwidth-delay product exceeds the value of 64K or $2^{16}$, we use scaling.

Bandwidth **must **be in bytes/sec and delay (RTT) **must **be in ms.

- What happens when we scale?

Window size increases from 64KB to 1GB, ie, from $2^{16}$B to $2^{30}$B

Now, coming to the question:

Calculating α

131070 * RTT = $2^{16}$

=> 131070 * RTT = 65536

=> RTT = 500 ms

Calculating β

Window size would be increased from $2^{16}$B to $2^{30}$B

i.e. from 65536 to 65536 * $2^{14}$B

**Option C**

- All categories
- General Aptitude 1.9k
- Engineering Mathematics 7.6k
- Digital Logic 2.9k
- Programming and DS 4.9k
- Algorithms 4.4k
- Theory of Computation 6.2k
- Compiler Design 2.1k
- Databases 4.1k
- CO and Architecture 3.4k
- Computer Networks 4.2k
- Non GATE 1.4k
- Others 1.5k
- Admissions 595
- Exam Queries 573
- Tier 1 Placement Questions 23
- Job Queries 72
- Projects 18

50,834 questions

57,853 answers

199,514 comments

108,380 users