Computer Networking Basics
In TCP flow control, what is the purpose of the receiver advertising its window size (receive window) to the sender?
- ATo detect network congestion and make routers along the path slow down forwarding
- BTo set the maximum length of data sent in one segment so that IP fragmentation is avoided
- CTo tell the sender how much data it may send without waiting for acknowledgments (ACKs), so the receiver's buffer does not overflow
Show answer and explanation
Answer: C. To tell the sender how much data it may send without waiting for acknowledgments (ACKs), so the receiver's buffer does not overflow
A TCP sender can send several segments in a row without waiting for acknowledgments (ACKs). But if the receiving application reads data slowly, the receive buffer can overflow. So with every ACK the receiver reports the free buffer space as the window size, and the sender keeps the unacknowledged data from exceeding that amount. When the free space reaches 0, the sender waits until it opens up. This is flow control, an adjustment between the two parties, sender and receiver. Adjusting the amount sent to network congestion is a separate mechanism, congestion control, and the maximum length of one segment is announced as the MSS at connection setup.
- A. Dealing with congestion is congestion control, in which the sender adjusts its own sending; routers are not told to slow down.
- B. That describes the MSS (maximum segment size).
- C. Correct. It limits the sender to the free space in the receive buffer.