Method and device for controlling congestion in host based on RDMA (Remote Direct Memory Access)
By sending periodic detection packets and monitoring confirmation packets in the RDMA network, combined with bandwidth allocation tools, the problem of difficulty in capturing and reflecting congestion signals in the host in the existing technology is solved, and effective congestion control and bandwidth optimization within the host are achieved, improving improve network performance.
Patent Information
- Application Number
- CN202410837439.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-26
- Publication Date
- 2024-09-13
- Estimated Expiration
- 2044-06-26
AI Technical Summary
The existing technology cannot effectively capture the congestion signal within the host, resulting in the congestion signal being difficult to directly reflect the actual situation. There is a lack of timely response and long feedback delay, and congestion control cannot be effectively implemented. In addition, the bandwidth allocation tool within the host does not support complex allocation functions, which increases The difficulty of bandwidth resource allocation makes it impossible to provide comprehensive and flexible bandwidth allocation and congestion control strategies.
Runs on the sender side of the remote direct memory access network, monitors receiver latency and traffic congestion signals by sending periodic probe packets and receiving return probe acknowledgment packets, calculates receive rate and send rate, and uses bandwidth allocation tools to reduce CPU memory bandwidth , and allocate the remaining bandwidth to the network card to achieve congestion control within the host.
It achieves timely transmission and reflection of congestion signals within the host. By adjusting the sending rate and bandwidth allocation, it effectively controls congestion within the host, optimizes network resource utilization and application performance, and avoids waste of available bandwidth.
Smart Images

Figure CN118646707A
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of network transmission control, and in particular to a method and device for controlling congestion in a host based on RDMA. Background Art
[0002] In recent years, Remote Direct Memory Access (RDMA) has been widely deployed in data centers to provide high-speed network services for applications such as machine learning, storage, and high-performance computing. Modern data center servers are usually equipped with RDMA network cards (RNICs), which are interconnected with memory controllers, integrated I / O controllers (IIOs), and cache / host agents (CHA) through a grid to form a complex intra-host network. In the RDMA network, data packets no longer pass through the CPU core, but are transmitted from the RDMA network card to the integrated I / O controller and then enter the memory controller through the grid architecture. In order to meet the growing network transmission needs, the intra-host network can provide sufficient bandwidth and lossless interconnection structure, so as to achieve continuous high-performance network transmission. However, since RNIC traffic cannot obtain sufficient available memory bandwidth when competing with the traffic of the central processor, it causes traffic congestion in the host.
[0003] In the prior art, since the congestion signal is usually far away from the actual congestion point and the network in the host has a lossless characteristic, the existing congestion control scheme fails to effectively capture the congestion signal in the host, making it difficult for the congestion signal to directly reflect the actual congestion situation. At the same time, there is a lack of effective host response and the feedback delay is long, and effective congestion control methods cannot be taken in time to control the congestion in the host. In addition, the existing host bandwidth allocation tool does not support complex allocation functions, which increases the difficulty of bandwidth resource allocation. When dealing with complex and changeable host congestion situations, the existing scheme fails to provide a comprehensive and flexible bandwidth allocation and congestion control strategy, and cannot fully optimize network resource utilization and application performance. Summary of the invention
[0004] In view of this, an embodiment of the present invention provides a host congestion control method and device based on RDMA to eliminate or improve one or more defects in the prior art and solve the problem that the prior art cannot adopt a congestion control method in time according to the congestion signal.
[0005] One aspect of the present invention provides a host-based congestion control method based on RDMA, the method is run on a sending end of a remote direct memory access network, and the method comprises the following steps:
[0006] Sending a periodic detection packet to the receiving end at a set interval, and receiving a return detection confirmation packet; the periodic detection packet and the return detection confirmation packet are transmitted between the sending end and the receiving end by recording a unique identifier, and are marked with a timestamp for calculating the delay of the receiving end;
[0007] Receiving a host traffic congestion signal transmitted by the receiving end through a returned detection confirmation packet; the host traffic congestion signal is generated when the receiving end detects that the occupancy value of the local integrated I / O controller buffer is higher than a set threshold;
[0008] Calculate the current receiving end delay according to the periodic detection packet and the returned detection confirmation packet, and calculate the current receiving end receiving rate in combination with the receiving end delay at the previous moment, the target delay and the receiving end receiving rate at the previous moment;
[0009] Calculating an alternative sending rate based on a preset congestion control algorithm, and taking the smaller of the alternative sending rate and the current receiving end receiving rate as the target sending rate of the sending end;
[0010] The host traffic congestion signal is also used to instruct the receiving end to reduce the available memory bandwidth in the central processing unit through a bandwidth allocation tool, and allocate the remaining available bandwidth to the network card of the receiving end for executing congested data caching.
[0011] In some embodiments, calculating the current receiving end delay according to the periodic detection packet and the returned detection confirmation packet includes:
[0012] Record the timestamp of the periodic detection packet received by the receiving end and the timestamp of the return detection confirmation packet sent by the receiving end; the timestamp of the periodic detection packet is used to mark the time Ts when the receiving end receives the periodic detection packet, and the timestamp of the return detection confirmation packet is used to mark the time Tr when the receiving end sends the return detection confirmation packet;
[0013] Calculate the current receiving end delay D according to the sending time and the receiving time cur , the expression is:
[0014] D cur =Tr-Ts.
[0015] In some embodiments, according to the current receiving end delay D cur , the receiving end delay at the last moment D old , target delay D thr and the receiving rate R at the previous moment ′ rev Calculate the current receiving end receiving rate R rev , the expression is:
[0016] R rev =R ′ rev ×[1-α×(D cur -D thr )-β×(D cur -D old )];
[0017] Among them, α and β are set parameters.
[0018] In some embodiments, the host traffic congestion signal is generated when the receiving end detects that the occupancy value of the local integrated I / O controller buffer is higher than a set threshold, and the performance data is obtained by reading the register set in the central processing unit, and the average value of the performance data is calculated and smoothed to obtain the occupancy value of the local integrated I / O controller buffer.
[0019] In some embodiments, a historical data analysis method is used to analyze the occupancy of the local integrated I / O controller buffer under different loads based on historical traffic data and set an occupancy value threshold, or a real-time monitoring method is used to monitor traffic characteristics in real time and set the occupancy value threshold of the local integrated I / O controller buffer based on traffic changes.
[0020] In some embodiments, reducing the available memory bandwidth within the central processing unit through a bandwidth allocation tool includes: using the bandwidth allocation tool to configure multiple service levels for the central processing unit core and reducing the available memory bandwidth within the central processing unit to a limited available memory bandwidth set according to each service level, wherein the limited available memory bandwidth is obtained by directly setting the size of the limited available memory bandwidth or setting the percentage of the limited available memory bandwidth to the total bandwidth.
[0021] In some embodiments, the method further comprises: storing status and performance data during the intra-host congestion signal transmission, the target sending rate adjustment, and the available bandwidth allocation as a log.
[0022] On the other hand, the present invention also provides a host congestion control device, including a processor, a memory and a computer program / instructions stored in the memory, wherein the processor is used to execute the computer program / instructions, and when the computer program / instructions are executed, the device implements the steps of the above method.
[0023] On the other hand, the present invention further provides a computer-readable storage medium having a computer program stored thereon, which implements the steps of the above method when executed by a processor.
[0024] On the other hand, the present invention also provides a computer program product, comprising a computer program / instruction, which implements the steps of the above method when executed by a processor.
[0025] The beneficial effects of the present invention are at least:
[0026] In the RDMA-based host congestion control method and device described in the present invention, when the receiving end detects the generation of a congestion signal, the sending end can promptly transmit the host congestion signal obtained by the receiving end to the sending end by sending the periodic detection packet and receiving the return detection confirmation packet, obtain the current receiving end delay through the timestamps of the periodic detection packet and the return detection confirmation packet, and calculate the current receiving end reception rate based on the current receiving end delay, the receiving end delay at the previous moment, the target delay and the receiving end reception rate at the previous moment, obtain the target transmission rate that the sending end needs to adjust to achieve in the current congestion situation based on the current receiving end reception rate and the alternative transmission rate, and take effective methods in time to achieve host congestion control.
[0027] Furthermore, the present invention uses the bandwidth allocation tool to configure multiple service levels for the central processing unit core and sets limits on available memory bandwidth according to each service level, flexibly adjusts the limits on available memory bandwidth and uses them as a standard for reducing the available memory bandwidth of the central processing unit, and at the same time allocates bandwidth according to priority, and allocates the remaining available bandwidth to the network card to ensure that the central processing unit and the network card obtain the required available bandwidth and avoid waste of available bandwidth.
[0028] Additional advantages, purposes, and features of the present invention will be described in part in the following description, and will become apparent to those skilled in the art after studying the following, or may be learned from the practice of the present invention. The purposes and other advantages of the present invention may be achieved and obtained by the structures specifically indicated in the specification and the accompanying drawings.
[0029] Those skilled in the art will appreciate that the objectives and advantages that can be achieved with the present invention are not limited to the above specific description, and the above and other objectives that can be achieved by the present invention will be more clearly understood from the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] The drawings described herein are used to provide a further understanding of the present invention, constitute a part of the present application, and do not constitute a limitation of the present invention. In the drawings:
[0031] Figure 1 The present invention is a flowchart of a method for controlling congestion in a host based on RDMA according to an embodiment of the present invention.
[0032] Figure 2The present invention is a schematic diagram of the structure of a method for controlling congestion in a host based on RDMA according to an embodiment of the present invention. DETAILED DESCRIPTION
[0033] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the embodiments and the accompanying drawings. Here, the illustrative embodiments of the present invention and their descriptions are used to explain the present invention, but are not intended to limit the present invention.
[0034] It should also be noted that, in order to avoid obscuring the present invention due to unnecessary details, only structures and / or processing steps closely related to the solutions according to the present invention are shown in the accompanying drawings, while other details that are not closely related to the present invention are omitted.
[0035] It should be emphasized that the term “include / comprises” when used herein refers to the presence of features, elements, steps or components, but does not exclude the presence or addition of one or more other features, elements, steps or components.
[0036] It should also be noted that, unless otherwise specified, the term “connection” herein may refer not only to a direct connection but also to an indirect connection involving an intermediate.
[0037] Hereinafter, embodiments of the present invention will be described with reference to the accompanying drawings. In the accompanying drawings, the same reference numerals represent the same or similar components, or the same or similar steps.
[0038] The congestion control method in the prior art fails to effectively capture the congestion signal in the host, making it difficult for the congestion signal to directly reflect the actual congestion situation. At the same time, there is a lack of effective host response and the feedback delay is long, so it is impossible to take effective congestion control methods in time to control the congestion in the host. In addition, the existing host bandwidth allocation tool does not support complex allocation functions, which increases the difficulty of bandwidth resource allocation. The existing congestion control method fails to provide a comprehensive and flexible bandwidth allocation and congestion control strategy when dealing with complex and changeable host congestion situations. The present invention proposes a host congestion control method and device based on RDMA. The method is executed based on the sending end of the remote direct memory access network. The receiving end sends a periodic detection packet to the receiving end and receives the return detection confirmation packet and the host traffic congestion signal transmitted by it. The current receiving end receiving rate is calculated according to the current receiving end delay, the receiving end delay at the last moment, the target delay and the receiving end receiving rate at the last moment. After comparing the current receiving end receiving rate with the alternative sending rate, the target sending rate to which the sending end sending rate needs to be adjusted is obtained, and the bandwidth allocation tool is used to reduce the available memory bandwidth of the central processing unit and allocate the remaining available bandwidth to the network card.
[0039] Figure 1The present invention is a flowchart of a method for controlling congestion in a host based on RDMA according to an embodiment of the present invention. Specifically, the present invention provides a method for controlling congestion in a host based on RDMA, which is run on a sending end of a remote direct memory access network, and includes the following steps S101 to S105:
[0040] Step S101: Send periodic detection packets to the receiving end at a set interval, and receive return detection confirmation packets; the periodic detection packets and return detection confirmation packets are transmitted between the sending end and the receiving end by recording unique identifiers and marking timestamps for calculating the delay of the receiving end.
[0041] Step S102: receiving the host traffic congestion signal transmitted by the receiving end through the return detection confirmation packet; the host traffic congestion signal is generated when the receiving end detects that the occupancy value of the local integrated I / O controller buffer is higher than the set threshold.
[0042] Step S103: Calculate the current receiving end delay according to the periodic detection packet and the returned detection confirmation packet, and calculate the current receiving end receiving rate in combination with the receiving end delay at the previous moment, the target delay and the receiving end receiving rate at the previous moment.
[0043] Step S104: Calculate an alternative sending rate based on a preset congestion control algorithm, and use the smaller of the alternative sending rate and the current receiving rate of the receiving end as the target sending rate of the sending end.
[0044] The traffic congestion signal within the host is also used to instruct the receiving end to reduce the available memory bandwidth within the central processing unit through a bandwidth allocation tool, and allocate the remaining available bandwidth to the network card of the receiving end for executing congested data caching.
[0045] Specifically, the present invention runs on RDMA (Remote Direct Memory Access), and the network card used is RNIC (RDMA network card). The network card supports RDMA direct transmission between the memories of two computers. In RDMA technology, the network card is located at both ends of data transmission, directly interacts with the computer's memory management system and operating system, and allows data to be directly transmitted between the two computer memories without going through the traditional operating system level copy process, thereby improving transmission efficiency and preventing data from being lost during transmission; when allocating bandwidth, a coarse-grained allocation strategy is adopted and a limit is set on the available memory bandwidth in the central processing unit to allocate the remaining bandwidth to the network card and avoid bandwidth waste.
[0046] In step S101 and step S102, the timestamps marked on the periodic detection packets and the returned detection confirmation packets indicate the sending time of the sender and the receiving time of the return to the sender after being processed by the receiving end. The returned detection confirmation packet indicates that the data packet of the sender has been successfully received and the next data packet can be sent to obtain the status of the receiving end and transmit the traffic congestion signal in the host. When a queue occurs in the buffer of the local integrated I / O controller, the occupancy value of the buffer of the local integrated I / O controller responds to the traffic congestion in the host and accurately and timely reflects the location and scale of the congestion in the host. The queue occurs in the buffer of the local integrated I / O controller because the memory interconnection congestion causes the credit replenishment delay of the memory controller to increase. Credit replenishment is the sender sending a data packet and receiving a data confirmation packet according to the consumption. The act of replenishing the sender's credit according to the credit situation, and then sending a new data packet after replenishment. When the data confirmation packet is not received, it is necessary to wait for the credit replenishment to be completed, and there will be a credit replenishment delay. The credit replenishment delay will affect data transmission, network resource utilization and application performance. Furthermore, the credit replenishment mechanism requires the sender to wait for the receiver to return enough credits to support data transmission before sending a data packet, ensuring that the data during network transmission will not exceed the receiver's data acceptance capacity, avoiding data loss and congestion, and responding to traffic congestion in the host through the occupancy value of the local integrated I / O controller buffer. The occupancy value of the local integrated I / O controller buffer will increase when the memory controller is congested, thereby obtaining the time and location of the host congestion.
[0047] Furthermore, RTT granularity (Round-Trip Time) describes the time of transmission from the sender to the receiver and then back to the sender. The round-trip delay is used to measure the performance of network transmission, which affects the efficiency of data transmission and the quality of network connection. In the present invention, due to network congestion, the time required from the sender to the receiver and from the receiver back to the sender is not equal, that is, the delay in the two directions is not equal. Therefore, the present invention uses sub-RTT granularity and monitors the change of sub-RTT to obtain the network congestion situation, and adjusts the flow and sending rate of the sender according to the fluctuation of sub-RTT, thereby quickly obtaining the network congestion situation and the change of network status.
[0048] In some embodiments, the traffic congestion signal in the host is generated when the receiving end detects that the occupancy value of the local integrated I / O controller buffer is higher than the set threshold value, and the performance data is obtained by reading the register set in the central processor, and the average value of the performance data is calculated and smoothed to obtain the occupancy value of the local integrated I / O controller buffer. In some embodiments, a historical data analysis method is used to analyze the occupancy of the local integrated I / O controller buffer under different loads based on historical traffic data and set an occupancy value threshold, or a real-time monitoring method is used to monitor traffic characteristics in real time and set the occupancy value threshold of the local integrated I / O controller buffer based on traffic changes.
[0049] Specifically, the registers used in the present invention are MSRs (Model Specific Registers). After reading the performance data in the registers, average processing and smoothing processing are performed to obtain more stable and reliable data, thereby obtaining a reliable occupancy value. The average processing can be implemented by simple averaging and moving average, and the smoothing processing can be implemented by exponential moving average and low-pass filter; the threshold needs to be set according to the central processing unit and memory bandwidth of each server; the historical data analysis method is to use traffic data to analyze the occupancy of the local integrated I / O controller buffer under different loads and set the threshold, and the real-time monitoring method is based on real-time monitoring of traffic characteristics and setting corresponding thresholds according to changes.
[0050] Furthermore, in addition to setting the occupancy value threshold of the local integrated I / O controller buffer according to the historical data analysis method and the real-time monitoring method, it can also be set according to network performance indicators, including delay, packet loss rate and throughput. Specifically, when monitoring network delay, if the delay starts to increase significantly, it is necessary to lower the occupancy value threshold of the local integrated I / O controller buffer. When observing the packet loss rate, if the packet loss rate increases, it is necessary to adjust the occupancy value threshold of the local integrated I / O controller buffer. The occupancy value threshold of the local integrated I / O controller buffer is set in combination with the change in throughput.
[0051] In step S103 and step S104, traffic congestion within the host causes delays in the receiving end and affects the timeliness of the receiving end in processing periodic detection packets, resulting in a time delay in returning the detection confirmation packet, thereby obtaining the current receiving end delay and calculating the current receiving rate of the receiving end, thereby comparing it with the selected sending rate to obtain the target transmission rate that the sending end needs to adjust.
[0052] In some embodiments, calculating the current receiving end delay according to the periodic detection packet and the returned detection confirmation packet includes:
[0053] Record the timestamp of the periodic detection packet received by the receiving end and the timestamp of the return detection confirmation packet sent by the receiving end; the timestamp of the periodic detection packet is used to mark the time Ts when the receiving end receives the periodic detection packet, and the timestamp of the return detection confirmation packet is used to mark the time Tr when the receiving end sends the return detection confirmation packet.
[0054] Calculate the current receiving end delay D based on the sending time and receiving time cur , the expression is:
[0055] D cur =Tr-Ts.
[0056] In some embodiments, according to the current receiving end delay D cur , the receiving end delay at the last moment D old , target delay D thr and the receiving rate R at the previous moment ′ rev Calculate the current receiving end receiving rate R rev , the expression is:
[0057] R rev =R ′ rev ×[1-α×(D cur -D thr )-β×(D cur -D old )];
[0058] Among them, α and β are set parameters.
[0059] Specifically, the calculation method of the current receiving end delay can also adopt a processing delay separation algorithm and a TSC (Timestamp Counter) synchronization algorithm. The calculation formula of the current receiving end receiving rate is the update formula of the receiving rate. As time changes, the current receiving end sends changes based on the receiving rate of the receiving end at the previous moment. The alternative sending rate is calculated by a preset congestion control algorithm deployed between hosts. The preset congestion control algorithm includes but is not limited to: DCQCN algorithm, TIMELY algorithm, HPCC algorithm and Swift algorithm. The receiving end adjusts the sending rate according to the calculated target sending rate. The receiving end adjusts the sending rate through the latest network card or data processing unit (DPU). High-performance network cards include ConnectX-6 and ConnectX-7, and data processing units include BlueField-2 DPU and BlueField-3DPU. The latest network card or data processing unit provides a programmable congestion control (PCC) framework. Programmable congestion control can write code and call the programmable congestion control interface to adjust the sending rate of the sender and adjust it to the target sending rate.
[0060] In some embodiments, reducing the available memory bandwidth in the central processing unit through a bandwidth allocation tool includes: using the bandwidth allocation tool to configure multiple service levels for the central processing unit core and reducing the available memory bandwidth in the central processing unit to a limited available memory bandwidth set according to each service level, wherein the limited available memory bandwidth is obtained by directly setting the size of the limited available memory bandwidth or by setting the percentage of the limited available memory bandwidth to the total bandwidth.
[0061] Specifically, the problem of traffic congestion within the host is due to the fact that the network card traffic and the host traffic cannot obtain sufficient bandwidth resources when competing for bandwidth, resulting in traffic congestion within the host. When the host is congested, it is necessary to reduce the available memory bandwidth of the CPU and use the bandwidth allocation tool MBA to allocate the available memory of the CPU and the available memory of the network card. The bandwidth allocation tool binds the CPU core to multiple service levels (COS, Class of Service). The service level is a mechanism used in the network to distinguish different types of traffic and allocate resources. The service level provides bandwidth guarantee for the CPU traffic and the network card traffic, and directly limits the memory bandwidth of COS. The memory bandwidth of COS can be directly limited through the Linux command line at the receiving end. Five levels of restrictions are set for the available memory bandwidth of the CPU traffic. After adjusting the sending rate and allocating memory, the maximum-minimum fairness of the network card traffic is achieved, ensuring that the network card obtains the minimum bandwidth guarantee while avoiding other traffic from occupying too much bandwidth, thereby achieving fair sharing of network resources.
[0062] In some embodiments, the method further comprises storing status and performance data during intra-host congestion signaling, target sending rate adjustment, and available bandwidth allocation as a log.
[0063] On the other hand, the present invention also provides a congestion control device within a host, comprising a processor, a memory, and a computer program / instruction stored in the memory, wherein the processor is used to execute the computer program / instruction, and when the computer program / instruction is executed, the device implements the steps of the above method.
[0064] On the other hand, the present invention further provides a computer-readable storage medium having a computer program stored thereon, which implements the steps of the above method when executed by a processor.
[0065] On the other hand, the present invention also provides a computer program product, comprising a computer program / instruction, which implements the steps of the above method when executed by a processor.
[0066] The present invention is described below in conjunction with a specific embodiment:
[0067] Figure 2 The present invention is a schematic diagram of the structure of a method for controlling congestion in a host based on RDMA according to an embodiment of the present invention. The congestion management mechanism proposed in the present invention aims to solve the problem of internal host traffic congestion in RDMA networks by combining intra-host traffic congestion avoidance and RNIC traffic adjustment at a sub-RTT (Asymmetric Round-Trip Time) granularity. The core technology is that the receiving end continuously monitors the congestion signal IIO Buffer (IIO Buffer, integrated I / O controller buffer) in the host and reasonably allocates resources in the host. At the same time, the sending end periodically sends detection packets and returns detection confirmation packets to obtain the processing delay of the receiving end, and adjusts the sending rate accordingly, and periodically sends detection packets and returns detection confirmation packets to mark timestamps (ts, timestamp). The mechanism is implemented on commercial servers and RNIC devices, and its performance is verified through experiments.
[0068] 1. Host internal traffic congestion response process.
[0069] The host internal traffic congestion response is mainly achieved by monitoring the occupancy of the IIO buffer. The IIO buffer occupancy can accurately and timely reflect the location and scale of the host internal congestion, because the memory interconnect congestion will increase the credit replenishment delay of the memory controller, thereby causing the IIO buffer to queue. The CPU socket is used to insert and fix the CPU.
[0070] 1.1 Monitoring IIO buffer occupancy: Use the specific registers (MSRs) provided by the Intel CPU hardware to monitor the IIO buffer occupancy in real time. Measure the current IIO occupancy value and set a threshold. If the threshold is exceeded, congestion occurs, otherwise, no congestion occurs.
[0071] 1.2 Allocating Resources: Since the standard host internal resource allocation tool does not support complex allocation functions, the present invention adopts a coarse-grained allocation strategy, sets a five-level limit on the available memory bandwidth of the host traffic, and releases the remaining bandwidth to the RNIC traffic. When congestion is detected, the present invention will reduce the available memory bandwidth of the host internal traffic to avoid bandwidth waste. Specifically, the present invention uses the Intel Memory Bandwidth Allocation Tool (MBA) to introduce a delay in memory requests to change the available memory bandwidth of the CPU core, thereby achieving a flexible resource allocation strategy.
[0072] 2. RNIC traffic congestion response process.
[0073] In order to cope with the congestion caused by RNIC traffic, the present invention proposes a traffic adjustment method based on a detection mechanism. The RNIC traffic sender periodically sends a detection packet and calculates the receiving end processing delay through the detection confirmation packet returned by the receiving end. Using this detection mechanism, the sender can dynamically adjust the sending rate to achieve maximum-minimum fairness between RNIC traffic.
[0074] Specifically, each time a new detection confirmation packet is received, the sender measures the processing delay of the receiver, denoted as D cur , and calculate the target delay value, recorded as D thr If the current processing delay exceeds the target delay, it means congestion has occurred. The sender will calculate the applicable rate R of the receiving process based on the current delay and the delay of the previous round. rev .
[0075] R rev =R ′ rev ×[1-α×(D cur -D thr )-β×(D cur -D old )];
[0076] Where D old is the receiving delay at the previous moment, α and β are the set parameters, and finally the sending rate R is adjusted according to the following formula trans .
[0077] R trans =min(Rrev ,R cc );
[0078] R cc is the sending rate calculated by the deployed inter-host congestion control algorithm. In this way, the present invention can transparently support upper layer applications without modifying data packets, while adapting to the congestion control mechanisms deployed in different commercial data centers. The latest network cards and data processing units have been widely deployed, the latest network cards include ConnectX-6 and ConnectX-7, and the data processing units include BlueField-2 and BlueField-3. The programmable functions of these devices can support the implementation and deployment of this mechanism.
[0079] In summary, the present invention provides a host congestion control method and device based on RDMA. The method is executed on the sending end of the remote direct memory access network. The receiving end sends a periodic detection packet to the receiving end and receives the returned detection confirmation packet and the host traffic congestion signal transmitted by it. The current receiving end receiving rate is calculated according to the current receiving end delay, the receiving end delay at the previous moment, the target delay and the receiving end receiving rate at the previous moment. After comparing the current receiving end receiving rate with the alternative sending rate, the target sending rate to which the sending end sending rate needs to be adjusted is obtained. The bandwidth allocation tool is used to reduce the available memory bandwidth of the central processing unit and allocate the remaining available bandwidth to the network card.
[0080] Furthermore, the present invention uses a bandwidth allocation tool to configure multiple service levels for the CPU core and sets limits on available memory bandwidth according to each service level, flexibly adjusts the limits on available memory bandwidth and uses them as a standard for reducing the available memory bandwidth of the CPU, and allocates bandwidth according to priority to ensure that the CPU and the network card obtain the required available bandwidth.
[0081] An embodiment of the present invention further provides a computer device, which may include a processor and a memory, wherein the processor and the memory may be connected via a bus or in other ways.
[0082] The processor may be a central processing unit (CPU). The processor may also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or a combination of the above chips.
[0083] The memory, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs, non-transitory computer executable programs and modules, such as the program instructions / modules corresponding to the key shielding method of the vehicle-mounted display device in the embodiment of the present invention. The processor executes various functional applications and data processing of the processor by running the non-transitory software programs, instructions and modules stored in the memory.
[0084] The memory may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function; the data storage area may store data created by the processor, etc. In addition, the memory may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other non-volatile solid-state storage device. In some embodiments, the memory may optionally include a memory remotely arranged relative to the processor, and these remote memories may be connected to the processor via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0085] The one or more modules are stored in the memory, and when executed by the processor, the method described in this embodiment is performed.
[0086] The embodiment of the present invention also provides a computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a processor, the steps of the aforementioned edge computing server deployment method are implemented. The computer-readable storage medium can be a tangible storage medium, such as a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a floppy disk, a hard disk, a removable storage disk, a CD-ROM, or any other form of storage medium known in the technical field.
[0087] It should be understood by those skilled in the art that the exemplary components, systems and methods described in conjunction with the embodiments disclosed herein can be implemented in hardware, software or a combination of the two. Whether it is performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention. When implemented in hardware, it can be, for example, an electronic circuit, an application specific integrated circuit (ASIC), appropriate firmware, a plug-in, a function card, etc. When implemented in software, the elements of the present invention are programs or code segments used to perform the required tasks. The program or code segment can be stored in a machine-readable medium, or transmitted on a transmission medium or a communication link via a data signal carried in a carrier.
[0088] It should be clear that the present invention is not limited to the specific configuration and processing described above and shown in the figures. For the sake of simplicity, a detailed description of the known method is omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of the present invention is not limited to the specific steps described and shown, and those skilled in the art can make various changes, modifications and additions, or change the order between the steps after understanding the spirit of the present invention.
[0089] In the present invention, features described and / or illustrated for one embodiment may be used in the same or similar manner in one or more other embodiments, and / or combined with features of other embodiments or replace features of other embodiments.
[0090] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the embodiments of the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A host congestion control method based on RDMA, characterized in that: The method is run on a sending end of a remote direct memory access network, and the method comprises the following steps: Sending a periodic detection packet to the receiving end at a set interval, and receiving a return detection confirmation packet; the periodic detection packet and the return detection confirmation packet are transmitted between the sending end and the receiving end by recording a unique identifier, and are marked with a timestamp for calculating the delay of the receiving end; Receiving a host traffic congestion signal transmitted by the receiving end through a returned detection confirmation packet; the host traffic congestion signal is generated when the receiving end detects that the occupancy value of the local integrated I / O controller buffer is higher than a set threshold; Calculate the current receiving end delay according to the periodic detection packet and the returned detection confirmation packet, and calculate the current receiving end receiving rate in combination with the receiving end delay at the previous moment, the target delay and the receiving end receiving rate at the previous moment; Calculating an alternative sending rate based on a preset congestion control algorithm, and taking the smaller of the alternative sending rate and the current receiving end receiving rate as the target sending rate of the sending end; The host traffic congestion signal is also used to instruct the receiving end to reduce the available memory bandwidth in the central processing unit through a bandwidth allocation tool, and allocate the remaining available bandwidth to the network card of the receiving end for executing congested data caching.
2. The RDMA-based host congestion control method according to claim 1, characterized in that: Calculating the current receiving end delay according to the periodic detection packet and the returned detection confirmation packet includes: Record the timestamp of the periodic detection packet received by the receiving end and the timestamp of the return detection confirmation packet sent by the receiving end; the timestamp of the periodic detection packet is used to mark the time Ts when the receiving end receives the periodic detection packet, and the timestamp of the return detection confirmation packet is used to mark the time Tr when the receiving end sends the return detection confirmation packet; Calculate the current receiving end delay D according to the sending time and the receiving time cur , the expression is: D cur =Tr-Ts。 3. The RDMA-based host congestion control method according to claim 1, characterized in that: According to the current receiving end delay D cur , the receiving end delay at the last moment D old , target delay D thr and the receiving rate R at the previous moment ′ rev Calculate the current receiving end receiving rate R rav , the expression is: R rev =R ′ rev ×[1-α×(D cur -D thr )-β×(D cur -D old )]; Among them, α and β are set parameters.
4. The RDMA-based host congestion control method according to claim 1, characterized in that: The host traffic congestion signal is generated when the receiving end detects that the occupancy value of the local integrated I / O controller buffer is higher than the set threshold. The performance data is obtained by reading the register set in the central processing unit, and the average value of the performance data is calculated and smoothed to obtain the occupancy value of the local integrated I / O controller buffer.
5. The RDMA-based host congestion control method according to claim 4, characterized in that: Use a historical data analysis method to analyze the occupancy of the local integrated I / O controller buffer under different loads based on historical traffic data and set an occupancy value threshold, or use a real-time monitoring method to monitor traffic characteristics in real time and set the occupancy value threshold of the local integrated I / O controller buffer based on traffic changes.
6. The RDMA-based host congestion control method according to claim 1, characterized in that: Reducing the available memory bandwidth in the central processing unit by using a bandwidth allocation tool includes: using the bandwidth allocation tool to configure multiple service levels for the central processing unit core, reducing the available memory bandwidth in the central processing unit to a limited available memory bandwidth set according to each service level, and the limited available memory bandwidth is obtained by directly setting the size of the limited available memory bandwidth or setting the percentage of the limited available memory bandwidth to the total bandwidth.
7. The RDMA-based host congestion control method according to claim 1, characterized in that: The method further includes storing status and performance data during the intra-host congestion signaling, the target sending rate adjustment, and the available bandwidth allocation as a log.
8. A congestion control device in a host, comprising a processor, a memory and a computer program / instruction stored in the memory, characterized in that: The processor is used to execute the computer program / instructions. When the computer program / instructions are executed, the device implements the steps of the method according to any one of claims 1 to 7.
9. A computer-readable storage medium having a computer program / instruction stored thereon, characterized in that: When the computer program / instructions are executed by a processor, the steps of the method as claimed in any one of claims 1 to 7 are implemented.
10. A computer program product comprising a computer program / instructions, characterized in that When the computer program / instructions are executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.
Citation Information
Patent Citations
Congestion control method for multi-tenant virtualized network
CN116233008A
Methods and systems for network congestion management
US20200336426A1
Window-based congestion control
US20230123387A1
Cited By
Method and device for relieving built-in congestion based on DRL rate adjustment
CN120512387A
Method and device for accurately relieving host congestion based on DPU
CN122372504A
DPU-based host side delay monitoring method and device
CN122420174A
