Data transmission method, server and storage medium

By obtaining and matching the remote direct memory access protocol information of the current server and the target server, ensuring that both parties to the communication use a consistent protocol, solving the data transmission abnormality caused by inconsistency of the protocol, and achieving the stability and normality of data transmission.

CN119025469AActive Publication Date: 2024-11-26BEIJING BITINTELLIGENCE INFORMATION TECHNOLOGY CO LTD
View PDF 9 Cites 0 Cited by

Patent Information

Application Number
CN202411060610.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-02
Publication Date
2024-11-26
Estimated Expiration
2044-08-02

AI Technical Summary

Technical Problem

The problem of inconsistent remote direct memory access protocol used by both parties in the communication leads to abnormal data transmission.

Method used

By obtaining the remote direct memory access protocol information supported by the current server and the target server, compatible target protocol information is determined, and data transmission is carried out based on the protocol information to ensure that the protocol used by both parties to the communication is consistent.

Benefits of technology

Ensure the normal progress of data transmission, avoid data transmission abnormalities and performance inconsistencies due to protocol incompatibility, and improve the stability of data transmission.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119025469A_ABST
    Figure CN119025469A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of computers, and discloses a data transmission method, a server and a storage medium, and the method comprises the steps: obtaining first protocol information of a remote direct memory access protocol supported by a current server; determining target protocol information based on the first protocol information and matched protocol information in second protocol information of a remote direct memory access protocol supported by the first target server; wherein the target protocol information is determined based on the first protocol information and second protocol information registered by the first target server on the protocol management platform; or the target protocol information is determined by negotiating with the first target server based on the first protocol information; and performing data transmission with the first target server based on a remote direct memory access protocol corresponding to the target protocol information. According to the invention, the problem of abnormal data transmission caused by inconsistency of remote direct memory access protocols used by both communication parties can be solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer technology, and in particular to a data transmission method, a server and a storage medium. Background Art

[0002] Remote Direct Memory Access (RDMA) is an important network protocol that enables high-speed remote access from one computer to the memory of another computer, and this access does not require the central processing unit (CPU) and operating system software of the computers at both ends. RDMA is widely used in data transmission due to its high-speed characteristics.

[0003] In related technologies, in order to improve the performance and availability of the RDMA protocol, improved methods such as packet retransmission algorithms, lossy networks, lossless networks, and congestion control protocols have been proposed. However, these improved methods will change the original RDMA protocol, thus causing protocol compatibility issues. If the RDMA protocols used by the communicating parties are inconsistent, data transmission abnormalities will occur. Summary of the invention

[0004] In view of this, the present invention provides a data transmission method, a server and a storage medium to solve the problem of abnormal data transmission caused by inconsistent remote direct memory access protocols used by two communicating parties.

[0005] In a first aspect, the present invention provides a data transmission method, the method comprising:

[0006] Obtain the first protocol information of the remote direct memory access protocol supported by the current server;

[0007] Determine target protocol information based on the first protocol information and the protocol information that matches the second protocol information of the remote direct memory access protocol supported by the first target server; wherein the target protocol information is determined based on the first protocol information and the second protocol information registered by the first target server in the protocol management platform; or, the target protocol information is determined through negotiation with the first target server based on the first protocol information;

[0008] Data is transmitted with the first target server based on the remote direct memory access protocol corresponding to the target protocol information.

[0009] In a second aspect, the present invention provides a server, comprising: a memory and a processor, the memory and the processor are communicatively connected to each other, computer instructions are stored in the memory, and the processor executes the data transmission method of the first aspect or any corresponding embodiment thereof by executing the computer instructions.

[0010] In a third aspect, the present invention provides a computer-readable storage medium having computer instructions stored thereon, the computer instructions being used to enable a computer to execute the data transmission method of the first aspect or any corresponding embodiment thereof.

[0011] In a fourth aspect, the present invention provides a data transmission device, the device comprising:

[0012] A local protocol acquisition module, used to acquire first protocol information of a remote direct memory access protocol supported by the current server;

[0013] a communication protocol determination module, configured to determine target protocol information based on the first protocol information and the protocol information that matches the second protocol information of the remote direct memory access protocol supported by the first target server; wherein the target protocol information is determined based on the first protocol information and the second protocol information registered by the first target server in the protocol management platform; or, the target protocol information is determined through negotiation with the first target server based on the first protocol information;

[0014] A communication data transmission module is used to perform data transmission with the first target server based on the remote direct memory access protocol corresponding to the target protocol information.

[0015] In a fifth aspect, the present invention provides a computer program product, comprising computer instructions for causing a computer to execute the data transmission method of the first aspect or any corresponding embodiment thereof.

[0016] The data transmission method disclosed in the present invention determines the target protocol information based on the first protocol information of the remote direct memory access protocol supported by the current server and the protocol information matched in the second protocol information of the remote direct memory access protocol supported by the first target server. Then, data is transmitted with the first target server based on the remote direct memory access protocol corresponding to the target protocol information. Therefore, it can ensure that the remote direct memory access protocols used by both parties of the data transmission are consistent, thereby ensuring normal data transmission. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0018] Figure 1 is a flowchart of a first data transmission method according to an embodiment of the present invention;

[0019] Figure 2 is a flow chart of a second data transmission method according to an embodiment of the present invention;

[0020] Figure 3 is a schematic diagram of a first type of data transmission interaction according to an embodiment of the present invention;

[0021] Figure 4 is a flowchart of a third data transmission method according to an embodiment of the present invention;

[0022] Figure 5 is a schematic diagram of interaction of a second type of data transmission according to an embodiment of the present invention;

[0023] Figure 6 is a structural block diagram of a data transmission device according to an embodiment of the present invention;

[0024] Figure 7 is a structural block diagram of a server according to an embodiment of the present invention. DETAILED DESCRIPTION

[0025] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.

[0026] Remote Direct Memory Access (RDMA) is an important network protocol that enables high-speed remote access from one computer to the memory of another computer, and this access does not require the central processing unit (CPU) and operating system software of the computers at both ends. RDMA is widely used in data transmission due to its high-speed characteristics.

[0027] In related technologies, in order to improve the performance and availability of the RDMA protocol, improvement methods such as packet retransmission algorithms, lossy networks, lossless networks, and congestion control protocols have been proposed. However, these improvement methods will bring changes to the original RDMA protocol, thus causing protocol compatibility issues. If the RDMA protocols used by both ends of the communication are inconsistent, data transmission anomalies will occur, for example, data transmission cannot proceed normally, data transmission performance does not meet expectations, or errors that are difficult to troubleshoot occur.

[0028] According to an embodiment of the present invention, a data transmission method embodiment is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0029] In this embodiment, a data transmission method is provided, which can be used in a server. Figure 1 is a flow chart of a data transmission method according to an embodiment of the present invention. Figure 1 As shown, the process includes the following steps:

[0030] Step S101: obtaining first protocol information of a remote direct memory access protocol supported by the current server.

[0031] Specifically, the first protocol information includes the protocol information of the remote direct memory access protocol (hereinafter referred to as RDMA) supported by each network card of the current server. The first protocol information includes the packet retransmission algorithm, whether lossless (also known as lossless) network support is required, the network congestion algorithm, etc. The packet retransmission algorithm includes the Go-Back-N algorithm, the Select_Repeat algorithm, etc. The network congestion algorithm includes the Data Center Quantized Congestion Notification (DCQCN), the round-trip time-based congestion control (Timely), the high-precision congestion control (HPCC), etc.

[0032] Step S102, determining the target protocol information based on the first protocol information and the matching protocol information in the second protocol information of the remote direct memory access protocol supported by the first target server; wherein the target protocol information is determined based on the first protocol information and the second protocol information registered by the first target server on the protocol management platform; or, the target protocol information is determined through negotiation with the first target server based on the first protocol information.

[0033] It should be noted that the matching protocol information refers to the RDMA protocol information that is compatible between the communicating parties. The matching protocol information can be the same or different. For example, the network congestion algorithm V2 supported by the first target server is compatible with both network congestion algorithm V1 and network congestion algorithm V2. If the current server supports network congestion algorithm V1, the current server and the first target server can choose network congestion algorithm V1 for communication.

[0034] Specifically, a centralized protocol management platform can be introduced to store the protocol information of the RDMA protocol supported by the RDMA network card of each server. Each server can query the protocol information of the RDMA protocol supported by the first target server to be communicated through the protocol management platform to determine the target protocol information according to the protocol information of the RDMA protocol of the first target server and the protocol information of the RDMA protocol of the current server. Alternatively, when the server establishes an RDMA connection through the Communication Management Protocol, the protocol information of the corresponding RDMA protocol is written into the message of establishing the RDMA connection, so that the current server and the first target server negotiate and determine the target protocol information.

[0035] Step S103: performing data transmission with the first target server based on the remote direct memory access protocol corresponding to the target protocol information.

[0036] Specifically, the current server establishes a connection with the first target server based on the remote direct memory access protocol corresponding to the target protocol information, so as to perform data transmission according to the remote direct memory access protocol.

[0037] The data transmission method provided in this embodiment determines the target protocol information based on the first protocol information of the remote direct memory access protocol supported by the current server and the protocol information matching in the second protocol information of the remote direct memory access protocol supported by the first target server. Then, data is transmitted with the first target server based on the remote direct memory access protocol corresponding to the target protocol information. Therefore, it can ensure that the remote direct memory access protocols used by both parties of the data transmission are consistent, thereby ensuring normal data transmission.

[0038] In this embodiment, a data transmission method is provided, which can be used in a server. Figure 2 is a flow chart of a second data transmission method according to an embodiment of the present invention. Figure 2 As shown, the process includes the following steps:

[0039] Step S201, obtaining first protocol information of a remote direct memory access protocol supported by the current server. For details, refer to the above step S101, which will not be described in detail here.

[0040] Step S202, determining the target protocol information based on the first protocol information and the matching protocol information in the second protocol information of the remote direct memory access protocol supported by the first target server; wherein the target protocol information is determined based on the first protocol information and the second protocol information registered by the first target server on the protocol management platform.

[0041] Specifically, the above step S202 includes:

[0042] Step S2021, obtaining target identification information of the first target server; wherein the target identification information includes at least one of the name of the first target server and the network address of the first target network card in the first target server.

[0043] Specifically, each server can register the protocol information of the RDMA protocol it supports with the protocol management platform through the corresponding server name and the network address of the server's RDMA network card. The current server can query the protocol management platform for the second protocol information of the first target server based on the server name of the first target server and / or the network address of the RDMA network card. Of course, in addition to the server name and the network address of the RDMA network card, the target identification information can also include other information related to the RDMA protocol of the first target server. The specific target identification information needs to be determined according to the information registered when registering the RDMA protocol as required by the protocol management platform.

[0044] Step S2022, sending a query request to the protocol management platform based on the target identification information; wherein the protocol management platform has registered the protocol information of multiple servers and the corresponding identification information; the protocol management platform is used to respond to the query request and query the second protocol information supported by the first target server in the protocol information of multiple servers based on the target identification information.

[0045] Specifically, the protocol management platform can provide a query service for servers that have registered the protocol information of the RDMA protocol on the platform. Each server can query the protocol information of the RDMA protocol supported by the RDMA network card of other servers through this query service.

[0046] Specifically, each server can register the protocol information of the RDMA protocol supported by the server to the protocol management platform through the corresponding identification information. At the same time, the protocol management platform stores the identification information of the registered server accordingly. Therefore, when data transmission with the first target server is required, the protocol management platform is queried for the protocol information of the RDMA protocol supported by the first target server by obtaining the target identification information of the first target server.

[0047] Step S2023, receiving feedback information from the protocol management platform.

[0048] Specifically, the protocol management platform responds to the query request, parses the query request, and obtains the target identification information. The protocol management platform queries the second protocol information corresponding to the target identification information in the protocol information corresponding to the multiple registered servers according to the target identification information. If the protocol management platform queries the second protocol information, the second protocol information is fed back to the current server as feedback information. If the protocol management platform does not query the second protocol information, feedback information is generated to characterize that the second protocol information has not been queried. Then, the protocol management platform feeds back the feedback information to the current server.

[0049] Step S2024: If the feedback information from the protocol management platform carries the second protocol information, the first protocol information is searched for protocol information matching the second protocol information to determine the target protocol information.

[0050] Specifically, the current server may obtain the second protocol information in the feedback information, and then determine the matching protocol information in the first protocol information and the second protocol information. If the number of matching protocol information is greater than 1, a suitable protocol information is selected from the matching protocol information as the target protocol information. Specifically, the current server may determine the target protocol information from the matching protocol information according to a predetermined protocol selection strategy, for example, randomly selecting or selecting in a predefined order.

[0051] It should be noted that if the matching protocol information includes multiple categories of sub-protocol information, a target sub-protocol information is selected from each category of sub-protocol information, and all selected target sub-protocol information is used as the target protocol information. For example, taking the categories including packet retransmission algorithm, whether lossless network support is required, and network congestion algorithm as an example, if the packet retransmission algorithm includes Go-Back-N and Select_repeat, whether lossless network support is required includes lossless network support required and lossless network support not required, and the network congestion algorithm includes DCQCN, Timely, and HPCC. Then, a target sub-protocol information can be selected from each category, for example, Go-Back-N is selected as the target sub-protocol information of the packet retransmission algorithm, lossless network support required is selected as the target sub-protocol information of whether the network congestion algorithm is required, and DCQCN is selected as the target sub-protocol information of the network congestion algorithm, so as to obtain the target protocol information of Go-Back-N, lossless network support required, and DCQCN. Thus, the current server performs data transmission with the first target server according to Go-Back-N, lossless network support required, and DCQCN.

[0052] Furthermore, the above step S202 also includes:

[0053] Step S2025: If the feedback information from the protocol management platform does not carry the second protocol information, the preset protocol information is determined as the target protocol information.

[0054] It is understandable that if the feedback information of the protocol management platform does not carry the second protocol information, it indicates that the first target server has not registered the protocol information of the RDMA protocol it supports in the protocol management platform. Therefore, the current server can use the preset protocol information (i.e., the protocol information of the default RDMA protocol) as the target protocol information, and perform data transmission with the first target server through the RDMA protocol corresponding to the preset protocol information.

[0055] Step S203: Data is transmitted with the first target server based on the remote direct memory access protocol corresponding to the target protocol information. For details, see the above step S103, which will not be described in detail here.

[0056] In some optional implementations, if the target protocol information is determined based on the first protocol information and the second protocol information registered by the first target server in the protocol management platform, the data transmission method of the present disclosure further includes:

[0057] Step a1, obtaining current identification information of the current server; wherein the current identification information includes at least one of the name of the current server and the network address of the second target network card in the current server, and the second target network card supports the remote direct memory access protocol.

[0058] It should be noted that before the current server obtains the target identification information of the first target server and sends a query request to the protocol management platform based on the target identification information, the current server needs to register the protocol information of the RDMA protocol it supports with the protocol management platform according to the current identification information of the current server.

[0059] Specifically, each server may register the protocol information of the RDMA protocol supported by its RDMA network card with the protocol management platform through an application programming interface (Application Programming Interface, API for short) for registering with the protocol management platform.

[0060] Step a2, based on the current identification information and the first protocol information, sends a registration request to the protocol management platform; wherein the protocol management platform is used to register the current identification information and the first protocol information in response to the registration request, so that other servers can query the first protocol information supported by the current server based on the protocol management platform.

[0061] Specifically, the current server can send a registration request to the protocol management platform based on the current identification information (such as the server name of the current server, the network address of the RDMA network card) and the first protocol information (such as the protocol information of the RDMA protocol supported by each RDMA network card). The protocol management platform responds to the registration request, parses the registration request, and obtains the current identification information and the corresponding first protocol information. The protocol management platform registers the current identification information and the corresponding first protocol information so that other servers query the protocol management platform for the first protocol information supported by the current server. In addition, the protocol management platform needs to return a response of registration success or registration failure to the registration request of the current server.

[0062] For example, Figure 3 As shown, taking the current server as server A and the first target server as server B as an example, server B can register its identification information and protocol information to the protocol management platform by calling the API through the network card NIC1. Then, server A can send a query request to the protocol management platform through the network card NIC0 and the identification information of server B, so that the protocol management platform can query the protocol information of server B in the protocol information of the RDMA protocol supported by the registered server. Server A determines the target protocol information based on its protocol information and the protocol information that matches the queried protocol information of server B.

[0063] It is worth noting that the negotiation of the RDMA protocol based on the protocol management platform does not require modification of the RDMA protocol.

[0064] In this embodiment, a third data transmission method is provided, which can be used for a server. Figure 4 is a flow chart of a third data transmission method according to an embodiment of the present invention. Figure 4 As shown, the process includes the following steps:

[0065] Step S401, obtaining first protocol information of a remote direct memory access protocol supported by the current server. For details, refer to the above step S101, which will not be described in detail here.

[0066] Step S402, determining target protocol information based on the first protocol information and the matching protocol information in the second protocol information of the remote direct memory access protocol supported by the first target server; wherein the target protocol information is determined by negotiation with the first target server based on the first protocol information.

[0067] Specifically, the above step S402 includes:

[0068] Step S4021: Generate a first target connection request based on the first protocol information.

[0069] Specifically, the above step S4021 includes: generating an initial connection request; writing the first protocol information in a preset message area of ​​the initial connection request to obtain a first target connection request.

[0070] It should be noted that the RDMA protocol stipulates that the RDMA connection is established through the communication management protocol. Figure 5 As shown, when server A establishes an RDMA connection with server B, it needs to transmit three messages to establish the connection. Specifically, server A initiates a connection request (also known as REQ) to server B, and the connection request may include the RDMA function and the network address of the network card in server A, etc. Server B replies to server A's feedback information (also known as REP) based on the connection request. The feedback information may include the attributes of this RDMA connection, such as Local Communication ID and Service ID, etc. Server A replies to server B with a confirmation message (also known as RTU) to confirm that the connection has been established. It should be noted that the RDMA connection attributes referred to above are used to inform the other party to communicate using the RDMA protocol. The RDMA connection attributes mentioned here are different from the protocol information of the RDMA protocol referred to in this disclosure, and the RDMA connection attributes do not include the protocol information of the RDMA protocol involved in the present invention.

[0071] It can be understood that the RDMA protocol can be understood as a large protocol family. The RDMA protocol contains multiple sub-protocols and specific algorithms (such as packet retransmission algorithm, whether lossless network support is required, network congestion algorithm). There may be differences in the sub-protocols and / or algorithms in the RDMA protocol supported by different servers. If the other party is informed to communicate using the RDMA protocol only through the communication management protocol, the RDMA protocols used by the communicating parties may be incompatible, that is, the sub-protocols and / or algorithms used in the RDMA protocol are incompatible, resulting in abnormal communication. Therefore, the data transmission method disclosed in the present invention aims to allow the communicating parties to negotiate the various possible contents that may exist in the RDMA protocol to ensure that the RDMA protocols used by the communicating parties are compatible at each sub-protocol level, thereby ensuring normal data transmission.

[0072] Based on this, the data transmission method disclosed in the present invention hopes to write the protocol information of the RDMA protocol into the message for establishing a connection, so that both communicating parties can negotiate the specific information of the RDMA protocol to be used.

[0073] Specifically, at the end of the REQ, REP and RTU information, there is a private data storage area (also called PrivateData domain) configured for storing private data (also called PrivateData) for establishing a connection.

[0074] Specifically, the preset message area is a private data storage area used to place private data in the initial connection request. The server can carry the negotiation information of the RDMA protocol through this preset message area.

[0075] For example, at the end of the preset message area of ​​the initial connection request, an rdma_negotiation_req message may be added to represent the protocol information. Then, the data format of the first target connection request may be:

[0076] struct rdma_negotiation_req

[0077] {

[0078] u64 retrans_algo;

[0079] u64 lossless_flag;

[0080] u64 cc_algo;

[0081] };

[0082] In this data format, u64 represents an unsigned 64-bit integer, retrans_algo represents the packet retransmission algorithm, lossless_flag represents whether lossless network support is required, and cc_algo represents the network congestion algorithm.

[0083] For example, assuming that the packet retransmission algorithms include Go-Back-N and Select_repeat, whether lossless network support is required includes lossless network support required and lossless network support not required, and the network congestion algorithms include DCQCN, Timely, and HPCC, the negotiated protocol information of the two parties of data transmission can be defined according to the following content. For example:

[0084] 1. Packet retransmission algorithm definition:

[0085] #define RETRANS_GO_BACK_N 0x01

[0086] #define RETRANS_SELECT_REPEAT 0x02

[0087] That is, the value of Go-Back-N (GO_BACK_N) of the packet retransmission algorithm (RETRANS) is defined as 0x01, and the value of Select_repeat (SELECT_REPEAT) is defined as 0x02.

[0088] 2. Whether lossless network support is required:

[0089] #define LOSSLESS_FLAG_LOSSLESS 0x01

[0090] #define LOSSLESS_FLAG_LOSSY 0x02

[0091] That is, it defines whether lossless network support is required (LOSSLESS_FLAG). The value of lossless network support (LOSSLESS) is 0x01, and the value of lossless network support (LOSSY) is 0x02.

[0092] 3. Network congestion algorithm definition:

[0093] #define CC_ALGO_DCQCN 0x01

[0094] #define CC_ALGO_TIMELY 0x02

[0095] #define CC_ALGO_HPCC0x04

[0096] That is, the value of DCQCN that defines the network congestion algorithm is 0x01, the value of Timely (TIMELY) is 0x02, and the value of HPCC is 0x04.

[0097] Then, when the current server initiates a first target connection request to the first target server, the following information is written in the preset message area:

[0098] {

[0099] u64 retrans_algo=RETRANS_GO_BACK_N|RETRANS_SELECT_REP EAT;

[0100] u64 lossless_flag=LOSSLESS_FLAG_LOSSLESS|LOSSLESS_FLAG_LOSSY;

[0101] u64 cc_algo=CC_ALGO_DCQCN|CC_ALGO_TIMELY|CC_ALGO_HPCC;

[0102] };

[0103] That is, the current server supports Go-Back-N and Select_repeat in the packet retransmission algorithm, Need lossless network support and Do not need lossless network support in whether lossless network support is required, and DCQCN, Timely, and HPCC in the network congestion algorithm.

[0104] It should be noted that the protocol information definition used in the above RDMA protocol negotiation process is only an example. In addition to using the above data structure to define the protocol information, other data structures can also be used to define the protocol information in the negotiation process, as long as both parties of data transmission can clearly understand the protocol information carried in the negotiation information.

[0105] Step S4022, sending the first target connection request to the first target server; wherein the first target server is used to respond to the first target connection request and determine the third protocol information based on the first protocol information and the matching protocol information in the supported second protocol information.

[0106] Specifically, the first target server responds to the first target connection request, parses the first target connection request, and obtains the first protocol information. Then, the first target server obtains the protocol information of the RDMA protocol supported by its RDMA network card (i.e., the second protocol information), and the first target server determines the third protocol information based on the first protocol information and the protocol information that matches the second protocol information.

[0107] Specifically, if the number of matching protocol information in the first protocol information and the second protocol information is greater than 1, the third protocol information may be selected from the matching protocol information according to certain criteria, such as a predefined protocol information priority or a user-specified protocol information priority.

[0108] It should be noted that if the matching protocol information includes multiple categories of sub-protocol information, the first target server selects one sub-protocol information from each category of sub-protocol information, and uses all selected sub-protocol information as the third protocol information. For example, taking the categories including packet retransmission algorithm, whether lossless network support is required, and network congestion algorithm as an example, if the packet retransmission algorithm includes Go-Back-N and Select_repeat, whether lossless network support is required includes lossless network support required and lossless network support not required, and the network congestion algorithms include DCQCN, Timely, and HPCC. Then, a sub-protocol information can be selected from each category, for example, Go-Back-N is selected as the sub-protocol information of the packet retransmission algorithm, lossless network support required is selected as the sub-protocol information of whether the network congestion algorithm is required, and HPCC is selected as the sub-protocol information of the network congestion algorithm, so as to obtain the third protocol information of Go-Back-N, lossless network support required, and HPCC.

[0109] Furthermore, at the end of the preset message area of ​​the feedback information of the first target server, an rdma_negotiation_req message may be added to represent the protocol information. Then, the data format of the feedback information of the first target server may be obtained as follows:

[0110] struct rdma_negotiation_req

[0111] {

[0112] u64 retrans_algo;

[0113] u64 lossless_flag;

[0114] u64 cc_algo;

[0115] };

[0116] In this data format, u64 represents an unsigned 64-bit integer, retrans_algo represents the packet retransmission algorithm, lossless_flag represents whether lossless network support is required, and cc_algo represents the network congestion algorithm.

[0117] Furthermore, when the first target server feeds back the third protocol information to the current server, the following information is written in the preset message area of ​​the feedback information:

[0118] struct rdma_negotiation_req

[0119] {

[0120] u64 retrans_algo=RETRANS_GO_BACK_N;

[0121] u64 lossless_flag=LOSSLESS_FLAG_LOSSLESS;

[0122] u64 cc_algo = CC_ALGO_HPCC;

[0123] };

[0124] That is, it indicates that the first target server supports Go-Back-N in the packet retransmission algorithm, requires lossless network support in whether lossless network support is required, and HPCC in the network congestion algorithm.

[0125] Step S4023: receiving feedback information from the first target server.

[0126] Specifically, the first target server parses the first target connection request to obtain the first protocol information, and then determines the third protocol information according to the second protocol information supported by the first target server and the protocol information matching the first protocol information. If the first protocol information and the second protocol information have matching protocol information, the first target server generates feedback information according to the third protocol information. If there is no matching protocol information between the first protocol information and the second protocol information, the first target server generates feedback information for indicating that there is no matching protocol information.

[0127] Step S4024: If the feedback information from the first target server carries the third protocol information, the third protocol information is determined as the target protocol information.

[0128] It can be understood that if the feedback information of the first target server carries the third protocol information, it indicates that both the current server and the first target server support the third protocol information, and the third protocol information can be used for data transmission, thereby ensuring that the RDMA protocols used by both parties of data transmission are consistent.

[0129] Furthermore, the above step S402 also includes:

[0130] Step S4025: If the feedback information from the first target server does not carry the third protocol information, the preset protocol information is determined as the target protocol information.

[0131] It should be noted that if the feedback information of the first target server does not carry the third protocol information, it indicates that the first target server does not support RDMA protocol negotiation. In this case, the current server can use the preset protocol information (ie, the protocol information of the default RDMA protocol) as the target protocol information.

[0132] Optionally, the preset protocol information includes at least one of Go-Back-N, lossless network support required, and DCQCN.

[0133] For example, assuming that there is no rdma_negotiation_req in the preset message area of ​​the feedback information responded by the first target server, it indicates that the first target server does not support RDMA protocol negotiation, and the current server and the first target server select the RDMA protocol corresponding to the preset protocol information to transmit data, for example, through Go-Back-N, requiring lossless network support, and DCQCN to transmit data with the first target server.

[0134] Step S403: Data is transmitted with the first target server based on the remote direct memory access protocol corresponding to the target protocol information. For details, see the above step S103, which will not be described in detail here.

[0135] In some optional implementations, if the target protocol information is determined by negotiation with the first target server based on the first protocol information, the data transmission method of the present disclosure further includes:

[0136] Step b1, in response to the second target connection request sent by the second target server, parsing the second target connection request to obtain fourth protocol information.

[0137] Specifically, the second target server sends a second target connection request to the current server based on the fourth protocol information of the RDMA protocol supported by the second target server. The current server parses the second target connection request to obtain the fourth protocol information of the RDMA protocol supported by the second target server.

[0138] Step b2: Search the first protocol information for protocol information that matches the fourth protocol information to determine the fifth protocol information.

[0139] Specifically, if the first protocol information and the fourth protocol information have matching protocol information, the current server determines the fifth protocol information in the matching protocol information according to the predefined protocol information priority and the like.

[0140] Step b3: Feedback the fifth protocol information to the second target server, so that the second target server performs data transmission with the current server based on the remote direct memory access protocol corresponding to the fifth protocol information.

[0141] Furthermore, if there is no matching protocol information between the first protocol information and the fourth protocol information, a feedback message indicating that RDMA protocol negotiation is not supported is fed back to the second target server, so that the second target server performs data transmission with the current server based on the RDMA protocol corresponding to the preset protocol information.

[0142] In some optional implementations, the data transmission method of the present disclosure further includes: after determining the target protocol information based on the feedback information of the first target server, replying confirmation information to the first target server to complete the communication connection with the first target server.

[0143] It can be understood that in the data transmission method disclosed in the present invention, two methods for negotiating the RDMA protocol between servers are provided, so as to ensure that both parties of the data transmission use the same RDMA protocol to transmit data, thereby ensuring the normal progress of data transmission and improving the stability of data transmission.

[0144] In this embodiment, a data transmission device is also provided, which is used to implement the above-mentioned embodiments and preferred implementation modes, and the descriptions that have been made will not be repeated. As used below, the term "module" can implement a combination of software and / or hardware of a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.

[0145] This embodiment provides a data transmission device, such as Figure 6 As shown, including:

[0146] The local protocol acquisition module 601 is used to acquire first protocol information of the remote direct memory access protocol supported by the current server;

[0147] The communication protocol determination module 602 is used to determine the target protocol information based on the first protocol information and the protocol information matched in the second protocol information of the remote direct memory access protocol supported by the first target server; wherein the target protocol information is determined based on the first protocol information and the second protocol information registered by the first target server in the protocol management platform; or the target protocol information is determined by negotiation with the first target server based on the first protocol information;

[0148] The communication data transmission module 603 is used to perform data transmission with the first target server based on the remote direct memory access protocol corresponding to the target protocol information.

[0149] In some optional implementations, if the target protocol information is determined based on the first protocol information and the second protocol information registered by the first target server in the protocol management platform, the communication protocol determination module 602 includes a first protocol negotiation unit; wherein the first protocol negotiation unit includes:

[0150] A first information acquisition subunit is used to acquire target identification information of a first target server; wherein the target identification information includes at least one of a name of the first target server and a network address of a first target network card in the first target server;

[0151] A query request sending subunit is used to send a query request to the protocol management platform based on the target identification information; wherein the protocol management platform has registered therein the protocol information of a plurality of servers and the corresponding identification information; the protocol management platform is used to respond to the query request and query the protocol information of the plurality of servers for the second protocol information supported by the first target server based on the target identification information;

[0152] A first feedback receiving subunit, used to receive feedback information from the protocol management platform;

[0153] The first protocol determination subunit is used to query the first protocol information for protocol information matching the second protocol information to determine the target protocol information if the feedback information from the protocol management platform carries the second protocol information.

[0154] In some optional implementations, the first protocol negotiation unit further includes:

[0155] The first candidate subunit is used to determine the preset protocol information as the target protocol information if the feedback information from the protocol management platform does not carry the second protocol information.

[0156] In some optional implementations, if the target protocol information is determined based on the first protocol information and the second protocol information registered by the first target server in the protocol management platform, the data transmission device further includes:

[0157] A local information acquisition module, used to acquire current identification information of the current server; wherein the current identification information includes at least one of the name of the current server and the network address of the second target network card in the current server;

[0158] A local protocol registration module is used to send a registration request to a protocol management platform based on current identification information and first protocol information; wherein the protocol management platform is used to register the current identification information and first protocol information in response to the registration request, so that other servers can query the first protocol information supported by the current server based on the protocol management platform.

[0159] In some optional implementations, if the target protocol information is determined by negotiation with the first target server based on the first protocol information, the communication protocol determination module 602 further includes a second protocol negotiation unit; wherein the second protocol negotiation unit includes:

[0160] A connection request generating subunit, configured to generate a first target connection request based on the first protocol information;

[0161] A connection request sending subunit, configured to send a first target connection request to a first target server; wherein the first target server is configured to determine third protocol information in response to the first target connection request based on the first protocol information and the protocol information that matches the supported second protocol information;

[0162] A second feedback receiving subunit, configured to receive feedback information from the first target server;

[0163] The second protocol determination subunit is configured to determine the third protocol information as the target protocol information if the feedback information of the first target server carries the third protocol information.

[0164] In some optional implementations, the connection request generation subunit is specifically used to: generate an initial connection request; write the first protocol information in a preset message area of ​​the initial connection request to obtain a first target connection request.

[0165] In some optional implementations, the second protocol negotiation unit further includes:

[0166] The second candidate subunit is configured to determine the preset protocol information as the target protocol information if the feedback information from the first target server does not carry the third protocol information.

[0167] In some optional implementations, if the target protocol information is determined by negotiation with the first target server based on the first protocol information, the data transmission device further includes:

[0168] a connection request response module, configured to respond to a second target connection request sent by a second target server, parse the second target connection request, and obtain fourth protocol information;

[0169] a same protocol query module, used to query the first protocol information for protocol information matching the fourth protocol information to determine the fifth protocol information;

[0170] The same protocol feedback module is used to feed back the fifth protocol information to the second target server, so that the second target server performs data transmission with the current server based on the remote direct memory access protocol corresponding to the fifth protocol information.

[0171] The further functional description of each of the above modules and units is the same as that of the above corresponding embodiments and will not be repeated here.

[0172] The data transmission device in this embodiment is presented in the form of a functional unit, where the unit refers to an ASIC (Application Specific Integrated Circuit) circuit, a processor and memory that executes one or more software or fixed programs, and / or other devices that can provide the above functions.

[0173] The embodiment of the present invention also provides a server having the above Figure 6 The data transmission device shown.

[0174] See also Figure 7 , Figure 7 is a structural block diagram of a server provided by an optional embodiment of the present invention, such as Figure 7As shown, the server includes: one or more processors 701, memory 702, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. Various components are connected to each other using different buses for communication, and can be installed on a common mainboard or installed in other ways as needed. The processor can process instructions executed in the server, including instructions stored in or on the memory to display the graphical information of the GUI on an external input / output device (such as a display device coupled to the interface). In some optional embodiments, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Similarly, multiple servers can be connected, and each device provides some necessary operations (for example, as a server array, a group of blade servers, or a multi-processor system). Figure 7 A processor 701 is taken as an example.

[0175] The processor 701 may be a central processing unit, a network processor or a combination thereof. The processor 701 may further include a hardware chip. The hardware chip may be a dedicated integrated circuit, a programmable logic device or a combination thereof. The programmable logic device may be a complex programmable logic device, a field programmable logic gate array, a general purpose array logic or any combination thereof.

[0176] The memory 702 stores instructions executable by at least one processor 701, so that the at least one processor 701 executes the method shown in the above embodiment.

[0177] The memory 702 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required by at least one function; the data storage area may store data created according to the use of the server, etc. In addition, the memory 702 may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some optional embodiments, the memory 702 may optionally include a memory remotely arranged relative to the processor 701, and these remote memories may be connected to the server 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.

[0178] The memory 702 may include a volatile memory, such as a random access memory; the memory may also include a non-volatile memory, such as a flash memory, a hard disk or a solid state drive; the memory 702 may also include a combination of the above types of memory.

[0179] The server also includes a communication interface 703, which is used for the server to communicate with other devices or communication networks.

[0180] The embodiment of the present invention also provides a computer-readable storage medium. The method according to the embodiment of the present invention can be implemented in hardware, firmware, or can be implemented as a computer code that can be recorded in a storage medium, or can be implemented as a computer code that is originally stored in a remote storage medium or a non-temporary machine-readable storage medium and will be stored in a local storage medium through a network download, so that the method described herein can be stored in such software processing on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only storage memory, a random access memory, a flash memory, a hard disk or a solid-state hard disk, etc.; further, the storage medium can also include a combination of the above types of memories. It can be understood that a computer, a processor, a microprocessor controller, or programmable hardware includes a storage component that can store or receive software or computer code. When the software or computer code is accessed and executed by a computer, a processor, or hardware, the method shown in the above embodiment is implemented.

[0181] A part of the present invention may be applied as a computer program product, such as a computer program instruction, which, when executed by a computer, can call or provide the method and / or technical solution according to the present invention through the operation of the computer. Those skilled in the art should understand that the existence of computer program instructions in computer-readable media includes, but is not limited to, source files, executable files, installation package files, etc., and accordingly, the way in which computer program instructions are executed by a computer includes, but is not limited to: the computer directly executes the instruction, or the computer compiles the instruction and then executes the corresponding compiled program, or the computer reads and executes the instruction, or the computer reads and installs the instruction and then executes the corresponding installed program. Here, the computer-readable medium may be any available computer-readable storage medium or communication medium accessible to the computer.

[0182] Although the embodiments of the present invention have been described in conjunction with the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the present invention, and such modifications and variations are all within the scope defined by the appended claims.

Claims

1. A data transmission method, characterized in that: The method comprises: Obtain the first protocol information of the remote direct memory access protocol supported by the current server; Determine target protocol information based on the first protocol information and the protocol information that matches the second protocol information of the remote direct memory access protocol supported by the first target server; wherein the target protocol information is determined based on the first protocol information and the second protocol information registered by the first target server in the protocol management platform; or, the target protocol information is determined through negotiation with the first target server based on the first protocol information; Data is transmitted with the first target server based on the remote direct memory access protocol corresponding to the target protocol information.

2. The method according to claim 1, characterized in that If the target protocol information is determined based on the first protocol information and second protocol information registered by the first target server in the protocol management platform, the target protocol information is determined based on the first protocol information and the second protocol information of the remote direct memory access protocol supported by the first target server, including: Acquire target identification information of the first target server; wherein the target identification information includes at least one of the name of the first target server and the network address of the first target network card in the first target server; Sending a query request to the protocol management platform based on the target identification information; wherein the protocol management platform has protocol information of multiple servers and corresponding identification information registered therein; the protocol management platform is used to respond to the query request and query the protocol information of the multiple servers for second protocol information supported by the first target server based on the target identification information; Receiving feedback information from the protocol management platform; If the feedback information from the protocol management platform carries the second protocol information, the first protocol information is searched for protocol information matching the second protocol information to determine the target protocol information.

3. The method according to claim 2, characterized in that The determining target protocol information based on the first protocol information and the protocol information matching in the second protocol information of the remote direct memory access protocol supported by the first target server further includes: If the feedback information from the protocol management platform does not carry the second protocol information, the preset protocol information is determined as the target protocol information.

4. The method according to claim 1, characterized in that: If the target protocol information is determined based on the first protocol information and second protocol information registered by the first target server in the protocol management platform, the method further includes: Acquire current identification information of the current server; wherein the current identification information includes at least one of the name of the current server and the network address of the second target network card in the current server; Based on the current identification information and the first protocol information, a registration request is sent to the protocol management platform; wherein the protocol management platform is used to register the current identification information and the first protocol information in response to the registration request, so that other servers can query the first protocol information supported by the current server based on the protocol management platform.

5. The method according to claim 1, characterized in that If the target protocol information is determined through negotiation with the first target server based on the first protocol information, then the target protocol information is determined based on the first protocol information and the protocol information matching the second protocol information of the remote direct memory access protocol supported by the first target server, including: generating a first target connection request based on the first protocol information; sending the first target connection request to the first target server; wherein the first target server is used to determine third protocol information in response to the first target connection request based on the first protocol information and the protocol information matched in the supported second protocol information; receiving feedback information from the first target server; If the feedback information of the first target server carries the third protocol information, the third protocol information is determined as the target protocol information.

6. The method according to claim 5, characterized in that The generating a first target connection request based on the first protocol information includes: Generate an initial connection request; The first protocol information is written into a preset message area of ​​the initial connection request to obtain the first target connection request.

7. The method according to claim 5, characterized in that The determining target protocol information based on the first protocol information and the protocol information matching in the second protocol information of the remote direct memory access protocol supported by the first target server further includes: If the feedback information of the first target server does not carry the third protocol information, the preset protocol information is determined as the target protocol information.

8. The method according to claim 1, characterized in that If the target protocol information is determined by negotiation with the first target server based on the first protocol information, the method further includes: In response to a second target connection request sent by a second target server, parsing the second target connection request to obtain fourth protocol information; querying the first protocol information for protocol information matching the fourth protocol information to determine fifth protocol information; The fifth protocol information is fed back to the second target server, so that the second target server performs data transmission with the current server based on the remote direct memory access protocol corresponding to the fifth protocol information.

9. A server, characterized in that: include: A memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the data transmission method according to any one of claims 1 to 8 by executing the computer instructions.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a computer to execute the data transmission method according to any one of claims 1 to 8.

Citation Information

Patent Citations

  • Protocol selection method and device, and computer readable medium

    CN109729040A

  • Data transmission method, device and system

    CN113382062A

  • SSL VPN remote access method and system and computer equipment

    CN114244569A

  • Network data transmission method, client, server and system

    CN114885042A

  • Network performance optimization method and device, storage medium and electronic equipment

    CN117336177A