Congestion control method and system based on delay and packet loss
By real-time detection and adjustment of network parameters, dynamically optimizing the size of the congestion window, the problems of low bandwidth utilization and increased round trip delay caused by blind adjustment in the existing technology are solved, and higher bandwidth utilization and lower latency are achieved, improving the Video quality and user experience.
Patent Information
- Application Number
- CN202211255437.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-10-13
- Publication Date
- 2024-12-10
- Estimated Expiration
- 2042-10-13
AI Technical Summary
The existing congestion control method based on latency and packet loss has the problem of blindly adjusting the window size in complex network environments, resulting in low bandwidth utilization and increased round trip delay, affecting video quality and user experience.
By detecting round-trip delay and bandwidth in real time, setting and adjusting the congestion window value in different time periods, combining packet loss situations, dynamically determine whether to increase or decrease the window size, avoid blind adjustments, and optimize network resource utilization.
It significantly improves bandwidth utilization, maintains low round-trip delay, improves video quality and user experience, and is suitable for environments with high random packet loss.
Smart Images

Figure CN115714746B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of communication technology, and in particular to a congestion control method based on delay and packet loss and a system thereof. Background Art
[0002] Internet-based communication technology is widely used in various work and life scenarios. However, in today's complex network environment, congestion problems often occur during network communication. The congestion control method in the existing Transmission Control Protocol (TCP) generally goes through two stages: a slow start stage with an increasing congestion window and a congestion avoidance stage with a decreasing congestion window.
[0003] Among them, setting the congestion window is a measure for satellite communications to prevent communication congestion in the Internet. It is a mechanism that combines a "congestion avoidance" algorithm and a "slow start" algorithm at the sending end. The "congestion window" is the window of "congestion avoidance". It is a sliding window installed at the sending end. The size of the congestion window is not larger than the window of the confirmation notification from the receiving end. "Slow start" is to control the congestion window to increase by one segment value every time a confirmation is received from the receiving end after the connection is established. When the congestion window value reaches the limit of "slow start", the slow start stops working and enters the congestion avoidance stage to reduce the congestion window and avoid network congestion.
[0004] The size of the congestion window depends on the degree of network congestion and changes dynamically.
[0005] The principle of the sender controlling the congestion window is: as long as there is no congestion in the network, the congestion window will be increased to send more packets. However, as long as there is congestion in the network, the congestion window will be reduced to reduce the number of packets injected into the network.
[0006] The existing congestion control methods in TCP mainly include delay-based congestion control methods and packet loss-based congestion control methods.
[0007] Delay-based congestion control methods such as the Vegas algorithm first go through a slow start phase, and then in the congestion avoidance phase, they will determine whether there is a queue in the router based on the real-time measured RTT value (Round-Trip Time, which refers to the time required for data to be transmitted from one end of the network to the other end). If the number of queued packets exceeds 4, the window will be reduced, and if not, the window will be increased. This can effectively reduce the number of queued packets in the router.
[0008] The Vegas algorithm was proposed in 1994. It is the first delay-based congestion control method after the release of the TCP protocol and has been tested by the TCP protocol development team. The Vegas algorithm first estimates the amount of data that the network can transmit in a certain period of time, and then compares it with the actual transmission capacity. If the data that should have been transmitted is not transmitted, it may be hung up by a router on the link. If this situation continues to occur, the sender will reduce the sending rate. This is in contrast to the method of using packet loss in standard TCP to determine whether congestion has occurred.
[0009] In certain situations, the Vegas algorithm will blindly believe that the forward delay is higher than it actually is. This happens when congestion occurs in the opposite direction. In this case, although the sender is not the one causing the congestion, the packets returning to the sender are delayed. This results in reducing the congestion window size when it is not really necessary to adjust the congestion window. This is a potential flaw shared by most methods that make congestion control decisions based on measuring RTT. Vegas is not equal when sharing a link with a standard TCP flow. The standard TCP sender wants to fill up the waiting queues in the network, while Vegas wants to keep them idle. Therefore, when the standard TCP sender sends packets, the Vegas sender will find that the delay is increasing, so it will reduce its sending rate. Ultimately, this leads to a situation that only benefits standard TCP.
[0010] In short, the delay-based algorithm seems perfect, which can fully utilize the bandwidth and maintain a relatively low RTT. However, the network is complex. When sharing a link with other algorithms such as those based on packet loss, due to its sensitivity to delay, the delay that is not increased by itself will also reduce the window and lead to weaker competitiveness.
[0011] Congestion control methods based on packet loss, such as the Cubic and Reno algorithms, also go through a slow start phase and a congestion avoidance phase. However, unlike delay-based algorithms, the window of packet loss-based algorithms keeps growing until the router queue is full and packet loss occurs. The congestion window is then reduced. The process of window growth and packet loss is then repeated.
[0012] The congestion control method based on packet loss is passive, and it makes network congestion judgments based on packet loss events in the network. Even if the load in the network is very high, as long as there is no congestion and packet loss, the protocol will not actively reduce its sending speed. The protocol based on packet loss feedback continues to occupy the router cache without packet loss. Although it improves the utilization of network bandwidth, it also means that after congestion and packet loss occur, the network jitter increases.
[0013] For example, the Cubic algorithm uses a cubic function as the growth function of the congestion window. The growth of its congestion window is no longer related to RTT, but only depends on the maximum window when congestion occurred last time and the time interval from the last time congestion occurred. The advantage of the Cubic algorithm is that as long as there is no packet loss, it will not actively reduce its own sending speed, and can maximize the use of the remaining network bandwidth, improve throughput, and can play a better performance in a network with high bandwidth and low packet loss rate.
[0014] However, the cubic algorithm cannot distinguish between congestion packet loss and transmission error packet loss. As long as packet loss is detected, the congestion window will be reduced and the sending rate will be lowered. In fact, when transmission error packet loss occurs, the network may not necessarily be congested, but the probability of transmission error packet loss is very low, so the performance of the cubic algorithm is not greatly affected.
[0015] In addition, when there is no packet loss, the cubic algorithm will continuously increase the size of the congestion window, inject traffic into the network, fill the buffer of the network device, and cause buffer expansion. Since the buffer tends to be saturated for a long time, new data packets entering the network will queue in the buffer, increasing unnecessary queuing delay. The larger the buffer, the higher the delay. In addition, the cubic algorithm still increases the congestion window while achieving high bandwidth utilization, which indirectly increases the packet loss rate and causes network jitter to increase.
[0016] In short, the packet loss-based congestion control method is difficult to fully utilize bandwidth resources in scenarios with more random packet loss such as mobile networks, because the algorithm is sensitive to packet loss and the window will be lowered when packet loss occurs. In scenarios without packet loss, the window will continue to increase, resulting in serious router queuing, which will result in a larger RTT. Summary of the invention
[0017] The present invention provides a congestion control method based on delay and packet loss and a system thereof, which is based on the congestion control method based on packet loss, and determines whether the window added during this period needs to be rolled back according to the change of RTT and the change of the estimated bandwidth value, giving full play to the advantages of the two methods, and can significantly improve the bandwidth utilization rate in an environment with high random packet loss, while maintaining a low RTT, providing users with videos with higher picture quality and lower delay, and improving user experience.
[0018] In a first aspect, the present invention provides a congestion control method based on delay and packet loss, characterized in that the method comprises:
[0019] Detecting a first round-trip delay and a first bandwidth in real time during a first time period;
[0020] detecting a second round trip delay and a second bandwidth in real time in a second time period;
[0021] Setting a first window value, where the first window value is a congestion window value at an initial moment of the first time period;
[0022] When the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth do not simultaneously meet a predetermined condition, increasing the congestion window value;
[0023] When the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth simultaneously meet a predetermined condition, the congestion window value is reduced.
[0024] In a second aspect, the present invention further provides a congestion control system based on delay and packet loss, characterized in that the system comprises:
[0025] A detection device, which is used to detect a first round-trip delay and a first bandwidth in real time in a first time period, and to detect a second round-trip delay and a second bandwidth in real time in a second time period;
[0026] A setting device, which is used to set a first window value, wherein the first window value is a congestion window value at an initial moment of the first time period;
[0027] a judging device, configured to judge whether the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth simultaneously satisfy a predetermined condition;
[0028] The congestion window value adjustment device is used for:
[0029] When the judging device judges that the first round-trip delay, the second round-trip delay, the first bandwidth and the second bandwidth do not simultaneously meet a predetermined condition, increasing the congestion window value;
[0030] When the determining device determines that the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth simultaneously meet a predetermined condition, the congestion window value is reduced.
[0031] The congestion control method and system based on delay and packet loss provided by the present invention are based on the congestion control method based on packet loss. It is not only based on the current packet loss situation, but also based on the change of RTT and the estimated bandwidth value change, as well as the current congestion window value, to effectively judge whether it is necessary to roll back the window increased during this period, giving full play to the advantages of the two methods. In an environment with relatively high random packet loss, it can significantly improve the bandwidth utilization rate, while maintaining a low RTT, providing users with higher quality and lower latency videos, and improving user experience. In addition, considering that there may be other traffic in the same link, the basic value of the round-trip delay is regularly detected, and the number of current data packets queued is calculated using the latest detected basic value of the round-trip delay, which can fully take into account the fluctuation of the round-trip delay caused by the background traffic. BRIEF DESCRIPTION OF THE DRAWINGS
[0032] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0033] Figure 1 is a flow chart of a congestion control method based on delay and packet loss provided by an embodiment of the present invention;
[0034] Figure 2 It is a flow chart of another congestion control method based on delay and packet loss provided by an embodiment of the present invention;
[0035] Figure 3 is a flow chart of another congestion control method based on delay and packet loss provided by an embodiment of the present invention;
[0036] Figure 4 It is a schematic diagram of a congestion control system based on delay and packet loss provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0037] The technical solution of the present invention is further described in detail below through the accompanying drawings and embodiments. SUMMARY OF THE INVENTION
[0039] As mentioned above, the present invention provides a congestion control method and system based on delay and packet loss, which can effectively determine whether the increased window needs to be rolled back, giving full play to the advantages of the two methods. In an environment with relatively high random packet loss, it can significantly improve bandwidth utilization while maintaining a low RTT, providing users with videos with higher picture quality and lower latency, thereby improving user experience.
[0040] Exemplary Methods
[0041] Figure 1 : is a flow chart of a congestion control method based on delay and packet loss provided by an embodiment of the present invention, and the embodiment includes the following steps:
[0042] S101: Detect a first round-trip delay and a first bandwidth in real time in a first time period.
[0043] Specifically, the round-trip delays of multiple data packets are detected in real time within a first time period, and the smallest round-trip delay is selected as the first round-trip delay. For example, the first time period is 50ms, and within 50ms, the sender sends 50 data packets and receives 50 acks from the receiver. According to the sending time of the 50 data packets and the receiving time of their corresponding 50 acks, 50 round-trip delays rtt are obtained, and the smallest rtt is selected as the first round-trip delay. Among them, ack (Acknowledge character) is a confirmation character. In data communication, it is a transmission control character sent by the receiving end to the sending end, indicating that the sent data has been confirmed to be received correctly. In the TCP / IP protocol, if the receiving end successfully receives the data, it will reply with an ack data. Usually the ack signal has its own fixed format and length, and is replied by the receiving end to the sending end.
[0044] The first bandwidth is the number of bytes ack_size confirmed in the first time period divided by the duration of the first time period. For example, if the duration of the first time period is 50 ms, and 1M bits are received in the 50 ms, then the first bandwidth is 20 Mbps.
[0045] S102: Detect a second round-trip delay and a second bandwidth in real time in a second time period.
[0046] Similarly, the second round trip delay is the minimum round trip delay among multiple round trip delays in the second time period. The second bandwidth is the amount of data confirmed by ACK in the second time period divided by the length of the second time period.
[0047] S103: Setting a first window value, where the first window value is a congestion window value at an initial moment of the first time period.
[0048] Among them, the congestion window is the congestion avoidance window. It is a sliding window installed at the sending end. The size of the congestion window is not larger than the window of the receiving end's confirmation notification. The size of the congestion window depends on the degree of congestion in the network and changes dynamically. As long as there is no congestion in the network, the congestion window will be increased to send more packets. However, as long as there is congestion in the network, the congestion window will be reduced to reduce the number of packets injected into the network.
[0049] The window value indicates the number of packets that can be sent within a round-trip delay or the number of packets that can be buffered.
[0050] S104: When the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth do not simultaneously meet a predetermined condition, increasing the congestion window value.
[0051] The predetermined conditions that the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth need to satisfy simultaneously are as follows:
[0052] First, the current number of data packets queued is greater than the second threshold, and the current number of data packets queued V is calculated specifically according to the following formula:
[0053] V = W1*rtt_min2 / rtt_base;
[0054] Wherein W1 is the first window value, rtt_min2 is the second round-trip delay, and rtt_base is the round-trip delay base value.
[0055] For example, assuming that W1 is 4, rtt_min2 is 100ms, and rtt_base is 50ms, the current number of data packets queued V is 8.
[0056] Second, the second round-trip delay is greater than the first round-trip delay.
[0057] Third, the second bandwidth is smaller than the first bandwidth.
[0058] For example, when the congestion window value is increased and more data packets are sent, it is detected that the bandwidth also increases, which means that so many data packets can actually be sent. Even if the round-trip delay increases, it may be caused by other background traffic, and not because the sender sends more data packets, causing the round-trip delay to increase. Therefore, in this case, only the first and second predetermined conditions are met, and the third predetermined condition is not met, and the congestion window value will not be reduced.
[0059] Likewise, if any of the three predetermined conditions is not satisfied, the congestion window value will continue to increase.
[0060] In actual applications, other traffic may exist on the same link, causing the round-trip delay base value to change. Therefore, the number of queues calculated using a fixed round-trip delay base value is not accurate. For example, in a delay-based algorithm like Vegas, other traffic is also counted as part of its own traffic because there is no process of re-detecting the round-trip delay base value, which leads to a continuous reduction in the window.
[0061] In order to better solve the problem of changes in the basic value of round-trip delay, preferably, a detection process of the basic value of round-trip delay is added, and the basic value of round-trip delay is measured at regular intervals. For example, the latest basic value of round-trip delay is remeasured every 8 times of the previous basic value of round-trip delay, and the congestion window value is adjusted down during the detection process to ensure that a smaller round-trip delay value can be detected. The detection time lasts for the duration of the previous basic value of round-trip delay, and finally the latest detected basic value of round-trip delay is substituted into the formula to calculate the current number of data packets queued V, and the basic value of round-trip delay is regularly updated to take into account the fluctuation of the round-trip delay caused by the background traffic.
[0062] More specifically, a certain amount of standard packets can be sent within a time period at regular intervals, and the return delay of the standard packets can be detected, and the average value can be calculated as the latest basic value of the round-trip delay; or a certain amount of standard packets can be sent within a time period at regular intervals, and the return delay of the standard packets can be detected, and the smallest round-trip delay can be taken as the latest basic value of the round-trip delay.
[0063] In addition, preferably, the duration of the first time period in step S101 and the second time period in step S102 are both a basic round-trip delay value.
[0064] S105: When the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth simultaneously meet a predetermined condition, reducing the congestion window value.
[0065] That is, if the aforementioned three predetermined conditions are met at the same time, the congestion window value is reduced.
[0066] The implementation method of reducing the congestion window value may be to reduce the congestion window value and reduce it to the first window value; or to reduce the congestion window value and reduce it to the first window value multiplied by a reduction coefficient. Preferably, the reduction coefficient is 0.6 to 0.8.
[0067] For example, if the second threshold is 4, the number of current data packets queued is greater than 4, the second round-trip delay is greater than the first round-trip delay, and the second bandwidth is less than or equal to the first bandwidth, the congestion window value is reduced to the first window value.
[0068] When the three predetermined conditions are met at the same time, the congestion window value is reduced, instead of reducing the congestion window value only when packet loss occurs, as in the prior art congestion control method based on packet loss. This embodiment effectively limits the growth of the congestion window according to the change of round-trip delay and bandwidth, avoids serious router queuing, and can effectively control the growth of round-trip delay and maintain a relatively low round-trip delay value.
[0069] As another optional embodiment, not only whether the three predetermined conditions are met but also the current packet loss situation should be considered, such as Figure 2 As shown, based on steps S101-S103, it also includes:
[0070] S201: Detect the current packet loss situation in real time to detect whether packet loss and retransmission are currently occurring.
[0071] S202: When the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth do not simultaneously satisfy a predetermined condition, and when packet loss and retransmission are not detected, increase the congestion window value.
[0072] For example, when the first round-trip delay, the second round-trip delay, the first bandwidth and the second bandwidth only meet the first predetermined condition, that is, the current number of data packets queued is greater than the second threshold, and the second and third predetermined conditions are not met, that is, the second round-trip delay is less than the first round-trip delay, the second bandwidth is greater than the first bandwidth, and no packet loss and retransmission are detected, the congestion window value continues to increase.
[0073] S203: Otherwise, reduce the congestion window value.
[0074] For example, when the first round-trip delay, the second round-trip delay, the first bandwidth and the second bandwidth only meet the first predetermined condition, that is, the current number of data packets queued is greater than the second threshold, and the second and third predetermined conditions are not met, that is, the second round-trip delay is less than the first round-trip delay, and the second bandwidth is greater than the first bandwidth, but it is detected that packet loss and retransmission are currently occurring, the congestion window value is rolled back, that is, the congestion window value is reduced.
[0075] As another optional embodiment, not only whether the three predetermined conditions and the current packet loss situation are met should be considered, but also the current congestion window value size should be considered, such as Figure 3 As shown, based on steps S101-S103, it also includes:
[0076] S301: Detect the current packet loss situation in real time and calculate the current congestion window value.
[0077] The current congestion window value W is calculated according to the following formula:
[0078] W = ack_size / mss;
[0079] Where ack_size is the number of bytes confirmed received within a congestion window, and mss is the number of bytes in a data packet.
[0080] S302: When the first round-trip delay, the second round-trip delay, the first bandwidth and the second bandwidth do not simultaneously satisfy a predetermined condition; and when packet loss and retransmission are not detected, or when packet loss and retransmission are detected but the current congestion window value is less than or equal to a first threshold, the congestion window value is increased.
[0081] That is, if the first round-trip delay, the second round-trip delay, the first bandwidth and the second bandwidth do not satisfy the three predetermined conditions at the same time, and packet loss and retransmission are not detected, the congestion window value is increased; or, if the first round-trip delay, the second round-trip delay, the first bandwidth and the second bandwidth do not satisfy the three predetermined conditions at the same time, and packet loss and retransmission are detected but the current congestion window value is less than or equal to the first threshold, the congestion window value is increased.
[0082] For example, the link of a mobile network may occasionally be unstable, such as when the mobile network is interfered with. In this case, packet loss does not actually mean that congestion has occurred. If a packet loss-based congestion control method is used, the congestion window value will be reduced once a packet loss event is detected. However, the actual congestion window value does not need to be reduced. The window has the ability to continue to send the original amount of data or more. Therefore, it is necessary to combine the current window value size to avoid the occurrence of a reduction in the congestion window value due to an interfering packet loss event.
[0083] For example, assuming that the first threshold is 4, the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth do not simultaneously satisfy the three predetermined conditions, it is detected that packet loss and retransmission are currently occurring, the number of bytes confirmed to be received in the current congestion window is 4500 bytes, and the number of bytes of a data packet is 1500 bytes, then the current congestion window value W=4500 / 1500=3, that is, the current congestion window value is less than the first threshold, and the congestion window value continues to increase.
[0084] S303: Otherwise, reduce the congestion window value.
[0085] That is, as long as the first round-trip delay, the second round-trip delay, the first bandwidth and the second bandwidth simultaneously satisfy the three predetermined conditions, the congestion window value is reduced; or as long as it is detected that packet loss and retransmission are currently occurring and the current congestion window value is greater than the first threshold, the congestion window value is reduced.
[0086] For example, assuming that the first threshold is 4, the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth do not simultaneously satisfy the three predetermined conditions, it is detected that packet loss and retransmission are currently occurring, the number of bytes confirmed to be received in the current congestion window is 7500 bytes, and the number of bytes of a data packet is 1500 bytes, then the current congestion window value W=7500 / 1500=5, that is, the current congestion window value is greater than the first threshold, then the congestion window value is reduced.
[0087] For another example, assuming that the first threshold is 4, the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth simultaneously satisfy the three predetermined conditions, even if it is not detected that packet loss and retransmission have not occurred, the number of bytes confirmed to be received in the current congestion window is 4500 bytes, and the number of bytes of a data packet is 1500 bytes, then the current congestion window value W=4500 / 1500=3, that is, the current congestion window value is less than the first threshold, and the congestion window value is also reduced.
[0088] Exemplary Systems
[0089] Accordingly, an embodiment of the present invention also provides a congestion control system based on delay and packet loss. Figure 4 Schematic diagram of a congestion control system 100 based on delay and packet loss provided by an embodiment of the present invention, such as Figure 4 As shown, the system 100 provided in this embodiment includes:
[0090] A detection device 101, which is used to detect a first round-trip delay and a first bandwidth in real time in a first time period, and to detect a second round-trip delay and a second bandwidth in real time in a second time period;
[0091] A setting device 102, which is used to set a first window value, wherein the first window value is a congestion window value at an initial moment of the first time period;
[0092] A determination device 104, configured to determine whether the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth simultaneously satisfy a predetermined condition;
[0093] A congestion window value adjusting device 103, configured to increase the congestion window value when the judging device 104 judges that the first round-trip delay, the second round-trip delay, the first bandwidth and the second bandwidth do not simultaneously meet a predetermined condition;
[0094] The congestion window value adjusting device 103 is configured to reduce the congestion window value when the judging device 104 judges that the first round-trip delay, the second round-trip delay, the first bandwidth and the second bandwidth simultaneously meet a predetermined condition.
[0095] The detection device 101 is also used to detect the current packet loss situation in real time;
[0096] When the first round-trip delay, the second round-trip delay, the first bandwidth and the second bandwidth do not simultaneously meet the predetermined conditions, and no packet loss retransmission is detected, the congestion window value adjustment device 103 is further used to increase the congestion window value;
[0097] Otherwise, the congestion window value adjusting device 103 is further configured to reduce the congestion window value.
[0098] The detection device 101 is also used to detect the current packet loss situation in real time. The system also includes a calculation device 106, and the calculation device 106 is used to calculate the current congestion window value;
[0099] When the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth do not simultaneously meet a predetermined condition; and when packet loss retransmission is not detected, or when packet loss retransmission is detected but the current congestion window value is less than or equal to a first threshold, the congestion window value adjustment device 103 is further used to increase the congestion window value;
[0100] Otherwise, the congestion window value adjusting device 103 is further configured to reduce the congestion window value.
[0101] The current congestion window value W=ack_size / mss;
[0102] Where ack_size is the number of bytes confirmed received within a congestion window, and mss is the number of bytes in a data packet.
[0103] The predetermined conditions that the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth simultaneously satisfy specifically include:
[0104] The current number of data packets queued is greater than the second threshold;
[0105] The second round trip delay is greater than the first round trip delay; and
[0106] The second bandwidth is smaller than the first bandwidth.
[0107] The current number of data packets queued V=W1*rtt_min2 / rtt_base;
[0108] Wherein W1 is the first window value, rtt_min2 is the second round-trip delay, and rtt_base is the round-trip delay base value.
[0109] The congestion window value adjusting device 103 is used to reduce the congestion window value and reduce it to the first window value.
[0110] The congestion window value adjusting device 103 is used to reduce the congestion window value and reduce it to the first window value multiplied by the reduction coefficient.
[0111] The reduction coefficient is 0.6 to 0.8.
[0112] The system further comprises a device 105 for measuring a basic round trip delay value, which is used to measure the basic round trip delay value at regular intervals.
[0113] The device 105 for measuring the basic value of the round trip delay comprises:
[0114] A sending module 115, which is used to send a certain amount of standard packets within a time period at regular intervals;
[0115] A delay detection module 125, which is used to detect the return delay of the standard packet;
[0116] The average value calculation module 135 is used to calculate the average value of the return delay of the standard packet to obtain the round-trip delay basic value.
[0117] The first round-trip delay is a minimum round-trip delay among multiple round-trip delays in the first time period.
[0118] The second round trip delay is a minimum round trip delay among multiple round trip delays in the second time period.
[0119] The duration of the first time period and the second time period are both the round-trip delay basic value.
[0120] It should be noted that although the operations of the congestion control method based on delay and packet loss of the present invention are described in a specific order in the accompanying drawings, this does not require or imply that these operations must be performed in this specific order, or that all the operations shown must be performed to achieve the desired results. Additionally or alternatively, some steps may be omitted, multiple steps may be combined into one step, and / or one step may be decomposed into multiple steps.
[0121] In addition, although several devices, units, or modules of the congestion control system based on delay and packet loss are mentioned in the above detailed description, this division is only exemplary and not mandatory. In fact, according to an embodiment of the present invention, the features and functions of two or more modules described above can be embodied in one module. Conversely, the features and functions of one module described above can be further divided into multiple modules to be embodied.
[0122] Although the spirit and principle of the present invention have been described with reference to several specific embodiments, it should be understood that the present invention is not limited to the disclosed specific embodiments, and the division of various aspects does not mean that the features in these aspects cannot be combined to benefit, and such division is only for the convenience of expression. The present invention is intended to cover various modifications and equivalent arrangements included in the spirit and scope of the attached claims.
[0123] The present invention provides:
[0124] 1. A congestion control method based on delay and packet loss, characterized in that the method comprises:
[0125] Detecting a first round-trip delay and a first bandwidth in real time during a first time period;
[0126] detecting a second round trip delay and a second bandwidth in real time in a second time period;
[0127] Setting a first window value, where the first window value is a congestion window value at an initial moment of the first time period;
[0128] When the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth do not simultaneously meet a predetermined condition, increasing the congestion window value;
[0129] When the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth simultaneously meet a predetermined condition, the congestion window value is reduced.
[0130] 2. The congestion control method according to item 1, characterized in that the method further comprises detecting the current packet loss situation in real time;
[0131] When the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth do not simultaneously meet a predetermined condition, and no packet loss retransmission is detected, increasing the congestion window value;
[0132] Otherwise, the congestion window value is reduced.
[0133] 3. The congestion control method according to item 1, characterized in that the method further comprises: detecting the current packet loss situation in real time and calculating the current congestion window value;
[0134] When the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth do not simultaneously meet a predetermined condition; and when packet loss retransmission is not detected, or when packet loss retransmission is detected but the current congestion window value is less than or equal to a first threshold, the congestion window value is increased;
[0135] Otherwise, the congestion window value is reduced.
[0136] 4. The congestion control method according to any one of item 3, characterized in that the method further comprises calculating the current congestion window value W according to the following formula:
[0137] W = ack_size / mss;
[0138] Where ack_size is the number of bytes confirmed received within a congestion window, and mss is the number of bytes in a data packet.
[0139] 5. The congestion control method according to any one of items 1 to 4, wherein the predetermined conditions that the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth simultaneously satisfy specifically include:
[0140] The current number of data packets queued is greater than the second threshold;
[0141] The second round trip delay is greater than the first round trip delay; and
[0142] The second bandwidth is smaller than the first bandwidth.
[0143] 6. The congestion control method according to item 5 is characterized in that the current number of data packets queued V is calculated according to the following formula:
[0144] V = W1*rtt_min2 / rtt_base;
[0145] Wherein W1 is the first window value, rtt_min2 is the second round-trip delay, and rtt_base is the round-trip delay base value.
[0146] 7. The congestion control method according to any one of items 1 to 6 is characterized in that the step of reducing the congestion window value is specifically: reducing the congestion window value and reducing it to the first window value.
[0147] 8. The congestion control method according to any one of items 1 to 7 is characterized in that the step of reducing the congestion window value is specifically: reducing the congestion window value and reducing it to the first window value multiplied by a reduction coefficient.
[0148] 9. The congestion control method according to item 8 is characterized in that the reduction coefficient is 0.6 to 0.8.
[0149] 10. The congestion control method according to any one of items 6 to 9 is characterized in that the method further comprises: measuring the basic value of the round-trip delay at regular intervals.
[0150] 11. The congestion control method according to item 10, wherein the step of measuring the basic value of the round-trip delay at regular intervals specifically comprises:
[0151] A certain amount of standard packets are sent within a time period at regular intervals, and the return delay of the standard packets is detected, and the average value thereof is calculated to obtain the basic round-trip delay value.
[0152] 12. The congestion control method according to any one of items 1 to 11, characterized in that the first round-trip delay is a minimum round-trip delay among multiple round-trip delays in the first time period;
[0153] The second round trip delay is a minimum round trip delay among multiple round trip delays in the second time period.
[0154] 13. The congestion control method according to any one of items 1 to 12 is characterized in that the duration of the first time period and the second time period are both the round-trip delay basic value.
[0155] 14. A congestion control system based on delay and packet loss, characterized in that the system comprises:
[0156] A detection device, which is used to detect a first round-trip delay and a first bandwidth in real time in a first time period, and to detect a second round-trip delay and a second bandwidth in real time in a second time period;
[0157] A setting device, which is used to set a first window value, wherein the first window value is a congestion window value at an initial moment of the first time period;
[0158] a judging device, configured to judge whether the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth simultaneously satisfy a predetermined condition;
[0159] The congestion window value adjustment device is used for:
[0160] When the judging device judges that the first round-trip delay, the second round-trip delay, the first bandwidth and the second bandwidth do not simultaneously meet a predetermined condition, increasing the congestion window value;
[0161] When the determining device determines that the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth simultaneously meet a predetermined condition, the congestion window value is reduced.
[0162] 15. The congestion control system according to item 14, characterized in that the detection device is also used to detect the current packet loss situation in real time;
[0163] When the first round-trip delay, the second round-trip delay, the first bandwidth and the second bandwidth do not simultaneously meet the predetermined conditions, and no packet loss retransmission is detected, the congestion window value adjustment device is further used to increase the congestion window value;
[0164] Otherwise, the congestion window value adjusting device is further configured to reduce the congestion window value.
[0165] 16. The congestion control system according to item 14, characterized in that the detection device is also used to detect the current packet loss situation in real time, and the system further includes a calculation device, and the calculation device is used to calculate the current congestion window value;
[0166] When the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth do not simultaneously meet a predetermined condition; and when packet loss retransmission is not detected, or when packet loss retransmission is detected but the current congestion window value is less than or equal to a first threshold, the congestion window value adjustment device is further used to increase the congestion window value;
[0167] Otherwise, the congestion window value adjusting device is further configured to reduce the congestion window value.
[0168] 17. The congestion control system according to any one of item 16, characterized in that the current congestion window value W = ack_size / mss;
[0169] Where ack_size is the number of bytes confirmed received within a congestion window, and mss is the number of bytes in a data packet.
[0170] 18. The congestion control system according to any one of items 14 to 17, wherein the predetermined conditions that the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth simultaneously satisfy specifically include:
[0171] The current number of data packets queued is greater than the second threshold;
[0172] The second round trip delay is greater than the first round trip delay; and
[0173] The second bandwidth is smaller than the first bandwidth.
[0174] 19. The congestion control system according to item 18, characterized in that the current number of data packets queued V = W1*rtt_min2 / rtt_base;
[0175] Wherein W1 is the first window value, rtt_min2 is the second round-trip delay, and rtt_base is the round-trip delay base value.
[0176] 20. The congestion control system according to any one of items 14 to 19, characterized in that the congestion window value adjustment device is used to reduce the congestion window value and reduce it to the first window value.
[0177] 21. The congestion control system according to any one of items 14 to 20, characterized in that the congestion window value adjustment device is used to reduce the congestion window value and reduce it to the first window value multiplied by a reduction coefficient.
[0178] 22. The congestion control system according to item 21 is characterized in that the reduction coefficient is 0.6 to 0.8.
[0179] 23. The congestion control system according to any one of items 19 to 22 is characterized in that the system further comprises a device for measuring a basic value of a round-trip delay, which is used to measure the basic value of the round-trip delay at regular intervals.
[0180] 24. The congestion control system according to item 23, wherein the device for measuring the basic value of round-trip delay comprises:
[0181] A sending module, which is used to send a certain amount of standard packets within a time period at regular intervals;
[0182] A delay detection module, which is used to detect the return delay of the standard packet;
[0183] The module for calculating the average value is used to calculate the average value of the return delay of the standard packet to obtain the basic value of the round-trip delay.
[0184] 25. The congestion control system according to any one of items 14 to 24, characterized in that the first round-trip delay is the minimum round-trip delay among multiple round-trip delays in the first time period;
[0185] The second round trip delay is a minimum round trip delay among multiple round trip delays in the second time period.
[0186] 26. The congestion control system according to any one of items 14 to 25, characterized in that the duration of the first time period and the second time period are both equal to a basic value of the round-trip delay.
Claims
1. A congestion control method based on delay and packet loss, characterized in that: The method comprises: Detecting a first round-trip delay and a first bandwidth in real time during a first time period; Detecting a second round trip delay and a second bandwidth in real time in a second time period; Setting a first window value, where the first window value is a congestion window value at an initial moment of the first time period; Detect the current packet loss situation in real time and calculate the current congestion window value; When the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth do not simultaneously satisfy a predetermined condition; and when packet loss retransmission is not detected, or when packet loss retransmission is detected but the current congestion window value is less than or equal to a first threshold, the congestion window value is increased, Otherwise, reducing the congestion window value; The predetermined conditions specifically include: The current number of data packets queued is greater than the second threshold; The second round trip delay is greater than the first round trip delay; and The second bandwidth is smaller than the first bandwidth.
2. The congestion control method according to claim 1, characterized in that: The method further includes calculating the current congestion window value W according to the following formula: W = ack_size / mss; Where ack_size is the number of bytes confirmed received within a congestion window, and mss is the number of bytes in a data packet.
3. The congestion control method according to claim 1, characterized in that: The current number V of data packets queued is calculated according to the following formula: V=W1*rtt_min2 / rtt_base; Wherein W1 is the first window value, rtt_min2 is the second round-trip delay, and rtt_base is the round-trip delay base value.
4. The congestion control method according to any one of claims 1 to 3, characterized in that: The step of reducing the congestion window value specifically includes reducing the congestion window value to the first window value.
5. The congestion control method according to any one of claims 1 to 3, characterized in that: The step of reducing the congestion window value is specifically: reducing the congestion window value, and reducing it to the first window value multiplied by the reduction coefficient.
6. The congestion control method according to claim 5, characterized in that: The reduction coefficient is 0.6~0.
8.
7. The congestion control method according to claim 4, characterized in that: The method further comprises: measuring a basic round-trip delay value at regular intervals.
8. The congestion control method according to claim 7, characterized in that: The step of measuring the basic value of the round-trip delay at regular intervals specifically includes: A certain amount of standard packets are sent within a time period at regular intervals, and the round-trip delays of the standard packets are detected, and the average value thereof is calculated to obtain the basic round-trip delay value.
9. The congestion control method according to any one of claims 1 to 3, characterized in that: The first round-trip delay is the minimum round-trip delay among multiple round-trip delays in the first time period; The second round-trip delay is a minimum round-trip delay among multiple round-trip delays in the second time period.
10. The congestion control method according to any one of claims 1 to 3, characterized in that: The duration of the first time period and the second time period are both a round-trip delay basic value.
11. A congestion control system based on delay and packet loss, characterized in that: The system comprises: A detection device, which is used to detect the first round-trip delay and the first bandwidth in real time in the first time period, detect the second round-trip delay and the second bandwidth in real time in the second time period, and detect the current packet loss situation in real time; A setting device, which is used to set a first window value, wherein the first window value is a congestion window value at an initial moment of the first time period; A calculation device, used for calculating a current congestion window value; A judging device, configured to judge whether the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth simultaneously satisfy a predetermined condition, wherein the predetermined condition specifically includes: The current number of data packets queued is greater than the second threshold; The second round trip delay is greater than the first round trip delay; and The second bandwidth is smaller than the first bandwidth; The congestion window value adjustment device is used for: When the first round-trip delay, the second round-trip delay, the first bandwidth, and the second bandwidth do not simultaneously meet a predetermined condition; and when packet loss retransmission is not detected, or when packet loss retransmission is detected but the current congestion window value is less than or equal to a first threshold, the congestion window value adjustment device is further used to increase the congestion window value; Otherwise, the congestion window value is reduced.
12. The congestion control system according to claim 11, characterized in that: The current congestion window value W=ack_size / mss; Where ack_size is the number of bytes confirmed received within a congestion window, and mss is the number of bytes in a data packet.
13. The congestion control system according to claim 12, characterized in that: The current number of data packets queued V=W1*rtt_min2 / rtt_base; Wherein W1 is the first window value, rtt_min2 is the second round-trip delay, and rtt_base is the round-trip delay base value.
14. The congestion control system according to any one of claims 11 to 13, characterized in that: The congestion window value adjustment device is used to reduce the congestion window value and reduce it to the first window value.
15. The congestion control system according to any one of claims 11 to 13, characterized in that: The congestion window value adjustment device is used to reduce the congestion window value and reduce it to the first window value multiplied by the reduction coefficient.
16. The congestion control system according to claim 15, characterized in that: The reduction coefficient is 0.6~0.
8.
17. The congestion control system according to claim 14, characterized in that: The system also includes a device for measuring a basic round-trip delay value, which is used to measure the basic round-trip delay value at regular intervals.
18. The congestion control system according to claim 17, characterized in that: The device for measuring the basic value of round-trip delay comprises: A sending module, which is used to send a certain amount of standard packets within a time period at regular intervals; A delay detection module, which is used to detect the round-trip delay of the standard packet; The average value calculation module is used to calculate the average value of the round-trip delay of the standard packet to obtain the round-trip delay base value.
19. The congestion control system according to any one of claims 11 to 13, characterized in that: The first round-trip delay is the minimum round-trip delay among multiple round-trip delays in the first time period; The second round-trip delay is a minimum round-trip delay among multiple round-trip delays in the second time period.
20. The congestion control system according to any one of claims 11 to 13, characterized in that: The duration of the first time period and the second time period are both a round-trip delay basic value.
