We all know that TCP is a reliable, connection-oriented transport layer protocol. We always hope that TCP can transmit data as quickly as possible. If there is such a situation that the sender sends data very quickly and the receiver has exhausted its resources and has no time to receive it, then the excess data will be discarded, which violates the principle of TCP reliability.
Therefore, it is necessary to introduce a method of flow control: to prevent the sender from sending too fast, so that the receiver can receive the data smoothly without causing congestion of the network link. Ideas Following this idea: let the sender not send too fast. Then let the receiver control the sender's data size, and notify the sender how much space is left to receive data each time it responds. Of course, the actual interaction is not that simple, it just provides a way of thinking. Using this idea, the sliding window method was born. Sliding Window The sliding window is like a window that tells the sender the size of the data that can be sent. It can also be said that the window marks the size of the receiver's buffer. The window size also indicates how much data can be sent at a time, and this window can slide, hence the name sliding window. How to tell the sender the window size? How to inform the sender of the window size? Do we need to resend a packet of data to tell the other party? This is obviously unreasonable. We can use the confirmation response packet cleverly. Having a confirmation response packet is not enough. What if it is the first interaction? Therefore, we need to inform the other party during the three-way handshake. (rwnd means receiving window) In the original confirmation response strategy, each time data is sent, an Ack response is required. The next data segment will be sent only after receiving the Ack. What if the sender does not receive the Ack response? This method is too inefficient. With the use of a sliding window, data can be sent multiple times as long as it does not exceed the other party's window size. This greatly improves efficiency. Sliding Window Details
Examples A sends data to B. When the connection is established, B tells A: "My receiving window rwnd = 400 (bytes). Note: The capital ACK above the arrow in the figure represents the confirmation bit ACK in the header, and the lowercase ack represents the value of the confirmation field. The above process is as follows:
|
<<: Summarize various issues between wireless AP and AC of WiFi system
As the network security situation becomes increas...
Operations and Continuous Delivery In the era of ...
All smart home appliances rely on connectivity to...
RAKsmart also offers substantial discounts on var...
[[431529]] Recently, the three major operators ha...
It is understood that IPv6 was first introduced i...
When it comes to TCP connection establishment and...
Recently, H3C, a leading manufacturer in the IP n...
As financial institutions gradually evolve toward...
Do you often hear descriptions like “5G Internet ...
[[427531]] DALLAS – AT&T* will partner with F...
Huawei recently released its Global Industry Visi...
As digital transformation is in full swing, the n...
The process of financial digitalization is accele...