Rdma virtualization apparatus supporting mixed virtual environments
By providing an RDMA virtualization appliance in a hybrid virtual environment, direct RDMA resource access between virtual machines and containers is enabled, resolving the incompatibility issues of existing technologies, improving data transfer performance, and reducing latency.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- FUDAN UNIVERSITY
- Filing Date
- 2021-07-09
- Publication Date
- 2026-04-28
AI Technical Summary
Existing TCP network virtualization technologies are ill-suited for RDMA networks and are incompatible with virtual machines and containers. There is a lack of a unified RDMA virtualization framework to support high-performance data transmission in hybrid virtual environments.
An RDMA virtualization device supporting hybrid virtual environments is provided, including virtual machines, containers, physical RDMA network cards and virtual layers. Direct RDMA resource access between virtual machines and containers is realized through a conversion module, a routing rule storage module, a connection management module and a resource mapping module.
It implements a unified RDMA virtualization framework for virtual machines and containers in a hybrid virtual environment, which improves data transmission performance, reduces virtual layer latency, achieves zero-copy transmission, and has performance close to native RDMA.
Smart Images

Figure CN115604255B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of computer network technology, and specifically relates to an RDMA virtualization device that supports hybrid virtual environments. Background Technology
[0002] With the expansion of software applications and the development of underlying computer hardware, cloud computing is becoming increasingly popular. The virtualization foundation of cloud computing is containers and virtual machines, each with its own advantages. Containers are lightweight, characterized by low resource consumption and fast startup, while virtual machines offer strong isolation. Currently, hybrid virtual environments using both are becoming increasingly common in cloud computing. Within the same cluster, a centralized virtualization management platform is needed for hybrid virtualization environments using virtual machines and containers to increase resource utilization, reduce management and maintenance complexity, and adapt to dynamically changing business needs.
[0003] Traditional TCP networks struggle to meet the data transmission demands of cloud computing environments. RDMA (Remote Direct Memory Access) networks, as a high-performance new type of network, are widely used in cloud computing environments across various data centers, providing services for data-intensive applications such as deep learning, big data systems, and distributed storage. RDMA networks, by bypassing the operating system, employing zero-copy, and hardware protocol stack technologies, offer high throughput, low latency, and low CPU load.
[0004] In hybrid virtualization environments, applications in virtual machines and containers leverage the high performance of RDMA, requiring a unified RDMA virtualization framework. However, due to the differences between RDMA networks and TCP, existing TCP network virtualization technologies are ill-suited for RDMA. Furthermore, existing RDMA virtualization solutions are incompatible with both virtual machines and containers. Therefore, a unified RDMA virtualization framework is crucial for hybrid virtualization environments.
[0005] Currently, most existing network virtualization is the virtualization of traditional networks. Wang Lei, Zhan Jianfeng, and others have carried out high-performance virtualization for traditional networks (see "Implementation Methods, Devices and Systems for Multi-Kernel Operating Systems", CN104077266B). Wu Tao, Wang Hao, and others have implemented a system for managing resources in a virtualized environment, which manages resources including computing, storage and network. This system provides high-speed network services to the virtualized system through file, bridge, storage and management monitors connected by InfiniBand (infinite bandwidth technology). Although this system uses RDMA technology in the virtual environment, it is not related to RDMA virtualization (see "A Multi-Kernel Processing Device Based on Multiple Operating Systems", CN104951374A). At present, there is still a lack of general RDMA virtualization frameworks related to RDMA virtualization, especially in hybrid virtual environments. Summary of the Invention
[0006] To address the aforementioned problems, this invention provides a high-performance RDMA virtualization device that supports hybrid virtual environments. The technical solution adopted by this invention is as follows:
[0007] This invention provides an RDMA virtualization device supporting a hybrid virtual environment, characterized by comprising: at least one virtual machine having a virtual machine interface; at least one container having a container interface; a physical RDMA network interface card; and a virtual layer (i.e., a host virtual layer) communicatively connected to the virtual machine interface, the container interface, and the physical RDMA network interface card, wherein the virtual layer has multiple virtual RDMA network interface cards obtained by virtualizing the physical RDMA network interface card, a conversion module, a routing rule storage module, a connection management module, a resource mapping module, and a control module, wherein each virtual RDMA network interface card corresponds one-to-one with a virtual machine and a container, and the conversion module is used to convert RDMA from the virtual machine interface... The command information is converted to make the command format of the RDMA command information consistent with the command format of the container interface. The RDMA command information includes at least a connection request command. The routing rule storage module stores pre-configured routing rules. When the virtual RDMA network card receives a connection request command from the virtual machine and the container, the virtual layer creates the corresponding RDMA resource and maps the RDMA resource to the virtual machine and the container through the resource mapping module. The connection management module establishes an RDMA connection between the virtual machine and the container based on the pre-configured routing rules, so that the virtual machine and the container can directly access each other's RDMA resources through the physical RDMA network card.
[0008] The RDMA virtualization apparatus supporting hybrid virtual environments provided by the present invention may also have the following technical features, wherein the connection management module has an acquisition unit, a judgment unit, and a connection creation unit. The acquisition unit acquires pre-configured routing rules from the routing rule storage module. The judgment unit determines whether to allow the establishment of an RDMA connection between a virtual machine and a container based on the preset routing rules. The connection creation unit is used to establish an RDMA connection between the virtual machine and the container based on the preset routing rules when the judgment unit determines that it is allowed, so that the virtual machine and the container can directly access each other's RDMA resources through the physical RDMA network card.
[0009] The RDMA virtualization device supporting hybrid virtual environments provided by the present invention may also have the following technical features: the connection management module further includes a resource destruction unit, and the RDMA command information includes a resource destruction command. When the virtual RDMA network card receives a resource destruction command sent from the virtual machine and the container, the resource destruction unit destroys the corresponding RDMA resources and shuts down the corresponding physical RDMA network card device.
[0010] Invention Function and Effect
[0011] The RDMA virtualization device supporting hybrid virtual environments provided by the present invention, having a conversion module, a unified management virtual layer, and a virtual RDMA network card with a unified interface, provides a unified RDMA virtualization framework for virtual machines and containers in hybrid virtualization environments. This framework differs from traditional network virtualization methods and enables these virtual machines and containers to utilize the high performance of RDMA.
[0012] Meanwhile, in the RDMA virtualization process of this invention, the resource mapping module maps resources and data to the user application space. Therefore, when transmitting data, the virtual layer can be bypassed, and the physical RDMA network card can directly access the content in the RDMA resources of the virtual machine and container, avoiding the delay of forwarding to the virtual layer and realizing zero copy. The RDMA performance of the virtual machine and container is close to the performance of the native RDMA, and is also different from the existing RDMA virtualization methods. Attached Figure Description
[0013] Figure 1 This is a structural block diagram of the RDMA virtualization device according to an embodiment of the present invention;
[0014] Figure 2 This is a connection diagram of the RDMA virtualization device according to an embodiment of the present invention;
[0015] Figure 3 This is a schematic diagram of virtual RDMA connection management according to an embodiment of the present invention;
[0016] Figure 4 This is a schematic diagram of RDMA resource mapping according to an embodiment of the present invention; and
[0017] Figure 5 This is a flowchart of the RDMA workflow according to an embodiment of the present invention. Detailed Implementation
[0018] To make the technical means, creative features, objectives and effects of the present invention easy to understand, the following describes the RDMA virtualization device supporting hybrid virtual environments of the present invention in detail with reference to embodiments and accompanying drawings.
[0019] <Example>
[0020] The RDMA virtualization device supporting the hybrid virtual environment in this embodiment is a server cluster equipped with an RDMA physical network card. The server operating system is Linux, and the virtualization layer listens for requests through Unix sockets.
[0021] Figure 1 This is a structural block diagram of the RDMA virtualization device according to an embodiment of the present invention. Figure 2 This is a connection diagram of the RDMA virtualization device according to an embodiment of the present invention.
[0022] like Figure 1 and Figure 2 As shown, the RDMA virtualization device 1 supporting hybrid virtual environments includes a virtual machine 11, a container 12, a virtual layer 13, and a physical RDMA network card 14.
[0023] Both virtual machine 11 and container 12 run applications and have interfaces for issuing connection request commands and resource destruction commands, as well as for transmitting data after the connection is established.
[0024] Virtual layer 13 is used for unified and centralized management of RDMA usage of virtual machine 11 and container 12.
[0025] like Figure 1 As shown, the virtual layer 13 has a conversion module 21, a virtual RDMA network card 22, a connection management module 23, a resource mapping module 24, a control module 25, and a routing rule storage module 26.
[0026] The conversion module 21 corresponds one-to-one with the virtual machine 11 and is used to convert the command information issued by the virtual machine 11 into a format consistent with that of the container.
[0027] The virtual RDMA network card 22 corresponds one-to-one with the virtual machine 11 and the container 12, and has a unified interface for receiving connection request commands and resource destruction commands.
[0028] Connection management module 23 is used to create requested RDMA connections for virtual machine 11 and container 12.
[0029] Resource mapping module 24 is used to map resources and data to the application space of virtual machine 11 and container 12.
[0030] The control module 25 is used to process received connection request commands and resource destruction commands.
[0031] The routing rule storage module 26 stores pre-configured routing rules.
[0032] In this embodiment, the pre-configured routing rule is that virtual machine 11 to container 12 is via virtual layer 13.
[0033] Start virtual layer 13 on the host, then start virtual machine 11 and container 12. Virtual layer 1 configures virtual RDMA network card 22 for virtual machine 11 and container 12.
[0034] After the above initialization work is completed, virtual machine 11 and container 12 can send connection request commands. These commands will be forwarded to the host virtual layer 13. The connection request command sent by virtual machine 11 will be converted to a format consistent with that of the container through a conversion module.
[0035] At this time, the control module 25 in the virtual layer 13 opens the physical RDMA network card 14 corresponding to the virtual RDMA network card 22. At the same time, the control module 25 creates corresponding RDMA resources for the virtual machine 11 and container 12, and maps the RDMA resources to the applications of the virtual machine 11 and container 12 through the resource mapping module 24.
[0036] Figure 3 This is a schematic diagram of virtual RDMA connection management according to an embodiment of the present invention.
[0037] like Figure 3 As shown, after receiving the connection request command, the connection management module 23 queries the routing rules configured in the routing rule storage module 26 to determine whether the corresponding RDMA connection is allowed to be established, and returns the command execution result to the virtual machine 11, container 12 and the application in container 31.
[0038] Figure 3 In the first instance, virtual machine 11 and container 12 are connected to the same virtual layer 13 and the same physical RDMA network card 14. The acquisition unit in the connection management module 23 obtains the routing rules stored in the routing rule storage module 26. The judgment unit determines that the connection is malicious based on the routing rules, so the connection management module 23 rejects the connection request and returns the result to virtual machine 11 and the application in container 12. Container 12 and container 31 are connected to different virtual layers and different physical RDMA network cards, but the judgment unit allows the connection to be established according to the routing rules. Therefore, the connection management module 23 establishes the corresponding RDMA connection and returns the result to container 12 and the application in container 31.
[0039] Applications in virtual machine 11 and container 12 can send resource destruction commands, which are also forwarded to virtual layer 13. After receiving the command, virtual layer 13 controls module 25 to destroy the corresponding RDMA resources and shut down the corresponding physical RDMA network card 14.
[0040] Figure 4 This is a schematic diagram of RDMA resource mapping according to an embodiment of the present invention.
[0041] like Figure 4As shown, after the RDMA connection is established in this embodiment, when the virtual machine 11 and container 12 use RDMA resources to send and receive data in the RDMA data path, the physical RDMA network card 14 can directly receive and execute work requests from the virtual machine 11 and container 12.
[0042] Figure 5 This is a flowchart of the RDMA workflow according to an embodiment of the present invention.
[0043] like Figure 5 As shown, the working process of the RDMA virtualization device 1 in a hybrid virtual environment includes the following steps:
[0044] Step 1: In the virtual machine and container, the connection request command is forwarded to the virtual layer. The control module uniformly opens the physical RDMA network card corresponding to the virtual RDMA network card and returns the result to the application in the virtual machine and container.
[0045] Step 2: When the virtual layer receives the command to create RDMA resources, the resource mapping module maps the RDMA resources to the applications of the virtual machine and the container.
[0046] Step 3: When the virtual layer receives the command, the connection management module will query the routing rules stored in the routing rule storage module. If the rules allow, a connection will be created based on the physical RDMA network card, and the result will be returned to the virtual machine and the application in the container.
[0047] Step 4: After the connection is established, data transfer operations between the virtual machine and the application in the container are executed directly on the local machine.
[0048] Step 5: After the transmission is completed, the virtual machine and the application in the container send a resource destruction command. After receiving the command, the virtual layer controls the destruction of the resources created by the physical RDMA network card, shuts down the corresponding physical RDMA network card device, and returns the result to the virtual machine and the application in the container.
[0049] Functions and effects of the embodiments
[0050] The RDMA virtualization device supporting hybrid virtual environments provided in this embodiment has a conversion module, a unified management virtual layer, and a virtual RDMA network card with a unified interface. Therefore, it provides a unified RDMA virtualization framework for virtual machines and containers in hybrid virtualization environments. This framework is different from traditional network virtualization methods and enables these virtual machines and containers to take advantage of the high performance of RDMA.
[0051] Meanwhile, during the RDMA virtualization process in this embodiment, the resource mapping module maps resources and data to the user application space. Therefore, when transmitting data, the virtual layer can be bypassed, and the physical RDMA network card can directly access the content in the RDMA resources of the virtual machine and container, avoiding the delay of forwarding to the virtual layer and realizing zero copy. The RDMA performance of the virtual machine and container is close to the performance of the native RDMA, and is also different from the existing RDMA virtualization methods.
[0052] The above embodiments are only used to illustrate specific implementations of the present invention, and the present invention is not limited to the scope of the description of the above embodiments.
[0053] In the above embodiment, an RDMA connection is established between a virtual machine and a container. In other embodiments of the present invention, an RDMA connection can also be established between virtual machines or between containers.
[0054] In the above embodiments, the RDMA virtualization device supporting hybrid virtual environments uses only one physical RDMA network card. In other embodiments of the present invention, multiple physical RDMA network cards may also be used.
Claims
1. An RDMA virtualization device supporting hybrid virtual environments, characterized in that, include: At least one virtual machine with a virtual machine interface; At least one container with a container interface; Physical RDMA network card; as well as, The virtual layer is communicatively connected to the virtual machine interface, container interface, and physical RDMA network card, respectively. The virtual layer includes multiple virtual RDMA network cards obtained by virtualizing the physical RDMA network card, a conversion module, a routing rule storage module, a connection management module, and a resource mapping module. The virtual RDMA network interface card corresponds one-to-one with the virtual machine and the container. The conversion module is used to convert the RDMA command information from the virtual machine interface so that the command format of the RDMA command information is consistent with the command format of the container interface. The RDMA command information includes at least a connection request command. The routing rule storage module stores pre-configured routing rules. When the virtual RDMA network interface receives a connection request command from the virtual machine and the container, the virtualization layer creates a corresponding RDMA resource and maps the RDMA resource to the virtual machine and the container through the resource mapping module. The connection management module establishes an RDMA connection between the virtual machine and the container based on the routing rules, enabling the virtual machine and the container to directly access each other's RDMA resources through the physical RDMA network card.
2. The RDMA virtualization apparatus supporting hybrid virtual environments according to claim 1, characterized in that, Also includes: The connection management module includes an acquisition unit, a judgment unit, and a connection creation unit. The acquisition unit retrieves pre-configured routing rules from the routing rule storage module. The decision unit, based on the routing rules, determines whether to allow the establishment of an RDMA connection between the virtual machine and the container. A connection creation unit is used to establish an RDMA connection between the virtual machine and the container based on the routing rules when the determination unit determines that it is true, so that the virtual machine and the container can directly access each other's RDMA resources through the physical RDMA network card.
3. The RDMA virtualization apparatus supporting hybrid virtual environments according to claim 1, characterized in that, Also includes: The connection management module also includes a resource destruction unit. The RDMA command information also includes resource destruction commands. When the virtual RDMA network card receives the resource destruction command sent by the virtual machine and the container, the resource destruction unit destroys the corresponding RDMA resources and shuts down the corresponding physical RDMA network card.
Citation Information
Patent Citations
Implementation method, implementation device and system of multi-core operating system
CN104077266B
Multi-kernel processing device based on multiple operating systems
CN104951374A
Virtual data center resource supplying method based on virtualization technology
CN107133083A
Memory sharing system and method based on virtual environment
CN112783667A