Methods, apparatus, equipment, media, and products for configuring congestion notification thresholds.
By automatically configuring ECN thresholds based on the configuration and performance parameters of network devices, the problems of complex ECN threshold configuration and high performance overhead in existing technologies are solved, achieving more efficient congestion control.
Patent Information
- Application Number
- CN202410347035.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-03-25
- Publication Date
- 2026-01-06
- Estimated Expiration
- 2044-03-25
AI Technical Summary
In existing technologies, ECN threshold configuration relies on human experience or AI prediction, which leads to complex operations and high performance overhead, making it difficult to effectively adjust to adapt to the actual caching needs of network devices and affecting congestion control performance.
By acquiring the configuration and performance parameters of network devices, calculating the proportional coefficient, and combining cache space parameters and congestion control algorithms, the ECN threshold is automatically configured and dynamically updated to adapt to network changes.
It simplifies the ECN threshold configuration process, reduces computational overhead, improves the adaptability and efficiency of congestion control, and enhances the congestion management performance of network devices.
Smart Images

Figure CN118827546B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of data transmission, and more particularly to a method, apparatus, device, medium, and product for configuring Explicit Congestion Notification (ECN) thresholds. Background Technology
[0002] In network switches, network congestion occurs when the bandwidth of inbound traffic exceeds that of outbound traffic. A typical example is multiple senders simultaneously transmitting network data to the same destination. The switch's buffer can handle temporary congestion, but if congestion persists for too long, the buffer will become overloaded. When the switch buffer is overloaded, the next incoming data packet will be dropped. Packet loss degrades application performance because retransmission and the complexity of transport protocols introduce latency. Lossless networks implement flow control mechanisms that can pause inbound traffic before the buffer overflows, preventing packet loss. However, flow control itself can contribute to the problem of congestion propagation.
[0003] Congestion control is used to reduce packet loss in lossy networks or congestion propagation in lossless networks. It also reduces switch buffer usage, thereby reducing latency and improving tolerance to burst traffic. For widely deployed ECN-based congestion control schemes, the marking threshold (ECN threshold) is crucial for providing high bandwidth and low latency. Traditionally, ECN thresholds are configured manually, with operators setting fixed thresholds based on network tuning experience. The appropriateness of the ECN threshold setting has a significant impact on congestion control algorithms that rely on ECN signals. For example, the DCQCN (Data Center Quantized Congestion Notification) congestion control algorithm adjusts the sending rate based on CNP (Congestion Notification Packets), and the BBRv2 (Bottleneck Bandwidth and Round-trip propagation time version 2) congestion control algorithm also adjusts the message sending rate based on congestion signals from ECN feedback. In addition, there are also methods for setting ECN thresholds based on AI (Artificial Intelligence), such as dynamically predicting network traffic changes based on the existing network traffic model and adjusting the ECN threshold in real time.
[0004] The above-mentioned method of manually configuring ECN thresholds requires operators to have a high level of experience in network performance tuning, and the operation is relatively cumbersome. The above-mentioned method of setting ECN thresholds based on AI relies on relatively accurate traffic detection and prediction methods, which will cause significant performance overhead to network devices, and adjusting the ECN threshold for a single queue may result in over-adjustment. Summary of the Invention
[0005] In view of this, embodiments of this application provide a method, apparatus, device, medium, and product for displaying congestion notification threshold configuration, which aims to improve the congestion control effect of network devices.
[0006] The technical solution of this application embodiment is implemented as follows:
[0007] In a first aspect, embodiments of this application provide a method for configuring an explicit congestion notification (ECN) threshold, including:
[0008] Obtain the configuration parameters and network performance parameters of the network device. The configuration parameters include at least the cache space parameters of the switching chip of the network device and the rated bandwidth of each port of the network device. The network performance parameters include at least the round-trip latency between each port of the network device and neighboring nodes.
[0009] Based on the rated bandwidth and round-trip delay of each port of the network device, a proportionality coefficient for each port of the network device is calculated. The proportionality coefficient represents the ratio of the bandwidth-delay product of a single port to the sum of the bandwidth-delay products of all network ports of the network device.
[0010] Based on the cache space parameters and the proportional coefficient of the target port of the network device, the ECN threshold of the message buffer queue of the target port is determined, where the target port is any port of the network device.
[0011] In the above scheme, the cache space parameters include: a first cache space parameter characterizing the size of the on-chip cache space of the switching chip and a second cache space parameter characterizing the size of the off-chip cache space of the switching chip. The step of determining the ECN threshold of the message buffer queue of the target port based on the cache space parameters and the proportionality coefficient of the target port of the network device includes:
[0012] Calculate the difference between the first cache space parameter and the sum of the bandwidth-delay products of all network ports of the network device;
[0013] The difference and the second cache space parameter are weighted and summed to obtain a sum value; wherein the weight of the difference is a first adjustment coefficient, and the weight of the second cache space parameter is a second adjustment coefficient.
[0014] Based on the scaling factor, the summation value, and the number of queues supported by the target port, the ECN threshold of the message buffer queue of the target port is determined.
[0015] In the above scheme, before determining the ECN threshold of the message buffer queue of the target port based on the cache space parameters and the proportional coefficient of the target port of the network device, the method further includes:
[0016] Based on the type of message buffer queue supported by the target port, configure the first adjustment coefficient and / or the second adjustment coefficient for each type of message buffer queue so that the ECN thresholds of different types of message buffer queues are different.
[0017] In the above scheme, determining the ECN threshold of the message buffer queue of the target port based on the proportional coefficient, the summation value, and the number of queues supported by the target port includes:
[0018] Obtain the ECN configuration template based on the type of congestion control algorithm;
[0019] Based on the proportional coefficient, the summation value, the number of queues supported by the target port, and the ECN configuration template, the ECN threshold of the message buffer queue of the target port is determined.
[0020] The method in the above scheme further includes:
[0021] Based on a set time interval, periodically detect whether there are changes in the neighboring nodes of the network device;
[0022] If so, the round-trip latency between each port of the network device and its neighboring nodes is reacquired, and based on the reacquired round-trip latency, the proportionality coefficient of each port of the network device and the proportionality coefficient of the target port of the network device based on the rated bandwidth and the round-trip latency of each port of the network device are calculated to determine the ECN threshold of the message buffer queue of the target port.
[0023] The method in the above scheme further includes:
[0024] If not, then obtain the transmission rate of the target port and the average queuing delay of the data packets in the message buffer queue; and update the ECN threshold of the message buffer queue of the target port based on the transmission rate and the average queuing delay of the data packets.
[0025] In the above scheme, updating the ECN threshold of the message buffer queue of the target port based on the transmission rate and the average queuing delay of the data packets includes:
[0026] Based on the transmission rate, the average queuing delay of the data packets, the preset expected transmission rate, and the preset expected average queuing delay of the data packets, an update adjustment value is obtained;
[0027] Multiply the updated adjustment value by the current ECN threshold value to obtain the threshold increment value;
[0028] The current ECN threshold and the threshold increment are weighted and summed, and the weighted sum is used as the updated ECN threshold.
[0029] In the above scheme, the step of obtaining the update adjustment value based on the transmission rate, the average queuing delay of data packets, the preset expected transmission rate, and the preset expected average queuing delay of data packets includes:
[0030] Based on the transmission rate and the preset desired transmission rate, a first adjustment value is generated;
[0031] A second adjustment value is generated based on the average queuing delay of the data packets and the preset expected average queuing delay of the data packets;
[0032] The first adjustment value and the second adjustment value are weighted and summed to obtain the updated adjustment value;
[0033] Wherein, the sum of the weight values of the first adjustment value and the second adjustment value is 1, and the weight values of the first adjustment value and the second adjustment value correspond to the type of the message buffer queue.
[0034] Secondly, embodiments of this application provide a device for configuring a congestion notification threshold, comprising:
[0035] The acquisition module is used to acquire the configuration parameters and network performance parameters of the network device. The configuration parameters include at least the cache space parameters of the switching chip of the network device and the rated bandwidth of each port of the network device. The network performance parameters include at least the round-trip latency between each port of the network device and neighboring nodes.
[0036] The calculation module is used to calculate the proportional coefficient of each port of the network device based on the rated bandwidth and round-trip delay of each port of the network device. The proportional coefficient represents the ratio of the bandwidth-delay product of a single port to the sum of the bandwidth-delay products of all network ports of the network device.
[0037] The threshold determination module is used to determine the ECN threshold of the message buffer queue of the target port based on the cache space parameters and the proportional coefficient of the target port of the network device, wherein the target port is any port of the network device.
[0038] Thirdly, embodiments of this application provide a network device, including: a processor and a memory for storing a computer program capable of running on the processor, wherein the processor, when running the computer program, executes the steps of the method described in the first aspect of embodiments of this application.
[0039] Fourthly, embodiments of this application provide a computer storage medium storing a computer program, which, when executed by a processor, implements the steps of the method described in the first aspect of embodiments of this application.
[0040] Fifthly, embodiments of this application provide a computer program product, including a computer program that, when executed by a processor, implements the steps of the method described in the first aspect of embodiments of this application.
[0041] The technical solution provided in this application obtains the configuration parameters and network performance parameters of a network device. The configuration parameters include at least the cache space parameters of the network device's switching chip and the rated bandwidth of each port of the network device. The network performance parameters include at least the round-trip latency between each port of the network device and its neighboring nodes. Based on the rated bandwidth and round-trip latency of each port of the network device, a proportionality coefficient is calculated for each port. This proportionality coefficient represents the ratio of the bandwidth-delay product of a single port to the sum of the bandwidth-delay products of all network ports of the network device. Based on the cache space parameters and the proportionality coefficient of the target port of the network device, the ECN threshold of the message buffer queue of the target port is determined. The target port can be any port of the network device. Thus, the ECN threshold of the message buffer queue of the target port can be determined according to the cache space parameters and the proportionality coefficient of the target port of the network device, making the ECN threshold adaptable to the actual cache requirements of the target port, effectively improving the congestion control effect of the network device. Attached Figure Description
[0042] Figure 1 This is a flowchart illustrating the ECN threshold configuration method according to an embodiment of this application;
[0043] Figure 2 A schematic diagram illustrating the initial setting of the ECN threshold in an application embodiment of this application;
[0044] Figure 3 This is a schematic diagram illustrating the dynamic update process of the ECN threshold in an application embodiment of this application;
[0045] Figure 4 This is a schematic diagram showing the structure of the congestion notification threshold configuration device according to an embodiment of this application;
[0046] Figure 5 This is a schematic diagram of the network device in an embodiment of this application. Detailed Implementation
[0047] The present application will now be described in further detail with reference to the accompanying drawings and embodiments.
[0048] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein in the specification of this application is for the purpose of describing particular embodiments only and is not intended to be limiting of this application.
[0049] This application provides an ECN threshold configuration method, applied to network devices, such as... Figure 1 As shown, the method includes:
[0050] Step 101: Obtain the configuration parameters and network performance parameters of the network device. The configuration parameters include at least the cache space parameters of the switching chip of the network device and the rated bandwidth of each port of the network device. The network performance parameters include at least the round-trip latency between each port of the network device and neighboring nodes.
[0051] Here, the network device includes a control chip and a switching chip, with the message buffer queue located on the switching chip. The control chip and the switching chip communicate via physical connection lines. The control chip can be a field-programmable gate array (FPGA) chip or a central processing unit (CPU). Optionally, the control chip and switching chip in the network device can also be integrated, meaning that control and forwarding functions are integrated onto a single chip.
[0052] For example, the buffers of network device nodes can be managed based on switch architectures such as CIOQ (combined input output queuing) and VOQ (Virtual output queuing). The message buffer queue can use only the on-chip cache space of the switching chip, or a hybrid caching method that uses both the on-chip and off-chip cache spaces of the switching chip.
[0053] Here, the cache space parameters of the switching chip may include: a first cache space parameter characterizing the size of the on-chip cache space of the switching chip and a second cache space parameter characterizing the size of the off-chip cache space of the switching chip. The first cache space parameter can be understood as the configured rated on-chip cache space, and the second cache space parameter can be understood as the configured rated off-chip cache space.
[0054] In one application example, the network device, using the Juniper QFX5210 switch, supports 64 full-duplex 100Gbps ports, meaning each port has a rated bandwidth of 100Gbps; the on-chip cache space is 42MB (i.e., the first cache space parameter), and the DRAM (Dynamic Random Access Memory) cache space is 16GB (i.e., the second cache space parameter).
[0055] Here, Round-Trip Time (RTT) is an important performance metric, representing the total delay from when the sender begins sending data until the sender receives an acknowledgment from the receiver. The RTT between each port of a network device and its neighboring nodes can be obtained through configuration files or probe packets. For example, based on the configuration file, the RTT set within a data center might be 10µs, while the RTT set in a wide area network might be 50ms. Alternatively, the minimum RTT of adjacent network nodes can be obtained through probe packets, such as by sending a ping packet from the outgoing interface to obtain the RTT from the outgoing interface to the next-hop node. This embodiment of the application does not limit this approach.
[0056] Step 102: Based on the rated bandwidth and round-trip delay of each port of the network device, calculate the proportionality coefficient of each port of the network device. The proportionality coefficient represents the ratio of the bandwidth-delay product of a single port to the sum of the bandwidth-delay products of all network ports of the network device.
[0057] Here, the Bandwidth Delay Product (BDP) refers to the product of a data link's capacity (bits per second) and its round-trip communication delay (in seconds).
[0058] It is understandable that the bandwidth-delay product (BDP) of each port of the network device is obtained by multiplying the rated bandwidth and round-trip time of each port, and the total bandwidth-delay product (BDP) is obtained by adding the BDPs of all ports of the network device. sum This allows us to calculate the proportionality coefficient R for each port, which is the BDP of a single port divided by the total bandwidth-delay product BDP. sum The proportional coefficient R of the port is obtained.
[0059] Step 103: Based on the cache space parameters and the proportional coefficient of the target port of the network device, determine the ECN threshold of the message buffer queue of the target port, where the target port is any port of the network device.
[0060] It is understood that, according to the embodiments of this application, the ECN threshold of the message buffer queue of the target port can be determined based on the cache space parameters and the proportion of the target ports of the network device, so that the ECN threshold is adapted to the actual cache requirements of the target port, which can effectively improve the congestion control effect of the network device.
[0061] It should be noted that the ECN threshold determined by the method in this application embodiment can automatically configure the ECN threshold by calculating the message buffer queue based on the on-chip cache of the switching chip of the network device, or the requirements of the on-chip cache and off-chip cache, thereby effectively improving the congestion control effect of the network device. In addition, compared with the AI ECN threshold dynamic adjustment method, the method in this application embodiment sets the ECN threshold based on a simple basis and with low computational overhead, which can effectively reduce the complexity of ECN threshold setting.
[0062] For example, the cache space parameters include: a first cache space parameter characterizing the size of the on-chip cache space of the switching chip and a second cache space parameter characterizing the size of the off-chip cache space of the switching chip. Determining the ECN threshold of the message buffer queue of the target port based on the cache space parameters and the scaling factor of the target port of the network device includes:
[0063] Calculate the difference between the first cache space parameter and the sum of the bandwidth-delay products of all network ports of the network device;
[0064] The difference and the second cache space parameter are weighted and summed to obtain a sum value; wherein the weight of the difference is a first adjustment coefficient, and the weight of the second cache space parameter is a second adjustment coefficient.
[0065] Based on the scaling factor, the summation value, and the number of queues supported by the target port, the ECN threshold of the message buffer queue of the target port is determined.
[0066] In one application example, the ECN threshold can be calculated using the following formula:
[0067] T≤R*(α*(bf1-BDP sum )+β*bf2) / q
[0068] Where T is the ECN threshold of the message buffer queue of the target port, R is the scaling factor of the target port, bf1 is the first buffer space parameter, and BDP is the first buffer space parameter. sum is the sum of the bandwidth-delay products of all network ports of the network device, bf2 is the second buffer space parameter, α is the first adjustment coefficient, β is the second adjustment coefficient, and q is the number of queues supported by the target port.
[0069] It is understood that α is the on-chip cache adjustment coefficient, and β is the off-chip cache adjustment coefficient. For example, the default value of α can be set to 1, and its size can be adjusted according to the total port BDP value and the size of the on-chip cache. The larger the value of α, the larger the threshold value of ECN; if the network node does not support off-chip cache, then the value of β is 0.
[0070] For example, before determining the ECN threshold of the message buffer queue of the target port based on the cache space parameters and the scaling factor of the target port of the network device, the method further includes:
[0071] Based on the type of message buffer queue supported by the target port, configure the first adjustment coefficient and / or the second adjustment coefficient for each type of message buffer queue so that the ECN thresholds of different types of message buffer queues are different.
[0072] Understandably, for different types of message buffer queues, the aforementioned first adjustment coefficient and / or second adjustment coefficient can be configured accordingly, resulting in different ECN thresholds for different types of message buffer queues. For example, for a low-latency mouse stream message buffer queue, a smaller α coefficient can be selected to calculate a smaller ECN threshold value, ensuring low latency and low packet loss rate for the mouse stream; for a high-throughput elephant stream message buffer queue, a larger α coefficient can be selected to calculate a larger ECN threshold value, ensuring the high throughput requirements of the elephant stream. In this way, the different requirements of message buffer queues and ECN threshold values for scenarios such as low-latency mouse streams and high-throughput elephant streams can be accommodated.
[0073] For example, determining the ECN threshold of the message buffer queue of the target port based on the scaling factor, the summation value, and the number of queues supported by the target port includes:
[0074] Obtain the ECN configuration template based on the type of congestion control algorithm;
[0075] Based on the proportional coefficient, the summation value, the number of queues supported by the target port, and the ECN configuration template, the ECN threshold of the message buffer queue of the target port is determined.
[0076] It should be noted that different ECN configuration templates can be configured for different congestion control algorithms. These ECN configuration templates can define the parameter composition of the ECN thresholds. For example, for the DCTCP (Data Center Transmission Control Protocol) congestion control algorithm, one ECN threshold is used, i.e., Kmin = Kmax = K, Pmax = 1, where K is the queue's ECN threshold, Kmax is the upper limit of the threshold, Kmin is the lower limit of the threshold, P is the congestion marking rate or packet loss rate, and Pmax is the maximum congestion marking probability. For the DCQCN congestion control algorithm, two ECN thresholds are used, i.e., Kmax and Kmin are different.
[0077] Exemplarily, the method further includes:
[0078] Based on a set time interval, periodically detect whether there are changes in the neighboring nodes of the network device;
[0079] If so, the round-trip latency between each port of the network device and its neighboring nodes is reacquired, and based on the reacquired round-trip latency, the proportionality coefficient of each port of the network device and the proportionality coefficient of the target port of the network device based on the rated bandwidth and the round-trip latency of each port of the network device are calculated to determine the ECN threshold of the message buffer queue of the target port.
[0080] Understandably, based on periodic detection, if it is determined that the neighbor nodes of a network device have changed, the RTT between each port of the network device and the neighbor nodes is reacquired, and the proportional coefficient of each port is updated based on the reacquired RTT. Based on the updated proportional coefficient, the ECN threshold of the message buffer queue of the target port is recalculated, thereby realizing the dynamic update of the ECN threshold and meeting the congestion control requirements after network changes.
[0081] Exemplarily, the method further includes:
[0082] If not, then obtain the transmission rate of the target port and the average queuing delay of the data packets in the message buffer queue; and update the ECN threshold of the message buffer queue of the target port based on the transmission rate and the average queuing delay of the data packets.
[0083] Understandably, based on periodic detection, if it is determined that there has been no change in the neighboring nodes of the network device, the transmission rate of the target port and the average queuing delay of the data packets in the message buffer queue are obtained; and based on the transmission rate and the average queuing delay of the data packets, the ECN threshold of the message buffer queue of the target port is updated.
[0084] It should be noted that, compared to the AI ECN's dynamic threshold adjustment method, the traffic monitoring and calculation overhead of this embodiment is less. It only needs to periodically detect whether the adjacent network nodes have changed, obtain parameters such as the outgoing interface rate and packet queuing delay, and realize the function of automatically configuring the ECN threshold. In contrast, the AI ECN device has a large overhead in traffic monitoring, prediction and calculation, which reduces the complexity of ECN threshold setting.
[0085] For example, updating the ECN threshold of the message buffer queue of the target port based on the transmission rate and the average queuing delay of the data packets includes:
[0086] Based on the transmission rate, the average queuing delay of the data packets, the preset expected transmission rate, and the preset expected average queuing delay of the data packets, an update adjustment value is obtained;
[0087] Multiply the updated adjustment value by the current ECN threshold value to obtain the threshold increment value;
[0088] The current ECN threshold and the threshold increment are weighted and summed, and the weighted sum is used as the updated ECN threshold.
[0089] It is understood that in this embodiment of the application, when there are no changes in adjacent network nodes, the ECN threshold only needs to be updated based on the transmission rate of the outgoing interface and the average queuing delay of data packets, which can effectively reduce the complexity and computational overhead of setting the ECN threshold. The transmission rate of the outgoing interface can be determined based on the number of bytes queued out within a set time granularity, and the average queuing delay of data packets can be obtained using the CoDel (Controlled Delay) active queue management algorithm.
[0090] For example, the step of determining the update adjustment value based on the transmission rate, the average queuing delay of data packets, a preset expected transmission rate, and a preset expected average queuing delay of data packets includes:
[0091] Based on the transmission rate and the preset desired transmission rate, a first adjustment value is generated;
[0092] A second adjustment value is generated based on the average queuing delay of the data packets and the preset expected average queuing delay of the data packets;
[0093] The first adjustment value and the second adjustment value are weighted and summed to obtain the updated adjustment value;
[0094] Wherein, the sum of the weight values of the first adjustment value and the second adjustment value is 1, and the weight values of the first adjustment value and the second adjustment value correspond to the type of the message buffer queue.
[0095] For example, assuming the weight of the first adjustment value is w1 and the weight of the second adjustment value is w2, for a throughput-sensitive message buffer queue, w1 = 0.7 and w2 = 0.3 can be configured; for a latency-sensitive message buffer queue, w1 = 0.3 and w2 = 0.7 can be configured. This better meets the ECN threshold update requirements of different types of message buffer queues.
[0096] The present application will be further described in detail below with reference to application examples.
[0097] In this application embodiment, the configuration of the ECN threshold includes the initial setting of the ECN threshold and the dynamic updating of the ECN threshold. The initial setting of the ECN threshold can be understood as the process of configuring the ECN threshold when the network device is first powered on, such as... Figure 2 As shown, the following steps may be included:
[0098] Step 201: Obtain the size of the on-chip cache and off-chip cache of the network node.
[0099] Here, the network device is taken as the Juniper QFX5210 switch, which supports 64 full-duplex 100Gbps ports, that is, the rated bandwidth of each port is 100Gbps; the on-chip cache space is 42MB (i.e., on-chip cache size), and the DRAM cache space is 16GB (i.e., off-chip cache size).
[0100] Step 202: Obtain the RTT of neighboring nodes and calculate the ratio R of the BDP of each port to the total BDP of available ports.
[0101] Here, the neighbor node RTT can be obtained through configuration files. For example, the RTT set inside the data center can be determined to be 10us based on the configuration file, and the RTT set in the wide area network can be 50ms. Alternatively, the minimum RTT of the adjacent network node can be obtained through probe packets, such as sending a ping packet from the outgoing interface to obtain the RTT from the outgoing interface to the next hop node.
[0102] The bandwidth-delay product (BDP) for each port of the network device is obtained by multiplying the rated bandwidth and round-trip time of each port. The total bandwidth-delay product (BDP) is obtained by summing the BDPs of all ports of the network device. sum Then, the proportional coefficient R of each port can be calculated, which can be done using the following formula (1):
[0103] R = BDP single / BDP sum (1)
[0104] Where R is the proportion of port BDP to the total BDP of the network node, BDP singleIt is a single-port BDP. sum It is the total BDP on network nodes or switching chips.
[0105] Step 203: Calculate the ECN threshold of the message buffer queue based on the configuration and formula.
[0106] For example, the ECN threshold can be calculated using the following formula (2):
[0107] T≤R*(α*(bf1-BDP sum )+β*bf2) / q (2)
[0108] Where T is the ECN threshold of the message buffer queue of the target port, R is the scaling factor of the target port, bf1 is the first buffer space parameter, and BDP is the first buffer space parameter. sum is the sum of the bandwidth-delay products of all network ports of the network device, bf2 is the second buffer space parameter, α is the first adjustment coefficient, β is the second adjustment coefficient, and q is the number of queues supported by the target port.
[0109] For example, the ECN configuration module can be obtained based on the type of congestion control algorithm, thereby determining the number of parameters for the ECN threshold, and calculating each ECN threshold according to formula (2). For example, for the DCTCP congestion control algorithm, the number of ECN thresholds used is 1, that is, Kmin = Kmax = K, Pmax = 1, K is the ECN threshold of the queue, Kmax is the upper limit of the threshold, Kmin is the lower limit of the threshold, P is the congestion marking rate or packet loss rate, and Pmax is the maximum congestion marking probability; for the DCQCN congestion control algorithm, the number of ECN thresholds used is 2, that is, Kmax and Kmin are different, and the ratio values can be set and combined with formula (2) to calculate Kmax and Kmin. For example, Kmax = T, Kmin = 0.2T, and the above ratio values can be defined by the ECN configuration template.
[0110] For example, the first adjustment coefficient and / or the second adjustment coefficient of each type of message buffer queue can be configured based on the type of message buffer queue supported by the target port, so that the ECN thresholds of different types of message buffer queues are different.
[0111] In one application example, a network device has 32 100Gbps ports, 42MB of on-chip cache, 16GB of DRAM, and a total BDP of 134.22KB*32 for the ports. Using only the on-chip cache, the ECN threshold is calculated using the above formulas (1) and (2) as shown in Table 1 below:
[0112] Table 1
[0113] Export bandwidth RTT BDP ECN threshold (α = 1, β = 0, q = 8) 100Gbps 10us 134.22KB ≤147.28KB
[0114] In another application example, a network device has 32 100Gbps ports, 42MB of on-chip cache, 16GB of DRAM, and a total BDP of 13.42MB*32 for the ports. Using the on-chip cache and off-chip cache, the ECN threshold is calculated using the above formulas (1) and (2) as shown in Table 2 below:
[0115] Table 2
[0116] Export bandwidth RTT BDP ECN threshold (α = 1, β = 0.2, q = 8) 100Gbps 10ms 13.42MB ≤11.29MB
[0117] Step 204: Set the ECN threshold for the message buffer queue.
[0118] Here, specific ECN thresholds can be configured for the corresponding message buffer queues. It's also understandable that desired parameters for the message buffer queues can be configured, such as setting the expected average packet queuing latency and the expected transmission rate of the port based on the ECN threshold.
[0119] It is understood that different ECN thresholds can be set for different message buffer queues in this application embodiment. For example, a smaller α coefficient can be selected to calculate a smaller ECN threshold value to ensure low latency and low packet loss rate in the mouse stream; a larger α coefficient can be selected to calculate a larger ECN threshold value to ensure the high throughput requirements of the elephant stream.
[0120] In this application embodiment, refer to Figure 3 Dynamic updates to the ECN threshold can include the following steps:
[0121] Step 301: Determine whether the neighboring nodes have changed. If yes, proceed to steps 302 to 304. If no, proceed to steps 305 to 306.
[0122] Here, the network detection module can periodically detect whether the neighboring nodes of the network device have changed. If so, the round-trip time between each port of the network device and the neighboring nodes is reacquired. Based on the reacquired round-trip time, the proportional coefficient of each port of the network device and the proportional coefficient of the target port of the network device based on the rated bandwidth and the round-trip time of each port of the network device are calculated, and the ECN threshold of the message buffer queue of the target port is determined based on the cache space parameters and the target port of the network device. That is, steps 302 to 304 are executed. If not, the transmission rate of the target port and the average queuing delay of the data packets in the message buffer queue are acquired. Based on the transmission rate, the average queuing delay of the data packets and the expected parameters, the ECN threshold of the message buffer queue of the target port is updated. That is, steps 305 and 306 are executed.
[0123] Step 302: Obtain the RTT of neighboring nodes and calculate the ratio R of the BDP of each port to the total BDP of available ports.
[0124] Here, the proportional coefficient R of each port can be calculated using the aforementioned formula (1), and the specific details can be found in the aforementioned description, which will not be repeated here.
[0125] Step 303: Calculate the ECN threshold of the message buffer queue based on the configuration and the first formula.
[0126] Here, the first formula is the aforementioned formula (2). The specific process of calculating the ECN threshold can be referred to the aforementioned description, and will not be repeated here.
[0127] Step 304: Set the ECN threshold and expected parameters for the message buffer queue.
[0128] Here, the ECN threshold setting module can configure specific ECN thresholds to the corresponding message buffer queues. It can also be understood that desired parameters for the message buffer queues can be configured, such as the desired average packet queuing delay and the desired transmission rate of the port based on the ECN threshold.
[0129] Step 305: Calculate the ECN threshold of the message buffer queue based on the port's transmission rate, the average queuing delay of the message buffer queue, and the expected parameters.
[0130] Here, the network detection module can collect the transmission rate of the outgoing interface and the average queuing delay of data packets in the message buffer queue, and calculate the ECN threshold of the message buffer queue based on the transmission rate of the port (i.e., the outgoing interface), the average queuing delay of data packets in the message buffer queue, and the expected parameters.
[0131] For example, the aforementioned update adjustment value can be calculated using the following formula (3):
[0132]
[0133] Where f is the update adjustment value, and the value of f ranges from [-1, 1]; txR is the transmission rate of the output interface. Dq represents the desired transmission rate; Dq represents the average queuing delay of data packets in the message buffer queue. The desired average queuing delay is defined by w1, where w1 is the proportional weight for throughput and w2 is the proportional weight for queuing delay. w1 + w2 = 1, and network devices can set these values according to their needs. For example, it is recommended to use w1 = 0.7 and w2 = 0.3 in throughput-sensitive networks and w1 = 0.3 and w2 = 0.7 in latency-sensitive networks.
[0134] The threshold increment value is obtained as shown in the following formula (4):
[0135] △T=f*T (4)
[0136] Where △T is the threshold increment value, and T is the current ECN threshold;
[0137] The ECN threshold is updated using the following formula (5):
[0138] T curr =γ*T+(1-γ)△T (5)
[0139] Among them, T curr The updated ECN threshold is γ, which is the weight value and its range is [0,1].
[0140] Step 306: Update the ECN threshold of the message buffer queue.
[0141] It is understood that the method of this application embodiment can configure and update the ECN threshold of the message buffer queue of the network device port according to the network status. When the network device is powered on for the first time, the ECN threshold can be calculated according to the aforementioned formulas (1) and (2); during periodic updates, if the neighboring nodes in the network have not changed, the ECN threshold of the message buffer queue can be updated according to the aforementioned formulas (3) to (5); if the neighboring nodes in the network have changed, the ECN threshold needs to be recalculated according to the aforementioned formulas (1) and (2).
[0142] To implement the method of this application embodiment, this application embodiment also provides a display congestion notification threshold configuration device, which corresponds to the above-described display congestion notification threshold configuration method. The steps in the above-described display congestion notification threshold configuration method embodiment are also fully applicable to this display congestion notification threshold configuration device embodiment.
[0143] like Figure 4As shown, the congestion notification threshold configuration device includes: an acquisition module 401, a calculation module 402, and a threshold determination module 403. The acquisition module 401 acquires configuration parameters and network performance parameters of the network device. The configuration parameters include at least the cache space parameters of the switching chip of the network device and the rated bandwidth of each port of the network device. The network performance parameters include at least the round-trip latency between each port of the network device and its neighboring nodes. The calculation module 402 calculates a proportionality coefficient for each port of the network device based on the rated bandwidth and round-trip latency of each port. The proportionality coefficient represents the ratio of the bandwidth-delay product of a single port to the sum of the bandwidth-delay products of all network ports of the network device. The threshold determination module 403 determines the ECN threshold of the message buffer queue of the target port based on the cache space parameters and the proportionality coefficient of the target port of the network device. The target port is any port of the network device.
[0144] For example, the cache space parameters include: a first cache space parameter characterizing the size of the on-chip cache space of the switching chip and a second cache space parameter characterizing the size of the off-chip cache space of the switching chip. The threshold determination module 403 is specifically used for:
[0145] Calculate the difference between the first cache space parameter and the sum of the bandwidth-delay products of all network ports of the network device;
[0146] The difference and the second cache space parameter are weighted and summed to obtain a sum value; wherein the weight of the difference is a first adjustment coefficient, and the weight of the second cache space parameter is a second adjustment coefficient;
[0147] Based on the scaling factor, the summation value, and the number of queues supported by the target port, the ECN threshold of the message buffer queue of the target port is determined.
[0148] For example, before determining the ECN threshold of the message buffer queue of the target port based on the cache space parameters and the proportional coefficient of the target port of the network device, the threshold determination module 403 is further configured to:
[0149] Based on the type of message buffer queue supported by the target port, configure the first adjustment coefficient and / or the second adjustment coefficient of each type of message buffer queue so that the ECN threshold of different types of message buffer queues is different.
[0150] For example, the threshold determination module 403 determines the ECN threshold of the message buffer queue of the target port based on the proportional coefficient, the summation value, and the number of queues supported by the target port, including:
[0151] Obtain the ECN configuration template based on the type of congestion control algorithm;
[0152] Based on the proportional coefficient, the summation value, the number of queues supported by the target port, and the ECN configuration template, the ECN threshold of the message buffer queue of the target port is determined.
[0153] For example, the congestion notification threshold configuration device further includes: a network detection module 404, used to periodically detect whether the neighbor nodes of the network device have changed based on a set time interval; if so, control the acquisition module 401 to reacquire the round-trip time between each port of the network device and the neighbor nodes, and control the calculation module 402 to perform the calculation of the proportional coefficient of each port of the network device based on the reacquired round-trip time and the rated bandwidth and round-trip time of each port of the network device; and control the threshold determination module 403 to determine the ECN threshold of the message buffer queue of the target port based on the cache space parameters and the proportional coefficient of the target port of the network device.
[0154] For example, the network detection module 404 is further configured to, if it is determined that the neighbor nodes of the network device have not changed, obtain the transmission rate of the target port and the average queuing delay of the data packets in the message buffer queue; and control the threshold determination module 403 to update the ECN threshold of the message buffer queue of the target port based on the transmission rate and the average queuing delay of the data packets.
[0155] For example, the threshold determination module 403 updates the ECN threshold of the message buffer queue of the target port based on the transmission rate and the average queuing delay of the data packets, including:
[0156] Based on the transmission rate, the average queuing delay of the data packets, the preset expected transmission rate, and the preset expected average queuing delay of the data packets, an update adjustment value is obtained;
[0157] Multiply the updated adjustment value by the current ECN threshold value to obtain the threshold increment value;
[0158] The current ECN threshold and the threshold increment are weighted and summed, and the weighted sum is used as the updated ECN threshold.
[0159] For example, the threshold determination module 403 calculates an update adjustment value based on the transmission rate, the average queuing delay of data packets, a preset expected transmission rate, and a preset expected average queuing delay of data packets, including:
[0160] Based on the transmission rate and the preset desired transmission rate, a first adjustment value is generated;
[0161] A second adjustment value is generated based on the average queuing delay of the data packets and the preset expected average queuing delay of the data packets;
[0162] The first adjustment value and the second adjustment value are weighted and summed to obtain the updated adjustment value;
[0163] Wherein, the sum of the weight values of the first adjustment value and the second adjustment value is 1, and the weight values of the first adjustment value and the second adjustment value correspond to the type of the message buffer queue.
[0164] In practical applications, the acquisition module 401, calculation module 402, threshold determination module 403, and network detection module 404 can be implemented by the processor in the network device. Of course, the processor needs to run the computer program in memory to implement its functions.
[0165] It should be noted that the above embodiments of the display congestion notification threshold configuration device are only illustrated by the division of the above-described program modules. In practical applications, the above processing can be assigned to different program modules as needed, that is, the internal structure of the device can be divided into different program modules to complete all or part of the processing described above. Furthermore, the display congestion notification threshold configuration device and the display congestion notification threshold configuration method embodiments provided above belong to the same concept, and their specific implementation process is detailed in the method embodiments, which will not be repeated here.
[0166] Based on the hardware implementation of the above program modules, and in order to implement the method of the embodiments of this application, the embodiments of this application also provide a network device. Figure 5 This is only an exemplary structure of the network device, not the entire structure; implementation is possible as needed. Figure 5 The structure shown may be part or all of the structure.
[0167] like Figure 5 As shown, the network device 500 provided in this embodiment includes at least one processor 501, a memory 502, a user interface 503, and at least one network interface 504. The various components in the network device 500 are coupled together via a bus system 505. It can be understood that the bus system 505 is used to implement communication between these components. In addition to a data bus, the bus system 505 also includes a power bus, a control bus, and a status signal bus. However, for clarity, in… Figure 5 The general designated all buses as Bus System 505.
[0168] The user interface 503 may include a monitor, keyboard, mouse, trackball, click wheel, buttons, touchpad, or touch screen.
[0169] The memory 502 in this embodiment is used to store various types of data to support the operation of the network device. Examples of such data include any computer program used to operate on the network device.
[0170] The display congestion notification threshold configuration method disclosed in this application can be applied to or implemented by the processor 501. The processor 501 may be an integrated circuit chip with signal processing capabilities. During implementation, each step of the display congestion notification threshold configuration method can be completed by integrated logic circuits in the hardware of the processor 501 or by instructions in software form. The processor 501 can be a general-purpose processor, a digital signal processor (DSP), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The processor 501 can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of this application. The general-purpose processor can be a microprocessor or any conventional processor, etc. The steps of the method disclosed in the embodiments of this application can be directly manifested as execution by a hardware decoding processor, or execution by a combination of hardware and software modules in the decoding processor. The software modules can be located in a storage medium, specifically memory 502. The processor 501 reads information from memory 502 and, in conjunction with its hardware, completes the steps of the display congestion notification threshold configuration method provided in the embodiments of this application.
[0171] In an exemplary embodiment, the network device may be implemented by one or more application-specific integrated circuits (ASICs), DSPs, programmable logic devices (PLDs), complex programmable logic devices (CPLDs), field-programmable gate arrays (FPGAs), general-purpose processors, controllers, microcontrollers (MCUs), microprocessors, or other electronic components to perform the aforementioned methods.
[0172] It is understood that memory 502 can be volatile memory or non-volatile memory, or both. Non-volatile memory can be read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), ferromagnetic random access memory (FRAM), flash memory, magnetic surface memory, optical disc, or compact disc read-only memory (CD-ROM); magnetic surface memory can be disk storage or magnetic tape storage. Volatile memory can be random access memory (RAM), which is used as an external cache. By way of example, but not limitation, many forms of RAM are available, such as Static Random Access Memory (SRAM), Synchronous Static Random Access Memory (SSRAM), Dynamic Random Access Memory (DRAM), Synchronous Dynamic Random Access Memory (SDRAM), Double Data Rate Synchronous Dynamic Random Access Memory (DDRSDRAM), Enhanced Synchronous Dynamic Random Access Memory (ESDRAM), Sync Link Dynamic Random Access Memory (SLDRAM), and Direct Rambus Random Access Memory (DRRAM).The memories described in the embodiments of this application are intended to include, but are not limited to, these and any other suitable types of memories.
[0173] In an exemplary embodiment, this application also provides a computer storage medium, specifically a computer-readable storage medium, such as a memory 502 storing a computer program, which can be executed by the processor 501 of the network device 500 to complete the steps described in the method of this application embodiment. The computer-readable storage medium can be a ROM, PROM, EPROM, EEPROM, Flash Memory, magnetic surface memory, optical disc, or CD-ROM, etc.
[0174] In an exemplary embodiment, this application also provides a computer program product, including a computer program that can be executed by the processor 501 of the network device 500 to perform the steps described in the method of this application embodiment.
[0175] It should be noted that terms such as "first" and "second" are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence.
[0176] Furthermore, the technical solutions described in the embodiments of this application can be combined arbitrarily without conflict.
[0177] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A method for display of Explicit Congestion Notification, ECN, threshold configuration, characterized by The method comprises: obtaining configuration parameters and network performance parameters of a network device, wherein the configuration parameters at least include buffer space parameters of a switch chip of the network device and rated bandwidths of ports of the network device, and the network performance parameters at least include round-trip delays between the ports of the network device and neighbor nodes; calculating proportion coefficients of the ports of the network device based on the rated bandwidths of the ports of the network device and the round-trip delays, wherein the proportion coefficients represent ratios of bandwidth-delay products of individual ports to a sum of bandwidth-delay products of all network ports of the network device; determining an ECN threshold of a message buffer queue of a target port of the network device based on the buffer space parameters and the proportion coefficient of the target port, wherein the target port is any port of the network device.
2. The method of claim 1, wherein, The buffer space parameters comprise a first buffer space parameter representing an in-chip buffer space size of the switch chip and a second buffer space parameter representing an off-chip buffer space size of the switch chip, and the determining of the ECN threshold of the message buffer queue of the target port based on the buffer space parameters and the proportion coefficient of the target port comprises: calculating a difference between the first buffer space parameter and a sum of bandwidth-delay products of all network ports of the network device; performing weighted summation on the difference and the second buffer space parameter to obtain a summation value, wherein a weight value of the difference is a first adjustment coefficient, and a weight value of the second buffer space parameter is a second adjustment coefficient; determining the ECN threshold of the message buffer queue of the target port based on the proportion coefficient, the summation value, and a number of queues supported by the target port.
3. The method of claim 2, wherein, Before the determining of the ECN threshold of the message buffer queue of the target port based on the buffer space parameters and the proportion coefficient of the target port, the method further comprises: configuring the first adjustment coefficient and / or the second adjustment coefficient of each type of message buffer queue based on a type of message buffer queue supported by the target port, so that ECN thresholds of different types of message buffer queues are different.
4. The method of claim 2, wherein, The determining of the ECN threshold of the message buffer queue of the target port based on the proportion coefficient, the summation value, and the number of queues supported by the target port comprises: obtaining an ECN configuration template based on a type of congestion control algorithm; determining the ECN threshold of the message buffer queue of the target port based on the proportion coefficient, the summation value, the number of queues supported by the target port, and the ECN configuration template.
5. The method of claim 1, wherein, The method further comprises: periodically detecting whether neighbor nodes of the network device change based on a set time length; If yes, the round-trip time between each port of the network device and a neighbor node is re-acquired, and based on the re-acquired round-trip time, the ECN threshold of the message buffer queue of the target port is updated based on the transmission rate and the average packet queuing delay of the message buffer queue.
6. The method of claim 5, wherein, The method further comprises: If no, the transmission rate of the target port and the average packet queuing delay of the message buffer queue are acquired, and the ECN threshold of the message buffer queue of the target port is updated based on the transmission rate and the average packet queuing delay.
7. The method of claim 6, wherein, The updating of the ECN threshold of the message buffer queue of the target port based on the transmission rate and the average packet queuing delay comprises: an update adjustment value is obtained based on the transmission rate, the average packet queuing delay, a preset expected transmission rate and a preset expected average packet queuing delay; the update adjustment value is multiplied by a current ECN threshold value to obtain a threshold increment value; a weighted sum of the current ECN threshold and the threshold increment value is obtained, and the weighted sum result is taken as an updated ECN threshold.
8. The method of claim 7, wherein, The obtaining of the update adjustment value based on the transmission rate, the average packet queuing delay, a preset expected transmission rate and a preset expected average packet queuing delay comprises: a first adjustment value is generated based on the transmission rate and a preset expected transmission rate; a second adjustment value is generated based on the average packet queuing delay and a preset expected average packet queuing delay; a weighted sum of the first adjustment value and the second adjustment value is obtained to obtain an update adjustment value; wherein the sum of the weight value of the first adjustment value and the weight value of the second adjustment value is 1, and the weight value of the first adjustment value and the weight value of the second adjustment value correspond to the type of the message buffer queue.
9. A device for configuring congestion notification (ECN) thresholds, characterized in that, comprise: a obtaining module configured to obtain configuration parameters and network performance parameters of a network device, the configuration parameters at least including a buffer space parameter of a switch chip of the network device and a rated bandwidth of each port of the network device, and the network performance parameters at least including a round-trip time between each port of the network device and a neighbor node; a calculating module configured to calculate a proportionality coefficient of each port of the network device based on the rated bandwidth of each port of the network device and the round-trip time; a threshold determining module configured to determine an ECN threshold of a message buffer queue of a target port based on the buffer space parameter and the proportionality coefficient of the target port, the target port being any port of the network device.
10. A network device, comprising: comprise: a processor and a memory for storing a computer program capable of running on the processor, wherein the processor is configured to execute the computer program to perform the steps of the method of any one of claims 1 to 8.
11. A computer storage medium having stored thereon a computer program, characterized in that The computer program, which is executed by a processor, implements the steps of the method according to any one of claims 1 to 8.
12. A computer program product comprising a computer program, characterized in that, The computer program, which is executed by a processor, implements the steps of the method according to any one of claims 1 to 8.
Citation Information
Patent Citations
Congestion processing method, network equipment and storage medium
CN113810309A
Congestion threshold determination method and device, equipment and storage medium
CN114070795A