Public cloud network configuration method and device, electronic equipment and storage medium
By using a network configuration method that combines pre-bound network segment information and flow table entries, the problems of link latency and low configuration efficiency in public cloud networks are solved, enabling faster configuration activation and higher efficiency, and adapting to the rapid expansion of large-scale services.
Patent Information
- Application Number
- CN202411246664.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-05
- Publication Date
- 2024-11-26
AI Technical Summary
In public cloud networks, network configuration information needs to go through multiple layers of processing and transmission, resulting in significant link latency, long configuration activation time, and low configuration efficiency. This is particularly detrimental to the rapid expansion and efficient operation of services in large-scale service deployment scenarios.
By pre-binding and integrating network segment information and merging flow table entries, network configuration methods are optimized. This includes integrating network segment information and merging flow table entries, reducing the number of flow table entries, and improving configuration efficiency.
It effectively reduces link latency, improves the speed and efficiency of network configuration activation, and adapts to the needs of rapid business expansion and frequent changes.
Smart Images

Figure CN119030866A_ABST
Abstract
Description
Background Art
[0002] With the development of cloud computing technology, k8s (an open source platform) and server-agnostic architecture have become the standard deployment methods for many applications. At the same time, the requirements for network performance of public cloud networks are getting higher and higher, such as QPS (Queries Per Second, throughput), configuration effectiveness time, etc.
[0003] In related technologies, network configuration information needs to be processed and transmitted at multiple levels, resulting in large link delays, long configuration validity times, and low configuration efficiency. Especially in large-scale service deployment scenarios, this will seriously hinder the rapid expansion and efficient operation of the business.
[0004] It should be noted that the information disclosed in the above background technology section is only used to enhance the understanding of the background of the present disclosure, and therefore may include information that does not constitute the prior art known to ordinary technicians in the field. Summary of the invention
[0005] The present disclosure provides a public cloud network configuration method, device, electronic device and storage medium, which at least to a certain extent overcome the problems of large link delay, long configuration effectiveness time and low configuration efficiency in related technologies.
[0006] Other features and advantages of the present disclosure will become apparent from the following detailed description, or may be learned in part by the practice of the present disclosure.
[0007] According to one aspect of the present disclosure, a public cloud network configuration method is provided, including:
[0008] When a user creates an elastic network card, obtain the network segment information pre-bound by the user;
[0009] Integrating the network segment information to obtain integrated network segment information;
[0010] Merging flow table entries according to the integrated network segment information to obtain a merged flow table entry set, wherein the flow table entry is used to describe the network configuration information;
[0011] When the virtual machine performs network communication, the network communication of the virtual machine is performed through the integrated network segment information and the merged flow table entry set.
[0012] In some exemplary embodiments, integrating the network segment information to obtain integrated network segment information includes:
[0013] The network segment information is integrated through the classless inter-domain routing format to obtain a plurality of integrated network segment information, wherein any integrated network segment information is used to configure a virtual machine for network communication.
[0014] In some exemplary embodiments, flow table entries are merged according to the integrated network segment information to obtain a merged flow table entry set, including:
[0015] Acquire multiple flow table entries according to each integrated network segment information, wherein any integrated network segment information corresponds to at least one flow table entry;
[0016] The flow table entries belonging to the same integrated network segment information are merged to obtain each merged flow table entry set.
[0017] In some exemplary embodiments, the public cloud network configuration method provided in the embodiments of the present disclosure is performed by a public cloud network service platform, and the public cloud network service platform is connected to a virtual switch. After merging flow table items according to the integrated network segment information to obtain a merged flow table item set, the method further includes:
[0018] The merged flow table entry set is sent to the virtual switch, and the virtual switch is used to implement network communication of the virtual machine according to the merged flow table entry set.
[0019] In some exemplary embodiments, when a user creates an elastic network card, obtaining the network segment information pre-bound by the user includes:
[0020] When a user creates an elastic network card, the user's pre-bound network segment information is obtained through a command line.
[0021] In some exemplary embodiments, the public cloud network configuration method provided by the embodiments of the present disclosure further includes:
[0022] If the current network configuration changes, the merged flow table entry set is updated to implement the changed network configuration.
[0023] According to another aspect of the present disclosure, a public cloud network configuration device is also provided, including:
[0024] A network segment information acquisition module, used to acquire the network segment information pre-bound by the user when the user creates an elastic network card;
[0025] A network segment information integration module, used to integrate the network segment information to obtain integrated network segment information;
[0026] A flow table item merging module, used to merge flow table items according to the integrated network segment information to obtain a merged flow table item set, wherein the flow table item is used to describe the network configuration information;
[0027] The network communication module is used to perform network communication of the virtual machine through the integrated network segment information and the merged flow table entry set when the virtual machine performs network communication.
[0028] In some exemplary embodiments, the network segment information integration module is used to integrate the network segment information through the classless inter-domain routing format to obtain multiple integrated network segment information, wherein any integrated network segment information is used to configure a virtual machine for network communication.
[0029] In some exemplary embodiments, the flow table entry merging module is used to obtain multiple flow table entries according to each integrated network segment information, wherein any integrated network segment information corresponds to at least one flow table entry;
[0030] The flow table entries belonging to the same integrated network segment information are merged to obtain each merged flow table entry set.
[0031] In some exemplary embodiments, the public cloud network configuration provided by the embodiments of the present disclosure is applied to a public cloud network service platform, the public cloud network service platform is connected to a virtual switch, and the device further includes:
[0032] The flow entry set sending module is used to send the merged flow entry set to the virtual switch, and the virtual switch is used to implement network communication of the virtual machine according to the merged flow entry set.
[0033] In some exemplary embodiments, the network segment information acquisition module is used to acquire the network segment information pre-bound by the user through a command line when the user creates an elastic network card.
[0034] In some exemplary embodiments, the public cloud network configuration device further includes:
[0035] The flow entry set updating module is used to update the merged flow entry set if the current network configuration changes, so as to make the changed network configuration effective.
[0036] According to another aspect of the present disclosure, an electronic device is also provided, which includes: a processor; and a memory for storing executable instructions of the processor; wherein the processor is configured to execute any one of the above-mentioned public cloud network configuration methods by executing the executable instructions.
[0037] According to another aspect of the present disclosure, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, any one of the above-mentioned public cloud network configuration methods is implemented.
[0038] According to another aspect of the present disclosure, a computer program product or a computer program is provided, the computer program product or the computer program including computer instructions, the computer instructions being stored in a computer-readable storage medium. A processor of an electronic device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the electronic device executes the public cloud network configuration method provided in various optional ways in any embodiment of the present disclosure.
[0039] The technical solution provided in the embodiments of the present disclosure can implement network configuration action pre-positioning by pre-binding network segment information, and can effectively reduce the number of flow table entries by merging flow table entries, thereby effectively improving the effectiveness speed of network configuration, reducing link delay, and improving network configuration efficiency.
[0040] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] The accompanying drawings herein are incorporated into the specification and constitute a part of the specification, illustrate embodiments consistent with the present disclosure, and together with the specification are used to explain the principles of the present disclosure. Obviously, the accompanying drawings described below are only some embodiments of the present disclosure, and for ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without creative work.
[0042] Figure 1 A schematic diagram showing a system architecture in an embodiment of the present disclosure;
[0043] Figure 2 A flow chart of a public cloud network configuration method in an embodiment of the present disclosure is shown;
[0044] Figure 3 A schematic diagram showing a public cloud network configuration system in an embodiment of the present disclosure is shown;
[0045] Figure 4 Another flow chart of a method for configuring a public cloud network in an embodiment of the present disclosure is shown;
[0046] Figure 5 A schematic diagram of a public cloud network configuration device in an embodiment of the present disclosure is shown;
[0047] Figure 6 A structural block diagram of an electronic device according to an embodiment of the present disclosure is shown;
[0048] Figure 7 A schematic diagram of a computer-readable storage medium in an embodiment of the present disclosure is shown. DETAILED DESCRIPTION
[0049] Example embodiments will now be described more fully with reference to the accompanying drawings. However, example embodiments can be implemented in a variety of forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that the disclosure will be more comprehensive and complete and to fully convey the concepts of the example embodiments to those skilled in the art. The described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.
[0050] In addition, the accompanying drawings are only schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the figures represent the same or similar parts, and their repeated description will be omitted. Some of the block diagrams shown in the accompanying drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software form, or implemented in one or more hardware modules or integrated circuits, or implemented in different networks and / or processor devices and / or microcontroller devices.
[0051] For ease of understanding, before introducing the embodiments of the present disclosure, several terms involved in the embodiments of the present disclosure are first explained as follows:
[0052] ENI (Elastic Network Interface) is a virtual network interface, mainly used in cloud computing environments. ENI allows users to create flexible network connections between cloud server instances, which usually run in VPC (Virtual Private Cloud).
[0053] OVS (Open vSwitch, open source virtual switch) is mainly used in server virtualization environments. OVS provides network isolation and packet forwarding functions similar to traditional network hardware, but OVS has higher programming flexibility and scalability than traditional network hardware.
[0054] Network segment information, in IP network, network segment information is a series of consecutive IP (Internet Protocol) addresses defined by subnet mask. Subnet mask is used to determine which parts of IP address represent network identification and which parts represent host identification.
[0055] The specific implementation of the embodiment of the present disclosure is described in detail below with reference to the accompanying drawings.
[0056] Figure 1 FIG. 1 is a schematic diagram showing an exemplary application system architecture of a public cloud network configuration method in an embodiment of the present disclosure. Figure 1As shown, the system architecture 100 may include a terminal device 101 , a network 102 and a server 103 .
[0057] The user may create an elastic network card through the terminal device 101. When the user creates an elastic network card, the terminal device 101 may obtain the network segment information pre-bound by the user and send the pre-bound network segment information to the server 103. The server 103 may receive the pre-bound network segment information and integrate the network segment information to obtain integrated network segment information.
[0058] Then, the server 103 can merge the flow table items according to the integrated network segment information to obtain a merged flow table item set, which is used to describe the network configuration information. Finally, when the virtual machine performs network communication, the server 103 can perform network communication of the virtual machine through the integrated network segment information and the merged flow table item set.
[0059] The network 102 is a medium for providing a communication link between the terminal device 101 and the server 103, and can be a wired network or a wireless network.
[0060] Optionally, the wireless network or wired network described above uses standard communication technology and / or protocol. The network is usually the Internet, but it can also be any network, including but not limited to a local area network (LAN), a metropolitan area network (MAN), a wide area network (WAN), a mobile, wired or wireless network, a dedicated network or any combination of a virtual private network). In some embodiments, the data exchanged through the network is represented by technologies and / or formats including Hyper Text Mark-up Language (HTML), Extensible Markup Language (XML), etc. In addition, conventional encryption technologies such as Secure Socket Layer (SSL), Transport Layer Security (TLS), Virtual Private Network (VPN), Internet Protocol Security (IPSec) can also be used to encrypt all or some links. In other embodiments, customized and / or dedicated data communication technologies can also be used to replace or supplement the above data communication technologies.
[0061] The terminal device 101 can be various electronic devices, including but not limited to smart phones, tablet computers, laptop computers, desktop computers, smart speakers, smart watches, wearable devices, augmented reality devices, virtual reality devices, etc.
[0062] Optionally, the client of the application installed in different terminal devices 101 is the same, or the client of the same type of application based on different operating systems. Based on the different terminal platforms, the specific form of the client of the application can also be different, for example, the application client can be a mobile client, a PC client, etc.
[0063] The server 103 may be a server that provides various services, such as a background management server that provides support for the device operated by the user using the terminal device 101. The background management server may analyze and process the received request and other data, and feed back the processing results to the terminal device.
[0064] Optionally, the server can be an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN (Content Delivery Network), as well as big data and artificial intelligence platforms.
[0065] Those skilled in the art will know that Figure 1 The number of terminal devices 101, networks 102 and servers 103 is only illustrative, and any number of terminal devices 101, networks 102 and servers 103 may be provided according to actual needs. The embodiments of the present disclosure are not limited to this.
[0066] Under the above system architecture, a public cloud network configuration method is provided in an embodiment of the present disclosure, and the method can be executed by any electronic device with computing and processing capabilities.
[0067] In some embodiments, the public cloud network configuration method provided in the embodiments of the present disclosure can be executed by the server in the above-mentioned system architecture; in other embodiments, the public cloud network configuration method provided in the embodiments of the present disclosure can be implemented by the terminal device and the server in the above-mentioned system architecture through interaction.
[0068] Figure 2 A flow chart of a public cloud network configuration method in an embodiment of the present disclosure is shown as follows: Figure 2 As shown, the public cloud network configuration method provided in the embodiment of the present disclosure includes the following steps S202 to S208.
[0069] S202: When a user creates an elastic network card, obtain the network segment information pre-bound by the user.
[0070] The disclosed embodiments do not limit the type of the elastic network card, for example, the elastic network card can be a primary elastic network card or an auxiliary elastic network card, etc. In addition, the functions and characteristics of the elastic network card may vary according to different cloud service providers, and the disclosed embodiments do not limit this.
[0071] In a possible implementation, a user can log in to the management control platform of the corresponding cloud service provider to create an elastic network card and fill in the configuration information of the elastic network card. The configuration information of the elastic network card may include, for example, the name, description information, the private network where the instance is located, the subnet to which the elastic network card belongs, etc.
[0072] In some exemplary embodiments, when a user creates an elastic network card, obtaining the network segment information pre-bound by the user includes: when the user creates the elastic network card, obtaining the network segment information pre-bound by the user through a command line.
[0073] In an exemplary embodiment, a CLI (Command Line Interface) may be displayed to the user, and the user may enter text commands in the command line interface to implement the creation of an elastic network card and the network segment information to be bound.
[0074] In some possible implementations, at least one IP address segment may be pre-applied for based on application scenarios, business requirements, etc. The pre-bound network segment information may be an IP address segment. The disclosed embodiment does not limit the number of pre-bound network segment information, and the pre-bound network segment information may be one or more IP address segments. The IP address segment may be in CIDR (Classless Inter-Domain Routing) format.
[0075] It should be noted that CIDR is a method of representing IP addresses and their related routing prefix lengths. CIDR can represent the size and range of an IP address block, and it can be applied to private IP address segments and public IP address segments.
[0076] For example, when a user creates an elastic network card, the user's pre-bound network segment information is obtained and bound to the elastic network card, so that when an IP address is dynamically allocated on the elastic network card, it can be directly selected from the bound address pool without having to reapply to the public cloud network each time.
[0077] S204, integrating the network segment information to obtain integrated network segment information.
[0078] The way to integrate the network segment information can be determined based on experience or application scenarios. For example, network segment planning can be performed after obtaining the network segment information, such as VLAN (Virtual Local Area Network) division, determination of subnet mask, determination of IP address range, etc. Then, a virtual network environment can be dynamically created through technologies such as SDK (Software Development Kit, software definition tool). Among them, each virtual network has its own independent network segment information. In addition, corresponding configurations of routing tables, firewall rules, and DNS (Domain Name System) records can also be performed.
[0079] In some exemplary embodiments, the network segment information is integrated to obtain integrated network segment information, including: integrating the network segment information through a classless inter-domain routing format to obtain multiple integrated network segment information, wherein any integrated network segment information is used to configure a virtual machine for network communication.
[0080] In an exemplary embodiment, the length of the network mask, that is, the number of bits of the network prefix, can be represented by a slash in the classless inter-domain routing format. For example, / 32 means that the length of the network mask is 32, and / 30 means that the length of the network mask is 30.
[0081] In a possible implementation, multiple consecutive / 32 network segment information may be integrated into a larger / 24 network segment information, or multiple consecutive / 32 network segment information may be integrated into a larger / 27 network segment information, thereby integrating the network segment information to obtain the integrated network segment information.
[0082] Taking the integration of / 32 network segment information into / 24 network segment information as an example, after receiving the network segment information pre-bound by the user, the public cloud network service platform can find the common network prefix of each / 32 network segment information, and then use this prefix to define a new larger network. For example, the address range of 10.0.1.1 to 10.0.1.254 can be integrated into 10.0.1.0, and the integrated network segment information of 10.0.1.0 / 24 is obtained.
[0083] In an exemplary embodiment, multiple integrated network segment information can be obtained based on the network segment information pre-bound by the user. For example, the address range of 10.0.1.1 to 10.0.1.254 can be integrated into 10.0.1.0 to obtain the integrated network segment information of 10.0.1.0 / 24. In addition, the address range of 10.0.2.1 to 10.0.2.254 can be integrated into 10.0.2.0 to obtain the integrated network segment information of 10.0.2.0 / 24. In addition, the address range of 10.0.3.1 to 10.0.3.254 can be integrated into 10.0.3.0 to obtain the integrated network segment information of 10.0.3.0 / 24.
[0084] In the above example, the public cloud network service platform can configure the three independent integrated network segment information 10.0.1.0 / 24, 10.0.2.0 / 24 and 10.0.3.0 / 24 to three different virtual switches respectively to achieve network communication for the corresponding virtual machines.
[0085] S206, merging flow table entries according to the integrated network segment information to obtain a merged flow table entry set, where the flow table entry is used to describe the network configuration information.
[0086] In some exemplary embodiments, flow table items are merged according to the integrated network segment information to obtain a merged flow table item set, including: obtaining multiple flow table items according to each integrated network segment information, wherein any integrated network segment information corresponds to at least one flow table item; and merging flow table items belonging to the same integrated network segment information to obtain each merged flow table item set.
[0087] Exemplarily, a flow entry can be used to describe network configuration information, which is a set of rules for identifying, processing, and forwarding data packets corresponding to each integrated network segment information. Among them, the flow entry can determine the matching rule between the data packet and the network segment information based on the source IP address or destination IP address of the data packet. Therefore, after the network segment information is integrated, the flow entry can be merged accordingly.
[0088] In one possible implementation, the existing flow table entries may be analyzed to find out flow table entries with the same or similar characteristics. For example, if there are multiple flow table entries for traffic of 10.0.1.1, 10.1.1.2, ..., 10.0.1.254 and 10.0.1.255, and these IP addresses all belong to the same / 24 network 10.0.1.0 / 24, then you may consider merging these flow table entries into one.
[0089] It should be noted that any integrated network segment information may correspond to one merged flow table entry set, or may correspond to multiple merged flow table entry sets.
[0090] The embodiments of the present disclosure do not limit the merging conditions of flow table entries. For example, the merging can be based on fields such as the source MAC (Media Access Control) address, target MAC address, source IP address, target IP address, TCP (Transmission Control Protocol) / UDP (User Datagram Protocol) port or protocol type in the flow table entry.
[0091] In some exemplary embodiments, the public cloud network configuration method provided by the embodiments of the present disclosure may be executed by a public cloud network service platform, which may be connected to a virtual switch.
[0092] In this case, after the flow table items are merged according to the integrated network segment information to obtain a merged flow table item set, the public cloud network configuration method provided by the embodiment of the present disclosure may also include: sending the merged flow table item set to the virtual switch, and the virtual switch is used to implement network communication of the virtual machine according to the merged flow table item set.
[0093] In an exemplary embodiment, the public cloud network service platform can provide virtual network infrastructure for virtual machines through OVS, so that virtual machines can communicate in the network like physical machines. Flow table entries can be stored in OVS. OVS can manage flow table entries through tools such as ovs-ofctl (an open source flow controller), which can be used to add, modify or delete flow table entries.
[0094] By merging flow table entries, the disclosed embodiment can enable OVS to efficiently process a large amount of network traffic, facilitate dynamic adjustment of its behavior as needed, and significantly reduce the total amount of flow table entries, thereby improving the efficiency of configuration effectiveness.
[0095] S208, when the virtual machine performs network communication, the network communication of the virtual machine is performed through the integrated network segment information and the merged flow table entry set.
[0096] Exemplarily, any virtual machine can establish a connection with OVS through a NIC (Network Interface Controller) interface. Since the flow table entries are merged according to the integrated network segment information, the forwarding path of the data packet can be determined through the merged flow table entries, thereby realizing network communication.
[0097] Exemplarily, if multiple virtual machines are currently included, the multiple virtual machines can be connected to multiple virtual ports of the OVS respectively, or can be connected to different OVSs respectively.
[0098] In some exemplary embodiments, the public cloud network configuration method provided by the embodiments of the present disclosure may further include: if the current network configuration changes, updating the merged flow table entry set to implement the changed network configuration.
[0099] In an exemplary embodiment, if an update to the network configuration information occurs, the corresponding update can be made directly in the merged flow table entry set without having to update each flow table entry separately. Therefore, the configuration effectiveness time can be greatly shortened and the network configuration effectiveness efficiency can be improved. The embodiment of the present disclosure can adapt to the needs of rapid business expansion and frequent changes.
[0100] The disclosed embodiment can combine pre-binding network segment information with flow table item merging. By prepending network configuration actions and implementing intelligent flow table item merging at the OVS level, the efficiency of network configuration changes in a public cloud environment is effectively improved, the speed at which network configuration takes effect is increased, and the resource overhead and delay problems caused by too many flow table items are reduced.
[0101] The method provided by the embodiment of the present disclosure can implement network configuration action pre-positioning by pre-binding network segment information, and can effectively reduce the number of flow table entries by merging flow table entries, thereby effectively improving the effectiveness speed of network configuration, reducing link delay, and improving network configuration efficiency.
[0102] Figure 3 A schematic diagram of a public cloud network configuration system in an embodiment of the present disclosure is shown.
[0103] When creating an elastic network card, the user can obtain the user's pre-bound network segment information through the command line. The public cloud network service platform can be, for example, a K8S (an open source application) service platform. The K8S service platform can interact with the scheduler. In addition, users can create virtual machines on the K8S service platform based on application scenarios, business needs, etc., wherein any virtual machine can include multiple Pods (a management unit for containers), and any virtual machine can achieve network communication through OVS based on different network segment information.
[0104] Figure 4 A flow chart of a public cloud network configuration method in an embodiment of the present disclosure is shown as follows: Figure 4 As shown, the public cloud network configuration method provided in the embodiment of the present disclosure includes the following steps S402 to S408.
[0105] S402: When creating an elastic network card, the user can apply for one or more CIDR-formatted IP address segments in advance according to business needs, and bind them to the elastic network card.
[0106] S404, after receiving the user's pre-bound network segment information, the public cloud network service platform merges multiple flow table entries in the same network segment in OVS through a flow table merging algorithm to obtain a merged flow table entry set.
[0107] S406: When the network configuration changes, the merged flow entry set is updated to implement the new configuration on OVS.
[0108] It should be noted that the implementation method of each step in S402 to S406 can refer to the relevant description in S202 to S208, which will not be repeated here.
[0109] It should be noted that the acquisition, storage, use, and processing of data in the technical solution disclosed in this disclosure are in compliance with the relevant provisions of national laws and regulations, and various types of data such as personal identity data, operation data, behavioral data, etc. related to individuals, customers, and groups obtained in the embodiments of this disclosure have all been authorized.
[0110] Based on the same inventive concept, a public cloud network configuration device is also provided in the embodiments of the present disclosure, as described in the following embodiments. Since the principle of solving the problem in the device embodiment is similar to that in the above method embodiment, the implementation of the device embodiment can refer to the implementation of the above method embodiment, and the repeated parts will not be repeated.
[0111] Figure 5 A schematic diagram of a public cloud network configuration device in an embodiment of the present disclosure is shown. Figure 5 As shown, the device comprises:
[0112] The network segment information acquisition module 501 is used to acquire the network segment information pre-bound by the user when the user creates an elastic network card;
[0113] The network segment information integration module 502 is used to integrate the network segment information to obtain integrated network segment information;
[0114] A flow entry merging module 503, used to merge flow entries according to the integrated network segment information to obtain a merged flow entry set, where the flow entry is used to describe network configuration information;
[0115] The network communication module 504 is used to perform network communication of the virtual machine through the integrated network segment information and the merged flow table entry set when the virtual machine performs network communication.
[0116] In some exemplary embodiments, the network segment information integration module 502 is used to integrate the network segment information through the classless inter-domain routing format to obtain multiple integrated network segment information, wherein any integrated network segment information is used to configure a virtual machine for network communication.
[0117] In some exemplary embodiments, the flow entry merging module 503 is used to obtain multiple flow entries according to each integrated network segment information, wherein any integrated network segment information corresponds to at least one flow entry;
[0118] The flow table entries belonging to the same integrated network segment information are merged to obtain each merged flow table entry set.
[0119] In some exemplary embodiments, the public cloud network configuration provided by the embodiments of the present disclosure is applied to a public cloud network service platform, the public cloud network service platform is connected to a virtual switch, and the device further includes:
[0120] The flow entry set sending module is used to send the merged flow entry set to the virtual switch, and the virtual switch is used to implement network communication of the virtual machine according to the merged flow entry set.
[0121] In some exemplary embodiments, the network segment information acquisition module 501 is used to acquire the network segment information pre-bound by the user through a command line when the user creates an elastic network card.
[0122] In some exemplary embodiments, the public cloud network configuration device provided by the embodiments of the present disclosure further includes:
[0123] The flow entry set updating module is used to update the merged flow entry set if the current network configuration changes, so as to make the changed network configuration effective.
[0124] It should be noted that the network segment information acquisition module 501, the network segment information integration module 502, the flow entry merging module 503 and the network communication module 504 can correspond to S202 to S208 in the method embodiment, respectively. The examples and application scenarios implemented by the above modules and the corresponding steps are the same, but are not limited to the contents disclosed in the above method embodiment. It should be noted that the above modules as part of the device can be executed in a computer system such as a set of computer executable instructions.
[0125] The device provided by the embodiment of the present disclosure can implement network configuration action pre-positioning by pre-binding network segment information, and can effectively reduce the number of flow table entries by merging flow table entries, thereby effectively improving the effectiveness speed of network configuration, reducing link delay, and improving network configuration efficiency.
[0126] Those skilled in the art will appreciate that various aspects of the present disclosure may be implemented as systems, methods or program products. Therefore, various aspects of the present disclosure may be specifically implemented in the following forms, namely: complete hardware implementation, complete software implementation (including firmware, microcode, etc.), or a combination of hardware and software implementations, which may be collectively referred to herein as "circuits", "modules" or "systems".
[0127] The embodiment of the present disclosure provides an electronic device, which exemplarily includes: a processor and a memory. The memory can be used to store executable instructions of the processor. The processor is configured to perform the public cloud network configuration method provided by the embodiment of the present disclosure by executing the above executable instructions.
[0128] Refer to the following Figure 6 The electronic device 600 according to this embodiment of the present disclosure is described. Figure 6 The electronic device 600 shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.
[0129] like Figure 6 As shown, the electronic device 600 is in the form of a general computing device. The components of the electronic device 600 may include but are not limited to: at least one processing unit 610, at least one storage unit 620, and a bus 630 connecting different system components (including the storage unit 620 and the processing unit 610).
[0130] The storage unit stores a program code, which can be executed by the processing unit 610, so that the processing unit 610 performs the steps of various exemplary embodiments of the present disclosure described in the above “Exemplary Method” section of this specification. For example, the processing unit 610 can perform the following steps of the above method embodiment:
[0131] When a user creates an elastic network card, the network segment information pre-bound by the user is obtained; the network segment information is integrated to obtain the integrated network segment information; the flow table items are merged according to the integrated network segment information to obtain a merged flow table item set, which is used to describe the network configuration information; when the virtual machine performs network communication, the network communication of the virtual machine is performed through the integrated network segment information and the merged flow table item set.
[0132] The storage unit 620 may include a readable medium in the form of a volatile storage unit, such as a random access storage unit (RAM) 6201 and / or a cache storage unit 6202 , and may further include a read-only storage unit (ROM) 6203 .
[0133] The storage unit 620 may also include a program / utility 6204 having a set (at least one) of program modules 6205, such program modules 6205 including but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment.
[0134] Bus 630 may represent one or more of several types of bus structures, including a memory unit bus or memory unit controller, a peripheral bus, an accelerated graphics port, a processing unit, or a local bus using any of a variety of bus architectures.
[0135] The electronic device 600 may also communicate with one or more external devices 640 (e.g., keyboards, pointing devices, Bluetooth devices, etc.), may also communicate with one or more devices that enable a user to interact with the electronic device 600, and / or communicate with any device that enables the electronic device 600 to communicate with one or more other computing devices (e.g., routers, modems, etc.). Such communication may be performed via an input / output (I / O) interface 650. Furthermore, the electronic device 600 may also communicate with one or more networks (e.g., local area networks (LANs), wide area networks (WANs), and / or public networks, such as the Internet) via a network adapter 660. As shown, the network adapter 660 communicates with other modules of the electronic device 600 via a bus 630. It should be understood that, although not shown in the figure, other hardware and / or software modules may be used in conjunction with the electronic device 600, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.
[0136] Through the description of the above implementation, it is easy for those skilled in the art to understand that the example implementation described here can be implemented by software, or by software combined with necessary hardware. Therefore, the technical solution according to the implementation of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, including several instructions to enable a computing device (which can be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the implementation of the present disclosure.
[0137] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart may be implemented as a computer program product, which includes: a computer program, which implements the above-mentioned public cloud network configuration method when executed by a processor.
[0138] In an exemplary embodiment of the present disclosure, a computer-readable storage medium is also provided, on which a computer program is stored, and when the computer program is executed by a processor, the public cloud network configuration method provided in the embodiment of the present disclosure can be implemented. The computer-readable storage medium can be a readable signal medium or a readable storage medium.
[0139] Figure 7 A schematic diagram of a computer-readable storage medium in an embodiment of the present disclosure is shown. Figure 7 As shown, a program product capable of implementing the above method of the present disclosure is stored on the computer-readable storage medium 700. In some possible implementations, various aspects of the present disclosure may also be implemented in the form of a program product, which includes a program code. When the program product is run on a terminal device, the program code is used to enable the terminal device to execute the steps according to various exemplary implementations of the present disclosure described in the above “Exemplary Method” section of this specification.
[0140] More specific examples of computer-readable storage media in the present disclosure may include, but are not limited to, an electrical connection having one or more conductors, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0141] In the present disclosure, a computer readable storage medium may include a data signal propagated in baseband or as part of a carrier wave, wherein a readable program code is carried. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. A readable signal medium may also be any readable medium other than a readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device.
[0142] Alternatively, the program code contained on the computer-readable storage medium may be transmitted using any appropriate medium, including but not limited to wireless, wired, optical cable, RF, etc., or any suitable combination of the foregoing.
[0143] In a specific implementation, the program code for performing the operation of the present disclosure may be written in any combination of one or more programming languages, including object-oriented programming languages such as Java, C++, etc., and conventional procedural programming languages such as "C" or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, as a separate software package, partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computing device (e.g., using an Internet service provider to connect through the Internet).
[0144] It should be noted that, although several modules or units of the device for action execution are mentioned in the above detailed description, this division is not mandatory. In fact, according to the embodiments of the present disclosure, the features and functions of two or more modules or units described above can be embodied in one module or unit. On the contrary, the features and functions of one module or unit described above can be further divided into multiple modules or units to be embodied.
[0145] In addition, although the steps of the method in the present disclosure are described in a specific order in the drawings, this does not require or imply that the steps must be performed in this specific order, or that all the steps shown must be performed to achieve the desired results. Additionally or alternatively, some steps may be omitted, multiple steps may be combined into one step, and / or one step may be decomposed into multiple steps, etc.
[0146] Through the description of the above implementation, it is easy for those skilled in the art to understand that the example implementation described here can be implemented by software, or by software combined with necessary hardware. Therefore, the technical solution according to the implementation of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, including several instructions to enable a computing device (which can be a personal computer, a server, a mobile terminal, or a network device, etc.) to execute the method according to the implementation of the present disclosure.
[0147] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the invention disclosed herein. The present disclosure is intended to cover any variations, uses or adaptations of the present disclosure, which follow the general principles of the present disclosure and include common knowledge or customary technical means in the art that are not disclosed in the present disclosure. The description and examples are to be regarded as exemplary only, and the true scope of the present disclosure is indicated by the appended claims.
Claims
1. A public cloud network configuration method, It is characterized in that include: When a user creates an elastic network card, obtain the network segment information pre-bound by the user; Integrating the network segment information to obtain integrated network segment information; Merging flow table entries according to the integrated network segment information to obtain a merged flow table entry set, wherein the flow table entry is used to describe the network configuration information; When the virtual machine performs network communication, the network communication of the virtual machine is performed through the integrated network segment information and the merged flow table entry set.
2. The public cloud network configuration method according to claim 1, It is characterized in that The step of integrating the network segment information to obtain integrated network segment information includes: The network segment information is integrated through the classless inter-domain routing format to obtain a plurality of integrated network segment information, wherein any integrated network segment information is used to configure a virtual machine for network communication.
3. The public cloud network configuration method according to claim 2, It is characterized in that The merging of flow table entries according to the integrated network segment information to obtain a merged flow table entry set includes: Acquire multiple flow table entries according to each integrated network segment information, wherein any integrated network segment information corresponds to at least one flow table entry; The flow table entries belonging to the same integrated network segment information are merged to obtain each merged flow table entry set.
4. The public cloud network configuration method according to any one of claims 1 to 3, It is characterized in that The method is performed by a public cloud network service platform, the public cloud network service platform is connected to a virtual switch, and after merging flow table items according to the integrated network segment information to obtain a merged flow table item set, the method further includes: The merged flow table entry set is sent to the virtual switch, and the virtual switch is used to implement network communication of the virtual machine according to the merged flow table entry set.
5. The public cloud network configuration method according to claim 4, It is characterized in that When the user creates an elastic network card, obtaining the network segment information pre-bound by the user includes: When a user creates an elastic network card, the user's pre-bound network segment information is obtained through a command line.
6. The public cloud network configuration method according to claim 1, It is characterized in that The method further comprises: If the current network configuration changes, the merged flow table entry set is updated to implement the changed network configuration.
7. A public cloud network configuration device, It is characterized in that include: A network segment information acquisition module, used to acquire the network segment information pre-bound by the user when the user creates an elastic network card; A network segment information integration module, used to integrate the network segment information to obtain integrated network segment information; A flow table item merging module, used to merge flow table items according to the integrated network segment information to obtain a merged flow table item set, wherein the flow table item is used to describe the network configuration information; The network communication module is used to perform network communication of the virtual machine through the integrated network segment information and the merged flow table entry set when the virtual machine performs network communication.
8. An electronic device, It is characterized in that include: processor; as well as A memory, configured to store executable instructions of the processor; The processor is configured to execute the public cloud network configuration method according to any one of claims 1 to 6 by executing the executable instructions.
9. A computer-readable storage medium having a computer program stored thereon, It is characterized in that When the computer program is executed by a processor, the public cloud network configuration method described in any one of claims 1 to 6 is implemented.
10. A computer program product, It is characterized in that The computer program product includes computer instructions, which are stored in a computer-readable storage medium. A processor of an electronic device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the electronic device executes the public cloud network configuration method as described in any one of claims 1 to 6.
