A method and device for ensuring consistency of network element device configuration

By introducing the agent and Raft protocol, consistent synchronization of network element device configurations is achieved, solving the problems of resource consumption and inconsistent status caused by reconciliation at too fast or too slow frequency in the existing technology, and improving the scalability and configuration consistency of the system.

CN116346601BActive Publication Date: 2026-04-21CHINA TELECOM CLOUD TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
CHINA TELECOM CLOUD TECH CO LTD
Filing Date
2023-03-12
Publication Date
2026-04-21

AI Technical Summary

Technical Problem

The existing method of periodically reconciling accounts through the controller and VNE device has problems such as excessive bandwidth consumption due to excessive fetching frequency, and inconsistency between the VNE device and the controller due to excessively slow fetching frequency.

Method used

By introducing an agent and adopting the Raft protocol, a synchronization update mechanism between the leader agent and the lower agent is used, combined with threshold judgment to perform full or incremental synchronization, ensuring the consistency of network element device configuration.

Benefits of technology

By using the Raft protocol to ensure configuration consistency among distributed nodes, the system's scalability is improved. The synchronization between network elements and agents has been enhanced with threshold judgment, enabling full synchronization when there are many missing configurations and incremental synchronization when there are few missing configurations, thus solving the problem of configuration inconsistency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116346601B_ABST
    Figure CN116346601B_ABST
Patent Text Reader

Abstract

This invention discloses a method and apparatus for ensuring configuration consistency of network element devices, relating to the field of Internet communication technology. The method for ensuring configuration consistency of network element devices includes the following steps: after receiving a configuration packet from the controller, the leader agent synchronizes and updates with the follower agent according to the Raft protocol. The leader agent and follower agent update the state database based on transactions added to the transaction database and then send an acknowledgment signal to the controller. By using the Raft protocol to ensure configuration consistency among distributed nodes, the introduction of agents to decouple the direct interaction between the controller and network elements improves system scalability. The synchronization between network elements and agents incorporates threshold judgment, which can automatically select full synchronization when there are many configuration gaps and incremental synchronization when there are few configuration gaps.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of Internet communication technology, and in particular to a method and apparatus for ensuring the consistency of network element device configuration. Background Technology

[0002] SDN (Software Defined Network) is a technology that allows for centralized configuration, management, monitoring, and programming of networks. It can meet the automation and customization needs of large-scale network devices and has been widely used in the cloud computing field.

[0003] SDN is mainly divided into the control plane and the data plane. The SDN controller implements functions such as network topology planning, route calculation and planning, flow table generation and distribution, and network element management and control. The data plane is usually handled by virtual network elements (VNEs) to forward user data. The forwarding table entries required during the forwarding process are generated and distributed by the control layer. Therefore, the controller has a large amount of configuration to synchronize with the VNEs. In actual production environments, various reasons can lead to inconsistencies in the configuration of network elements, such as abnormal network element and network management interfaces, network jitter, and network element failures. Therefore, ensuring the consistency of VNE and controller configurations is a very challenging aspect.

[0004] Currently, one industry-used solution involves periodically reconciling the controller and VNE devices. This reconciliation process requires the VNE device to retrieve all configuration information from the controller, comparing it point-by-point with the network element's configuration information to identify discrepancies and perform corresponding CRUD operations. Because this solution requires periodic configuration retrieval and comparison, fetching too frequently consumes significant bandwidth and computing resources, while fetching too slowly prolongs the time between VNE device and controller state inconsistencies. Summary of the Invention

[0005] This application provides a method and apparatus for ensuring the consistency of network element device configurations. It solves the problems of existing methods that rely on periodic reconciliation between controllers and VNE devices, where excessively fast fetching leads to the consumption of large amounts of bandwidth computing resources, while excessively slow fetching leads to prolonged inconsistencies between the VNE device and the controller. The method achieves strong consistency between agents through the Raft protocol, and network elements and agents synchronize their configurations, thereby ensuring the eventual consistency of the overall configuration.

[0006] This application provides a method for ensuring the consistency of network element device configurations, including the following steps:

[0007] S1. After receiving the configuration packet from the controller, the leader agent synchronizes and updates with the lower agent according to the Raft protocol.

[0008] S2, the leader agent and follower agent update the state database based on the transactions added to the transaction database and then send an acknowledgment signal to the controller;

[0009] S3, while the leader agent and follower lower agent update the status database based on the transactions added to the transaction database, the follower lower agent updates the configuration based on the configuration ID requested by the network element.

[0010] Furthermore, the synchronization update between the leader agent and the follower lower agent in S1 includes a first phase and a second phase. The first phase involves sending a configuration package to the follower lower agent and only writing to the transaction database. The second phase is a confirmation phase, in which the state database is modified based on the transactions from the first phase.

[0011] Furthermore, the first stage specifically includes the following steps:

[0012] The first step is for the leader agent to receive the configuration package sent by the controller and assign an auto-incrementing ID to the configuration package.

[0013] The second step is to verify whether the configuration in the configuration package is valid. If it is valid, the configuration package is synchronized to loweragent. If it is invalid, an error is reported.

[0014] Furthermore, the second stage specifically includes the following steps:

[0015] Step 1: After the follow lower agent successfully verifies the data, the leader agent receives the confirmation signal sent by the follow lower agent.

[0016] The second step is that after the leader agent has collected more than half of the confirmation signals, it sends confirmation signals to the lower agents.

[0017] The third step involves the leader agent and follower lower agent writing the configuration into the transaction database.

[0018] Step 4: After updating the state database based on the transactions added to the transaction database, the leader agent and follower agent send an acknowledgment signal to the controller.

[0019] Furthermore, before sending the configuration package, the controller will first receive a configuration request for the resource, modify the relevant resource, and set the synchronization signal to error. After receiving the confirmation signal sent by the leader agent, the controller will set the synchronization signal to correct.

[0020] Furthermore, the transaction library in S2 consists of configuration transactions received sequentially, and an auto-incrementing ID is generated for each configuration. The state library is a full library of all current configurations, which can be obtained from each transaction in the transaction library through state transitions.

[0021] Furthermore, the process of updating the configuration in S3 by the lower agent based on the configuration ID requested by the network element specifically includes:

[0022] S31, the configuration ID for the lower agent to receive timed requests from network elements;

[0023] S32. Compare the received configuration ID with the lower agent's own configuration ID to determine if it is greater than the set threshold. If it is, start full synchronization; otherwise, start incremental update.

[0024] Furthermore, during full synchronization, the configuration is provided from the state library;

[0025] When performing incremental updates, incremental synchronization is performed from the transaction database based on the transaction ID.

[0026] This application provides an apparatus for ensuring the consistency of network element device configurations, comprising a synchronization update module, a confirmation module, and a network element configuration update module, wherein:

[0027] The synchronization update module is used to follow the lower agent to synchronize and update with the leader agent via the Raft protocol after the leader agent receives the configuration packet sent by the controller.

[0028] The confirmation module is used to follow the lower agent and the leader agent to update the status database based on the transactions added to the transaction database, and then the leader agent sends a confirmation signal to the controller.

[0029] The network element configuration update module is used to update the status database based on the transaction database added by the lower agent and the leader agent, while the lower agent updates the configuration based on the configuration ID requested by the network element.

[0030] This application provides a computer-readable storage medium for storing a program that, when executed by a processor, implements a method for ensuring the consistency of network element device configurations.

[0031] One or more technical solutions provided in the embodiments of this application have at least the following technical effects or advantages:

[0032] The Raft protocol ensures configuration consistency across distributed nodes, and the introduction of an agent decouples the direct interaction between the controller and network elements, improving system scalability. The synchronization between network elements and agents incorporates threshold judgment, which can automatically select full synchronization when there are many missing configurations and incremental synchronization when there are few missing configurations. Attached Figure Description

[0033] Figure 1 A flowchart illustrating the method for ensuring network element device configuration consistency provided in Embodiment 1 of this application;

[0034] Figure 2 A structural diagram of a device for ensuring the consistency of network element equipment configuration provided in Embodiment 1 of this application;

[0035] Figure 3 The flowchart of the method for ensuring network element device configuration consistency provided in Embodiment 1 of this application is shown below;

[0036] Figure 4 The flowchart illustrates the synchronization process between the network element and the agent, which is part of the method for ensuring consistent network element configurations provided in Embodiment 1 of this application. Detailed Implementation

[0037] This application provides a method and apparatus for ensuring the consistency of network element device configurations. It solves the problems of existing methods that rely on periodic reconciliation between controllers and VNE devices, where excessively high fetching frequency leads to excessive bandwidth consumption and excessively low fetching frequency leads to prolonged inconsistencies between VNE devices and controllers. By using the Raft protocol to ensure configuration consistency in distributed nodes, and introducing an agent to decouple the direct interaction between the controller and network elements, the system's scalability is improved. The synchronization between network elements and agents incorporates threshold judgment, which can automatically select full synchronization when there are many configuration omissions and incremental synchronization when there are few configuration omissions.

[0038] The technical solution in this application embodiment addresses the problems of existing traffic flow prediction methods ignoring spatial dependencies and convolutional neural networks failing to effectively capture the spatial correlation of traffic conditions. The overall approach is as follows:

[0039] The controller and network element are decoupled, changing from direct communication between the controller and network element to communication with the agent. The agent is a component based on the Raft protocol introduced in this patent. Strong consistency between agents is ensured through the Raft protocol. The network element and agent synchronize their configurations, thereby ensuring the eventual consistency of the overall configuration.

[0040] To better understand the above technical solutions, the following will provide a detailed explanation of the technical solutions in conjunction with the accompanying drawings and specific implementation methods.

[0041] Example 1

[0042] like Figure 1 The diagram shown is a flowchart of a method for ensuring the configuration consistency of network element devices according to an embodiment of this application. This method is applied in an apparatus for ensuring the configuration consistency of network element devices and includes the following steps:

[0043] S1. After receiving the configuration packet from the controller, the leader agent synchronizes and updates with the lower agent according to the Raft protocol.

[0044] S2, the leader agent and follower agent update the state database based on the transactions added to the transaction database and then send an acknowledgment signal to the controller;

[0045] S3, while the leader agent and follower lower agent update the status database based on the transactions added to the transaction database, the follower lower agent updates the configuration based on the configuration ID requested by the network element.

[0046] Furthermore, such as Figure 3 As shown, the synchronization update between the leader agent and the follower lower agent in S1 includes a first phase and a second phase. The first phase is to send a configuration package to the follower lower agent and only writes to the transaction database. The second phase is a confirmation phase, in which the state database is modified according to the transactions in the first phase.

[0047] Furthermore, the first stage specifically includes the following steps:

[0048] The first step is for the leader agent to receive the configuration package sent by the controller and assign an auto-incrementing ID to the configuration package.

[0049] The second step is to verify whether the configuration in the configuration package is valid. If it is valid, the configuration package is synchronized to loweragent. If it is invalid, an error is reported.

[0050] Furthermore, the second stage specifically includes the following steps:

[0051] Step 1: After the follow lower agent successfully verifies the data, the leader agent receives the confirmation signal sent by the follow lower agent.

[0052] The second step is that after the leader agent has collected more than half of the confirmation signals, it sends confirmation signals to the lower agents.

[0053] The third step involves the leader agent and follower lower agent writing the configuration into the transaction database.

[0054] Step 4: After updating the state database based on the transactions added to the transaction database, the leader agent and follower agent send an acknowledgment signal to the controller.

[0055] In this embodiment, the synchronization between the Leader agent and the Follower agent is divided into two stages. The first stage is sending, which only involves writing to the transaction database. The second stage is the confirmation stage, which modifies the state database based on the transactions from the first stage.

[0056] The Leader agent receives the configuration package sent by the controller and assigns an auto-incrementing ID to the received configuration package. Then, it verifies the configuration in the configuration package to determine whether the configuration is valid. If the configuration is invalid, the Leader agent will return an error message. If the verification result is valid, the Leader agent will synchronize the configuration package to the Follower agent, thus completing the first phase.

[0057] In the second phase, the follow lower agent will perform secondary verification. After successful verification, it will send a confirmation message to the leader agent. Once the leader agent has collected more than half of the confirmation messages, it will send a confirmation message to the follow lower agent to end the verification. After that, the follow lower agent and the leader agent will work together.

[0058] Furthermore, before sending the configuration package, the controller will first receive a configuration request for the resource, modify the relevant resource, and set the synchronization signal to error. After receiving the confirmation signal sent by the leader agent, the controller will set the synchronization signal to correct.

[0059] In this embodiment, the configuration received by the controller is an operation on a certain resource. It will update the configuration in its own database, but set the synchronization flag to false, and then send the configuration to the leader agent. The leader agent will then synchronize it to other follower agents according to the Raft protocol. After the synchronization is completed, the leader agent will send an ACK to the controller. The controller will then modify the database to set the flag of the configuration to true.

[0060] When the controller connects to the synchronization agent, if the agent is not the leader, then the agent will forward the request to the leader agent to complete the request.

[0061] Furthermore, the transaction library in S2 consists of configuration transactions received sequentially, and an auto-incrementing ID is generated for each configuration. The state library is a full library of all current configurations, which can be obtained from each transaction in the transaction library through state transitions.

[0062] Furthermore, such as Figure 4 As shown, the process of the lower agent updating the configuration based on the configuration ID requested by the network element in S3 specifically includes:

[0063] S31, the configuration ID for the lower agent to receive timed requests from network elements;

[0064] S32. Compare the received configuration ID with the lower agent's own configuration ID to determine if it is greater than the set threshold. If it is, start full synchronization; otherwise, start incremental update.

[0065] In this embodiment, during the synchronization process between the leader agent and the follower agent, the agent sends a notification to the network element when it completes the transaction status update, and the network element updates its own configuration in a timely manner.

[0066] On the other hand, when a network element restarts or a new network element goes online, the agent will first synchronize the latest configuration with the follow-up agent. At the same time, the network element itself will also update its own status based on the synchronized configuration. The network element agent will store a transaction ID. If this transaction ID is compared with the global transaction ID and exceeds a certain threshold, a full synchronization will be initiated. If only a few configurations are missing, an incremental update will be initiated.

[0067] like Figure 2The diagram shown is a structural diagram of a device for ensuring the configuration consistency of network element devices according to an embodiment of this application. The device for ensuring the configuration consistency of network element devices according to an embodiment of this application includes a synchronization update module, a confirmation module, and a network element configuration update module, wherein:

[0068] The synchronization update module is used to follow the lower agent to synchronize and update with the leader agent via the Raft protocol after the leader agent receives the configuration packet sent by the controller.

[0069] The confirmation module is used to follow the lower agent and the leader agent to update the status database based on the transactions added to the transaction database, and then the leader agent sends a confirmation signal to the controller.

[0070] The network element configuration update module is used to update the status database based on the transaction database added by the lower agent and the leader agent, while the lower agent updates the configuration based on the configuration ID requested by the network element.

[0071] The technical solutions described in the embodiments of this application have at least the following technical effects or advantages:

[0072] The Raft protocol ensures configuration consistency across distributed nodes, and the introduction of an agent decouples the direct interaction between the controller and network elements, improving system scalability. The synchronization between network elements and agents incorporates threshold judgment, which can automatically select full synchronization when there are many missing configurations and incremental synchronization when there are few missing configurations.

[0073] A computer-readable storage medium for storing a program that, when executed by a processor, implements a method for ensuring configuration consistency of network elements.

[0074] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0075] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0076] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0077] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0078] Although preferred embodiments of the invention have been described, those skilled in the art, upon learning the basic inventive concept, can make other changes and modifications to these embodiments. Therefore, the appended claims are intended to be interpreted as including both the preferred embodiments and all changes and modifications falling within the scope of the invention.

[0079] Obviously, those skilled in the art can make various modifications and variations to this invention without departing from its spirit and scope. Therefore, if these modifications and variations fall within the scope of the claims of this invention and their equivalents, this invention also intends to include these modifications and variations.

Claims

1. A method for ensuring the consistency of network element device configuration, characterized in that, Includes the following steps: S1. After receiving the configuration packet from the controller, the leader agent synchronizes and updates with the follower agent according to the Raft protocol. S2. After the leader agent and follower agent update the state database based on the transactions added to the transaction database, they send an acknowledgment signal to the controller. S3. While the leader agent and follower agent update the status database based on the transactions added to the transaction database, the follower agent updates the configuration based on the configuration ID requested by the network element. The process of updating the configuration of the follower agent in S3 based on the configuration ID requested by the network element specifically includes: S31, the configuration ID of the follower agent for receiving timed requests from network elements; S32. Compare the received configuration ID with the follower agent's own configuration ID to determine if it is greater than the set threshold. If it is, start full synchronization; otherwise, start incremental update.

2. The method for ensuring the consistency of network element device configuration as described in claim 1, characterized in that, The synchronization update between the leader agent and the follower agent in S1 includes a first phase and a second phase. The first phase is to send a configuration package to the follower agent and only writes to the transaction database. The second phase is a confirmation phase, in which the state database is modified according to the transactions in the first phase.

3. The method for ensuring the consistency of network element device configuration as described in claim 2, characterized in that, The first stage specifically includes the following steps: The first step is for the leader agent to receive the configuration package sent by the controller and assign an auto-incrementing ID to the configuration package. The second step is to verify whether the configuration in the configuration package is valid. If it is valid, the configuration package is synchronized to followeragent; if it is invalid, an error is reported.

4. The method for ensuring the consistency of network element device configuration as described in claim 2, characterized in that, The second stage specifically includes the following steps: Step 1: After the follower agent successfully verifies the identity, the leader agent receives the confirmation signal sent by the follower agent. The second step is that after the leader agent has collected more than half of the confirmation signals, it sends confirmation signals to the follower agents. The third step involves the leader agent and follower agent writing the configuration into the transaction database. Step 4: After updating the state database based on the transactions added to the transaction database, the leader agent and follower agent send an acknowledgment signal to the controller.

5. The method for ensuring the consistency of network element device configuration as described in claim 1, characterized in that, Before sending the configuration package, the controller will first receive a configuration request for the resource, modify the relevant resource, and set the synchronization signal to error. After receiving the confirmation signal sent by the leader agent, the controller will set the synchronization signal to correct.

6. The method for ensuring the consistency of network element device configuration as described in claim 1, characterized in that, The transaction library in S2 consists of configuration transactions received in sequence, and an auto-incrementing ID is generated for each configuration. The state library is a full library of all current configurations, which can be obtained from each transaction in the transaction library through state transitions.

7. The method for ensuring network element device configuration consistency as described in claim 1, characterized in that: When performing a full synchronization, the configuration is provided from the state database; When performing incremental updates, incremental synchronization is performed from the transaction database based on the transaction ID.

8. A device for ensuring the consistency of network element equipment configuration, characterized in that, It includes a synchronization update module, a confirmation module, and a network element configuration update module, among which: The synchronization update module is used by the follower agent to synchronize with the leader agent via the Raft protocol after the leader agent receives the configuration packet sent by the controller. The confirmation module is used by the follower agent and the leader agent to update the status database based on the transactions added to the transaction database, and then the leader agent sends a confirmation signal to the controller. The network element configuration update module is used to update the status database based on the transaction database added by the follower agent and the leader agent, while the follower agent updates the configuration based on the configuration ID requested by the network element. The process of updating the configuration of the follower agent in the network element configuration update module based on the configuration ID requested by the network element specifically includes: S31, the configuration ID of the follower agent for receiving timed requests from network elements; S32. Compare the received configuration ID with the follower agent's own configuration ID to determine if it is greater than the set threshold. If it is, start full synchronization; otherwise, start incremental update.

9. A computer-readable storage medium for storing a program, characterized in that, When the program is executed by the processor, it implements a method for ensuring the consistency of network element device configuration as described in any one of claims 1 to 7.

Citation Information

Patent Citations

  • Data synchronization method and device, electronic equipment and storage medium

    CN111949731A

  • Configuration data processing method, software-defined network equipment, system and storage medium

    CN112019360A