Disclosure of Invention
In view of the foregoing, it is desirable to provide a network communication establishment method, system, and computer device, which can reduce performance overhead when communication is performed between virtual machines in different network segments.
In a first aspect, the present application provides a network communication establishment method, applied to any one controller in a controller cluster of a cloud computing system, including:
Responding to a routing request of a first virtual machine, and determining a computing node where at least one second virtual machine to be connected is located;
and reflecting the route information of the first virtual machine to the computing node of each second virtual machine according to the connection mode of the computing node of each second virtual machine and the controller so as to complete the communication establishment between the first virtual machine and each second virtual machine.
In the network communication establishment method provided by the embodiment of the application, any one controller in a controller cluster of a cloud computing system responds to a routing request of a first virtual machine, at least one computing node where a second virtual machine to be established is located is first determined, and then the routing information of the first virtual machine is reflected to the computing node where the second virtual machine is located according to the connection mode of the computing node where the second virtual machine is located and the controller, so that communication establishment between the first virtual machine and the second virtual machines is completed, wherein the first virtual machine represents the virtual machine connected to the controller. According to the method, the controller cluster is arranged in the cloud computing system, so that direct communication between virtual machines of different network segments is established through any controller in the controller cluster, firstly, when a route request of a first virtual machine is received, a computing node where a second virtual machine is located is determined by the controller, then, based on a route reflection function of the controller, route information of the first virtual machine is reflected to the computing node where the second virtual machine is located, communication establishment between the first virtual machine and the second virtual machine is completed, direct communication between the first virtual machine and the second virtual machine is enabled, and therefore the controller achieves the shortest path of communication interaction between the virtual machines of different network segments, and performance cost in communication between the virtual machines of different network segments is reduced.
In one embodiment, determining a computing node where at least one second virtual machine to establish a connection is located includes:
acquiring configuration information of a network in a cloud computing system and network information of the network where a first virtual machine is located;
Acquiring a plurality of candidate computing nodes matched with the network information according to the configuration information of the network;
and determining other computing nodes except the computing node where the first virtual machine is located in each candidate computing node as the computing node where at least one second virtual machine to be connected is located.
In the network communication establishment method provided by the embodiment of the application, firstly, the configuration information of a network in a cloud computing system and the network information of a network where a first virtual machine is located are acquired, then, a plurality of candidate computing nodes matched with the network information are acquired according to the configuration information of the network, and then, other computing nodes except the computing node where the first virtual machine is located in each candidate computing node are determined to be the computing node where at least one second virtual machine to be connected is located. In the method, configuration information of a network environment in a cloud computing system and network information of a network where a first virtual machine is located are acquired, and then all computing nodes which are the same as the network information of the first virtual machine are acquired from the network configuration information, wherein the computing nodes comprise the computing nodes where the first virtual machine is located, so that other computing nodes except the computing nodes where the first virtual machine is located in the computing nodes are the computing nodes where a second virtual machine is located, which is equivalent to acquiring the computing nodes which are located in the same network with the first virtual machine as the computing nodes where the second virtual machine is located based on the network configuration information of the cloud computing system and the network information of the first virtual machine, and a foundation is provided for communication establishment between the first virtual machine and the second virtual machine.
In one embodiment, according to a connection mode between a computing node where each second virtual machine is located and a controller, reflecting routing information of the first virtual machine to the computing node where each second virtual machine is located, including:
For any computing node where the second virtual machine is located, if the computing node where the second virtual machine is located is directly connected with the controller, the routing information is directly reflected to the computing node where the second virtual machine is located;
If the second virtual machine computing node is connected with the controller through the second controller, the routing information is forwarded to the second controller, so that the second controller reflects the routing information to the computing node where the second virtual machine is located, and the controller is connected with the second controller in a full connection mode.
In the network communication establishment method provided by the embodiment of the application, for any computing node where a second virtual machine is located, if the computing node where the second virtual machine is located is directly connected with a controller, the routing information is directly reflected to the computing node where the second virtual machine is located, if the computing node where the second virtual machine is connected with the controller through the second controller, the routing information is forwarded to the second controller, so that the second controller reflects the routing information to the computing node where the second virtual machine is located, and the controller and the second controller are connected in a full connection mode. In the method, the connection mode of the computing node where the second virtual machine is located and the controller is divided into two types, when the connection mode is direct connection, the controller can directly reflect the route information to the computing node where the second virtual machine is located, and when the connection mode is indirect connection through the second controller, the controller needs to forward the route information of the first virtual machine to the second controller, and then the second controller reflects the route information to the computing node where the second virtual machine is located, which is equivalent to providing different route reflection modes based on different connection modes of the computing node where the second virtual machine is located and the controller, so that the route information of the first virtual machine is accurately synchronized to the computing node where the second virtual machine is located, and the communication establishment between the first virtual machine and the second virtual machine is accurately and efficiently completed.
In a second aspect, an embodiment of the present application further provides a network communication establishment method, which is applied to a computing node where a first virtual machine in a cloud computing system is located, where the method includes:
acquiring routing information of a first virtual machine;
And sending a routing request to the controller according to the routing information to instruct the controller to determine the computing node where at least one second virtual machine to be connected is located, reflecting the routing information of the first virtual machine to the computing node where each second virtual machine is located according to the connection mode of the computing node where each second virtual machine is located and the controller, and completing communication establishment between the first virtual machine and each second virtual machine, wherein the controller is a controller connected with the first virtual machine in a controller cluster of the cloud computing system.
In the network communication establishment method provided by the embodiment of the application, the computing node where the first virtual machine is located in the cloud computing system firstly acquires the routing information of the first virtual machine, and then sends a routing request to the controller according to the routing information to instruct the controller to determine the computing node where at least one second virtual machine to be connected is located, and reflects the routing information of the first virtual machine to the computing node where each second virtual machine is located according to the connection mode of the computing node where each second virtual machine is located and the controller, so that the communication establishment between the first virtual machine and each second virtual machine is completed, wherein the controller is a controller connected with the first virtual machine in a controller cluster of the cloud computing system. According to the method, a computing node where a first virtual machine is located sends a routing request to a controller connected with the first virtual machine in a controller cluster in a cloud computing system according to routing information of the first virtual machine, so that the controller can establish direct communication between virtual machines of different network segments, the controller firstly determines the computing node where a second virtual machine is located, then reflects the routing information of the first virtual machine to the computing node where the second virtual machine is located based on a routing reflection function of the controller, so that communication establishment between the first virtual machine and the second virtual machine is completed, the first virtual machine and the second virtual machine can be directly communicated, and therefore the controller can achieve the shortest path for communication interaction between the virtual machines of different network segments, and performance cost in communication between the virtual machines of different network segments is reduced.
In one embodiment, the computing node where the first virtual machine is located includes a first virtual router and a first virtual router agent, and the obtaining the routing information of the first virtual machine includes:
under the condition that the first virtual machine is started, the first virtual router generates a forwarding table item and informs the first virtual router agent through a network link communication mechanism;
and the first virtual router agent processes the forwarding table entry to obtain the routing information.
In the network communication establishment method provided by the embodiment of the application, the computing node where the first virtual machine is located comprises the first virtual router and the first virtual router agent, and under the condition that the first virtual machine is started, the first virtual router generates the forwarding table entry and informs the first virtual router agent through the network link communication mechanism, and then the first virtual router agent processes the forwarding table entry to obtain the routing information. In the method, a first virtual router and a first virtual router agent are arranged in a computing node where a first virtual machine is located, and are used for generating routing information of the first virtual machine, when the first virtual machine is detected to be started, the first virtual router generates a forwarding table item first and sends the forwarding table item to the first virtual router agent, so that the first virtual router agent translates the forwarding table item into the routing information, and a data basis is provided for a controller to establish network communication between the first virtual machine and a second virtual machine.
In one embodiment, the controller is connected with the computing node where the first virtual machine is located through an instant messaging protocol, and the method further comprises:
And the first virtual router agent sends the routing information to the controller through the instant messaging protocol under the condition that the routing information is acquired.
In the network communication establishment method provided by the embodiment of the application, the controller is connected with the computing node where the first virtual machine is located through an instant messaging protocol, and the first virtual router agent sends the routing information to the controller through the instant messaging protocol under the condition that the first virtual router agent obtains the routing information. In the method, after the first virtual router agent obtains the routing information of the first virtual machine, the routing information of the first virtual machine is sent to the controller, so that the controller reflects the routing information to complete communication establishment between the first virtual machine and the second virtual machine, and performance cost when the first virtual machine and the second virtual machine communicate is reduced.
In a third aspect, an embodiment of the present application further provides a network communication establishment method, which is applied to a computing node where a second virtual machine in a cloud computing system is located, where the method includes:
The method comprises the steps of receiving route information of a first virtual machine reflected by a controller, wherein the controller is a controller connected with the first virtual machine in a controller cluster of a cloud computing system, determining a computing node where at least one second virtual machine to be connected is located after the controller receives a route request of the first virtual machine, and reflecting the route information to the computing node where the second virtual machine is located according to a connection mode of the computing node where each second virtual machine is located and the controller;
and according to the routing information, completing communication establishment between the first virtual machine and the second virtual machine.
In the network communication establishment method provided by the embodiment of the application, the computing node of the second virtual machine in the cloud computing system receives the route information of the first virtual machine reflected by the controller, and completes communication establishment between the first virtual machine and the second virtual machine according to the route information, wherein the controller is a controller connected with the first virtual machine in a controller cluster of the cloud computing system, and the route information is reflected to the computing node of the second virtual machine according to the connection mode of the computing node of each second virtual machine and the controller after the controller determines that at least one second virtual machine to be connected is positioned under the condition that the controller receives the route request of the first virtual machine. According to the method, when a controller connected with a first virtual machine receives a routing request of the first virtual machine, a computing node where a second virtual machine is located is determined, then, based on a routing reflection function of the controller, routing information of the first virtual machine is reflected to the computing node where the second virtual machine is located, the computing node where the second virtual machine is located processes the received routing information so as to complete communication establishment between the first virtual machine and the second virtual machine, and direct communication between the first virtual machine and the second virtual machine can be achieved, so that the controller achieves the shortest path for communication interaction between virtual machines of different network segments, and performance cost in communication between the virtual machines of different network segments is reduced.
In one embodiment, the computing node where the second virtual machine is located includes a second virtual router and a second virtual router agent, and completing communication establishment between the first virtual machine and the second virtual machine according to the routing information includes:
The second virtual router agent sends the routing information to the second virtual router under the condition that the routing information of the first virtual machine reflected by the controller is received;
the second virtual router translates the routing information into forwarding entries to enable communication connection between the first virtual machine and the second virtual machine.
In the network communication establishment method provided by the embodiment of the application, the computing node where the second virtual machine is located comprises the second virtual router and the second virtual router agent, and the second virtual router agent sends the routing information to the second virtual router under the condition that the second virtual router agent receives the routing information of the first virtual machine reflected by the controller, so that the second virtual router translates the routing information into a forwarding table item to realize communication connection between the first virtual machine and the second virtual machine. In the method, a computing node where the second virtual machine is located comprises a second virtual router and a second virtual router agent, and the second virtual router agent is used for processing route information of the first virtual machine and completing communication establishment between the first virtual machine and the second virtual machine, wherein the second virtual router agent sends the route information to the second virtual router after receiving the route information of the first virtual machine, so that the second virtual router translates the route information into a forwarding table item, and communication connection between the first virtual machine and the second virtual machine is successfully established, thereby enabling the first virtual machine and the second virtual machine to be in direct communication, and reducing performance overhead during communication between the first virtual machine and the second virtual machine.
In a fourth aspect, the embodiment of the application also provides a network communication establishment system, which comprises a controller, a computing node where a first virtual machine is located and a computing node where a second virtual machine is located, wherein the first virtual machine is a virtual machine connected to the controller;
a controller for implementing the steps of the method in any one of the embodiments of the first aspect above;
The computing node where the first virtual machine is located is configured to implement the method in any one of the embodiments of the second aspect;
the computing node where the second virtual machine is located is configured to implement the steps of the method in any one of the embodiments of the third aspect.
In a fifth aspect, an embodiment of the present application further provides a network communication establishment apparatus, including:
the node determining module is used for responding to the routing request of the first virtual machine and determining the computing node where at least one second virtual machine to be connected is located;
The route reflection module is used for reflecting route information of the first virtual machine to the computing node where each second virtual machine is located according to the connection mode of the computing node where each second virtual machine is located and the controller so as to complete communication establishment between the first virtual machine and each second virtual machine.
In a sixth aspect, an embodiment of the present application further provides a network communication establishment apparatus, including:
the route information acquisition module is used for acquiring the route information of the first virtual machine;
The routing request sending module is used for sending a routing request to the controller according to the routing information so as to instruct the controller to determine the computing node where at least one second virtual machine to be connected is located, and reflecting the routing information of the first virtual machine to the computing node where each second virtual machine is located according to the connection mode of the computing node where each second virtual machine is located and the controller, so that the communication establishment between the first virtual machine and each second virtual machine is completed; the controller is a controller connected with the first virtual machine in a controller cluster of the cloud computing system.
In a seventh aspect, an embodiment of the present application further provides a network communication establishment apparatus, including:
the system comprises a route information receiving module, a controller and a controller, wherein the route information receiving module is used for receiving route information of a first virtual machine reflected by the controller, the controller is a controller connected with the first virtual machine in a controller cluster of a cloud computing system, and the route information is reflected to a computing node where each second virtual machine is located according to a connection mode of the computing node where each second virtual machine is located and the controller after the controller determines the computing node where at least one second virtual machine to be connected is located under the condition that the controller receives a route request of the first virtual machine;
And the communication establishment module is used for completing communication establishment between the first virtual machine and the second virtual machine according to the routing information.
In an eighth aspect, the present application also provides a computer device comprising a memory and a processor, the memory storing a computer program, the processor implementing the steps of the method in the first aspect, the second aspect or any one of the embodiments of the third aspect when the computer program is executed.
In a ninth aspect, the application also provides a computer readable storage medium having stored thereon a computer program which when executed by a processor performs the steps of the method of the first, second or third aspects described above, or any embodiment of the third aspect.
In a tenth aspect, the application also provides a computer program product comprising a computer program which, when executed by a processor, implements the steps of the method of any of the embodiments of the first, second or third aspects described above.
According to the network communication establishment method, the network communication establishment system and the computer equipment, any one controller in a controller cluster of a cloud computing system responds to a routing request of a first virtual machine, at least one computing node where a second virtual machine to be established is located is firstly determined, and then route information of the first virtual machine is reflected to the computing node where the second virtual machine is located according to a connection mode of the computing node where the second virtual machine is located and the controller, so that communication establishment between the first virtual machine and the second virtual machines is completed, wherein the first virtual machine represents the virtual machine connected to the controller. According to the method, the controller cluster is arranged in the cloud computing system, so that direct communication between virtual machines of different network segments is established through any controller in the controller cluster, firstly, when a route request of a first virtual machine is received, a computing node where a second virtual machine is located is determined by the controller, then, based on a route reflection function of the controller, route information of the first virtual machine is reflected to the computing node where the second virtual machine is located, communication establishment between the first virtual machine and the second virtual machine is completed, direct communication between the first virtual machine and the second virtual machine is enabled, and therefore the controller achieves the shortest path of communication interaction between the virtual machines of different network segments, and performance cost in communication between the virtual machines of different network segments is reduced.
Detailed Description
The present application will be described in further detail with reference to the drawings and examples, in order to make the objects, technical solutions and advantages of the present application more apparent. It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the scope of the application.
The technical background of the embodiments of the present application is described below.
A software-defined network (SoftwareDefinedNetwork, SDN) is an emerging network architecture whose core idea is to separate the control layer from the data layer of the network, manage the entire network through a centralized controller, and configure and manage the network in a software-based manner. The architecture enables a network administrator to dynamically adjust network behavior in a programmed manner, thereby improving flexibility and expandability of the network.
In a cloud computing environment, a two-layer network is realized between the same virtual private cloud (Virtual Private Cloud, VPC), so that the scale of a set of virtualized environment is directly determined by the nano tube scale of the virtual network, and the original implementation of openstack is taken as an example, the scale of a computing node of a set of neutron network nano tubes is about 300, the bottleneck is that the middleware of the neutron network is rabbitmq, and the problems of rabbitmq message backlog, loss and the like can occur under the condition of scale deployment. In the process of forwarding the virtual machine data packet, how to realize the shortest path is a matter to be considered by a software-defined network system, taking openstack native implementation as an example, two virtual machines in different network segments inside a tenant must communicate through a gateway node, so that performance overhead is brought, and the whole gateway node also becomes a forwarding bottleneck point of the whole virtual network.
Based on the above, the embodiment of the application provides a network communication establishment method, by setting a controller cluster in a cloud computing system, so as to establish direct communication between virtual machines of different network segments through any controller in the controller cluster, firstly, the controller determines a computing node where a second virtual machine is located when receiving a routing request of a first virtual machine, and then, based on a routing reflection function of the controller, reflects routing information of the first virtual machine to the computing node where the second virtual machine is located, so as to complete communication establishment between the first virtual machine and the second virtual machine, and enable the first virtual machine and the second virtual machine to directly communicate, thus, the controller realizes a shortest path for communication interaction between virtual machines of different network segments, and reduces performance cost when communicating between virtual machines of different network segments. Of course, the technical solutions provided in the embodiments of the present application are not limited to only solving the above-mentioned problems, and other technical effects exist, and can be specifically described in the following embodiments.
It should be noted that the beneficial effects or the technical problems to be solved by the embodiments of the present application are not limited to this one, but may be other implicit or related problems, and particularly, reference may be made to the following description of embodiments.
The following describes an application environment of the network communication establishment method provided by the embodiment of the present application, and may be applied to an application environment as shown in fig. 1. The controllers 104 in the controller cluster communicate with the computing nodes 102 through a network, and each controller 104 can communicate with each other. Optionally, the controllers are connected in a fully connected mode, for example, in an internal border gateway protocol fully meshed mode (Internal Border Gateway Protocol FULL-mesh, iBGP FULL-mesh). Each controller 104 is connected to a corresponding computing node in an instant messaging Protocol, for example, an Extensible messaging and presence Protocol (XMPP) connection. It should be noted that the number of controllers in the controller cluster may also be extended, and other controllers are not shown in fig. 1.
The following describes the technical scheme of the present application and how the technical scheme of the present application solves the above technical problems in detail with specific embodiments. The following embodiments may be combined with each other, and the same or similar concepts or processes may not be described in detail in some embodiments. Embodiments of the present application will be described below with reference to the accompanying drawings.
In an exemplary embodiment, as shown in fig. 2, a network communication establishment method is provided, and the method is applied to any one of the controllers 104 in fig. 1 for illustration, and includes the following steps 201 to 202. Wherein:
s201, determining a computing node where at least one second virtual machine to be connected is located in response to a routing request of a first virtual machine, wherein the first virtual machine represents a virtual machine connected to a controller.
The routing request of the first virtual machine establishes a request for the first virtual machine to initiate communication to the controller for establishing network communication with the second virtual machine. For example, the first virtual machine may send a routing request to the controller according to the routing information of the first virtual machine. The first virtual machine is a virtual machine connected to the controller, and can directly initiate a routing request to the controller.
When the controller receives a routing request of the first virtual machine, firstly determining a computing node where at least one second virtual machine to be connected is located. In the embodiment of the present application, the number of the second virtual machines may be one or more.
In one implementation, the controller may obtain the computing node where the second virtual machine is located by calling an application programming code interface (Application Programming Interface, API) provided by the cloud computing management platform. For example, the controller may obtain the detailed information of the second virtual machine by calling a corresponding API and transmitting an Identifier (Identifier , ID) or other unique identification information of the second virtual machine, where the detailed information includes related data of a computing node where the second virtual machine is located, such as a node name, an internet protocol (Internet Protocol, IP) address, and the like.
In another implementation manner, the controller may obtain network topology and network connection information of the virtual machine by communicating with an SDN controller in the cloud computing system. The SDN controller may provide a correspondence between an IP address of the virtual machine and a computing node where the SDN controller is located, so that the controller determines a location of the second virtual machine.
S202, according to the connection mode of the computing nodes of the second virtual machines and the controller, the routing information of the first virtual machine is reflected to the computing nodes of the second virtual machines, so that the communication establishment between the first virtual machine and the second virtual machines is completed.
After determining the computing node of the second virtual machine to be connected, the controller reflects the routing information of the first virtual machine to the computing node of each second virtual machine through the routing reflection function of the controller, so that the computing node of the second virtual machine processes the routing information of the first virtual machine, and communication establishment between the first virtual machine and the second virtual machine is completed.
When the routing information of the first virtual machine is reflected to the computing node where each second virtual machine is located, the controller may adopt different modes to reflect the routing information of the first virtual machine to the computing node where each second virtual machine is located based on the difference of the connection modes between the computing node where each second virtual machine is located and the controller.
In one scenario, the computing node where the second virtual machine is located is directly connected to the controller. For example, if the computing node where a certain second virtual machine is directly connected to the controller, the controller may directly reflect the routing information of the first virtual machine to the computing node where the second virtual machine is located, so that the computing node where the second virtual machine is located processes the received routing information, and communication establishment between the first virtual machine and the second virtual machine is implemented.
In another scenario, the connection mode between the computing node where the second virtual machine is located and the controller is indirect connection. For example, if the computing node where the second virtual machine is located is indirectly connected to the controller, the controller needs to process the routing information of the first virtual machine, and then reflect the routing information of the first virtual machine to the computing node where the second virtual machine is located, so that the computing node where the second virtual machine is located processes the received routing information, and communication establishment between the first virtual machine and the second virtual machine is achieved. For example, the manner in which the controller processes the routing information of the first virtual machine includes one or more of encryption processing, arithmetic processing, analysis processing, conversion processing, and forwarding processing.
In the embodiment of the application, in order to solve the problem of high performance expenditure during communication between virtual machines of different network segments, a controller cluster is introduced into a cloud computing system, so that the transverse expansion capability of a controller depends on the unified nano tube capability of a cloud network to a computing node, and the route reflection among computing nodes is completed through the route reflection function of each controller, so that network communication among the virtual machines of different network segments is established, direct communication interaction among the virtual machines of different network segments is realized, and the shortest interaction path among the virtual machines of different network segments is realized without a gateway node, thereby reducing the performance expenditure during communication among the virtual machines of different network segments. In addition, it should be noted that when the controller fails, the system may automatically select another controller to take over the operation of the controller, so as to complete the communication establishment between the first virtual machine and the second virtual machine, and ensure the reliability and performance of the system.
In the network communication establishment method provided by the embodiment of the application, any one controller in a controller cluster of a cloud computing system responds to a routing request of a first virtual machine, at least one computing node where a second virtual machine to be established is located is first determined, and then the routing information of the first virtual machine is reflected to the computing node where the second virtual machine is located according to the connection mode of the computing node where the second virtual machine is located and the controller, so that communication establishment between the first virtual machine and the second virtual machines is completed, wherein the first virtual machine represents the virtual machine connected to the controller. According to the method, the controller cluster is arranged in the cloud computing system, so that direct communication between virtual machines of different network segments is established through any controller in the controller cluster, firstly, when a route request of a first virtual machine is received, a computing node where a second virtual machine is located is determined by the controller, then, based on a route reflection function of the controller, route information of the first virtual machine is reflected to the computing node where the second virtual machine is located, communication establishment between the first virtual machine and the second virtual machine is completed, direct communication between the first virtual machine and the second virtual machine is enabled, and therefore the controller achieves the shortest path of communication interaction between the virtual machines of different network segments, and performance cost in communication between the virtual machines of different network segments is reduced.
Based on the above embodiments, an embodiment is provided for the above process of determining the computing node where the second virtual machine is located.
In an exemplary embodiment, as shown in fig. 3, determining a computing node where at least one second virtual machine to establish a connection is located includes:
S301, acquiring configuration information of a network in a cloud computing system and network information of a network where a first virtual machine is located.
For a cloud computing system adopting a software-defined network, different users can customize the network under the same controller, so that a plurality of networks exist in the cloud computing system, and the users can select the computing nodes at will under different networks. Based on the network communication, any virtual machine can establish network communication with the virtual machine on any computing node under the same network, so that any computing node under the same network as the first virtual machine can be used as the computing node where the second virtual machine is located.
Based on the above, in the embodiment of the application, the computing node which is in the same network as the first virtual machine is obtained as the computing node where the second virtual machine is located. Firstly, the controller needs to acquire network information of a network where the first virtual machine is located and acquire configuration information of a network environment in the cloud computing system, so that a computing node which is in the same network as the first virtual machine is determined based on the configuration information of the network environment and the network information of the first virtual machine. Wherein the network information of the first virtual machine includes, but is not limited to, a network name, a network identification ID, a network IP address, etc. of the first virtual machine.
S302, according to the configuration information of the network, a plurality of candidate computing nodes matched with the network information are obtained.
After acquiring the configuration information of the network in the cloud computing system and the network information of the network where the first virtual machine is located, the controller acquires a plurality of candidate computing nodes which are the same as the network information of the network where the first virtual machine is located from the configuration information of the network, wherein the candidate computing nodes are all the computing nodes of the network where the first virtual machine is located, and the computing nodes where the first virtual machine is located are included.
S303, determining other computing nodes except the computing node where the first virtual machine is located in each candidate computing node as the computing node where at least one second virtual machine to be connected is located.
The candidate computing nodes comprise computing nodes where the first virtual machine is located, based on the computing nodes where the first virtual machine is located, the computing nodes where the first virtual machine is located are removed from the candidate computing nodes, and the rest of the computing nodes are computing nodes which are located in the same network as the first virtual machine, namely, the computing nodes where at least one second virtual machine to be connected is located.
In the network communication establishment method provided by the embodiment of the application, firstly, the configuration information of a network in a cloud computing system and the network information of a network where a first virtual machine is located are acquired, then, a plurality of candidate computing nodes matched with the network information are acquired according to the configuration information of the network, and then, other computing nodes except the computing node where the first virtual machine is located in each candidate computing node are determined to be the computing node where at least one second virtual machine to be connected is located. In the method, configuration information of a network environment in a cloud computing system and network information of a network where a first virtual machine is located are acquired, and then all computing nodes which are the same as the network information of the first virtual machine are acquired from the network configuration information, wherein the computing nodes comprise the computing nodes where the first virtual machine is located, so that other computing nodes except the computing nodes where the first virtual machine is located in the computing nodes are the computing nodes where a second virtual machine is located, which is equivalent to acquiring the computing nodes which are located in the same network with the first virtual machine as the computing nodes where the second virtual machine is located based on the network configuration information of the cloud computing system and the network information of the first virtual machine, and a foundation is provided for communication establishment between the first virtual machine and the second virtual machine.
Based on the above embodiments, an embodiment will be described for the above procedure of reflecting the routing information of the first virtual machine.
In an exemplary embodiment, according to a connection manner between a computing node where each second virtual machine is located and a controller, reflecting route information of the first virtual machine to the computing node where each second virtual machine is located includes:
For any computing node where the second virtual machine is located, if the computing node where the second virtual machine is located is directly connected with the controller, the routing information is directly reflected to the computing node where the second virtual machine is located, if the computing node where the second virtual machine is located is connected with the controller through the second controller, the routing information is forwarded to the second controller so that the second controller reflects the routing information to the computing node where the second virtual machine is located, and the controller and the second controller are connected in a full connection mode.
In the embodiment of the present application, the connection mode between the computing node where the second virtual machine is located and the controller is divided into two types, one type is that the computing node where the second virtual machine is located is directly connected to the controller, taking fig. 1 as an example, the first virtual machine is a virtual machine on any one computing node connected to the first controller in fig. 1, at this time, the controller is the first controller, if the computing node where the second virtual machine is located is also any one computing node connected to the first controller, the computing node where the second virtual machine is located is directly connected to the first controller, and the other type is that the computing node where the second virtual machine is located is connected to the controller through the second controller, still taking fig. 1 as an example, the first virtual machine is a controller on any one computing node connected to the first controller in fig. 1, at this time, if the computing node where the second virtual machine is located is any one computing node connected to the second controller, the second virtual machine is connected to the first controller, and the second virtual machine is located through the second controller.
When the computing node of the second virtual machine is directly connected with the controller, the controller can directly reflect the routing information to the computing node of the second virtual machine. In the embodiment of the present application, each controller is connected to a computing node by an instant messaging protocol, for example, an XMPP protocol, so that the controller may reflect the routing information of the first virtual machine to the computing node where the second virtual machine is located through the XMPP protocol.
When the computing node where the second virtual machine is located is connected with the controller through the second controller, the controller can forward the routing information of the first virtual machine to the second controller, and then the second controller reflects the routing information of the first virtual machine to the node where the second virtual machine is located. The controller and the second controller are connected in a FULL connection mode, for example, iBGP FULL-mesh is used for connection, so that the controller can reflect the route information of the first virtual machine to the second controller through iBGP, and if the second controller is still connected with the computing node where the second virtual machine is located by XMPP protocol, the second controller also reflects the route information of the first virtual machine to the computing node where the second virtual machine is located through XMPP protocol.
In the network communication establishment method provided by the embodiment of the application, for any computing node where a second virtual machine is located, if the computing node where the second virtual machine is located is directly connected with a controller, the routing information is directly reflected to the computing node where the second virtual machine is located, if the computing node where the second virtual machine is connected with the controller through the second controller, the routing information is forwarded to the second controller, so that the second controller reflects the routing information to the computing node where the second virtual machine is located, and the controller and the second controller are connected in a full connection mode. In the method, the connection mode of the computing node where the second virtual machine is located and the controller is divided into two types, when the connection mode is direct connection, the controller can directly reflect the route information to the computing node where the second virtual machine is located, and when the connection mode is indirect connection through the second controller, the controller needs to forward the route information of the first virtual machine to the second controller, and then the second controller reflects the route information to the computing node where the second virtual machine is located, which is equivalent to providing different route reflection modes based on different connection modes of the computing node where the second virtual machine is located and the controller, so that the route information of the first virtual machine is accurately synchronized to the computing node where the second virtual machine is located, and the communication establishment between the first virtual machine and the second virtual machine is accurately and efficiently completed.
The above description is directed to the embodiment related to the execution subject side of the controller. The embodiment of the application also provides the corresponding embodiment of the process for the execution main body by using the computing node where the first virtual machine is located. Next, a description will be given of related embodiments of a network communication establishment method that uses a computing node where a first virtual machine is located as an execution subject.
In an exemplary embodiment, as shown in fig. 4, a network communication establishment method is provided, which is applied to a computing node where a first virtual machine in a cloud computing system is located, and the method includes:
s401, obtaining the route information of the first virtual machine.
In one embodiment, the routing information of the first virtual machine may be obtained through a virtualization management platform in the cloud computing system. Generally, a virtualized management platform in a cloud computing system centrally manages network configuration of virtual machines, and an administrator configures network parameters for a first virtual machine on the management platform, including routing related information such as an IP address, a subnet mask, and the like. The computing node where the first virtual machine is located can acquire the routing information of the first virtual machine by calling an API interface provided by the virtualization management platform.
In another embodiment, the routing information of the first virtual machine may be obtained by the SDN controller. In the software defined network architecture, an SDN controller is responsible for managing and controlling traffic and routing in the network, and routing information of the first virtual machine is centrally managed and distributed by the SDN controller. The computing node where the first virtual machine is located is used as a node in the SDN network, is communicated with the SDN controller, and can receive the routing information of the first virtual machine issued by the SDN controller.
And S402, sending a routing request to a controller according to the routing information to instruct the controller to determine a computing node where at least one second virtual machine to be connected is located, reflecting the routing information of the first virtual machine to the computing node where each second virtual machine is located according to the connection mode of the computing node where each second virtual machine is located and the controller, and completing communication establishment between the first virtual machine and each second virtual machine, wherein the controller is a controller connected with the first virtual machine in a controller cluster of the cloud computing system.
And after receiving the routing information of the first virtual machine, the computing node where the first virtual machine is located sends a routing request to the controller according to the routing information, so that the controller completes communication establishment between the first virtual machine and the second virtual machine after receiving the routing request. The controller is a controller connected with the first virtual machine in a controller cluster of the cloud computing system.
When receiving a routing request of a first virtual machine, a controller firstly determines a computing node where at least one second virtual machine to be connected is located, and reflects routing information of the first virtual machine to the computing node where the second virtual machine is located according to a connection mode of the computing node where each second virtual machine is located and the controller, so that communication establishment between the first virtual machine and each second virtual machine is completed. The communication establishment procedure performed by the controller may refer to the foregoing embodiments, and will not be described herein.
In the network communication establishment method provided by the embodiment of the application, the computing node where the first virtual machine is located in the cloud computing system firstly acquires the routing information of the first virtual machine, and then sends a routing request to the controller according to the routing information to instruct the controller to determine the computing node where at least one second virtual machine to be connected is located, and reflects the routing information of the first virtual machine to the computing node where each second virtual machine is located according to the connection mode of the computing node where each second virtual machine is located and the controller, so that the communication establishment between the first virtual machine and each second virtual machine is completed, wherein the controller is a controller connected with the first virtual machine in a controller cluster of the cloud computing system. According to the method, a computing node where a first virtual machine is located sends a routing request to a controller connected with the first virtual machine in a controller cluster in a cloud computing system according to routing information of the first virtual machine, so that the controller can establish direct communication between virtual machines of different network segments, the controller firstly determines the computing node where a second virtual machine is located, then reflects the routing information of the first virtual machine to the computing node where the second virtual machine is located based on a routing reflection function of the controller, so that communication establishment between the first virtual machine and the second virtual machine is completed, the first virtual machine and the second virtual machine can be directly communicated, and therefore the controller can achieve the shortest path for communication interaction between the virtual machines of different network segments, and performance cost in communication between the virtual machines of different network segments is reduced.
Based on the above embodiments, the above process of obtaining the routing information of the first virtual machine is described in an embodiment.
In an exemplary embodiment, as shown in fig. 5, a computing node where a first virtual machine is located includes a first virtual router and a first virtual router agent, and obtaining routing information of the first virtual machine includes:
S501, under the condition that the first virtual machine is started, the first virtual router generates a forwarding table item and informs the first virtual router agent through a network link communication mechanism.
In the embodiment of the application, the computing node where the first virtual machine is located further comprises a first virtual router and a first virtual router agent besides the first virtual machine.
When the computing node where the first virtual machine is located obtains the routing information of the first virtual machine, the routing information can be obtained through a first virtual router and a first virtual router agent deployed in the computing node where the first virtual machine is located.
Under the condition that the first virtual machine is detected to be started, a first virtual router in a computing node where the first virtual machine is located generates a forwarding table entry and informs the first virtual router agent through a network link Socket (Netlink). The first virtual router may generate the forwarding table item based on network related information of the first virtual machine in the configuration information of the network. Wherein the network related information of the first virtual machine includes an IP address of the first virtual machine, a subnet mask, and the like.
S502, the first virtual router agent processes the forwarding table entry to obtain the routing information.
When the first virtual router agent receives the forwarding table entry sent by the first virtual router, the first virtual router agent translates the received forwarding table entry into route information, and then the route information of the first virtual machine is obtained. The forwarding table item is translated into the routing information, and key information is mainly extracted from the forwarding table item and is arranged according to the format and specification of the routing information. For example, destination network information, next hop address, interface, etc. information is extracted from the forwarding table entry.
In the network communication establishment method provided by the embodiment of the application, the computing node where the first virtual machine is located comprises the first virtual router and the first virtual router agent, and under the condition that the first virtual machine is started, the first virtual router generates the forwarding table entry and informs the first virtual router agent through the network link communication mechanism, and then the first virtual router agent processes the forwarding table entry to obtain the routing information. In the method, a first virtual router and a first virtual router agent are arranged in a computing node where a first virtual machine is located, and are used for generating routing information of the first virtual machine, when the first virtual machine is detected to be started, the first virtual router generates a forwarding table item first and sends the forwarding table item to the first virtual router agent, so that the first virtual router agent translates the forwarding table item into the routing information, and a data basis is provided for a controller to establish network communication between the first virtual machine and a second virtual machine.
Based on the above embodiment, an embodiment is provided for the procedure of processing the routing information by the first virtual router.
In an exemplary embodiment, the controller is connected with the computing node where the first virtual machine is located through an instant messaging protocol, and the method further comprises:
and the first virtual router agent sends the routing information to the controller through an instant messaging protocol under the condition that the routing information is acquired.
In the embodiment of the present application, each controller is connected to a corresponding computing node through an instant messaging protocol, and then the controller is also connected to the computing node where the first virtual machine is located through the instant messaging protocol, for example, through an XMPP protocol.
And after the first virtual router translates the forwarding table entry into the routing information to obtain the routing information of the first virtual machine, the routing information of the first virtual machine is sent to the controller. The first virtual router sends the route information of the first virtual machine through an instant messaging protocol.
In the network communication establishment method provided by the embodiment of the application, the controller is connected with the computing node where the first virtual machine is located through an instant messaging protocol, and the first virtual router agent sends the routing information to the controller through the instant messaging protocol under the condition that the first virtual router agent obtains the routing information. In the method, after the first virtual router agent obtains the routing information of the first virtual machine, the routing information of the first virtual machine is sent to the controller, so that the controller reflects the routing information to complete communication establishment between the first virtual machine and the second virtual machine, and performance cost when the first virtual machine and the second virtual machine communicate is reduced.
The above description is directed to the embodiment in which the computing node where the first virtual machine is located is the execution subject side. The embodiment of the application also provides the corresponding embodiment of the process for the execution main body by using the computing node where the second virtual machine is located. Next, a description will be given of related embodiments of a network communication establishment method that uses a computing node where a second virtual machine is located as an execution subject.
In an exemplary embodiment, as shown in fig. 6, a network communication establishment method is provided, which is applied to a computing node where a second virtual machine in a cloud computing system is located, and the method includes:
The method comprises the steps of S601, receiving route information of a first virtual machine reflected by a controller, wherein the controller is a controller connected with the first virtual machine in a controller cluster of a cloud computing system, and the route information is reflected to a computing node where each second virtual machine is located according to a connection mode of the computing node where each second virtual machine is located and the controller after the controller determines the computing node where at least one second virtual machine to be connected is located under the condition that the controller receives a route request of the first virtual machine.
The controller is a controller connected with a first virtual machine in a controller cluster of the cloud computing system, after receiving a routing request of the first virtual machine, the controller determines a computing node where at least one second virtual machine to be connected is located, and reflects routing information of the first virtual machine to the computing node where the second virtual machine is located according to a connection mode of the computing node where the second virtual machine is located and the controller, so that the computing node where the second virtual machine is located receives the routing information of the first virtual machine reflected by the control. The method for determining the computing node where the second virtual machine is located and the method for reflecting the routing information of the first virtual machine by the controller can refer to the foregoing embodiments, and are not described herein again.
S602, according to the routing information, the communication establishment between the first virtual machine and each second virtual machine is completed.
After the computing node where the second virtual machine is located receives the routing information of the first virtual machine, network communication between the first virtual machine and the second virtual machine is realized based on the routing information of the first virtual machine.
The computing node where the second virtual machine is located can process the received routing information of the first virtual machine, so that communication between the first virtual machine and the second virtual machine is established.
For example, after receiving the routing information of the first virtual machine, the second virtual machine may perform accuracy verification and network reachability verification on the routing information. For example, whether the destination network address, the subnet mask, the next hop address, etc. in the routing information are accurate or not is checked, so that the information is complete and accords with the network configuration rule. And sending a network reachability test request according to the received routing information, thereby checking whether the network of the first virtual machine is reachable.
In the network communication establishment method provided by the embodiment of the application, the computing node of the second virtual machine in the cloud computing system receives the route information of the first virtual machine reflected by the controller, and completes communication establishment between the first virtual machine and the second virtual machine according to the route information, wherein the controller is a controller connected with the first virtual machine in a controller cluster of the cloud computing system, and the route information is reflected to the computing node of the second virtual machine according to the connection mode of the computing node of each second virtual machine and the controller after the controller determines that at least one second virtual machine to be connected is positioned under the condition that the controller receives the route request of the first virtual machine. According to the method, when a controller connected with a first virtual machine receives a routing request of the first virtual machine, a computing node where a second virtual machine is located is determined, then, based on a routing reflection function of the controller, routing information of the first virtual machine is reflected to the computing node where the second virtual machine is located, the computing node where the second virtual machine is located processes the received routing information so as to complete communication establishment between the first virtual machine and the second virtual machine, and direct communication between the first virtual machine and the second virtual machine can be achieved, so that the controller achieves the shortest path for communication interaction between virtual machines of different network segments, and performance cost in communication between the virtual machines of different network segments is reduced.
Based on the above embodiments, an embodiment is described for the above process of establishing communication between the first virtual machine and the second virtual machine.
In an exemplary embodiment, as shown in fig. 7, the computing node where the second virtual machine is located includes a second virtual router and a second virtual router agent, and completing communication establishment between the first virtual machine and the second virtual machine according to the routing information includes:
s701, the second virtual router agent, upon receiving the route information of the first virtual machine reflected by the controller, transmits the route information to the second virtual router.
In the embodiment of the application, the computing node where the second virtual machine is located also comprises a virtual router and a virtual router agent, which are respectively the second virtual router and the second virtual router agent, and the second virtual router agent is used for processing the routing information of the first virtual machine so as to establish network communication between the first virtual machine and the second virtual machine.
When the controller reflects the route information of the first virtual machine to the computing node where the second virtual machine is located, the route information is directly received by a second virtual router agent in the computing node where the second virtual machine is located, and after receiving the route information of the first virtual machine, the second virtual router agent directly sends the route information of the first virtual machine to the second virtual router. The second virtual router agent can send the route information of the first virtual machine to the second virtual router through the Netlink.
S702, the second virtual router translates the routing information into a forwarding table entry to realize communication connection between the first virtual machine and the second virtual machine.
And the second virtual router translates the routing information into a forwarding table entry after receiving the routing information of the first virtual machine, so that communication connection between the first virtual machine and the second virtual machine is realized.
In the network communication establishment method provided by the embodiment of the application, the computing node where the second virtual machine is located comprises the second virtual router and the second virtual router agent, and the second virtual router agent sends the routing information to the second virtual router under the condition that the second virtual router agent receives the routing information of the first virtual machine reflected by the controller, so that the second virtual router translates the routing information into a forwarding table item to realize communication connection between the first virtual machine and the second virtual machine. In the method, a computing node where the second virtual machine is located comprises a second virtual router and a second virtual router agent, and the second virtual router agent is used for processing route information of the first virtual machine and completing communication establishment between the first virtual machine and the second virtual machine, wherein the second virtual router agent sends the route information to the second virtual router after receiving the route information of the first virtual machine, so that the second virtual router translates the route information into a forwarding table item, and communication connection between the first virtual machine and the second virtual machine is successfully established, thereby enabling the first virtual machine and the second virtual machine to be in direct communication, and reducing performance overhead during communication between the first virtual machine and the second virtual machine.
In addition, in an exemplary embodiment, a procedure of network communication establishment and data transmission after network communication establishment in the present application will be described.
The iBGP FULL-mesh connection between the controller clusters, the XMPP connection between the controller and the compute nodes, the single controller supports approximately 500 compute nodes, and when the physical cluster is larger, the number of controllers can be laterally expanded to support larger compute nodes.
BGP FULL mesh mode provides a highly reliable route delivery mechanism by ensuring that each node establishes BGP connections with all other nodes, helping to quickly resume communication in the event of a network failure, since traffic can be routed through other paths even if some paths fail. Although BGP FULL mesh mode can be challenging in large networks, it still has good scalability in small and medium-scale controller clusters. By adding new nodes and connections, the controller scale can be easily extended. The size limitation of BGP FULL mesh mode is mainly reflected in the number of nodes. In BGP FULL mesh mode, each node needs to establish BGP connection with all other nodes. Thus, as the number of control nodes increases, the number of connections each node needs to maintain increases exponentially. This may result in ① resource consumption in that each node needs to consume a relatively large amount of CPU, memory, and network bandwidth to maintain BGP connections with other nodes. When the number of nodes is large, this may lead to resource bottlenecks, affecting the performance and stability of the network. ② The convergence speed is slower, and the BGP FULL mesh mode may result in a slower convergence speed. When a network change occurs (e.g., a node failure or a route update), all nodes need to recalculate the route and update their BGP connections, which may cause traffic disruption or increased delay in the network.
Based on the above considerations, the number of nodes to which BGP FULL mesh mode is applicable is typically within 100 controller nodes of the network environment. In sum, the theoretical scale of the unified nano-tube capacity of the cloud network is 50000 computing nodes, so that the unified nano-tube capacity of the cloud network is greatly improved.
In the embodiment of the application, the controller reflects the routes of all the computing nodes to realize the overall management and control of the whole network route, and the virtual router translates the route information into the forwarding table entry in each computing node to finally realize the shortest path of the virtual machine mutual access. The controller mainly comprises two parts, one part is configured and issued, the other part is route reflection, the configured and issued mainly completes the configuration information of the whole network environment, such as the configuration information of a network, a subnet and the like, and the route reflection mainly completes the route reflection among the cross-computing nodes.
As shown in fig. 8, the shortest path of the physical network is implemented through the data center physical network of backbone/leaf structure in combination with the distributed gateway function of the switch. At the virtual network layer, the controller uniformly controls the full-virtual network routing data, and the mutual access of the same tenant virtual machine is only one hop, so that the optimal path is finally realized. The physical machine IP addresses are 10.0.36.2 and 10.0.36.3, and the virtual machine addresses are cross-subnet segments 192.168.1.2/24 and 192.168.2.2/24.
The process of establishing network communication between the first virtual machine and the second virtual machine is as follows:
(1) And starting the first virtual machine, generating a forwarding table item by the first virtual machine router, and informing the first virtual router agent through the Netlink.
(2) The first virtual router agent translates the forwarding table entry into routing information that is sent to the controller via XMPP protocol.
(3) The controller reflects the routing information to a second virtual router agent of a computing node where the second virtual machine is located through an XMPP protocol.
(4) And after receiving the routing information of the first virtual machine, the second virtual router agent sends the routing information to the second virtual router through the Netlink.
(5) The second virtual router translates the routing information into forwarding entries to complete communication establishment between the first virtual machine and the second virtual machine.
After the communication between the first virtual machine and the second virtual machine is established, the first virtual machine can directly perform data transmission with the second virtual machine.
In the data forwarding process of the first virtual router, the first virtual router forwards (Virtual Routing and Forwarding, VRF) two-layer and three-layer forwarding table items according to the virtual router, and a virtual machine is used for sending data messages for example:
(1) The first virtual router receives a message from the virtual machine interface.
(2) The flow table is looked up and the action corresponding to the flow is performed if any already exists.
(3) If the flow action is route forwarding, the VRF two-layer, three-layer and next-hop entries are searched.
(4) And encapsulating the virtual extended local area network (Virtual eXtensible Local Area Network, vxlan) message according to the address of the target physical node, and sending out the virtual extended local area network (Virtual eXtensible Local Area Network, vxlan) message.
In the embodiment, the cross-subnet communication does not need to pass through gateway nodes, the path is shortest, the performance cost in the communication between the virtual machines of different network segments is reduced, the expansion capacity of the controller is strong, and the scale of the unified nano-tube computing node is large.
It should be understood that, although the steps in the flowcharts related to the embodiments described above are sequentially shown as indicated by arrows, these steps are not necessarily sequentially performed in the order indicated by the arrows. The steps are not strictly limited to the order of execution unless explicitly recited herein, and the steps may be executed in other orders. Moreover, at least some of the steps in the flowcharts described in the above embodiments may include a plurality of steps or a plurality of stages, which are not necessarily performed at the same time, but may be performed at different times, and the order of the steps or stages is not necessarily performed sequentially, but may be performed alternately or alternately with at least some of the other steps or stages.
Based on the same inventive concept, the embodiment of the application also provides a network communication establishment system. The implementation of the solution provided by the system is similar to the implementation described in the above method, so the specific limitation in the one or more network communication establishment systems provided below may be referred to the limitation in the network communication establishment method above, and will not be repeated here.
In an exemplary embodiment, the network communication establishment system comprises a controller, a computing node where a first virtual machine is located and a computing node where a second virtual machine is located, wherein the first virtual machine is a virtual machine connected to the controller;
The method comprises the steps of executing the method in any embodiment taking the controller as an execution subject, the steps of executing the method in any embodiment taking the computing node of the first virtual machine as the execution subject by the first virtual machine, and the steps of executing the method in any embodiment taking the computing node of the second virtual machine as the execution subject by the second virtual machine.
Based on the same inventive concept, the embodiment of the application also provides a network communication establishment device for realizing the above-mentioned network communication establishment method. The implementation of the solution provided by the device is similar to the implementation described in the above method, so the specific limitation in the embodiments of the network communication establishment device or devices provided below may be referred to the limitation of the network communication establishment method hereinabove, and will not be described herein.
In one exemplary embodiment, as shown in fig. 9, there is provided a network communication establishment apparatus including a node determination module 10 and a route reflection module 20, wherein:
the node determining module 10 is configured to determine, in response to a routing request of a first virtual machine, a computing node where at least one second virtual machine to be connected is located;
The route reflection module 20 is configured to reflect route information of the first virtual machine to the computing node where each second virtual machine is located according to a connection mode between the computing node where each second virtual machine is located and the controller, so as to complete communication establishment between the first virtual machine and each second virtual machine.
In one embodiment, the node determining module 10 is further configured to:
The method comprises the steps of obtaining configuration information of a network in a cloud computing system and network information of a network where a first virtual machine is located, obtaining a plurality of candidate computing nodes matched with the network information according to the configuration information of the network, and determining other computing nodes except the computing node where the first virtual machine is located in each candidate computing node as computing nodes where at least one second virtual machine to be connected is located.
In one embodiment, the route reflection module 20 is further configured to:
For any computing node where the second virtual machine is located, if the computing node where the second virtual machine is located is directly connected with the controller, the routing information is directly reflected to the computing node where the second virtual machine is located, if the computing node where the second virtual machine is located is connected with the controller through the second controller, the routing information is forwarded to the second controller so that the second controller reflects the routing information to the computing node where the second virtual machine is located, and the controller and the second controller are connected in a full connection mode.
In an exemplary embodiment, as shown in fig. 10, there is provided a network communication establishment apparatus including a routing information acquisition module 30 and a routing request transmission module 40, wherein:
A route information obtaining module 30, configured to obtain route information of the first virtual machine;
the routing request sending module 40 is configured to send a routing request to the controller according to the routing information, so as to instruct the controller to determine a computing node where at least one second virtual machine to be connected is located, reflect the routing information of the first virtual machine to the computing node where each second virtual machine is located according to a connection mode between the computing node where each second virtual machine is located and the controller, and complete communication establishment between the first virtual machine and each second virtual machine, where the controller is a controller connected with the first virtual machine in a controller cluster of the cloud computing system.
In one embodiment, the routing information acquisition module 30 is further configured to:
Under the condition that the first virtual machine is started, the first virtual router generates a forwarding table item and informs the first virtual router agent through a network link communication mechanism, and the first virtual router agent processes the forwarding table item to obtain routing information.
In one embodiment, the network communication establishment apparatus further includes:
and the route information sending module is used for sending the route information to the controller through the instant messaging protocol under the condition that the first virtual router agent acquires the route information.
In one exemplary embodiment, as shown in fig. 11, there is provided a network communication establishment apparatus including a routing information receiving module 50 and a communication establishment module 60, wherein:
the route information receiving module 50 is used for receiving route information of a first virtual machine reflected by a controller, wherein the controller is a controller connected with the first virtual machine in a controller cluster of the cloud computing system, and the route information is reflected to a computing node where each second virtual machine is located according to a connection mode of the computing node where each second virtual machine is located and the controller after the controller determines the computing node where at least one second virtual machine to be connected is located under the condition that the controller receives a route request of the first virtual machine;
The communication establishment module 60 is configured to complete communication establishment between the first virtual machine and the second virtual machine according to the routing information.
In one embodiment, the communication establishment module 60 is further configured to:
the second virtual router agent sends the routing information to the second virtual router under the condition that the routing information of the first virtual machine reflected by the controller is received; the second virtual router translates the routing information into forwarding entries to enable communication connection between the first virtual machine and the second virtual machine.
The respective modules in the above-described network communication establishing apparatus may be implemented in whole or in part by software, hardware, and a combination thereof. The above modules may be embedded in hardware or may be independent of a processor in the computer device, or may be stored in software in a memory in the computer device, so that the processor may call and execute operations corresponding to the above modules.
In one exemplary embodiment, a computer device is provided, which may be a server, and the internal structure thereof may be as shown in fig. 12. The computer device includes a processor, a memory, an Input/Output interface (I/O) and a communication interface. The processor, the memory and the input/output interface are connected through a system bus, and the communication interface is connected to the system bus through the input/output interface. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The database of the computer device is for storing network communication setup data. The input/output interface of the computer device is used to exchange information between the processor and the external device. The communication interface of the computer device is used for communicating with an external terminal through a network connection. The computer program is executed by a processor to implement a network communication establishment method.
It will be appreciated by those skilled in the art that the structure shown in FIG. 12 is merely a block diagram of some of the structures associated with the present inventive arrangements and is not limiting of the computer device to which the present inventive arrangements may be applied, and that a particular computer device may include more or fewer components than shown, or may combine some of the components, or have a different arrangement of components.
In one exemplary embodiment, a computer device is provided comprising a memory and a processor, the memory having stored therein a computer program, the processor when executing the computer program performing the steps of:
Responding to a routing request of a first virtual machine, and determining a computing node where at least one second virtual machine to be connected is located;
and reflecting the route information of the first virtual machine to the computing node of each second virtual machine according to the connection mode of the computing node of each second virtual machine and the controller so as to complete the communication establishment between the first virtual machine and each second virtual machine.
The implementation principle and technical effect of each step implemented by the processor in the embodiment of the present application are similar to those of the above network communication establishment method, and are not described herein.
In one embodiment, a computer readable storage medium is provided having a computer program stored thereon, which when executed by a processor, performs the steps of:
Responding to a routing request of a first virtual machine, and determining a computing node where at least one second virtual machine to be connected is located;
and reflecting the route information of the first virtual machine to the computing node of each second virtual machine according to the connection mode of the computing node of each second virtual machine and the controller so as to complete the communication establishment between the first virtual machine and each second virtual machine.
The steps implemented when the computer program is executed by the processor in the embodiment of the present application, the implementation principle and the technical effect are similar to those of the above network communication establishment method, and are not described herein again.
In one embodiment, a computer program product is provided comprising a computer program which, when executed by a processor, performs the steps of:
Responding to a routing request of a first virtual machine, and determining a computing node where at least one second virtual machine to be connected is located;
and reflecting the route information of the first virtual machine to the computing node of each second virtual machine according to the connection mode of the computing node of each second virtual machine and the controller so as to complete the communication establishment between the first virtual machine and each second virtual machine.
The steps implemented when the computer program is executed by the processor in the embodiment of the present application, the implementation principle and the technical effect are similar to those of the above network communication establishment method, and are not described herein again.
In one exemplary embodiment, a computer device is provided comprising a memory and a processor, the memory having stored therein a computer program, the processor when executing the computer program performing the steps of:
acquiring routing information of a first virtual machine;
And sending a routing request to the controller according to the routing information to instruct the controller to determine the computing node where at least one second virtual machine to be connected is located, reflecting the routing information of the first virtual machine to the computing node where each second virtual machine is located according to the connection mode of the computing node where each second virtual machine is located and the controller, and completing communication establishment between the first virtual machine and each second virtual machine, wherein the controller is a controller connected with the first virtual machine in a controller cluster of the cloud computing system.
The implementation principle and technical effect of each step implemented by the processor in the embodiment of the present application are similar to those of the above network communication establishment method, and are not described herein.
In one embodiment, a computer readable storage medium is provided having a computer program stored thereon, which when executed by a processor, performs the steps of:
acquiring routing information of a first virtual machine;
And sending a routing request to the controller according to the routing information to instruct the controller to determine the computing node where at least one second virtual machine to be connected is located, reflecting the routing information of the first virtual machine to the computing node where each second virtual machine is located according to the connection mode of the computing node where each second virtual machine is located and the controller, and completing communication establishment between the first virtual machine and each second virtual machine, wherein the controller is a controller connected with the first virtual machine in a controller cluster of the cloud computing system.
The steps implemented when the computer program is executed by the processor in the embodiment of the present application, the implementation principle and the technical effect are similar to those of the above network communication establishment method, and are not described herein again.
In one embodiment, a computer program product is provided comprising a computer program which, when executed by a processor, performs the steps of:
acquiring routing information of a first virtual machine;
And sending a routing request to the controller according to the routing information to instruct the controller to determine the computing node where at least one second virtual machine to be connected is located, reflecting the routing information of the first virtual machine to the computing node where each second virtual machine is located according to the connection mode of the computing node where each second virtual machine is located and the controller, and completing communication establishment between the first virtual machine and each second virtual machine, wherein the controller is a controller connected with the first virtual machine in a controller cluster of the cloud computing system.
The steps implemented when the computer program is executed by the processor in the embodiment of the present application, the implementation principle and the technical effect are similar to those of the above network communication establishment method, and are not described herein again.
In one exemplary embodiment, a computer device is provided comprising a memory and a processor, the memory having stored therein a computer program, the processor when executing the computer program performing the steps of:
The method comprises the steps of receiving route information of a first virtual machine reflected by a controller, wherein the controller is a controller connected with the first virtual machine in a controller cluster of a cloud computing system, determining a computing node where at least one second virtual machine to be connected is located after the controller receives a route request of the first virtual machine, and reflecting the route information to the computing node where the second virtual machine is located according to a connection mode of the computing node where each second virtual machine is located and the controller;
and according to the routing information, completing communication establishment between the first virtual machine and the second virtual machine.
The implementation principle and technical effect of each step implemented by the processor in the embodiment of the present application are similar to those of the above network communication establishment method, and are not described herein.
In one embodiment, a computer readable storage medium is provided having a computer program stored thereon, which when executed by a processor, performs the steps of:
The method comprises the steps of receiving route information of a first virtual machine reflected by a controller, wherein the controller is a controller connected with the first virtual machine in a controller cluster of a cloud computing system, determining a computing node where at least one second virtual machine to be connected is located after the controller receives a route request of the first virtual machine, and reflecting the route information to the computing node where the second virtual machine is located according to a connection mode of the computing node where each second virtual machine is located and the controller;
and according to the routing information, completing communication establishment between the first virtual machine and the second virtual machine.
The steps implemented when the computer program is executed by the processor in the embodiment of the present application, the implementation principle and the technical effect are similar to those of the above network communication establishment method, and are not described herein again.
In one embodiment, a computer program product is provided comprising a computer program which, when executed by a processor, performs the steps of:
The method comprises the steps of receiving route information of a first virtual machine reflected by a controller, wherein the controller is a controller connected with the first virtual machine in a controller cluster of a cloud computing system, determining a computing node where at least one second virtual machine to be connected is located after the controller receives a route request of the first virtual machine, and reflecting the route information to the computing node where the second virtual machine is located according to a connection mode of the computing node where each second virtual machine is located and the controller;
and according to the routing information, completing communication establishment between the first virtual machine and the second virtual machine.
The steps implemented when the computer program is executed by the processor in the embodiment of the present application, the implementation principle and the technical effect are similar to those of the above network communication establishment method, and are not described herein again.
It should be noted that, the user information (including but not limited to user equipment information, user personal information, etc.) and the data (including but not limited to data for analysis, stored data, presented data, etc.) related to the present application are both information and data authorized by the user or sufficiently authorized by each party, and the collection, use and processing of the related data are required to meet the related regulations.
Those skilled in the art will appreciate that implementing all or part of the above described methods may be accomplished by way of a computer program stored on a non-transitory computer readable storage medium, which when executed, may comprise the steps of the embodiments of the methods described above. Any reference to memory, database, or other medium used in embodiments provided herein may include at least one of non-volatile and volatile memory. The nonvolatile Memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash Memory, optical Memory, high density embedded nonvolatile Memory, resistive random access Memory (ReRAM), magneto-resistive random access Memory (Magnetoresistive Random Access Memory, MRAM), ferroelectric Memory (Ferroelectric Random Access Memory, FRAM), phase change Memory (PHASE CHANGE Memory, PCM), graphene Memory, and the like. Volatile memory can include random access memory (Random Access Memory, RAM) or external cache memory, and the like. By way of illustration, and not limitation, RAM can be in various forms such as static random access memory (Static Random Access Memory, SRAM) or dynamic random access memory (Dynamic Random Access Memory, DRAM), etc. The databases referred to in the embodiments provided herein may include at least one of a relational database and a non-relational database. The non-relational database may include, but is not limited to, a blockchain-based distributed database, and the like. The processor referred to in the embodiments provided in the present application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic unit, a data processing logic unit based on quantum computing, or the like, but is not limited thereto.
The technical features of the above embodiments may be arbitrarily combined, and all possible combinations of the technical features in the above embodiments are not described for brevity of description, however, as long as there is no contradiction between the combinations of the technical features, they should be considered as the scope of the description.
The foregoing examples illustrate only a few embodiments of the application and are described in detail herein without thereby limiting the scope of the application. It should be noted that it will be apparent to those skilled in the art that several variations and modifications can be made without departing from the spirit of the application, which are all within the scope of the application. Accordingly, the scope of the application should be assessed as that of the appended claims.