Data transmission path determination method and computing device
By deploying service and driver modules in the user space and kernel space of the computing node, and combining them with the packet statistics function of the switching node, the problem of switch hardware dependence in the existing technology is solved, and efficient, low-impact RoCE data flow transmission path detection and flexible networking are achieved.
Patent Information
- Application Number
- CN202510857519.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-24
- Publication Date
- 2025-11-14
AI Technical Summary
Existing technologies rely on the hardware configuration of switches and RDMA feature recognition capabilities when probing the transmission path of RoCE data streams, resulting in high resource overhead and significant impact on online service performance. Furthermore, they do not support flexible networking of diverse switching nodes.
By deploying the target service in the user space and the target driver module in the kernel space of the computing node, and using the functional interface of the network card driver to obtain the information of the target data packet, combined with the packet statistics function of the switching node, the transmission path of the RoCE data stream is determined by a one-way or two-way search method, thus avoiding hardware dependence on the switch.
It reduces resource overhead during path detection, minimizes the impact on online service performance, enables flexible networking of diverse switching nodes, and improves detection efficiency and accuracy.
Smart Images

Figure CN120956689A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of data transmission technology, and in particular to a method for determining a data transmission path and a computing device. Background Technology
[0002] RoCEv2 is a version of Remote Direct Memory Access over Converged Ethernet (RoCE). It enables remote direct memory access (RDMA) on Ethernet infrastructure through RoCEv2 technology, and has the advantages of low latency and high throughput. It is often used in scenarios with high network performance requirements, such as high-performance computing scenarios.
[0003] In the aforementioned scenario, during communication based on the RoCE protocol, a series of data packets transmitted through the User Datagram Protocol (UDP) / Internet Protocol (IP) network are transmitted between the source and destination ends to form a data stream, which can be called a RoCE data stream.
[0004] To reduce network congestion, the transmission path of RoCE data streams needs to be optimized. Detecting the transmission path of RoCE data streams is fundamental to optimizing them.
[0005] Currently, RDMA features such as source QPN, destination QPN, source IP, and destination IP are collected at the switch side as "flow identifiers." These "flow identifiers" are used to identify and distinguish RoCE data flows passing through the switch, thus obtaining the transmission path of the RoCE data flow. This approach is highly dependent on the capabilities of the switches along the transmission path and requires specialized detection technologies for RDMA communication scenarios, such as in-band network telemetry (INT). INT inserts "path metadata" into data packets to detect the transmission path of the RoCE data flow. However, INT-based transmission path detection schemes also require configuring INT functionality on the switches, relying on the switch's hardware configuration and increasing the data processing burden on the switches. Summary of the Invention
[0006] This application provides a method and computing device for determining a data transmission path, thereby detecting the transmission path of a RoCE data stream.
[0007] In a first aspect, embodiments of this application provide a method for determining a data transmission path, applied to a probing device. The method includes: sending an information request to a first computing node, the information request being used to request first information of a target data packet; the first information includes a source IP, a destination IP, a target protocol, a source port, and a destination port, the target data packet being a Remote Direct Memory Access (RoCE) data packet based on converged Ethernet sent or received by the first computing node; receiving the first information of the target data packet returned by the first computing node; and determining a target transmission path for the target data packet between the first computing node and a second computing node based on the first information of the target data packet; the first computing node and the second computing node are connected through one or more switching nodes.
[0008] Thus, the switches do not need to be capable of recognizing RDMA characteristics in RoCE data flows, nor do they need to be configured with INT functionality. This means no specific hardware support is required, minimizing resource overhead during path probing and reducing the impact on online service performance. Furthermore, since there are no stringent requirements on switch functionality and configuration, switching nodes with different functions and configurations can coexist in the same cluster network, enabling flexible networking of diverse switching nodes.
[0009] In one possible implementation, the information request includes the identifier of the target network interface card (NIC) on the first compute node. The target data packet is a RoCE data packet sent or received via the target NIC.
[0010] In this way, by specifying a particular RDMA network card as the target network card, the detection device can detect the path of the RoCE data stream sent and received by the specific RDMA network card, making it more targeted.
[0011] In one possible implementation, determining the target transmission path of the target data packet between the first computing node and the second computing node based on the first information of the target data packet includes: obtaining the first information of data packets transmitted on each switching node along a candidate transmission path; the candidate transmission path includes data transmission paths connecting the first computing node and the second computing node through one or more switching nodes. By matching the first information of the target data packet with the first information of data packets transmitted on each switching node, the target switching node traversed by the target data packet is identified, and the target transmission path of the target data packet is formed by connecting the first computing node, the target switching node, and the second computing node.
[0012] In this way, by collecting the first information of the data packets transmitted by each port of the switching node on the candidate transmission path and matching it with the first information of the target data packet, if the first information of a certain data packet matches the first information of the target data packet, the data packet can be determined to be the target data packet, and the switching node port can be determined as a switching node port in the target transmission path, thereby accurately detecting the target transmission path.
[0013] In one possible implementation, matching the first information of the target data packet with the first information of data packets transmitted on the switching nodes includes: taking the first switching node connected to the first computing node as the starting point of the target transmission path, and determining the next-hop switching node on the target transmission path by matching the first information of the target data packet with the first information of data packets transmitted on switching nodes within a first range, until a second switching node connected to the second computing node is determined, thus obtaining the complete target transmission path. The first range includes switching nodes connected to the target data packet output of the current hop switching node.
[0014] Thus, in the unidirectional search method, starting from the first switching node connected to the source (first computing node), the search proceeds unidirectionally towards the destination (second computing node) along the links in the network topology until a second switching node connected to the second computing node is found, thus obtaining the destination switching node. The target switching node includes the first switching node, the switching node whose first information of the data stream within the first range matches the first information of the target data packet, and the second switching node, thereby obtaining the complete path. In this way, each hop switching node is determined step-by-step during the unidirectional search until the complete path is obtained, making the process relatively straightforward. In some simple network topologies or with short transmission paths, the detection efficiency is even higher.
[0015] In one possible implementation, matching the first information of the target data packet with the first information of data packets transmitted on the switching nodes includes: taking the first switching node connected to the first computing node as the starting point of the first local path, matching the first information of the target data packet with the first information of data packets transmitted on switching nodes within a first range to determine the next-hop switching node, until a third switching node is determined; the first local path includes the first computing node, the first switching node, and the third switching node, and the first range includes switching nodes connected to the target data packet exit point of the current hop switching node. Taking the second switching node connected to the second computing node as the starting point of the second local path, matching the first information of the target data packet with the first information of data packets transmitted on switching nodes within a second range to determine the previous-hop switching node, until a third switching node is determined; wherein, the second range includes switching nodes connected to the target data packet entry point of the current hop switching node, and the second local path includes the third switching node, the second switching node, and the second computing node. The target transmission path includes the first local path and the second local path.
[0016] Thus, in this bidirectional search approach, a first local path is determined starting from the first switching node connected to the source (first computing node), and a second local path is determined in reverse order starting from the second switching node connected to the destination (second computing node). The paths converge at the intermediate third switching node to obtain the destination switching node. The destination switching node includes the first switching node, the switching node whose first information in the data stream within the first range matches the first information in the target data packet, the third switching node, the switching node whose first information in the data stream within the second range matches the first information in the target data packet, and the second switching node, thereby obtaining the complete path. Because bidirectional search is used, the target can be found faster, especially in large cluster networks with many switching nodes between the source and destination, reducing search time and scope and improving efficiency. Simultaneously, bidirectional search can, to some extent, mutually verify the accuracy of the paths, reducing the error rate.
[0017] Secondly, embodiments of this application provide another method for determining a data transmission path, applied to a first computing node. The method includes: receiving an information request from a probe device, the information request requesting first information about a target data packet, the first information including a source IP, destination IP, target protocol, source port, and destination port, the target data packet being a Remote Direct Memory Access (RoCE) data packet based on converged Ethernet sent or received by the first computing node. In response to the information request, acquiring the first information about the target data packet and returning the first information about the target data packet to the probe device, the first information being used by the probe device to determine the target transmission path of the target data packet between the first computing node and the second computing node; the first computing node and the second computing node are connected through one or more switching nodes.
[0018] In this way, the resource overhead during the path detection process is minimized, the performance impact on online services is reduced, and flexible networking of diverse switching nodes is achieved.
[0019] In one possible implementation, the first computing node includes an operating system, which includes a target service deployed in user space and a target driver module created in kernel space. Receiving first information about the target data packet in response to an information request includes: via the target service, in response to the information request, invoking the target driver module; and via the target driver module, in response to the invocation by the target service, querying the first information about the target data packet in the network interface card driver in kernel space.
[0020] Thus, by deploying the target service in the user space of the first computing node and the target driver module in the kernel space of the first computing node, the target driver module exposes the functional interface of the network card target driver in the kernel space to the user space, enabling the user space program (i.e. the target service) to securely and controllably access the resources in the network card target driver to obtain the first information of the target data packets sent and received by the RDMA network card.
[0021] In one possible implementation, the operating system further includes an intermediate module deployed in user space. Receiving the first information of the target data packet in response to an information request also includes: through the intermediate module, in response to a call from the target service, invoking a target driver module. The target driver module, in response to the call from the intermediate module, queries the network card driver in kernel space for the first information of the target data packet. The intermediate module includes library files that translate the call from the target service into a call that the target driver module can process, and then pass the information request to the target driver module.
[0022] This is primarily applicable to scenarios where the target service is a Java program. Through the intermediate module, a Java program (i.e., the target service) can call non-Java code, such as C / C++ code. It only needs to call the high-level interface of the .so file, without needing to concern itself with the details of the underlying system calls. Thus, the .so file in the intermediate module can act as an intermediary layer between the target service and the target driver module, encapsulating kernel calls and handling cross-language data conversion, enabling the upper-layer target service to indirectly obtain the first information of the target data packet from the network card driver.
[0023] In one possible implementation, the information request includes the identifier of the target network interface card (NIC) on the first computing node. The target data packet is a RoCE data packet sent or received via the target NIC. This allows the probing device to probe the path of RoCE data streams sent and received by a specific RDMA NIC, making the probing more targeted.
[0024] Thirdly, embodiments of this application provide a computing device. The computing device includes a processor and a memory. The processor executes instructions stored in the memory to cause the computing device to perform the methods described above.
[0025] The technical effects brought about by the third aspect can be seen in the technical effects brought about by different implementation methods in the first and / or second aspects, and will not be repeated here.
[0026] Based on the implementation methods provided in the above aspects, this application can be further combined to provide more implementation methods. Attached Figure Description
[0027] Figure 1 A schematic diagram illustrating an implementation of RDMA provided in this application embodiment;
[0028] Figure 2 A schematic diagram of the protocol stack of RoCEv2 provided for embodiments of this application;
[0029] Figure 3 This application provides a schematic diagram of the structure of a detection device and a cluster network.
[0030] Figure 4 A schematic diagram of the system architecture of a first computing node provided in an embodiment of this application;
[0031] Figure 5 This is a schematic diagram of the structure of a computing device provided in an embodiment of this application;
[0032] Figure 6 A cluster network architecture diagram provided for an embodiment of this application;
[0033] Figure 7 A flowchart illustrating a method for determining a data transmission path provided in an embodiment of this application;
[0034] Figure 8 A schematic diagram of a data transmission path determination device provided in an embodiment of this application;
[0035] Figure 9 A schematic diagram of another data transmission path determination device provided in an embodiment of this application;
[0036] Figure 10 This is a schematic diagram of another computing device provided in an embodiment of this application. Detailed Implementation
[0037] The technical solutions in the embodiments of this application will now be described with reference to the accompanying drawings.
[0038] In the description of this application, unless otherwise stated, " / " indicates that the objects before and after are in an "or" relationship. For example, A / B can mean A or B. "And / or" in this application is merely a description of the relationship between the related objects, indicating that there can be three relationships. For example, A and / or B can mean: A exists alone, A and B exist simultaneously, and B exists alone. A and B can be singular or plural.
[0039] Furthermore, in the description of this application, unless otherwise stated, "multiple" means two or more. "At least one of the following" or similar expressions refer to any combination of these items, including any combination of a single item or a plurality of items. For example, at least one of a, b, or c can mean: a, b, c, ab, ac, bc, or abc, where a, b, and c can be single or multiple.
[0040] Furthermore, to facilitate a clear description of the technical solutions in the embodiments of this application, the terms "first" and "second" are used in the embodiments of this application to distinguish identical or similar items with substantially the same function and effect. Those skilled in the art will understand that the terms "first" and "second" do not limit the quantity or execution order, and that "first" and "second" are not necessarily different. Meanwhile, in the embodiments of this application, the terms "exemplary" or "for example" are used to indicate that something is being used as an example, illustration, or description. Any embodiment or design scheme described as "exemplary" or "for example" in the embodiments of this application should not be construed as being more preferred or advantageous than other embodiments or design schemes. Specifically, the use of terms such as "exemplary" or "for example" is intended to present related concepts in a concrete manner for ease of understanding.
[0041] The following is a brief introduction to the application scenarios involved in the embodiments of this application.
[0042] Remote direct memory access (RDMA) is a direct memory access technology that allows data to be transferred directly between the memory of two devices without the intervention of the operating systems and CPUs of either device. It is particularly suitable for applications with high requirements for bandwidth, latency, and CPU load.
[0043] Figure 1This is a schematic diagram illustrating an implementation of RDMA in an embodiment of this application. In RDMA mode, the application layer interacts directly with the network port, and memory data does not need to be processed by the kernel protocol stack (such as the TCP / IP protocol stack). TCP (Transmission Control Protocol) is a connection-oriented, reliable, byte-stream-based transport layer communication protocol. A queue pair (QP) is a pair of interconnected queues in a network adapter (RDMA network card, RNIC) specifically designed for Remote Direct Memory Access technology. It allows the sender and receiver to bypass the central processing unit and kernel protocol stack and directly interact with memory data. The sender is the party initiating the communication, and the receiver is the party responding. The queue pair includes a send queue (SQ) and a receive queue (RQ). The send queue is used to generate and store the sender's requests, such as read or write requests for remote memory. The receive queue is used to store the receiver's pre-receive requests or to buffer data received by the receiver. In essence, the receive queue is the receive buffer registry of the RDMA network card, and the pre-receive request refers to the buffer information submitted in advance by the receiver. Through the receive queue, the RDMA network card can autonomously receive data without the need for access from the central processing unit and kernel protocol stack.
[0044] In this embodiment, source QPs and destination QPs are involved. The source QP refers to the sender's QP, and the destination QP refers to the receiver's QP. Both the sender's and receiver's QPs have a unique QPN (QP number) used to identify the QP in the network and distinguish different QPs. In RDMA communication, a quadruple is a set of core parameters used to uniquely identify a communication path or connection. The source QPN and destination QPN are key components of the quadruple, used to identify the source QP and destination QP, respectively.
[0045] Remote Direct Memory Access over Converged Ethernet (RoCE) is a network protocol that allows the use of Remote Direct Memory Access (RDMA) over an Ethernet network, aiming to achieve high-performance, low-latency data transmission over Ethernet networks. RoCEv2 is a version of the RoCE protocol, in which RoCEv2 uses UDP as the transport layer protocol.
[0046] RoCEv2 technology enables RDMA to be performed on Ethernet infrastructure, offering advantages such as low latency and high throughput. It is often used in scenarios with high network performance requirements, such as high-performance computing scenarios.
[0047] The specific implementation of RoCEv2 technology involves the collaborative work of multiple network protocols. Its core is to encapsulate RDMA protocol data units (PDUs) through UDP and use Ethernet and IP networks to achieve cross-node transmission.
[0048] Figure 2 This is a schematic diagram illustrating the protocol stack hierarchy of RoCEv2 as provided in an embodiment of this application. Figure 2 As shown, the RoCEv2 protocol stack hierarchy, from top to bottom, is: Application Layer, RDMA Layer, UDP Layer, IP Layer, and Ethernet Layer. Correspondingly, the packet encapsulation format, from outside to inside, includes the Ethernet header, IP header, UDP header, and RDMA PDU. Combined with... Figure 2 Taking the data packet transmission process on the sender side as an example: First, the application layer initiates an operation (such as a send operation) through an RDMA interface (such as Verbs). The RDMA data to be sent includes the source QP, destination QP, RDMA operation type (such as read, write, atomic operation), and the data content to be sent. Then, at the RDMA layer, the RDMA data is mapped to the RoCEv2 protocol format. Key fields include a four-tuple (source QPN, destination QPN, source Qkey, destination Qkey) and other RDMA control information (such as message length, opcode, etc.). This completes the RoCEv2 header encapsulation, resulting in the RDMA PDU. The source QPN and destination QPN are used to identify the source QP and destination QP of this communication and are subsequently mapped to the source UDP port and destination UDP port. Next, at the UDP layer, a source port (random or fixed) is allocated to the UDP header and mapped to the source QPN. The destination port is specified, for example, 4791 (the standard RoCEv2 port), and mapped to the receiver's destination QPN. This completes the UDP header encapsulation. Next, at the IP layer, the source IP, destination IP, and protocol number indicating the upper-layer protocol type are filled into the IP header. At the Ethernet layer (Ethernet transport layer), information such as the source MAC address and destination MAC address is encapsulated, and finally the data packet enters the physical network.
[0049] In the example above, the source UDP port and destination UDP port encapsulated in the UDP header, and the source IP, destination IP, and protocol number encapsulated in the IP header constitute a quintuple.
[0050] In this embodiment of the application, in the aforementioned scenario of performing RDMA based on RoCEv2, a series of data packets transmitted over a UDP / IP network form a logical data stream between the source (sender) and the destination (receiver). For ease of explanation, this application refers to such a data stream as a RoCE data stream. It can be seen that in the communication process based on RoCEv2 technology, the four-tuple (source QPN, destination QPN, etc.) encapsulated in the RoCEv2 header, along with the aforementioned five-tuple, can uniquely identify the data packets sent by the sender, that is, can identify the data stream composed of this series of data packets.
[0051] To reduce network congestion, the transmission path of RoCE data streams needs to be optimized. Determining the transmission path of RoCE data streams is fundamental to this optimization. The transmission path of a RoCE data stream represents which network devices (such as switching nodes) the RoCE data stream passes through after it originates from the source and ultimately reaches the destination. Network congestion refers to the phenomenon where network performance degrades when the network load exceeds its capacity due to the limited nature of network resources (such as bandwidth and memory). This phenomenon typically leads to increased network latency, higher packet loss rates, and may even cause network cluster collapse.
[0052] This application provides a method for determining a data transmission path, applied to a detection device, which can specifically be a computing device. This method does not require configuring INT functionality on the switch, nor does it require the switch to have the ability to identify RDMA characteristics; that is, it does not require specific hardware support, thus minimizing resource overhead during path detection and reducing the performance impact on online services.
[0053] First, the probe device sends an information request to the computing node, requesting the first information of the target data packet. The target data packet is generated based on the original data packet. The original data packet includes second information, including the source QPN and destination QPN. The target data packet includes the aforementioned first information, including the source IP, destination IP, protocol number, source port, and destination port. Referring to the above description of the application scenario of this application, for example, the original data packet is a data packet without UDP header, IP header, and Ethernet layer encapsulation; that is, the original data packet is an RDMA PDU in RoCEv2 protocol format. Correspondingly, the target data packet is a data packet encapsulated with UDP header, IP header, and Ethernet layer encapsulation; that is, a data packet that has undergone multi-layer protocol encapsulation by the sender's protocol stack before being transmitted in the physical network. Then, the probe device receives the first information of the target data packet returned by the computing node and, based on the first information of the target data packet, probes the target transmission path of the target data packet. It should be understood that the data stream formed by a series of target data packets during transmission is the aforementioned RoCE data stream. The first information of the target data packet is the first information of this RoCE data stream. Thus, the detection device obtains the first information of the RoCE data stream on the computing node side, and then uses the first information of the RoCE data stream as the "flow identifier" of the RoCE data stream to determine the transmission path of the RoCE data stream in the cluster network. Since the first information refers to information including source IP, destination IP, protocol number, source port, and destination port, the switch only needs to have ordinary observation capabilities (such as the transport layer packet statistics function netstream that is commonly supported by current switches) to identify the first information in the data packet.
[0054] As can be seen, the data transmission path determination method provided in this application does not require the switch to have the ability to identify RDMA characteristics in the RoCE data stream, nor does it require the INT function to be configured on the switch. That is, it does not require the support of specific hardware, which minimizes the resource overhead in the path detection process and reduces the impact on the performance of online services.
[0055] Furthermore, the data transmission path determination method provided in this application embodiment does not place excessive requirements on the functions and configurations of the switches, thus allowing switching nodes with different functions and configurations to coexist in the same cluster network, achieving flexible networking of diverse switching nodes.
[0056] The system architecture of the embodiments of this application will be described below as an example.
[0057] This application provides a detection device. The detection device can be a computing device. The detection device can communicate with a computing node. For example, such as... Figure 3 As shown, the detection device can communicate with any computing node in the cluster network.
[0058] In this embodiment of the application, the detection device is mainly used to detect the transmission path of RoCE data streams between different computing nodes.
[0059] For example, in a scenario where RDMA is performed based on RoCEv2 between the first and second compute nodes in a cluster, the first compute node acts as the sender and the second compute node as the receiver. A series of target data packets sent by the first compute node to the second compute node logically form a RoCE data stream. The probing device is used to probe the transmission path of the RoCE data stream from the first compute node to the second compute node.
[0060] Taking any two compute nodes in the cluster, the first and second compute nodes, that perform RDMA based on RoCEv2, as an example:
[0061] The first computing node, including an RDMA network interface card (NIC), generates a target data packet based on the original data packet using the RDMA NIC and sends the target data packet to the second computing node. The target data packet includes first information, and the original data packet includes second information. The first information includes the source IP, destination IP, protocol number, source port, and destination port. The second information includes the source QPN and destination QPN.
[0062] Based on the above description of the application scenario of this application, in one example, the original data packet is a data packet without UDP header, IP header, and Ethernet layer information encapsulated by the first computing node; that is, the original data packet is an RDMA PDU in RoCEv2 protocol format. Correspondingly, the target data packet is a data packet encapsulated by the first computing node with UDP header, IP header, and Ethernet layer information; that is, a data packet that has undergone multi-layer protocol encapsulation by the protocol stack of the first computing node before being transmitted in the network. After the target data packet is sent by the first computing node, it is transmitted in the network through the transmission path between the first and second computing nodes, and is finally received by the second computing node.
[0063] In this embodiment, when the detection device probes the transmission path of the RoCE data stream, it sends an information request to a first computing node or a second computing node. The information request is used to request first information of the target data packet. In response to the information request, the first computing node or the second computing node returns the first information of the target data packet to the detection device. Then, the detection device uses the first information as a "stream identifier" to probe the transmission path of the RoCE data stream to which the target data packet belongs.
[0064] In the embodiments of this application, Figure 3Taking the cluster network shown as an example, there is at least one switching node on the transmission path between multiple computing nodes. The switching node has packet observation capabilities, such as being configured with packet statistics functions. Based on the packet statistics function on the switching node, the probing device can collect the first information of any data packet forwarded by any switching node, namely, the source IP, destination IP, source port, destination port, and protocol number. When the probing device collects the first information of any data packet on any switching node, it can match the first information of the target data packet with the first information of the data packets on the switching nodes to determine all the switching nodes that the target data packet passed through after being sent by the first computing node, thereby obtaining the transmission path of the target data packet.
[0065] The specific implementation method of the detection device determining the transmission path of the target data packet based on the first information of the target data packet will be described in detail in the specific embodiments of the data transmission path determination method given in this application, and will not be repeated here.
[0066] Figure 4 This is a schematic diagram of the system architecture of a first computing node provided in an embodiment of this application. Figure 4 As shown, the first computing node includes an operating system, which includes target services deployed in user space and target driver modules deployed in kernel space, as well as a network card driver for an RDMA network card deployed in kernel space.
[0067] The target service, in response to information requests from the probe device, invokes the target driver module. The target driver module, in response to the call from the target service, queries the network interface card (NIC) driver for the first information of the target data packet and returns it to the target service. The target service also returns the first information of the target data packet to the probe device.
[0068] In this embodiment, by deploying the target service in the user space of the first computing node and the target driver module in the kernel space of the first computing node, the target driver module exposes the functional interface of the network card driver in the kernel space to the user space, so that the user space program (i.e. the target service) can securely and controllably access the resources in the network card driver to obtain the first information of the target data packets sent and received by the RDMA network card.
[0069] In one implementation, the operating system of the first computing node further includes an intermediate module deployed in user space. The target service specifically invokes the intermediate module in response to an information request. The intermediate module, in response to the target service's invocation, invokes the target driver module. The target driver module, specifically, in response to the intermediate module's invocation, queries the network interface card (NIC) driver for the first information of the target data packet. In other words, the intermediate module is used by the target service to invoke the target driver module. The intermediate module includes library files that translate the target service's invocation into invocations that the target driver module can process, and pass the probe device's information request to the target driver module, enabling the target driver module to obtain the first information of the target data packet from the NIC driver based on the information request.
[0070] For example, the library file can be a .so file (such as getInfo.so). It should be understood that a .so file is a shared library (shared object) file. The .so file contains function calls. The target service calls the function calls in the .so file, and the function calls the target driver module to obtain the first information of the target data packet from the network card driver.
[0071] The above embodiments are particularly suitable for scenarios where the target service is a Java program. Through the intermediate module, a Java program (i.e., the target service) can call non-Java code, such as C / C++ code. Only the high-level interface of the .so file needs to be called; the details of the underlying system calls are not required. Thus, the .so file in the intermediate module can serve as an intermediary layer between the target service and the target driver module, encapsulating kernel calls and handling cross-language data conversion, enabling the upper-layer target service to indirectly obtain the first information of the target data packet in the network card driver.
[0072] Optionally, the target driver module exposes the network interface card (NIC) driver interface to the user-space target service or .so file by registering a block device. For example, the target driver module registers a block device and creates a corresponding device file, which is then mounted to the file system. User-space programs (such as native code through the .so file) can access this device file by calling functions to send information requests to the kernel-space NIC driver. The target driver module parses the information requests, completes the query of the target data packet, and returns the query results.
[0073] In the embodiments of this application, the detection device and / or computing node can be a computing device. Specifically, the computing device can be a network device, such as a server. The server can be a single physical or logical server, or it can consist of two or more physical or logical servers that share different responsibilities and cooperate to achieve the various functions of the server.
[0074] For example, the server can be a blade server, a high-density server, a rack server, or a tower server, etc.
[0075] The hardware of this computing device includes a processor, a basic input / output system (BIOS) chip, an out-of-band controller, and memory. The software primarily includes the BIOS, an out-of-band management module, and an operating system (OS). Figure 5 As shown in the figure, this application provides a schematic diagram of the structure of a computing device.
[0076] A processor may include a CPU, which contains one or more CPU cores. All data processing operations of the CPU are performed by the CPU cores. The more CPU cores a CPU contains, the faster it can process data.
[0077] The BIOS chip is a chip located on the motherboard used for initializing and detecting various hardware components during the power-on process of a computing device. The BIOS chip includes a flash memory area.
[0078] The out-of-band management module is deployed within the out-of-band controller, while the operating system is deployed within the processor.
[0079] Out-of-band management modules can be management units for non-business modules. For example, an out-of-band management module can remotely maintain and manage computing devices through a dedicated data channel. This out-of-band management module is completely independent of the computing device's operating system and can communicate with the BIOS and operating system through the computing device's out-of-band management interface.
[0080] For example, the out-of-band management module may include a management unit for the operating status of the computing device, a management system in the management chip, a system management mode (SMM), etc. It should be noted that the specific form of the out-of-band management module is not limited in the embodiments of this application; the above is merely an illustrative example.
[0081] An operating system (OS) is a computer program that manages and controls the hardware and software resources of a computing device. Any other software must run with the support of the operating system. After the computing device is powered on, the BIOS first performs a series of operations such as self-test and initialization, and then boots the OS, allowing the user to use the computing device normally.
[0082] BIOS is a set of programs embedded in the BIOS chip on the motherboard of a computing device. The main function of BIOS is to provide the lowest-level and most direct hardware settings and control for computing devices.
[0083] Memory, also known as internal memory or main memory, is installed in memory slots on the motherboard of a computing device.
[0084] It should be noted that the system architecture and application scenarios described in the embodiments of this application are for the purpose of more clearly illustrating the technical solutions of the embodiments of this application, and do not constitute a limitation on the technical solutions provided in the embodiments of this application. As those skilled in the art will know, with the evolution of system architecture and the emergence of new application scenarios, the technical solutions provided in the embodiments of this application are also applicable to similar technical problems.
[0085] For ease of understanding, the following description, in conjunction with the above system and accompanying drawings, and the following... Figure 6 The cluster network architecture diagram shown illustrates the method for determining the data transmission path provided in the embodiments of this application.
[0086] Figure 6 This is a cluster network architecture diagram provided for an embodiment of this application. For example... Figure 6 As shown in the example, the cluster network includes multiple compute nodes (e.g., compute node 1-compute node 4, ..., compute node n) and switching nodes (e.g., L1-L4, ..., Ln) for connecting the compute nodes. Furthermore, the cluster network may also include switching nodes (e.g., S1-S2, ..., Sn) for connecting the switching nodes (e.g., L1-L4, ..., Ln). If, in practical applications, the switching nodes (e.g., S1-S2, ..., Sn) are insufficient to meet the connection requirements between compute nodes, more switching nodes can be added. It should be noted that... Figure 6 This is an example of a cluster network structure where compute nodes and switching nodes, as well as switching nodes, can be arbitrarily connected according to actual needs. For example, compute node 1 can also be connected to switching nodes L2, L3, etc.
[0087] For example, a switching node can be a switch, which is divided into leaf switches and spine switches. The leaf switch provides network connectivity to the compute nodes and also connects uplink to the spine switch. A leaf switch is like... Figure 6 The switching nodes L1-L4, ..., Ln in the spine switch are as follows: Figure 6 The switching nodes S1-S2, ... Sn in the network are configured. Leaf switches and spine switches dynamically select multiple paths through equal cost multipath (ECMP) routing. In this way, multiple leaf switches and multiple spine switches form multiple transmission paths for RoCE data flows.
[0088] For example, a compute node may include multiple network interface cards (NICs) (such as Nic1-1, Nic1-2). The NICs of the compute node are connected to the ports of the switching node. Each switch may have multiple ports (such as x1-x2, y1-y3 on switch L1). In this way, the NIC of the source compute node acts as the sender, and the NIC of the destination compute node acts as the receiver. The RoCE data stream is sent from the source end, passes through the transmission path formed by the ports of the switching node, and finally reaches the destination end.
[0089] In a cluster network, the two ends of a transmission path are different computing nodes, and there is generally at least one switching node along the path. There are multiple transmission paths in a cluster network; a pair of computing nodes typically has more than one transmission path. These transmission paths can be characterized by the network topology of the cluster network. Network topology represents the connection relationships between switching nodes and their ports, and between switching nodes' ports and the network interface cards (NICs) of computing nodes.
[0090] For example, combining Figure 6 As shown, the network topology is as follows: Network interface card Nic1-1 of computing node 1 is connected to port x1 of L1; Network interface card Nic1-2 of computing node 1 is connected to port x2 of L1; Network interface card Nic2-1 of computing node 2 is connected to port x1 of L2; Network interface card Nic3-1 of computing node 3 is connected to port x1 of L3; Network interface card Nic4-1 of computing node 4 is connected to port x1 of L4; Network interface card Nicn-1 of computing node n is connected to port x1 of Ln. Ports y1, y2, and y3 of L1 are connected to ports x1 of S1, x1 of S2, and x1 of Sn, respectively; ports y1 and y2 of L2 are connected to ports x2 of S1 and x2 of S2, respectively; ports y1, y2, and y3 of L3 are connected to ports x3 of S1, x3 of S2, and x2 of Sn, respectively; ports y1, y2, and y3 of L4 are connected to ports x4 of S1, x4 of S2, and x3 of Sn, respectively; and ports y1, y2, and y3 of Ln are connected to ports x5 of S1, x5 of S2, and x4 of Sn, respectively.
[0091] Based on this, a transmission path for the RoCE data flow (target flow A) can be: Network interface card Nic1-1 of compute node 1 → Port x1 of L1 → Port y1 of L1 → Port x1 of S1 → Port x3 of S1 → Port y1 of L3 → Port x1 of L3 → Network interface card Nic3-1 of compute node 3. If any port in the current transmission path of target flow A experiences network congestion, it will lead to higher communication overhead for target flow A, such as slower transmission speed or higher latency. In this case, path optimization is required, such as switching the transmission path of target flow A. For example, a compute node includes one or more graphics processing units (GPUs), and each GPU has a corresponding network interface card connected to a port on a leaf switch.
[0092] For example, each switching node in the cluster network is configured with a packet statistics function. When it is necessary to collect the source IP, destination IP, source port, destination port, and protocol number of packets from a particular switching node, the probe device controls the switching node to turn on or off the packet statistics function. In this way, the packet statistics function on the switching node does not need to be in a constantly active state, reducing resource overhead.
[0093] like Figure 7 As shown in the figure, this application embodiment provides a method for determining a data transmission path, the method including:
[0094] S701, the detection device sends an information request to the first computing node.
[0095] An information request is used to request first information about the target data packet.
[0096] The target data packet is generated by the sender's RDMA network card after multi-layer protocol encapsulation of the original data packet. The first computing node can be either the sender or the receiver of the target data packet.
[0097] The original data packet follows the RoCEv2 protocol format and belongs to an RDMA PDU, containing the second information (source QPN and destination QPN). The destination data packet is a network data packet encapsulated by the sender's RDMA network card with a UDP header, IP header, and Ethernet layer, containing the first information (source IP, destination IP, UDP protocol number, source port, and destination port). During UDP header encapsulation, a source port is assigned to the UDP header (which can be randomly assigned or a fixed value) and mapped to the source QPN; at the same time, the destination port is specified (such as RoCEv2 standard port 4791) and mapped to the receiver's destination QPN, thus completing the mapping between the source QPN and destination QPN in the second information and the source port and destination port in the first information.
[0098] In this embodiment of the application, the first information is the five-tuple identifier of the RoCE data stream, which is used to identify and distinguish the RoCE data stream passing through the switch, thereby realizing the detection of the RoCE data stream transmission path to which the target data packet belongs. The RoCE data stream to which the target data packet belongs can be understood as the RoCE data stream containing the target data packet.
[0099] S702, the first computing node responds to the information request and obtains the first information of the target data packet.
[0100] In one possible implementation, the information request includes the identifier of the target network interface card (NIC) on the first computing node. The target data packet is a RoCE data packet sent or received via the target NIC. The first computing node includes one or more RDMA NICs, and the target NIC is one of these RDMA NICs. In this implementation, by specifying a particular RDMA NIC as the target NIC, the probing device can more specifically target the path of RoCE data streams sent and received by that specific RDMA NIC.
[0101] In one possible implementation, the first compute node, acting as a service provider, exposes a RESTful API (Representational State Transfer Application Programming Interface) (e.g., the interface path URI is: / api / roce / five-tuple). The probing device accesses this URI by constructing an HTTP GET request and carrying characteristic parameters of the target data stream. For example, the characteristic parameters might be the source IP and / or destination IP. The probing device can perform path probing on data streams sent / received by a specific network interface card (NIC) on a specific compute node. This means the probing device can specify the source IP and / or destination IP of the data stream to be probed and include them in the request. Upon receiving this information request, the first compute node, based on the URI path resolution request intent, retrieves the first information (source IP, destination IP, UDP protocol number, source port, destination port) of the corresponding RoCE data stream from the NIC driver and returns it to the probing device. It can be seen that the first information includes not only the source IP and / or destination IP but also the UDP protocol number, source port, and destination port. This can be understood as the probing device obtaining the complete five-tuple of the corresponding data stream from the compute node based on the source IP and / or destination IP.
[0102] In some embodiments, the first computing node, in response to an information request, obtains the first information of the target data packet by: invoking a target driver module via a target service in response to the information request; and querying the target data packet's first information in the network card driver within the kernel space via the target driver module in response to the invocation of the target service.
[0103] In one implementation, in response to a call from the target service, querying the first information of the target data packet in the network card driver in the kernel space includes: first, in response to a call from the target service, obtaining the first information of the target data packet from the corresponding form in the network card driver (such as a local mapping table storing the first information of the RoCE data stream).
[0104] In other embodiments, the first computing node's response to an information request to obtain the first information of the target data packet further includes: invoking a target driver module via an intermediate module in response to a call from the target service. The target driver module is used to query the first information of the target data packet in the network card driver in the kernel space in response to the call from the intermediate module.
[0105] The intermediate module includes a .so file, which is used to convert the call to the target service into a call that the target driver module can process, and to pass the information request of the probe device to the target driver module so that the target driver module can obtain the first information of the target data packet from the network card driver according to the information request.
[0106] A .so file is a shared library (shared object) file. For example, a .so file contains function calls. The target service calls these functions in the .so file, and these functions retrieve the initial information of the target data packet from the network interface card (NIC) driver by calling the target driver module.
[0107] The above embodiments are particularly suitable for scenarios where the target service is a program written in Java. Through the intermediate module, a Java program (i.e., the target service) can call non-Java code, such as C / C++ code, by simply calling the high-level interface of the .so file, without needing to concern itself with the details of the underlying system calls, thus improving the maintainability and scalability of the system.
[0108] S703, the first computing node returns the first information of the target data packet to the detection device.
[0109] After the first computing node returns the first information of the target data packet to the probe device, the probe device receives the first information of the target data packet returned by the first computing node.
[0110] S704, the detection device determines the target transmission path of the target data packet between the first computing node and the second computing node based on the first information of the target data packet.
[0111] The target transmission path is the transmission path of the target data packet from its source to its destination. The first computing node and the second computing node are its source and destination, respectively. For example, the first computing node is the source and the second computing node is the destination; or, the first computing node is the destination and the second computing node is the source. The source and destination of the target data packet are determined based on the first information of the target data packet. The source IP indicates the source and the destination IP indicates the destination. For example, if the source IP and destination IP in the first information are the IP address of network interface card Nic1-1 of computing node 1 and the IP address of network interface card Nic3-1 of computing node 3, respectively, then computing node 1 and computing node 3 are the source and destination, respectively.
[0112] In this embodiment, for a target data packet, its target transmission path between the source and destination is detected based on its first information. Specifically, by collecting the first information of data packets forwarded by the switching nodes between the source and destination, and matching it with the first information of the target data packet, the switching nodes actually traversed by the target data packet are identified, thereby obtaining the target transmission path.
[0113] In some embodiments, determining the target transmission path of the target data packet between the first computing node and the second computing node based on the first information of the target data packet includes: obtaining the first information of data packets transmitted on each switching node along the candidate transmission path. The candidate transmission path includes data transmission paths connecting the first computing node and the second computing node through one or more switching nodes. By matching the first information of the target data packet with the first information of data packets transmitted on each switching node along each candidate transmission path, the target switching nodes traversed by the target data packet are identified, thus obtaining the target transmission path.
[0114] Specifically, the first information of the target data packet is matched with the first information of the data packets transmitted on each switching node on each candidate transmission path. This can include: determining whether the first information of the data packet transmitted on a certain port of the switching node is the same as the first information of the target data packet. If they are the same, the match is successful; if they are different, the match fails.
[0115] In the above embodiments, by collecting the first information of data packets transmitted on each port of the switching node and matching it with the first information of the target data packet, if the first information of a certain data packet successfully matches the first information of the target data packet, the data packet can be determined to be the target data packet, and the switching node port can be identified as a switching node port in the target transmission path, thereby accurately detecting the target transmission path. A successful match here can be understood as the first information being the same.
[0116] Taking the first computing node and the second computing node as the source and destination of the target data packet, respectively, and combining with the network topology shown in Figure 6, the first computing node and the second computing node are computing node 1 and computing node 3, respectively. The transmission path between computing node 1 and computing node 3 includes transmission paths 1-3.
[0117] The transmission path 1 is as follows: Network card Nic1-1 of compute node 1 → Port x1 of L1 → Port y1 of L1 → Port x1 of S1 → Port x3 of S1 → Port y1 of L3 → Port x1 of L3 → Network card Nic3-1 of compute node 3.
[0118] The transmission path 2 is as follows: Network card Nic1-1 of computing node 1 → Port x1 of L1 → Port y2 of L1 → Port x1 of S2 → Port x3 of S2 → Port y2 of L3 → Port x1 of L3 → Network card Nic3-1 of computing node 3.
[0119] The transmission path 3 is as follows: Network card Nic1-1 of compute node 1 → Port x1 of L1 → Port y3 of L1 → Port x1 of Sn → Port x2 of Sn → Port y3 of L3 → Port x1 of L3 → Network card Nic3-1 of compute node 3.
[0120] According to the above embodiment, transmission paths 1-3 are candidate transmission paths. Next, the first information of the data packets transmitted on each switching node on transmission paths 1-3 is obtained and matched with the first information of the target data packet. If the match is successful, it indicates that the data packet is the target data packet, and the switching node port through which the target data packet passes is the port in the target transmission path, thereby detecting the target transmission path of the target data packet.
[0121] For example, taking transmission path 1 as an example, the following example illustrates the acquisition of the first information of data packets transmitted on each switching node of transmission path 1 and their matching with the first information of the target data packet: The first information of data packets transmitted on ports x1 of L1, y1 of L1, x1 of S1, x3 of S1, y1 of L3, and x1 of L3 are acquired respectively. If the first information of the data packets transmitted on ports x1 of L1, y1 of L1, x1 of S1, x3 of S1, y1 of L3, and x1 of L3 are all the same as the first information of the target data packet, then ports y1 of L1, x1 of S1, x3 of S1, y1 of L3, and x1 of L3 are transmitting the target data packet, which are nodes in the target transmission path, and therefore transmission path 1 is the target transmission path.
[0122] Optionally, when acquiring the first information of data packets transmitted on each switching node along transmission path 1, if network interface card Nic1-1 of computing node 1 is only connected to port x1 of L1, and network interface card Nic3-1 of computing node 3 is only connected to port x1 of L3, then the first information of data packets transmitted on port x1 of L1 and port x1 of L3 need not be acquired. In this case, the target data packet output from network interface card Nic1-1 of computing node 1 will necessarily be input to port x1 of L1; and the target data packet must be output from port x1 of L3 to be input to network interface card Nic3-1 of computing node 3. This improves the efficiency of determining the target transmission path.
[0123] In one implementation, a one-way search method is used to determine the target transmission path of the target data packet. Specifically, taking the first switching node connected to the first computing node as the starting point of the target transmission path, the next-hop switching node on the target transmission path is determined by matching the first information of the target data packet with the first information of data packets transmitted on switching nodes within a first range, until the second switching node connected to the second computing node is determined, thus obtaining the complete target transmission path.
[0124] The first range can be understood as the set of switching nodes connected to the exit point of the target data packet at the current hop switching node. The exit point can be understood as the port that outputs the target data packet, and the specific switching node connected to it can be determined based on the network topology. For example, the exit point of the target data packet at the current hop switching node is... Figure 2 If port y1 of L1 is connected to the switching node S1, specifically port x1 of S1, then the switching nodes within the first range include S1. The next-hop switching node can be understood as the switching node to which the target data packet output from the current hop switching node is input.
[0125] In the unidirectional search method, starting from the first switching node connected to the source (first computing node), the search proceeds unidirectionally towards the destination (second computing node) along the links in the network topology until a second switching node connected to the second computing node is found. The destination switching node is then obtained. The target switching node includes the first switching node, the switching node whose first information of the data stream within the first range matches the first information of the target data packet, and the second switching node, thus obtaining the complete path. In this way, each hop switching node is determined step-by-step during the unidirectional search until the complete path is obtained, making the process relatively straightforward. This method is more efficient in simple network topologies or when the transmission path is short.
[0126] Taking computing node 1 as the first computing node and computing node 3 as the second computing node as an example, and combining the network topology shown in Figure 6, the first step is to determine the first switching node as L1. Since the network card Nic1-1 of computing node 1 is connected to port x1 of L1, port x1 of L1 is directly used as a port in the target transmission path. The second step is to determine the exit point of the target data packet on L1. Specifically, the first information of the data packets on the other ports (x2, y1, y2, y3) of L1 is collected. If the first information of the data packet on port y1 of L1 is the same as the first information of the target data packet, then port y1 of L1 is determined as the exit point of the target data packet on L1, that is, a port in the target transmission path. The third step is to take the switching node S1 connected to port y1 of L1 as the switching node in the first range, that is, the next-hop switching node, and take port x1 of S1 as a port in the target transmission path. Fourth step: Using S1 as the current hop switching node, collect the first information of the data packets on ports of S1 (such as one or more of x2, x3, x4, and x5). If the first information of the data packet on port x3 of S1 is the same as the first information of the target data packet, then port x3 of S1 is determined as the exit point of the target data packet on S1, that is, a port in the target transmission path. Fifth step: Use switching node L3 connected to port x3 of S1 as the first range switching node, that is, the next hop switching node is L3, and use port y1 of L3 as a port in the target transmission path. Sixth step: Use L3 as the current hop switching node, and use port x1 of L3 connected to computing node 3 as a port in the target transmission path. Thus, the target transmission path of the target data packet between computing node 1 and computing node 3 is detected as follows: network card Nic1-1 of computing node 1 → port x1 of L1 → port y1 of L1 → port x1 of S1 → port x3 of S1 → port y1 of L3 → port x1 of L3 → network card Nic3-1 of computing node 3.
[0127] It should be understood that if the target data packet exit (such as port y1 of L1) is connected to multiple ports (such as port x1 of S1, port x2 of S1, and port x1 of S2), the first information of the data packets on the multiple ports can be collected respectively, and the port where the data packets whose first information is the same as the first information of the target data packet are located (such as port x1 of S1) is used as the port in the target transmission path.
[0128] In another implementation, a bidirectional search method is used to determine the target transmission path of the target data packet. Specifically, on the one hand, taking the first switching node connected to the first computing node as the starting point of the first local path, the next-hop switching node is determined by matching the first information of the target data packet with the first information of data packets transmitted on switching nodes within a first range (i.e., the set of switching nodes connected to the exit of the target data packet at the current hop switching node; the exit can be understood as the port that outputs the target data packet, and the specific switching node connected to the exit can be determined according to the network topology). On the other hand, taking the second switching node connected to the second computing node as the starting point of the second local path, the previous-hop switching node is determined by matching the first information of the target data packet with the first information of data packets transmitted on switching nodes within a second range (i.e., the set of switching nodes connected to the entry of the target data packet at the current hop switching node; the entry can be understood as the port that inputs the target data packet, and the specific switching node connected to the entry can be determined according to the network topology). Thus, the exchange nodes of the first local path and the second local path are searched in parallel until the common intersection node of the first local path and the second local path is determined, which is the third exchange node. Finally, a complete target transmission path is obtained by connecting the first local path (including the first computing node, the first exchange node, and the third exchange node) and the second local path (including the third exchange node, the second exchange node, and the second computing node). The third exchange node is the connection point of the first local path and the second local path.
[0129] In the bidirectional search approach, a first local path is determined starting from the first switching node connected to the source (first computing node), and a second local path is determined in reverse order starting from the second switching node connected to the destination (second computing node). The paths converge at the intermediate third switching node to obtain the destination switching node. The destination switching node includes the first switching node, switching nodes where the first information of the data stream within the first range matches the first information of the target data packet, the third switching node, switching nodes where the first information of the data stream within the second range matches the first information of the target data packet, and the second switching node, thus obtaining the complete path. Because bidirectional search is used, the target can be found faster, especially in large cluster networks with many switching nodes between the source and destination, reducing search time and scope and improving efficiency. Simultaneously, bidirectional search can, to some extent, mutually verify the accuracy of the paths, reducing the error rate.
[0130] For example, taking the first computing node as computing node 1, and the network card that specifically sends the target data packet as network card Nic1-1, and the second computing node as computing node 3, and the network card that specifically receives the target stream as network card Nic3-1, combined with... Figure 6The network topology shown is as follows: the first switching node is L1. Exploring the first local path starting from L1, the first local path is: network interface card Nic1-1 of computing node 1 → port x1 of L1 → port y1 of L1 → port x1 of S1. Specifically, based on the network topology, port x1 of L1 is the port connected to network interface card Nic1-1 of computing node 1, and thus becomes a node in the first local path. The first information of the data packets transmitted on ports other than port x1 of L1 is obtained. The first information of the data packets transmitted on port y1 of L1 is the same as the first information of the target data packet; therefore, port y1 of L1 is also considered a node in this first local path. Next, based on the network topology, port x1 of S1, which is connected to port y1 of L1, is determined, and port x1 of S1 is also considered a node in the first local path. Meanwhile, since the second switching node is L3, exploring the second local path starting from L3 yields the following path: port x3 of S1 → port y1 of L3 → port x1 of L3 → network interface card Nic3-1 of compute node 3. Specifically, the second local path probes from L3, which is connected to network interface card Nic3-1 of compute node 3. Based on the network topology, port x1 of L3 is connected to network interface card Nic3-1 of compute node 3, thus serving as a node in the second local path. The first information of data packets transmitted on ports other than port x1 of L3 is obtained. If the first information of the data packet transmitted on port y1 of L3 is the same as the first information of the target data packet, then port y1 of L3 is also considered a node in the second local path. Next, based on the network topology, port x3 of S1, which is connected to port y1 of L3, is identified and designated as a node in the first local path. At this point, the first local path and the second local path have a common intersection node (i.e., S1), so the probing stops. In this way, the second local path and the first local path are determined. The two local paths merge at the third switching node (S1), thus obtaining the complete target transmission path: network card Nic1-1 of computing node 1 → port x1 of L1 → port y1 of L1 → port x1 of S1 → port x3 of S1 → port y1 of L3 → port x1 of L3 → network card Nic3-1 of computing node 3.
[0131] In this embodiment, the switch does not need to have the ability to identify RDMA characteristics in RoCE data streams, nor does it need to be configured with INT functionality. This means no specific hardware support is required, minimizing resource overhead during path probing and reducing the impact on online service performance. Furthermore, since there are no excessive requirements on the switch's functionality and configuration, switching nodes with different functions and configurations can coexist in the same cluster network, enabling flexible networking of diverse switching nodes.
[0132] like Figure 8As shown, this application embodiment provides a data transmission path determination device 200, applied to a detection device. The data transmission path determination device 200 includes: a sending module 21, a first receiving module 22, and a determination module 23. The sending module 21 is used to send an information request to a first computing node. The information request requests first information of a target data packet; the first information includes a source IP, a destination IP, a target protocol, a source port, and a destination port. The target data packet is any Remote Direct Memory Access (RoCE) data packet based on Converged Ethernet sent or received by the first computing node. The first receiving module 22 is used to receive the first information of the target data packet returned by the first computing node. The determination module 23 is used to determine the target transmission path of the target data packet between the first computing node and a second computing node based on the first information of the target data packet.
[0133] like Figure 9 As shown, this application embodiment provides another data transmission path determination device 300, applied to a first computing node. The data transmission path determination device 300 includes a second receiving module 31 and a response module 32. The second receiving module 31 receives an information request from a probe device. The information request requests first information about a target data packet, including a source IP address, a destination IP address, a target protocol, a source port, and a destination port. The target data packet is any Remote Direct Memory Access (RoCE) data packet sent or received by the first computing node based on converged Ethernet. The response module 32 responds to the information request, acquires the first information about the target data packet, and returns the first information about the target data packet to the probe device. The first information is used by the probe device to determine the target transmission path of the target data packet between the first and second computing nodes.
[0134] like Figure 10 As shown, this application embodiment provides another computing device 500. The computing device 500 includes a processor 510 and a memory 520 for storing processor-executable instructions. When the processor 510 is configured to execute instructions, the computing device 500 implements the data transmission path determination method described above.
[0135] Figure 10 The computing device 500 shown is merely an example and should not impose any limitations on the functionality and scope of use of the embodiments of this application.
[0136] The computing device 500 is manifested in the form of a general-purpose computing device. The components of the computing device 500 may include, but are not limited to: one or more processors 510, memory 520, communication bus 540 connecting different system components (including memory 520 and processor 510), and communication interface 530.
[0137] The communication bus 540 represents one or more of several bus architectures, including a memory bus or memory controller, a peripheral bus, a graphics acceleration port, a processor, or a local bus using any of the various bus architectures. Examples of these architectures include, but are not limited to, the Industry Standard Architecture (ISA) bus, the Micro Channel Architecture (MAC) bus, the Enhanced ISA bus, the Video Electronics Standards Association (VESA) local bus, and the Peripheral Component Interconnect (PCI) bus.
[0138] Computing device 500 typically includes a variety of computer system readable media. These media can be any available media that can be accessed by the computing device, including volatile and non-volatile media, removable and non-removable media.
[0139] Memory 520 may include computer system readable media in the form of volatile memory, such as random access memory (RAM) and / or cache memory. The computing device may further include other removable / non-removable, volatile / non-volatile computer system storage media. Although Figure 10 As not shown, a disk drive for reading and writing to a removable non-volatile disk (e.g., a "floppy disk") and an optical disc drive for reading and writing to a removable non-volatile optical disc (e.g., a compact disc read-only memory (CD-ROM), a digital video disc read-only memory (DVD-ROM), or other optical media) may be provided. In these cases, each drive may be connected to the communication bus 540 via one or more data media interfaces. The memory 520 may include at least one program product having a set (e.g., at least one) of program modules configured to perform the functions of the embodiments of this application.
[0140] A program / utility having a set (at least one) of program modules can be stored in memory 520. Such program modules include—but are not limited to—an operating system, one or more application programs, other program modules, and program data. Each or some combination of these examples may include an implementation of a network environment. The program modules typically perform the functions and / or methods described in the embodiments of this application.
[0141] The computing device 500 can also communicate with one or more external devices (e.g., keyboard, pointing device, display, etc.), and with one or more devices that enable a user to interact with the computing device, and / or with any device that enables the computing device to communicate with one or more other computing devices (e.g., network interface card, modem, etc.). This communication can be performed through the communication interface 530. Furthermore, the computing device 500 can also communicate through a network adapter (… Figure 10 (Not shown) communicates with one or more networks (e.g., Local Area Network (LAN), Wide Area Network (WAN), and / or public networks, such as the Internet). The aforementioned network adapter can communicate with other modules of the computing device via the communication bus 540. It should be understood that, although... Figure 10 As not shown, the computing device 500 may be used with other hardware and / or software modules, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, Redundant Arrays of Independent Drives (RAID) systems, tape drives, and data backup storage devices.
[0142] The processor 510 executes various functional applications and data processing by running programs stored in the memory 520, such as implementing the data transmission path determination method provided in the embodiments of this application.
[0143] It is understood that the interface connection relationships between the modules illustrated in the embodiments of this application are merely illustrative and do not constitute a structural limitation on the computing device 500. In other embodiments of this application, the computing device 500 may also employ different interface connection methods or combinations of multiple interface connection methods as described in the above embodiments.
[0144] It is understood that the aforementioned computing devices, etc., include hardware structures and / or software modules corresponding to the execution of each function in order to achieve the above-mentioned functions. Those skilled in the art should readily recognize that, in conjunction with the exemplary units and algorithm steps described in conjunction with the embodiments disclosed herein, the embodiments of this application can be implemented in hardware or a combination of hardware and computer software. Whether a function is executed in a hardware-driven or software-driven manner depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the embodiments of this application.
[0145] This application embodiment can divide the above-mentioned computing device into functional modules according to the above method example. For example, each function can be divided into a separate functional module, or two or more functions can be integrated into one processing module. The integrated module can be implemented in hardware or as a software functional module. It should be noted that the module division in this application embodiment is illustrative and only represents one logical functional division. In actual implementation, there may be other division methods.
[0146] This application also provides a storage medium storing computer program instructions. When the computer program instructions are executed by a computing device, the computing device implements the data transmission path determination method described above.
[0147] This application also provides a computer program product, which includes a computer program that, when at least one processor executes the computer program, causes the at least one processor to execute the data transmission path determination method provided in this application embodiment.
[0148] The computing device, storage medium, or computer program product provided in the embodiments of this application are all used to execute the corresponding methods provided above. Therefore, the beneficial effects they can achieve can be referred to the beneficial effects in the corresponding methods provided above, and will not be repeated here.
[0149] Through the above description of the embodiments, those skilled in the art will clearly understand that, for the sake of convenience and brevity, only the division of the above functional modules is used as an example. In practical applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. The specific working process of the system, device, and unit described above can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.
[0150] In the embodiments of this application, the functional units can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0151] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solutions of the embodiments of this application, essentially, or the parts that contribute to the prior art, or all or part of the technical solutions, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) or processor to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as flash memory, portable hard disk, read-only memory, random access memory, magnetic disk, or optical disk.
[0152] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A method for determining a data transmission path, characterized in that, Applied to a detection device, the method includes: A message request is sent to the first computing node. The message request is used to request first information of the target data packet. The first information includes source IP, destination IP, target protocol, source port and destination port. The target data packet is a Remote Direct Memory Access (RoCE) data packet based on converged Ethernet sent or received by the first computing node. Receive the first information of the target data packet returned by the first computing node; Based on the first information of the target data packet, the target transmission path of the target data packet between the first computing node and the second computing node is determined; the first computing node and the second computing node are connected through one or more switching nodes.
2. The determination method according to claim 1, characterized in that, The information request includes the identifier of the target network interface card on the first computing node; the target data packet is a RoCE data packet sent or received via the target network interface card.
3. The determining method according to claim 1 or 2, characterized in that, Determining the target transmission path of the target data packet between the first computing node and the second computing node based on the first information of the target data packet includes: First information of data packets transmitted on each switching node on a candidate transmission path is obtained; the candidate transmission path includes a data transmission path connecting the first computing node and the second computing node through one or more switching nodes; by matching the first information of the target data packet with the first information of the data packets transmitted on each switching node, the target switching node through which the target data packet passes is identified, and the target transmission path of the target data packet is formed by connecting the first computing node, the target switching node, and the second computing node.
4. The determination method according to claim 3, characterized in that, The step of matching the first information of the target data packet with the first information of the data packets transmitted on the switching node includes: Taking the first switching node connected to the first computing node as the starting point of the target transmission path, the next-hop switching node on the target transmission path is determined by matching the first information of the target data packet with the first information of the data packets transmitted on the switching nodes within the first range, until the second switching node connected to the second computing node is determined, thus obtaining the complete target transmission path; wherein, the first range includes the switching nodes connected to the target data packet exit of the current hop switching node.
5. The determination method according to claim 3, characterized in that, The step of matching the first information of the target data packet with the first information of the data packets transmitted on the switching node includes: Taking the first switching node connected to the first computing node as the starting point of the first local path, the next hop switching node is determined by matching the first information of the target data packet with the first information of the data packets transmitted on the switching nodes within the first range, until the third switching node is determined. The first local path includes the first computing node, the first switching node, and the third switching node. The first range includes the switching nodes connected to the target data packet exit of the current hop switching node. Taking the second switching node connected to the second computing node as the starting point of the second local path, the previous hop switching node is determined by matching the first information of the target data packet with the first information of the data packets transmitted on the switching nodes within the second range, until the third switching node is determined; wherein, the second range includes the switching nodes connected to the target data packet entry point of the current hop switching node, and the second local path includes the third switching node, the second switching node, and the second computing node; The target transmission path includes the first local path and the second local path.
6. A method for determining a data transmission path, characterized in that, Applied to the first computing node, the method includes: The system receives an information request from a detection device. The information request is used to request first information of a target data packet. The first information includes source IP, destination IP, target protocol, source port, and destination port. The target data packet is a Remote Direct Memory Access (RoCE) data packet based on converged Ethernet sent or received by the first computing node. In response to the information request, the first information of the target data packet is obtained and returned to the detection device. The first information is used by the detection device to determine the target transmission path of the target data packet between the first computing node and the second computing node. The first computing node and the second computing node are connected through one or more switching nodes.
7. The determination method according to claim 6, characterized in that, The first computing node includes an operating system, which includes target services deployed in user space and target driver modules created in kernel space; The step of obtaining the first information of the target data packet in response to the information request includes: In response to the information request, the target service invokes the target driver module. The target driver module, in response to the call of the target service, queries the first information of the target data packet in the network card driver in the kernel space.
8. The determination method according to claim 7, characterized in that, The operating system further includes an intermediate module deployed in the user-space environment, and the step of obtaining the first information of the target data packet in response to the information request further includes: In response to the call of the target service, the intermediate module calls the target driver module, which in turn queries the first information of the target data packet in the network card driver in the kernel space in response to the call of the intermediate module. The intermediate module includes a library file, which is used to convert the call to the target service into a call that the target driver module can process, and to pass the information request to the target driver module.
9. The determining method according to claim 7 or 8, characterized in that, The information request includes the identifier of the target network interface card on the first computing node; the target data packet is a RoCE data packet sent or received via the target network interface card.
10. A computing device, characterized in that, Including processor and memory; The processor is configured to execute instructions stored in the memory to cause the computing device to perform the method as described in any one of claims 1-5 or the method as described in any one of claims 6-9.