IBM Tivoli Storage Manager, Version 7.1

TCP flow control and the sliding window

Transmission Control Protocol (TCP) uses a sliding window for flow control. Before you tune any TCP/IP settings, first understand how the TCP sliding window works.

The TCP sliding window determines the number of unacknowledged bytes, x, that one system can send to another. Two factors determine the value of x:

The sending system cannot send more bytes than space that is available in the receive buffer on the receiving system. TCP on the sending system must wait to send more data until all bytes in the current send buffer are acknowledged by TCP on the receiving system.

On the receiving system, TCP stores received data in a receive buffer. TCP acknowledges receipt of the data, and advertises (communicates) a new receive window to the sending system. The receive window represents the number of bytes that are available in the receive buffer. If the receive buffer is full, the receiving system advertises a receive window size of zero, and the sending system must wait to send more data. After the receiving application retrieves data from the receive buffer, the receiving system can then advertise a receive window size that is equal to the amount of data that was read. Then, TCP on the sending system can resume sending data.

The available space in the receive buffer depends on how quickly data is read from the buffer by the receiving application. TCP keeps the data in its receive buffer until the receiving application reads it from that buffer. After the receiving application reads the data, that space in the buffer is available for new data. The amount of free space in the buffer is advertised to the sending system, as described in the previous paragraph.

Ensure that you understand the TCP window size when you use sliding window for flow control. The window size is the amount of data that can be managed. You might need to adjust the window size if the receive buffer receives more data than it can communicate. For more information about optimizing the TCP window size, see Optimization of window size for different operations on the same system.

How the send and receive buffers interact has the following consequences:

Typically, you set the send window and the receive window sizes separately for an operating system. In AIX®, for example, the tcp_sendspace and tcp_recvspace parameters of the no command can be used to set the send and receive window sizes.

The sliding window that is used by Tivoli Storage Manager operations is controlled with the TCPWINDOWSIZE option.



Feedback