Control instruction sending method, network controller, service controller and electronic equipment
A cache-based system for storing and periodically resending failed control instructions addresses network failures in cloud networks, enhancing reliability and service creation success rates.
Patent Information
- Application Number
- CN202310694148.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-06-12
- Publication Date
- 2024-12-13
AI Technical Summary
In cloud network applications, control instructions often fail due to network controller crashes, excessive load, or network jitter, leading to failed service creations and poor user experience.
Implement a cache system in each data center to store control instructions that fail to be sent, allowing a master network controller to periodically resend these instructions, and provide a fallback mechanism across data centers for disaster recovery.
Enhances the reliability of control instruction delivery, reducing the impact of temporary network failures and improving the success rate of service creations.
Smart Images

Figure CN119135728A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of cloud technology. Specifically, the present application relates to a control instruction sending method, a network controller in a network controller cluster, a business controller and an electronic device. Background Art
[0002] In cloud network applications, when users want to activate a service, they configure control parameters through the front-end WEB page provided by the service controller. After calculation and arrangement by the service controller and network controller, they are finally converted into control instructions for the network device and sent to the network device, thus completing the activation of the service.
[0003] In actual scenarios, there may be various reasons that may cause the control command to fail to be issued, such as the network controller to which it is distributed crashing abnormally, or being unable to respond due to excessive load, or the controlled network device temporarily experiencing network jitter and being unable to receive the command normally.
[0004] In the related art, when a control instruction fails, it will be re-issued. If it fails several times in a row, the control instruction will not be sent again. If the issuance fails, the user's service creation will be prompted as failed, which will cause a bad experience for the user and also affect the success rate of service creation. Summary of the invention
[0005] The embodiments of the present application provide a control instruction sending method, a network controller, a service controller, a computer-readable storage medium, and a computer program product, which can solve the above-mentioned problems of the prior art. The technical solution is as follows:
[0006] In a first aspect, an embodiment of the present application provides a control instruction sending method, which is applied to a master network controller in a first network controller cluster, where the first network controller cluster is associated with a first data center, and the method includes:
[0007] Based on a preset period, determining at least one target control instruction from a cache of a target data center, the target data center including the first data center;
[0008] Sending the target control instruction to a network device related to the target control instruction;
[0009] Each data center is associated with a corresponding network controller cluster, and the cache of each data center stores control instructions that have failed to be sent continuously by each network controller in the associated network controller cluster;
[0010] Each control instruction is associated with a network device and a network service, and the control instruction is used to instruct the associated network device to execute the associated network service.
[0011] In a second aspect, an embodiment of the present application provides a control instruction sending method, which is applied to any network controller in a first network controller cluster, where the first network controller cluster is associated with a first data center, and the method includes:
[0012] Generate a control instruction based on a service request of the network device, wherein the control instruction is associated with a network device and a network service, and the control instruction is used to instruct the associated network device to execute the associated network service;
[0013] Sending the control instruction to the associated network device;
[0014] In response to a failure in sending the control instruction, storing the control instruction in a cache of the first data center.
[0015] In a third aspect, an embodiment of the present application provides a control instruction sending method, which is applied to a service controller, wherein the service controller is at least a management server of a second network controller cluster and is connected to a main network controller in a first network controller cluster, and the method includes:
[0016] If it is determined that all network controllers in the second network controller cluster fail, sending the cache of the second data center to the master network controller in the first network controller cluster;
[0017] Wherein, the cache of the second data center includes at least one control instruction that failed to be repeatedly sent by the second network controller cluster;
[0018] Each control instruction is associated with a network device and a network service, and the control instruction is used to instruct the associated network device to execute the associated network service.
[0019] In a fourth aspect, an embodiment of the present application provides a master network controller in a first network controller cluster, the first network controller cluster is associated with a first data center, and the master network controller includes:
[0020] an instruction determination module, configured to determine at least one target control instruction from a cache of a target data center based on a preset period, the target data center including the first data center;
[0021] An instruction resending module, used for sending the target control instruction to the network device related to the target control instruction;
[0022] Each data center is associated with a corresponding network controller cluster, and the cache of each data center stores control instructions that have failed to be sent continuously by each network controller in the associated network controller cluster.
[0023] In a fifth aspect, an embodiment of the present application provides any one network controller in a first network controller cluster, the first network controller cluster is associated with a first data center, and the network controller includes:
[0024] An instruction generation module, used to generate a control instruction based on a service request, wherein the control instruction is associated with a network device and a network service, and the control instruction is used to instruct the associated network device to execute the associated network service;
[0025] An instruction sending module, used for sending the control instruction to the associated network device;
[0026] In response to a failure in repeatedly sending the control instruction, storing the control instruction in a cache of the first data center.
[0027] In a sixth aspect, an embodiment of the present application provides a service controller, wherein the service controller is at least a management server of a second network controller cluster and is connected to a master network controller in a first network controller cluster, and the service controller includes:
[0028] A cache address sending module, configured to send the address of the cache of the second data center to the main network controller in the first network controller cluster if it is determined that all network controllers in the second network controller cluster fail;
[0029] Wherein, the cache of the second data center includes at least one control instruction that failed to be repeatedly sent by the second network controller cluster;
[0030] Each control instruction is associated with a network device and a network service, and the control instruction is used to instruct the associated network device to execute the associated network service.
[0031] In a seventh aspect, an embodiment of the present application provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement the control instruction sending method provided in any one of the first to third aspects.
[0032] In an eighth aspect, an embodiment of the present application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the control instruction sending method provided in any one of the first to third aspects.
[0033] In a ninth aspect, an embodiment of the present application provides a computer program product, including a computer program, which, when executed by a processor, implements the control instruction sending method provided in any one of the first to third aspects.
[0034] The beneficial effects of the technical solution provided by the embodiment of the present application are:
[0035] Based on a preset period, at least one target control instruction is determined from the cache summary of the target data center, and the target control instruction is sent to the network device related to the target control instruction. The present application creates a cache for each data center, and stores in the cache the control instructions that have failed to be sent continuously by each network controller in the network controller cluster managed by the data center. This allows the control instructions that have failed to be sent continuously to still have a chance to be reissued. Since the main network controller of this scheme sends the control instructions in the cache once every preset period, it can effectively solve the problem of temporary sending failure caused by network link failure, network equipment failure, etc. BRIEF DESCRIPTION OF THE DRAWINGS
[0036] Figure 1a A schematic diagram of the system architecture of a cloud network application scenario provided in an embodiment of the present application;
[0037] Figure 1b An interactive diagram for creating a network acceleration service for an embodiment of the present application;
[0038] Figure 1c A schematic diagram of network controller clusters in different data centers provided in an embodiment of the present application;
[0039] Figure 2a A schematic diagram of a system architecture for implementing a control instruction sending method provided in an embodiment of the present application;
[0040] Figure 2b A schematic flow chart of a control instruction sending method executed by a master network controller in a first network controller cluster according to an embodiment of the present application;
[0041] Figure 2c A schematic diagram of the execution logic of the network controller provided in an embodiment of the present application;
[0042] Figure 3 An interactive schematic diagram of a control instruction sending method provided in an embodiment of the present application;
[0043] Figure 4 A schematic diagram of a process for determining a target control instruction provided in an embodiment of the present application;
[0044] Figure 5 A flowchart of a control instruction sending method executed by a main network controller provided in another embodiment of the present application;
[0045] Figure 6 A schematic flow chart of a control instruction sending method executed by a network controller in a first network controller cluster provided in an embodiment of the present application;
[0046] Figure 7A flowchart of a control instruction sending method executed by a management server provided in an embodiment of the present application;
[0047] Figure 8 An interactive schematic diagram of a specific application scenario provided in an embodiment of the present application;
[0048] Fig. 9 A schematic diagram of the structure of the main network controller provided in an embodiment of the present application;
[0049] Fig.10 A schematic diagram of the structure of the main network controller provided in an embodiment of the present application;
[0050] Fig.11 A schematic diagram of the structure of a service controller provided in an embodiment of the present application;
[0051] Fig.12 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0052] The embodiments of the present application are described below in conjunction with the drawings in the present application. It should be understood that the implementation methods described below in conjunction with the drawings are exemplary descriptions for explaining the technical solutions of the embodiments of the present application and do not constitute a limitation on the technical solutions of the embodiments of the present application.
[0053] It will be understood by those skilled in the art that, unless specifically stated, the singular forms "one", "an" and "the" used herein may also include plural forms. It should be further understood that the terms "including" and "comprising" used in the embodiments of the present application refer to that the corresponding features can be implemented as the presented features, information, data, steps, operations, elements and / or components, but do not exclude the implementation as other features, information, data, steps, operations, elements, components and / or combinations thereof supported by the technical field. It should be understood that when we call an element "connected" or "coupled" to another element, the one element can be directly connected or coupled to the other element, or it can refer to that the one element and the other element establish a connection relationship through an intermediate element. In addition, the "connection" or "coupling" used here may include wireless connection or wireless coupling. The term "and / or" used here indicates at least one of the items defined by the term, for example, "A and / or B" can be implemented as "A", or as "B", or as "A and B".
[0054] In order to make the objectives, technical solutions and advantages of the present application clearer, the implementation methods of the present application will be further described in detail below with reference to the accompanying drawings.
[0055] Cloud technology is a general term for network technology, information technology, integration technology, management platform technology, application technology, etc. based on the cloud computing business model. It can form a resource pool, which can be used on demand and is flexible and convenient. Cloud computing technology will become an important support. The backend services of the technical network system require a large amount of computing and storage resources, such as video websites, picture websites and more portal websites. With the rapid development and application of the Internet industry, in the future, each item may have its own identification mark, which needs to be transmitted to the backend system for logical processing. Data of different levels will be processed separately. All kinds of industry data need strong system backing support, which can only be achieved through cloud computing.
[0056] Cloud storage is a new concept that extends and develops from the concept of cloud computing. A distributed cloud storage system (hereinafter referred to as storage system) refers to a storage system that uses cluster applications, grid technology, and distributed storage file systems to bring together a large number of different types of storage devices (storage devices are also called storage nodes) in the network through application software or application interfaces to work together and provide external data storage and business access functions.
[0057] In short, a database can be seen as an electronic filing cabinet - a place where electronic files are stored, and users can add, query, update, delete, and other operations on the data in the files. The so-called "database" is a collection of data that is stored together in a certain way, can be shared with multiple users, has as little redundancy as possible, and is independent of the application.
[0058] A database management system (DBMS) is a computer software system designed for managing databases. It generally has basic functions such as storage, retrieval, security, and backup. Database management systems can be classified according to the database model they support, such as relational, XML (Extensible Markup Language); or according to the type of computer they support, such as server clusters, mobile phones; or according to the query language used, such as SQL (Structured Query Language), XQuery; or according to performance focus, such as maximum scale, maximum operating speed; or other classification methods. Regardless of the classification method used, some DBMS can cross categories, for example, supporting multiple query languages at the same time.
[0059] Big data refers to a collection of data that cannot be captured, managed, and processed by conventional software tools within a certain time frame. It is a massive, high-growth, and diverse information asset that requires new processing models to have stronger decision-making power, insight discovery, and process optimization capabilities. With the advent of the cloud era, big data has also attracted more and more attention. Big data requires special technologies to effectively process large amounts of data within a tolerable time frame. Technologies applicable to big data include large-scale parallel processing databases, data mining, distributed file systems, distributed databases, cloud computing platforms, the Internet, and scalable storage systems.
[0060] See also Figure 1a , a schematic diagram of the system architecture of an exemplary cloud network application scenario. As shown in the figure, when a user wants to activate a network service, he configures the control parameters through the front-end WEB page provided by the service controller, which is finally converted into control instructions of the network device after calculation and arrangement by the service controller and the network controller, and sent to the network device, thus completing the activation of the network service.
[0061] The business controller is a global controller deployed in the cloud, and the network controller is a regional controller. A large data center (Internet Data Center, IDC for short) deploys a network controller cluster, which includes multiple network controllers.
[0062] The following uses the creation of a network acceleration service as an example to illustrate the creation process. Figure 1b As shown in the figure, when the user creates a network segment acceleration service to the service controller, the service controller performs orchestration calculations and determines that the service includes four main steps: creating a network tunnel, creating a policy route, creating a border gateway protocol (Border Gateway Protocol, BGP), and creating a network quality analyzer (Network Quality Analyzer, NQA). The service controller determines the relevant control parameters of each step in turn and sends them to the network controller. The network controller further orchestrates the received control parameters to generate specific control instructions and sends them to the network device. Figure 1bThe figure shows the interaction between the network controller and the network device according to the control parameters related to the creation of the network tunnel issued by the service controller. It can be seen that the network controller performs three key steps in order to create a network tunnel between the network device: 1. Create a virtual forwarding table; 2. Create a tunnel; 3. Issue an encryption key. Specifically, the virtual forwarding table, also known as the virtual routing forwarding table (Virtual Routing Forwarding, VRF), can be used to logically divide the two interactive machines into multiple virtual switches, which can distinguish different business traffic. Different network services go through different VRFs, so that they are independent of each other, achieving the purpose of controlling the global traffic direction of the device. By creating a tunnel, a data packet of a network protocol can be encapsulated in another network protocol and sent. Building a GRE tunnel allows network devices in two different network segments to communicate and give full play to the functions of network devices. The purpose of issuing encryption keys is to achieve tunnel encryption so that data packets can be safely passed from one network to another.
[0063] Network controllers are usually deployed in regional IDC rooms that are closer to network devices. At least one data center is deployed in each geographic region. Network devices under the jurisdiction of the data center are divided based on the scope of the data center. For details, see Figure 1c , which exemplarily shows a schematic diagram of the network controller clusters of different data centers provided in an embodiment of the present application. For example, the network controller cluster deployed in the South China data center is responsible for managing the network devices in various provinces in South China, and the network controller cluster deployed in the North China data center is responsible for managing the network devices in various provinces in North China. The business controller in the cloud will send the control parameters of different network devices to the network controller to which the network devices belong.
[0064] In order to improve the availability of the system, the network controllers of each data center in the embodiment of the present application are deployed in a cluster manner, and the number of network controllers in the network controller cluster can be dynamically expanded and reduced. Figure 1c For example, since there are more businesses in South China at the current stage, more network controllers are deployed in the South China data center than in the North China data center.
[0065] From the previous introduction, we can know that the steps and links of issuing network services are relatively long. In addition, the effective time of network devices in different regions may be involved. Therefore, the interface provided to users at the front end of the service controller is usually asynchronous. That is, when a user creates a new service, the service controller checks the parameters and returns the successful creation (the page enters the service effective state). The background controller service starts asynchronous orchestration and issuing instructions.
[0066] In actual scenarios, there may be various reasons that may lead to the failure of service delivery, such as abnormal downtime of the network controller to which the service is delivered, or the inability to respond due to excessive load, or temporary network jitter of the controlled network device that cannot be received normally.
[0067] In the related art, the network controller will retry upon failure. For example, if a command fails to be sent once, it will wait for 3 seconds and then retry again. It will not retry after a certain number of consecutive failures.
[0068] The creation of network services is based on the control parameters input by the user. They are first arranged by the upper-level service controller and then sent to the network controller for arrangement. If the control instructions generated finally fail to be sent to the network device, the most likely reason is that the network device has a temporary failure (stuttering or downtime), the network link failure, etc. In theory, if there is a problem with the parameters input by the user, the upper-level service controller should be able to check it out. Unless there is a bug in the service program, it will not generate a control instruction that the network device cannot execute. If the instruction fails to be sent, the user's service creation will be marked as failed, which will cause a bad experience for the user and affect the success rate of service creation.
[0069] The control instruction sending method, network controller, service controller, electronic device, computer-readable storage medium and computer program product provided in the present application are intended to solve the above technical problems in the prior art.
[0070] The following describes several exemplary embodiments to illustrate the technical solutions of the embodiments of the present application and the technical effects produced by the technical solutions of the present application. It should be noted that the following embodiments can refer to, draw on or combine with each other, and the same terms, similar features and similar implementation steps in different embodiments will not be described repeatedly.
[0071] Figure 2a A schematic diagram of a system architecture for implementing a control instruction sending method provided in an embodiment of the present application, wherein the system may include a terminal 101 and a first server 102.
[0072] Data can be transmitted between the first server 102 and the terminal 101 via a target protocol link, which may include a link based on a transport layer protocol, such as a Transmission Control Protocol (TCP) link or a User Datagram Protocol (UDP) link transmission and other transport layer protocols.
[0073] The first server 102 can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers. It can also be 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, as well as big data and artificial intelligence platforms.
[0074] In one implementation of an embodiment of the present application, the first server 102 is a cloud server, and the first server can provide artificial intelligence cloud services, such as artificial intelligence cloud services that provide account security services (MMORPG). The so-called artificial intelligence cloud service is generally referred to as AIaaS (AI as aService, Chinese for "AI as a Service"). This is a mainstream service mode of an artificial intelligence platform. Specifically, the AIaaS platform will split several common AI services and provide independent or packaged services in the cloud. This service model is similar to opening an AI theme mall: all developers can access and use one or more artificial intelligence services provided by the platform through an API interface. Some senior developers can also use the AI framework and AI infrastructure provided by the platform to deploy and operate their own cloud artificial intelligence services. For example, the first server can provide a network business creation service.
[0075] The terminal 101 may be any device. In one implementation of the embodiment of the present application, the terminal 101 is a client terminal that can run a program for creating a network service.
[0076] In an embodiment of the present application, a control instruction sending method is provided, which is applied to a main network controller in a first network controller cluster, wherein the first network controller cluster is associated with a first data center, such as Figure 2b As shown, the method includes:
[0077] S201. Determine at least one target control instruction from a cache of a target data center based on a preset period, where the target data center includes the first data center;
[0078] S202: Send the target control instruction to a network device related to the target control instruction.
[0079] See also Figure 2c, which exemplarily shows a schematic diagram of the execution logic of each network controller in a network controller cluster. As shown in the figure, each data center in an embodiment of the present application has an associated network controller cluster, that is, a network controller cluster, and the present application provides a fallback solution for continuous failure of the network controller to send down, that is, a cache is built in each data center. If a network controller in the network controller cluster associated with the data cluster sends a control instruction and fails repeatedly for a preset number of times (for example, 3 times), the control instruction will be stored in the cache instead of being directly discarded.
[0080] The control instructions stored in the cache will be periodically taken out and sent again by the main network controller in the network controller cluster. Once sent successfully, they will be removed from the cache. If they still fail to send, they can be discarded or remain in the cache.
[0081] It can be seen from the above embodiments that the control instruction of the embodiment of the present application is related to a network device and a network service, and the control instruction is used to instruct the associated network device to execute the associated network service.
[0082] In some embodiments, the master network controller in a network controller cluster can be updated, that is, a master network controller can be changed to a slave network controller at a certain moment, and a slave network controller can be changed to a master network controller at a certain moment. The master-slave switching method can be implemented based on zookeeper, which will not be repeated in the embodiments of the present application.
[0083] In some embodiments, a timer may be started on the main network controller to retrieve control instructions from the cache in batches at preset time intervals, and then send the control instructions to the corresponding network devices according to the network devices associated with the control instructions.
[0084] The control instruction sending method of the embodiment of the present application is applied to the main network controller in the first network controller cluster, the first network controller cluster is associated with the first data center, the main network controller determines at least one target control instruction from the cache summary of the target data center based on a preset period, and sends the target control instruction to the network device related to the target control instruction. The present application creates a cache for each data center, and stores in the cache the control instructions that have failed to be sent continuously by each network controller in the network controller cluster managed by the data center, so that the control instructions that have failed to be sent continuously still have the opportunity to be re-issued. Since the main network controller of this scheme sends the control instruction in the cache once every preset period, it can effectively solve the problem of temporary sending failure caused by network link failure, network equipment failure and other reasons.
[0085] On the basis of the above embodiments, as an optional embodiment, the target data center of the embodiment of the present application also includes a second data center, and the second data center is associated with a second network controller cluster.
[0086] Determining at least one target control instruction from a cache in a target data center, the method also comprising:
[0087] Receive the address of the cache of the second data center sent by the service controller;
[0088] The address of the cache of the second data center is sent by the service controller when the second network controller cluster fails.
[0089] The embodiments of the present application further implement disaster recovery across data centers. Generally, the network controller cluster of a data center can meet the system availability of the data center, but in extreme scenarios, when the computer rooms of a data center are all unavailable, such as when a power outage or fire occurs, there is still a risk of data loss. For such extreme scenarios, the embodiments of the present application require the cloud-based business controller to check the health status of the network controller clusters associated with each data center. When it is found that all network controllers in a network controller cluster are faulty, the cache address of the data center will be temporarily sent to the main network controllers of other network controller clusters, and the main network controllers of other network controller clusters will be responsible for issuing control instructions for the cache of the faulty network controller cluster.
[0090] See also Figure 3 , which exemplarily shows an interactive schematic diagram of the control instruction sending method of an embodiment of the present application. As shown in the figure, the business controller checks the health status of the network controller clusters associated with each of the two data centers. For example, the business controller can send heartbeat packets to all network controllers of the two network controller clusters, and determine whether the business controller and the network controller can communicate normally based on whether a heartbeat response returned by the network controller is received. In some embodiments, the business controller can send heartbeat packets to the master network controller of the two network controller clusters, and the master network controller forwards the heartbeat packets to other slave network controllers, and the slave network controller returns the heartbeat response to the master network controller, and the master network controller summarizes all received heartbeat responses and returns them to the business controller. If the business controller can receive the heartbeat response, it determines that the health status of the corresponding network controller cluster is normal. Otherwise, it is abnormal.
[0091] In some embodiments, when a business controller sends a heartbeat packet to a master network controller, the master network controller first returns a heartbeat response to the business controller so that the business controller determines that communication with the master network controller is normal. After forwarding the heartbeat packet to the slave network controller, the master network controller waits for a certain period of time to receive the heartbeat responses returned by each slave network controller, and then sends the collected heartbeat responses to the business controller. If the business controller does not send a response message for receiving the heartbeat response, the master network controller instructs other slave network controllers to re-determine the master network controller. The original master network controller sends the collected heartbeat responses to the new master network controller, and the new network controller sends the collected heartbeat responses to the business controller. If the response message sent by the business controller is still not received, the heartbeat response is stopped.
[0092] If the business controller does not receive the heartbeat response from all network controllers in a network controller cluster, it determines that all network controllers in the second network controller cluster have failed. At this time, the address of the cache of the first data center is sent to the main network controller of the first network controller cluster. The main network controller of the first network controller cluster receives the address of the cache of the second data center, determines the target control instruction from the cache of the first data center and the cache of the second data center, and sends it to the relevant network devices.
[0093] Based on the above embodiments, as an optional embodiment, the main network controller of the first data center also receives the control parameters sent by the service controller, so that the main network controller of the first data center generates control instructions according to the control parameters and sends them to the corresponding network devices. In other words, when the second network controller cluster fails, if the service controller receives the control parameters that should be processed by the second network controller cluster, it will also be transferred to the main network controller of the first network controller cluster for processing, so as to prevent the control instructions from not being generated and sent in time.
[0094] Based on the above embodiments, as an optional embodiment, determining at least one target control instruction from the cache of the target data center includes:
[0095] Determining read reference information of each control instruction stored in the cache, wherein the read reference information includes at least one of an instruction write time or an instruction priority;
[0096] At least one target control instruction is determined from the cache according to the read reference information of each control instruction.
[0097] Since each network controller in a network controller cluster will store the control instructions that it has failed to send continuously in the cache, the number of control instructions stored in the cache is sometimes relatively large, and the main network controller does not have the conditions to send all the control instructions, so it is necessary to filter a part of the control instructions stored in the cache as the target control instructions to be sent. When determining the target control instruction, the embodiment of the present application needs to determine the reading reference information of each control instruction, and the reading reference information can be at least one of the instruction writing time or the instruction priority. The instruction writing time refers to the time when the control instruction is stored in the cache, and the instruction priority refers to the sending priority of the control instruction.
[0098] In some embodiments, the instruction priority of a control instruction can be determined according to the priority of a network device associated with the control instruction, or according to the priority of a network service associated with the control instruction. The priority of the network service can be configured by the user, or by the user's own level. For example, if the user himself is a VIP of a cloud network application, then the priority of the network service created by the user is higher than that of the network service created by a non-VIP, and the corresponding control instruction can be selected as the target control instruction with higher priority.
[0099] Based on the above embodiments, as an optional embodiment, determining at least one target control instruction from the cache according to the read reference information of each control instruction includes:
[0100] Based on the instruction writing time of each control instruction, determining each candidate control instruction whose writing time is not less than a preset time from each control instruction;
[0101] The candidate control instructions not exceeding a preset number are determined as target control instructions.
[0102] When the control instruction is stored in the cache, the embodiment of the present application can record the time when the control instruction is stored in the cache, that is, the instruction writing time. When the main network controller periodically determines the target control instruction, it determines multiple candidate control instructions whose writing time is not less than the preset time based on the instruction writing time of each control instruction, and then determines the candidate control instructions not exceeding the preset number as the target control instruction. The preset number can be determined according to the real-time load of the main network controller, so as to realize the dynamic resending of the target control instruction, while not affecting the purpose of the main network controller sending other control instructions.
[0103] See also Figure 4 , which exemplarily shows a flow chart of determining a target control instruction provided by an embodiment of the present application, as shown in the figure, including:
[0104] S401, determining that the current time is a preset time from the time when the target control instruction was last determined;
[0105] S402, determine whether there is an unmarked control instruction in the cache, if yes, proceed to step S403, if not, proceed to step S404;
[0106] S403, determine whether the value recorded by the counter reaches a preset value, if so, execute S404, if not, execute S405;
[0107] S404, determining that the step of determining the target control instruction has ended, and returning to S401 in the next cycle;
[0108] S405, selecting an unmarked control instruction from the cache;
[0109] S406, determining whether the written duration of the control instruction is not less than the preset duration, if so, executing S407, if not, executing S409;
[0110] S407, sending the control instruction to the network device associated with the control instruction;
[0111] S408, determining whether the control instruction is sent successfully, if yes, deleting the control instruction in the cache and returning to execute S402, if no, executing S409;
[0112] S409: Mark the control instruction and return to execute S402.
[0113] On the basis of the above-mentioned embodiments, as an optional embodiment, the cache of the embodiment of the present application stores the control parameters of the control instructions and the transmission information related to the control instructions through a data table.
[0114] Specifically, there are many types of control instructions generated by the network controller. In order to identify each control instruction, even if it is a control instruction of the same type sent to the same network device, the embodiment of the present application will generate a unique instruction identifier. In addition to the instruction identifier, the transmission information also includes the instruction type, the device identifier of the network device, the center identifier of the data center associated with the control instruction, and the time when the control instruction is stored in the data table (that is, the time when the instruction is written).
[0115] The data table of the embodiment of the present application includes multiple fields, including a first field and at least one second field. The first field is used to store control parameters, such as the source port and source IP address of the policy routing. Since the specific control parameters of different types of control instructions vary greatly and cannot be stored in a structured data table, the embodiment of the present application serializes the control parameters into a byte stream and stores the serialized control parameters through the first field.
[0116] In some embodiments, the serialization process of the embodiment of the present application includes json serialization or protobuf serialization. The advantage of using json serialization data is that the serialized data is human readable, while the protobuf serialization has higher performance.
[0117] It has been verified that by serializing the control parameters and then storing the data table, the embodiment of the present application can increase the volume of the data table by 20-30% compared to not performing the serialization process.
[0118] Please refer to Table 1, which exemplarily shows a data table of an embodiment of the present application. The table has 4 fields, wherein the first field is used to store control parameters, and the three second fields are respectively used to store transmission information such as instruction identifier, instruction type and device identifier. It can be seen that the formats of the information stored in the second fields corresponding to different control instructions in the embodiment of the present application are not much different, and structured storage can be used, while the formats of the control parameters corresponding to different control instructions are quite different. For example, the control parameter srcIP corresponding to instruction identifier 1001 in Table 1 refers to the source IP address used as the basis for routing during load balancing, and the control parameter specifically indicates an IP address, while the control parameter srcPort corresponding to instruction identifier 1002 refers to the source target port, and the control parameter specifically indicates a port number, which is quite different from the structure of the IP address. Therefore, the control parameters in the table are serialized into json into human-readable information, and the generated data mention is also reduced to a certain extent.
[0119]
[0120] Table 1 Data table of an embodiment of this application
[0121] Please refer to Table 2, please refer to Table 1, which exemplarily shows a data table of another embodiment of the present application, the table has 6 fields, wherein the first field is used to store control parameters, and the 5 second fields are respectively used to store instruction identifier, instruction type, area identifier, write time, device identifier and other transmission information, wherein the area identifier is used to identify which network controller cluster processes the control instruction, and the write time is the time when the control instruction is stored in the cache. By carrying the control parameters and transmission information shown in Table 2, both the network controller in the same network controller cluster and other master nodes across network controller clusters can correctly identify the control instructions in the data table and issue them.
[0122]
[0123]
[0124] Table 2 Data table of another embodiment of the present application
[0125] Based on the above embodiments, as an optional embodiment, the transmission information stored in the second field of the embodiment of the present application is also serialized data, and the data has a preset byte length.
[0126] It should be noted that explicitly storing all fields in the cache will take up a lot of storage resources. The above embodiment also mentioned that the control parameters can be serialized using json or protobuf to improve efficiency. On this basis, consider storing the transmission information stored in the second field in a more efficient way. If only a unique identifier and the serialized string of the instruction parameters are stored, the instruction cache can be saved with minimal resources.
[0127] In an embodiment of the present application, the number of second fields is 1, that is, the second field stores all transmission information. Taking the above Table 2 as an example, the second field will store four types of transmission information, namely, instruction type, area identifier, device identifier and write time. By serializing these four types of transmission information into data of a preset byte length, the setting of the instruction identifier can be omitted, and all storage information can be stored at the same time.
[0128] Please refer to Table 3. The embodiment of the present application can design an instruction identifier with a length of 128 bits, that is, 16 bytes. The composition of the instruction identifier is shown in Table 3. 42 bits represent the Unix timestamp, which can represent a time length of 139 years in milliseconds; 10 bits represent the area identifier, that is, it can represent 1024 areas; 16 bits represent the device identifier, that is, it can represent 65536 devices; 10 bits represent the instruction type, that is, it can represent 1024 types.
[0129] length meaning capacity 42bit Instruction writing time Maximum 139 years 10bit Area identification 1024 regions 16bit Equipment identification 63356 devices 10bit Instruction Type 1024 instruction types 16bit Instruction auto-increment sequence number 65535-bit serial number
[0130] Table 3 Bit information table of the embodiment of the present application
[0131] Table 3 has a total of 94 valid bits, and the remaining bits are reserved. Designed in this way, a control instruction only needs a 16-byte instruction identifier plus the instruction parameters serialized by protobuf. At the same time, the 16-byte instruction identifier includes all the transmission information processed by serialization, such as the instruction type, the device identifier of the network device associated with the control instruction, the center identifier of the data center associated with the control instruction, and the time when the control instruction is stored in the data table, etc.
[0132] Based on the above embodiments, as an optional embodiment, sending the target control instruction to a network device related to the target control instruction includes:
[0133] Determine the network device associated with each target control instruction;
[0134] If it is determined that one network device is associated with multiple target control instructions, the multiple target control instructions are sent to the network device in batches.
[0135] After determining at least one target control instruction, the embodiment of the present application will determine the network device managed by each target control instruction. If it is determined that a network device is associated with multiple target control instructions, the multiple target control instructions will be sent to the network device in batches to reduce the number of interactions and improve the sending efficiency.
[0136] See also Figure 5 , which exemplarily shows a flow chart of a control instruction sending method executed by a main network controller of a first data center provided in another embodiment of the present application, as shown in the figure, including:
[0137] S501, generating a control instruction based on a service request;
[0138] S502, sending a control instruction to the associated network device, and if the sending fails, repeating the sending for a preset number of times;
[0139] S503, in response to a failure in repeatedly sending the control instruction, determining a control parameter and at least one transmission information related to the control instruction, the transmission information including: an instruction type, a device identifier of a network device associated with the control instruction, a center identifier of a data center associated with the control instruction, and an instruction writing time;
[0140] S504: Write the result of serializing the control parameters as the instruction identifier into the first field of the cached data table, and write the result of serializing all the transmission information as the instruction identifier into the second field of the cached data table, so as to complete the storage of the control instruction into the cache of the first data center;
[0141] S505. Receive the address of the cache of the second data center sent by the service controller;
[0142] S506, based on a preset cycle, determining read reference information of each control instruction stored in a cache of a target data center, wherein the read reference information includes at least one of an instruction write time or an instruction priority, and the target data center includes a first data center and a second data center;
[0143] S507, determining at least one target control instruction from the cache according to the read reference information of each control instruction;
[0144] S508: Send the target control instruction to the network device related to the target control instruction.
[0145] The embodiment of the present application also provides a control instruction sending method, which is applied to any network controller in a first network controller cluster, wherein the first network controller cluster is associated with a first data center, such as Figure 6 As shown, the method includes:
[0146] S601, generating a control instruction based on a service request, wherein the control instruction is associated with a network device and a network service, and the control instruction is used to instruct the associated network device to execute the associated network service;
[0147] S602, sending the control instruction to the associated network device;
[0148] S603: In response to a failure in repeatedly sending the control instruction, store the control instruction in a cache of the first data center.
[0149] In an embodiment of the present application, the user configures the control parameters of the network service through the front-end page provided by the service controller and sends a service request to the service controller. It can be understood that the service request includes the control parameters configured by the user. The service controller forwards the service request to the network controller, and the network controller generates a control instruction based on the service request. The control instruction is associated with a network device and a network service.
[0150] In some embodiments, after generating a control instruction, the network controller can send the control instruction to the network device associated with the control instruction. In addition, after generating the control instruction, the control instruction can be temporarily stored, and the control instructions that need to be sent to the same network device can be sent in batches at regular intervals.
[0151] It can be seen from the above embodiments that creating a network service often involves multiple steps, and each step requires sending corresponding control instructions to the network controller and the network device. Therefore, in some embodiments, the network controller can count the interval time for sending control instructions for each step. For any two steps, if the interval time between the two steps is less than a preset threshold, the control instructions corresponding to the two steps can be sent in batches, thereby reducing the number of interactions between the network device and the network controller and improving the interaction efficiency.
[0152] When the network controller of the embodiment of the present application fails to send a control instruction, it will send the control instruction again. When repeated sending of the control instruction fails, the control instruction will not be discarded, but the control instruction will be sent to the cache of the first data center, laying the foundation for the master node in the subsequent network controller cluster to periodically send the control instructions in the cache.
[0153] Based on the above embodiments, as an optional embodiment, storing the control instruction in the cache of the first data center includes:
[0154] determining a control parameter and at least one transmission information associated with the control instruction;
[0155] Performing serialization processing on the control parameters to obtain serialized control parameters;
[0156] The serialized control parameters are recorded in the first field of the cached data table, and the corresponding transmission information is recorded in each second field of the data table.
[0157] It can be seen from the above embodiments that the transmission information of the embodiments of the present application may include the instruction identifier, instruction type, device identifier of the network device associated with the control instruction, the center identifier of the data center associated with the control instruction, and the time when the control instruction is stored in the data table, etc.
[0158] The data table of the embodiment of the present application includes a first field and multiple second fields. Since the formats of different control instructions are different, the first field of the embodiment of the present application is used to store serialized control parameters to adapt to structured data table storage, and can also effectively reduce the data storage volume.
[0159] Each second field of the data table of the embodiment of the present application is used to store corresponding transmission information, and the number of transmission information stored in each second field can be one or more, which is not specifically limited in the embodiment of the present application. For example, one second field is used to store the instruction identifier of the control instruction, and another second field is used to store the instruction type and the device identifier.
[0160] It should be noted that explicitly storing all fields in the cache will take up a lot of storage resources. Therefore, the embodiment of the present application further stores the serialized transmission information in the second field, and the serialized transmission information is of a preset byte length. In this way, when a second field stores multiple transmission information, it can be split and parsed based on the byte length corresponding to each transmission information.
[0161] In one embodiment, the transmission information may also be serialized using json or protobuf.
[0162] Based on the above embodiments, as an optional embodiment, the transmission information stored in the second field is also stored in a more efficient manner. If only a unique identifier and a serialized string of instruction parameters are stored, the instruction cache can be saved with minimal resources. Therefore, the present application stores all transmission information in a second field, and uses all transmission information after serialization as the instruction identifier of the control instruction.
[0163] The embodiment of the present application also provides a control instruction sending method, which is applied to a service controller, wherein the service controller is at least a management server of a second network controller cluster. In some embodiments, the service controller may be a management server of all network controller clusters, and the service controller is connected to a main network controller in the first network controller cluster, such as Figure 7 As shown, the method includes:
[0164] S701: If it is determined that all network controllers in the second network controller cluster fail, send the cache of the second data center to the main network controller in the first network controller cluster.
[0165] The cache of the second data center in the embodiment of the present application includes at least one control instruction that the second network controller cluster repeatedly sends failed. Each control instruction is associated with a network device and a network service, and the control instruction is used to instruct the associated network device to execute the associated network service.
[0166] The embodiments of the present application realize disaster recovery across data centers. Generally, the network controller cluster of a data center can meet the system availability of the data center, but in extreme scenarios, when the computer rooms of a data center are all unavailable, such as when a power outage or fire occurs, there is still a risk of data loss. For such extreme scenarios, the embodiments of the present application require the cloud-based business controller to check the health status of the network controller clusters associated with each data center. When it is found that all network controllers in a network controller cluster are faulty, the cache address of the data center will be temporarily sent to the main network controllers of other network controller clusters, and the main network controllers of other network controller clusters will be responsible for issuing control instructions for the cache of the faulty network controller cluster.
[0167] The following describes the method for sending a control instruction according to an embodiment of the present application in conjunction with a specific application scenario.
[0168] See also Figure 8 , which exemplarily shows an interactive diagram of a specific application scenario provided by an embodiment of the present application. The user of this scenario hopes to open a network acceleration service from Shanghai to Beijing and requires that the traffic from an IP address from Shanghai to Beijing, such as 172.XX1, be transmitted through a dedicated encrypted tunnel.
[0169] The parameters entered by the user in the WEB page provided by the business controller include: the source address and destination address of the accelerated service (i.e. Shanghai to Beijing), the destination IP address of the acceleration 172.XX1, the secret key of the encrypted tunnel, etc. Since Shanghai belongs to the East China Data Center, the business controller sends the parameters entered by the user to the network controller cluster of the East China Data Center. A network controller of the East China Data Center sends a control instruction to the dedicated gateway (network device) from Shanghai to Beijing to establish an encrypted tunnel and configure the policy routing of the destination IP to guide the business traffic into the encrypted tunnel.
[0170] Since the network controller is disconnected from the above network device and the repeated sending of control instructions fails, the control instructions are stored in the cache of the East China Data Center. However, due to a power outage in the East China Data Center during the preset period, the service controller is disconnected from the network controller cluster of the East China Data Center, so the service controller sends the address of the cache of the East China Data Center to the main network controller of the Central China Data Center, and the main network controller of the Central China Data Center re-sends the control instructions to the above network device. After the transmission is successful and the network device creates the network acceleration service, the user is fed back a message that the service has been successfully created.
[0171] The embodiment of the present application provides a master network controller in a first network controller cluster, such as Fig. 9 As shown, the first network controller cluster is associated with the first data center, and the main network controller may include: an instruction determination module 901 and an instruction resending module 902, wherein:
[0172] An instruction determination module 901 is used to determine at least one target control instruction from a cache of a target data center based on a preset period, wherein the target data center includes the first data center;
[0173] An instruction resending module 902 is used to send the target control instruction to the network device related to the target control instruction;
[0174] Each data center is associated with a corresponding network controller cluster, and the cache of each data center stores control instructions that have failed to be sent continuously by each network controller in the associated network controller cluster.
[0175] The main network controller of the embodiment of the present application can execute the control instruction sending method on the main network controller side provided in the embodiment of the present application, and its implementation principle is similar. The actions performed by each module in the main network controller of each embodiment of the present application correspond to the steps in the method of each embodiment of the present application. For the detailed functional description of each module of the main network controller, please refer to the description in the corresponding method shown in the previous text, which will not be repeated here.
[0176] The embodiment of the present application provides a network controller in a first network controller cluster, such as Fig.10 As shown, the first network controller cluster is associated with the first data center, and the network controller includes an instruction generation module 1001 and an instruction sending module 1002. Specifically:
[0177] An instruction generation module 1001 is used to generate a control instruction based on a service request, wherein the control instruction is associated with a network device and a network service, and the control instruction is used to instruct the associated network device to execute the associated network service;
[0178] An instruction sending module 1002 is used to send the control instruction to the associated network device;
[0179] In response to a failure in repeatedly sending the control instruction, storing the control instruction in a cache of the first data center.
[0180] The network controller of the embodiment of the present application can execute the control instruction sending method on the network controller side provided in the embodiment of the present application, and its implementation principle is similar. The actions performed by each module in the network controller of each embodiment of the present application correspond to the steps in the method of each embodiment of the present application. For the detailed functional description of each module of the network controller, please refer to the description in the corresponding method shown in the previous text, which will not be repeated here.
[0181] The present application embodiment provides a service controller, such as Fig.11 As shown, the service controller is at least a management server of the second network controller cluster and is connected to the main network controller in the first network controller cluster. The service controller includes a cache address sending module 1101, specifically:
[0182] The cache address sending module 1101 is used to send the cache address of the second data center to the main network controller in the first network controller cluster if it is determined that all network controllers in the second network controller cluster fail;
[0183] Wherein, the cache of the second data center includes at least one control instruction that failed to be repeatedly sent by the second network controller cluster;
[0184] Each control instruction is associated with a network device and a network service, and the control instruction is used to instruct the associated network device to execute the associated network service.
[0185] The business controller of the embodiment of the present application can execute the control instruction sending method on the business controller side provided in the embodiment of the present application, and its implementation principle is similar. The actions performed by each module in the business controller of each embodiment of the present application correspond to the steps in the method of each embodiment of the present application. For the detailed functional description of each module of the network controller, please refer to the description in the corresponding method shown in the previous text, which will not be repeated here.
[0186] An electronic device is provided in an embodiment of the present application, including a memory, a processor and a computer program stored in the memory, and the processor executes the above-mentioned computer program to implement the steps of the control instruction sending method. Compared with the related art, it can achieve: based on a preset period, at least one target control instruction is determined from the cache summary of the target data center, and the target control instruction is sent to the network device related to the target control instruction. The present application creates a cache for each data center, and stores the control instructions that have failed to be sent continuously by each network controller in the network controller cluster managed by the data center in the cache, so that the control instructions that have failed to be sent continuously still have a chance to be re-issued. Since the main network controller of this scheme sends the control instruction in the cache once every preset period, it can effectively solve the problem of temporary sending failure caused by network link failure, network equipment failure and other reasons.
[0187] In an alternative embodiment, an electronic device is provided, such as Fig.12 As shown, Fig.12 The electronic device 4000 shown includes: a processor 4001 and a memory 4003. The processor 4001 and the memory 4003 are connected, such as through a bus 4002. Optionally, the electronic device 4000 may also include a transceiver 4004, which may be used for data interaction between the electronic device and other electronic devices, such as data transmission and / or data reception. It should be noted that in actual applications, the transceiver 4004 is not limited to one, and the structure of the electronic device 4000 does not constitute a limitation on the embodiments of the present application.
[0188] Processor 4001 may be a CPU (Central Processing Unit), a general-purpose processor, a DSP (Digital Signal Processor), an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Gate Array) or other programmable logic devices, transistor logic devices, hardware components or any combination thereof. It may implement or execute various exemplary logic blocks, modules and circuits described in conjunction with the disclosure of this application. Processor 4001 may also be a combination that implements computing functions, such as a combination of one or more microprocessors, a combination of a DSP and a microprocessor, etc.
[0189] The bus 4002 may include a path to transmit information between the above components. The bus 4002 may be a PCI (Peripheral Component Interconnect) bus or an EISA (Extended Industry Standard Architecture) bus. The bus 4002 may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Fig.12 Only one thick line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.
[0190] The memory 4003 may be a ROM (Read Only Memory) or other types of static storage devices that can store static information and instructions, a RAM (Random Access Memory) or other types of dynamic storage devices that can store information and instructions, or an EEPROM (Electrically Erasable Programmable Read Only Memory), a CD-ROM (Compact Disc Read Only Memory) or other optical disk storage, optical disk storage (including compressed optical disk, laser disk, optical disk, digital versatile disk, Blu-ray disk, etc.), magnetic disk storage media, other magnetic storage devices, or any other medium that can be used to carry or store computer programs and can be read by a computer, without limitation herein.
[0191] The memory 4003 is used to store the computer program for executing the embodiment of the present application, and the execution is controlled by the processor 4001. The processor 4001 is used to execute the computer program stored in the memory 4003 to implement the steps shown in the above method embodiment.
[0192] An embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps and corresponding contents of the aforementioned method embodiment can be implemented.
[0193] The embodiment of the present application also provides a computer program product, including a computer program, which can implement the steps and corresponding contents of the aforementioned method embodiment when executed by a processor.
[0194] The terms "first", "second", "third", "fourth", "1", "2", etc. (if any) in the specification and claims of this application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the numbers used in this way can be interchanged where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than that shown or described in the drawings.
[0195] It should be understood that, although each operation step is indicated by arrows in the flowchart of the embodiment of the present application, the implementation order of these steps is not limited to the order indicated by the arrows. Unless clearly stated herein, in some implementation scenarios of the embodiment of the present application, the implementation steps in each flowchart can be performed in other orders according to demand. In addition, some or all of the steps in each flowchart may include multiple sub-steps or multiple stages based on actual implementation scenarios. Some or all of these sub-steps or stages may be executed at the same time, and each sub-step or stage in these sub-steps or stages may also be executed at different times respectively. In different scenarios of execution time, the execution order of these sub-steps or stages may be flexibly configured according to demand, and the embodiment of the present application does not limit this.
[0196] The above is only an optional implementation method for some implementation scenarios of the present application. It should be pointed out that for ordinary technicians in this technical field, without departing from the technical concept of the solution of the present application, other similar implementation methods based on the technical ideas of the present application are also within the protection scope of the embodiments of the present application.
Claims
1. A control instruction sending method, characterized in that: Applied to a master network controller in a first network controller cluster, the first network controller cluster being associated with a first data center, the method comprising: Based on a preset period, determining at least one target control instruction from a cache of a target data center, the target data center including the first data center; Sending the target control instruction to a network device related to the target control instruction; Each data center is associated with a corresponding network controller cluster, and the cache of each data center stores control instructions that have failed to be sent continuously by each network controller in the associated network controller cluster; Each control instruction is associated with a network device and a network service, and the control instruction is used to instruct the associated network device to execute the associated network service.
2. The method according to claim 1, characterized in that The target data center also includes a second data center, the second data center is associated with a second network controller cluster; The determining at least one target control instruction from the cache of the target data center also includes: Receive the address of the cache of the second data center sent by the service controller; The address of the cache of the second data center is sent by the service controller when the second network controller cluster fails.
3. The method according to claim 1 or 2, characterized in that: The determining at least one target control instruction from the cache of the target data center includes: Determining read reference information of each control instruction stored in the cache, the read reference information comprising at least one of an instruction write time or an instruction priority; At least one target control instruction is determined from the cache according to the read reference information of each control instruction.
4. The method according to claim 3, characterized in that The determining at least one target control instruction from the cache according to the read reference information of each control instruction comprises: Based on the instruction writing time of each control instruction, determining each candidate control instruction whose writing time is not less than a preset time from each control instruction; The candidate control instructions not exceeding a preset number are determined as target control instructions.
5. The method according to claim 1, characterized in that The cache stores control parameters of the control instruction and transmission information related to the control instruction through a data table; The data table includes a first field and at least one second field, the first field is used to store the serialized control parameters, and each second field is used to store at least one transmission information related to the control instruction.
6. The method according to claim 5, characterized in that The second field is used to store at least one type of transmission information after serialization processing, and the at least one type of transmission information after serialization processing has a preset byte length.
7. The method according to claim 5 or 6, characterized in that: The serialization processing method is json serialization method or protobuf serialization method.
8. The method according to claim 5 or 6, characterized in that: The transmission information related to the control instruction also includes one of the following: Instruction identification; Instruction type; The device identifier of the network device associated with the control instruction; The central identifier of the data center to which the control instruction is associated, and Instruction writing time.
9. The method according to claim 1, characterized in that: The sending the target control instruction to the network device related to the target control instruction includes: Determine the network device associated with each target control instruction; If it is determined that one network device is associated with multiple target control instructions, the multiple target control instructions are sent to the network device in batches.
10. A control instruction sending method, characterized in that: Applied to any one network controller in a first network controller cluster, the first network controller cluster being associated with a first data center, the method comprising: Generate a control instruction based on the service request, wherein the control instruction is associated with a network device and a network service, and the control instruction is used to instruct the associated network device to execute the associated network service; sending the control instruction to the associated network device; In response to a failure in repeatedly sending the control instruction, storing the control instruction in a cache of the first data center.
11. The method according to claim 10, characterized in that The storing the control instruction in the cache of the first data center includes: determining a control parameter and at least one transmission information associated with the control instruction; Performing serialization processing on the control parameters to obtain serialized control parameters; The serialized control parameters are recorded in the first field of the cached data table, and the corresponding transmission information is recorded in each second field of the data table.
12. The method according to claim 11, characterized in that The recording of corresponding transmission information in each second field in the data table includes: For each second field in the data table, serialize the transmission information corresponding to the second field to obtain the serialized transmission information, where the serialized transmission information has a preset byte length; The transmission information after the serialization process is recorded in the second field.
13. A control instruction sending method, characterized in that: Applied to a service controller, the service controller is at least a management server of a second network controller cluster and is connected to a master network controller in a first network controller cluster, the method comprising: If it is determined that all network controllers in the second network controller cluster fail, sending the address of the cache of the second data center to the master network controller in the first network controller cluster; Wherein, the cache of the second data center includes at least one control instruction that failed to be repeatedly sent by the second network controller cluster; Each control instruction is associated with a network device and a network service, and the control instruction is used to instruct the associated network device to execute the associated network service.
14. A master network controller in a first network controller cluster, characterized in that: The first network controller cluster is associated with a first data center, and the master network controller includes: an instruction determination module, configured to determine at least one target control instruction from a cache of a target data center based on a preset period, the target data center including the first data center; An instruction resending module, used for sending the target control instruction to the network device related to the target control instruction; Each data center is associated with a corresponding network controller cluster, and the cache of each data center stores control instructions that have failed to be sent continuously by each network controller in the associated network controller cluster.
15. A network controller in a first network controller cluster, characterized in that: The first network controller cluster is associated with a first data center, and the network controller includes: An instruction generation module, used to generate a control instruction based on a service request, wherein the control instruction is associated with a network device and a network service, and the control instruction is used to instruct the associated network device to execute the associated network service; An instruction sending module, used for sending the control instruction to the associated network device; In response to a failure in repeatedly sending the control instruction, storing the control instruction in a cache of the first data center.
16. A service controller, characterized in that: The service controller is at least a management server of the second network controller cluster and is connected to a main network controller in the first network controller cluster. The service controller includes: A cache address sending module, configured to send the address of the cache of the second data center to the main network controller in the first network controller cluster if it is determined that all network controllers in the second network controller cluster fail; Wherein, the cache of the second data center includes at least one control instruction that failed to be repeatedly sent by the second network controller cluster; Each control instruction is associated with a network device and a network service, and the control instruction is used to instruct the associated network device to execute the associated network service.
17. An electronic device comprising a memory, a processor and a computer program stored in the memory, characterized in that: The processor executes the computer program to implement the control instruction sending method according to any one of claims 1 to 12.
18. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the control instruction sending method according to any one of claims 1 to 12 is implemented.
Citation Information
Patent Citations
Method and device for issuing strategy
CN106911680A
Data processing method and system and electronic equipment
CN114896281A
Storage controller failover system
US20170242771A1
Injecting controlled network failures using in-situ OAM and other techniques
US20220353143A1
