What is the maximum window size in segments of a TCP connection?

Consider one TCP connection (Reno) that uses a 10 Mbps link. Assume that this link does not buffer data and that the receiver's receive buffer is much larger than the congestion window. Suppose that each TCP segment is 1500 bytes in size , and the two-way communication propagation delay between the sender and receiver should be 200 ms . Also, suppose a TCP connection is always in the overflow prevention phase (ignore slow start).

What is the maximum window size in the segments this TCP connection can reach?

So, we know the connection bandwidth and delay, I think we can be able to manipulate the following formula so that we can find the window size.

Bandwidth = Window Size / RTT

Throughput * RTT = Window Size

10 Mbps * 200 ms = Window Size

I am not sure if this is correct. It’s hard for me to find anything else related to finding the window size other than this formula.

+4
source share
3 answers

I think you are asking how data can be obtained from end to end on a wire. In this case, you are close. Throughput * RTT [units: B / S * S] is the length of the wire. Ignoring PMTUs, packet overhead, hardware encoding, etc., then * RTT / PacketSize bandwidth will give you an estimate. But hold on, I used RTT. My reception window is really about how much it can fit on a wire in one direction, so divide it in half.

If your implementation does not support window scaling, then min, that with 2 ^ 16. If this happens, you start it with 2 ^ 30.

+1
source

The maximum window size per segment can be up to 2 ^ 30 / MSS, where MSS is the maximum segment size. 2 ^ 30 = (2 ^ 16 * 2 ^ 14) happens through this, as Michael said in his answer. If your network bandwidth and product delays are greater than the TCP receiver window size than the window scaling option is enabled for TCP connections, and most operating systems support these features. Scaling supports up to 14-bit multiplicative shift for window size. You can read the following for a better explanation:

http://en.wikipedia.org/wiki/TCP_window_scale_option

http://www.ietf.org/rfc/rfc1323.txt

+1
source

Packets will be deleted if the maximum transfer rate exceeds the bandwidth

(maximum window size * size of 1 segment) / RTT = channel capacity
( maximum window size * 1500 * 8) / 200 * 10 ^ -3 = 10 * 10 ^ -6
You can solve this for maximum window size .

We divide by RTT, because after this time an ACK will be received so that the sender can send more segments without the need to increase the window size.

0
source

Source: https://habr.com/ru/post/1342470/


All Articles