A configuration verification method and device, electronic equipment and storage medium

By comparing configuration differences using version numbers and operation codes in the cloud cluster, the problem of inconsistent edge server configurations was solved, enabling fast and accurate configuration verification and improving the efficiency and real-time performance of the cloud cluster.

CN119766653BActive Publication Date: 2025-11-11CHINA TELECOM CLOUD TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411776805.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-05
Publication Date
2025-11-11
Estimated Expiration
2044-12-05

AI Technical Summary

Technical Problem

In cloud clusters, edge servers may fail to receive configurations from the configuration center in a timely manner due to network latency or machine failures, resulting in inconsistent configurations and affecting service quality.

Method used

By transmitting baseline configuration items between central configuration nodes and edge nodes, and comparing differences in configuration items using version numbers and operation codes, rapid verification and updates are achieved, avoiding the reordering process and improving verification efficiency and real-time performance.

Benefits of technology

It enables fast and accurate configuration verification, saves system resources of edge nodes, avoids the impact on external service provision, and is particularly suitable for situations involving a large number of configurations and frequent changes.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119766653B_ABST
    Figure CN119766653B_ABST
Patent Text Reader

Abstract

The application provides a configuration verification method and device, electronic equipment and a storage medium. The application adds operation code and a version number to the newly added configuration in the central configuration node that needs to be verified, realizes the verification of the newly added configuration in the central configuration node that needs to be verified, does not need to sort multiple configurations each time, saves time, improves the verification efficiency, has high real-time performance, saves the system resources of the edge node, and avoids affecting the normal service provision of the edge node.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of cloud computing technology, and in particular to a configuration verification method, apparatus, electronic device, and storage medium. Background Technology

[0002] In practice, in cloud clusters, a configuration center typically distributes configurations to various edge servers. However, due to various reasons such as network latency or machine failure, the edge servers may not receive the configurations distributed by the configuration center. This results in inconsistencies between the configurations on the edge servers and those distributed by the configuration center (which the configuration center expects the edge servers to have), thus affecting the edge servers' ability to provide services. Therefore, it is necessary to verify the configurations on the edge servers against those distributed by the configuration center to ensure consistency. Summary of the Invention

[0003] This application discloses a configuration verification method, apparatus, electronic device, and storage medium.

[0004] In a first aspect, this application discloses a configuration verification method applied to edge nodes, the method comprising:

[0005] Receive the baseline configuration items sent by the central configuration node; the baseline configuration items include: baseline configuration, the operation code corresponding to the baseline configuration, and the version number of the baseline configuration. The baseline configuration is the configuration added in the central configuration node.

[0006] In the set of historical configuration items stored in the edge node, find the configuration item to be verified. The configuration item to be verified includes: the configuration to be verified, the operation code corresponding to the configuration to be verified, and the version number of the configuration to be verified. The version number in the configuration item to be verified is the same as the version number in the base configuration item.

[0007] Obtain the configuration items that differ between the baseline configuration items and the configuration items to be verified;

[0008] Execute the operation code in the differentiated configuration item for the configuration in the differentiated configuration item;

[0009] If no distinguishing configuration item exists in the historical configuration item set, the distinguishing configuration item is stored in the historical configuration item set.

[0010] Secondly, this application discloses a configuration verification method applied to a central configuration node, the method comprising:

[0011] Retrieve the baseline configuration item, which includes: the baseline configuration, the operation code corresponding to the baseline configuration, and the version number of the baseline configuration. The baseline configuration is the configuration added in the central configuration node.

[0012] Send a baseline configuration item to the edge node; enable the edge node to receive the baseline configuration item sent by the central configuration node; search for the configuration item to be verified in the historical configuration item set stored in the edge node. The configuration item to be verified includes: the configuration to be verified, the operation code corresponding to the configuration to be verified, and the version number of the configuration to be verified. The version number in the configuration item to be verified is the same as the version number in the baseline configuration item; obtain the difference configuration item between the baseline configuration item and the configuration item to be verified; execute the operation code in the difference configuration item for the configuration in the difference configuration item; if the difference configuration item does not exist in the historical configuration item set, store the difference configuration item in the historical configuration item set.

[0013] Thirdly, this application discloses a configuration verification device applied to an edge node, the device comprising:

[0014] The receiving module is used to receive the baseline configuration items sent by the central configuration node. The baseline configuration items include: baseline configuration, operation code corresponding to the baseline configuration, and version number of the baseline configuration. The baseline configuration is the configuration added in the central configuration node.

[0015] The lookup module is used to search for the configuration item to be verified in the set of historical configuration items stored in the edge node. The configuration item to be verified includes: the configuration to be verified, the operation code corresponding to the configuration to be verified, and the version number of the configuration to be verified; the version number in the configuration item to be verified is the same as the version number in the baseline configuration item.

[0016] The first acquisition module is used to acquire the difference configuration items between the baseline configuration items and the configuration items to be verified.

[0017] The execution module is used to execute the operation code in the differentiated configuration items.

[0018] The storage module is used to store the distinguishable configuration items in the historical configuration item set when there are no distinguishable configuration items in the historical configuration item set.

[0019] Fourthly, this application discloses a configuration verification device applied to a central configuration node, the device comprising:

[0020] The second acquisition module is used to acquire the baseline configuration item. The baseline configuration item includes: baseline configuration, operation code corresponding to the baseline configuration, and version number of the baseline configuration. The baseline configuration is the configuration added in the central configuration node.

[0021] The sending module is used to send baseline configuration items to edge nodes; enabling edge nodes to receive baseline configuration items sent by the central configuration node; searching for a configuration item to be verified in the historical configuration item set stored in the edge node; the configuration item to be verified includes: the configuration to be verified, the corresponding operation code, and the version number of the configuration to be verified, and the version number in the configuration item to be verified is the same as the version number in the baseline configuration item; obtaining the difference configuration item between the baseline configuration item and the configuration item to be verified; executing the operation code in the difference configuration item on the configuration in the difference configuration item; and storing the difference configuration item in the historical configuration item set if the difference configuration item does not exist in the historical configuration item set.

[0022] Fifthly, this application discloses an electronic device comprising: a processor; and a memory for storing processor-executable instructions; wherein the processor is configured to perform the method as described in any of the preceding aspects.

[0023] Sixthly, this application discloses a non-transitory computer-readable storage medium that, when the instructions in the storage medium are executed by a processor of an electronic device, enables the electronic device to perform the methods described in any of the preceding aspects.

[0024] In a seventh aspect, this application discloses a computer program product in which, when the instructions in the computer program product are executed by a processor of an electronic device, the electronic device is enabled to perform the method described in any of the preceding aspects.

[0025] The technical solution provided in this application may include the following beneficial effects:

[0026] This application enables the verification of newly added configurations that require verification in the central configuration node by adding operation codes and version numbers. Each verification does not require sorting multiple configurations, saving time, improving verification efficiency, and providing high real-time performance. It also saves system resources of edge nodes and avoids affecting the normal external service provided by edge nodes. Attached Figure Description

[0027] Figure 1 This is a flowchart of the steps of a configuration verification method according to this application.

[0028] Figure 2 This is a structural block diagram of a configuration verification device according to this application.

[0029] Figure 3 This is a structural block diagram of a configuration verification device according to this application.

[0030] Figure 4 This is a block diagram of an electronic device according to this application.

[0031] Figure 5This is a block diagram of an electronic device according to this application. Detailed Implementation

[0032] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0033] The general configuration verification method is to determine whether the MD5 (Message-Digest Algorithm) value of the edge server's configuration file is consistent with the MD5 value of the configuration issued by the configuration center. If they are inconsistent, it means that the configuration of the edge server is inconsistent with the configuration issued by the configuration center (the configuration that the configuration center expects the edge server to have). In this case, the configuration center will reissue the configuration to the edge server.

[0034] However, a configuration sent from the configuration center to the edge server in one transaction may contain multiple configurations. These configurations have a default order, and the overall MD5 value of the multiple configurations sent by the configuration center is related to the default order. However, due to network latency, machine failure, or other reasons, the order of the individual configurations received by the edge server may differ from the default order. Therefore, the overall MD5 value of the multiple configurations calculated by the edge server is related to the receiving order of the individual configurations.

[0035] This results in the edge server actually loading multiple configurations issued by the configuration center and completing the correct configuration. In other words, it means that the configuration of the edge server is consistent with the configuration issued by the configuration center (the configuration that the configuration center expects the edge server to have). However, the overall MD5 value of the multiple configurations issued by the configuration center is different from the overall MD5 value of the multiple configurations calculated by the edge server. This will mistakenly lead to the conclusion that the edge server has not loaded the multiple configurations issued by the configuration center. That is, it will mistakenly believe that the configuration of the edge server is inconsistent with the configuration issued by the configuration center (the configuration that the configuration center expects the edge server to have), resulting in an incorrect verification result.

[0036] To address this, the edge server can reorder the various configurations received into a default order and calculate the overall MD5 value of the sorted configurations. This ensures that the overall MD5 value of the configurations sent from the configuration center is the same as the overall MD5 value calculated by the edge server, preventing any verification errors.

[0037] However, the process of reordering the various configurations among the received configurations to the default order by the edge server often takes a long time, resulting in low verification efficiency and low real-time performance.

[0038] Especially for a large number of different configurations of the same type (all of which are IP addresses or URLs), such as multiple blacklisted IP addresses, multiple whitelisted IP addresses, and multiple URLs to be unblocked (Uniform Resource Locator), the problem of long sorting time and low verification efficiency is very significant.

[0039] Therefore, the proposed solution in this application is put forward.

[0040] Before introducing the solution of this application, the technical terms that may be involved in this application will be explained.

[0041] Incremental update: Based on the full data at a certain point in time, the updated data is then distributed to the machines that need to be updated, that is, only the difference data is updated.

[0042] This application provides a configuration verification system, which includes a central configuration node and edge nodes.

[0043] The central configuration node and edge nodes can be located in the same cloud cluster.

[0044] The central configuration node can be a physical machine in the cloud cluster, or a virtual machine set up on a physical machine in the cloud cluster.

[0045] Edge nodes can be physical machines in a cloud cluster, or virtual machines hosted on physical machines in a cloud cluster.

[0046] There can be multiple edge nodes in a cloud cluster, and the central configuration node communicates and connects with each edge node.

[0047] Reference Figure 1 The diagram illustrates a flowchart of a configuration verification method according to this application, wherein the method includes:

[0048] In step S101, the central configuration node obtains the baseline configuration item, which includes: the baseline configuration, the corresponding operation code, and the version number of the baseline configuration. The baseline configuration is a configuration newly added to the central configuration node.

[0049] For example, if the central configuration node has already distributed configurations 1, 2, and 3 to the edge nodes, and subsequently, the central configuration node receives additional configurations 4 and 5 from the operations and maintenance personnel that need to be distributed to the edge nodes, then the base configurations will be configurations 4 and 5.

[0050] Thus, the baseline configuration items obtained by the central configuration node are baseline configuration item 4 and baseline configuration item 5.

[0051] The baseline configuration item 4 includes: baseline configuration 4, the operation code corresponding to baseline configuration 4, and the version number of baseline configuration 4.

[0052] The baseline configuration item 5 includes: baseline configuration 5, the operation code corresponding to baseline configuration 5, and the version number of baseline configuration 5.

[0053] Each operation code corresponds to an operation method. Executing the operation code corresponding to a configuration will perform the operation specified by that operation code on that configuration. Operation methods include adding, deleting, delaying, and advancing, among others.

[0054] The version number is used to indicate the updated version of the configuration item, and the version number can be an incrementing sequence.

[0055] In one example, the base configuration item includes "IP address|Operation code|Version number". The operation code uses "0" or "1", where "0" represents a delete operation (performing a delete operation on the IP address in the configuration item, for example, deleting the IP address from the IP address list), and "1" represents an add operation (performing an add operation on the IP address in the configuration item, for example, adding the IP address to the IP address list). The version number uses an incrementing sequence, "1", "2", "3" successively.

[0056] Typically, edge nodes store configuration items issued by the central configuration node, for example, by storing them in a collection of historical configuration items already stored in the edge node.

[0057] When the edge server needs to use the configuration, it can load the historical configuration items in the order they are stored in the historical configuration item collection from earliest to latest.

[0058] In step S102, the central configuration node sends the baseline configuration items to the edge nodes.

[0059] There can be one or more baseline configuration items.

[0060] If multiple baseline configuration items are issued in each batch, then the multiple baseline configuration items need to be a complete version of the configuration item. That is, configuration items with the same version number can be issued to edge nodes for verification in the same batch.

[0061] The central configuration server can record the version number of each configuration item sent. Multiple configuration items corresponding to the same version number will only be sent to the edge nodes once.

[0062] In step S103, the edge node receives the baseline configuration items sent by the central configuration node.

[0063] In step S104, the edge node searches for the configuration item to be verified in the set of historical configuration items stored in the edge node. The configuration item to be verified includes: the configuration to be verified, the operation code corresponding to the configuration to be verified, and the version number of the configuration to be verified. The version number in the configuration item to be verified is the same as the version number in the baseline configuration item.

[0064] The collection of historical configuration items stored in the edge node is used to store the historical configuration items stored by the edge node during the historical process. Each historical configuration item includes: the historical configuration, the corresponding operation code, and the version number of the historical configuration.

[0065] The configuration item to be verified can be one or more.

[0066] For example, the version number in the baseline configuration item can be obtained, and then all historical configuration items with that version number can be found in the set of historical configuration items stored in the edge node, and all of them can be used as configuration items to be verified.

[0067] In step S105, the edge node obtains the difference configuration item between the baseline configuration item and the configuration item to be verified.

[0068] The configuration and version number in the configuration item are used as keywords, and the operation code is used as the keyword value. The keywords and keyword values ​​in the benchmark configuration item and the configuration item to be verified are compared.

[0069] The system retrieves configuration items with the same keyword but different keyword values, as well as configuration items whose keyword exists only in the base configuration item and configuration items whose keyword exists only in the configuration item to be verified.

[0070] For baseline configuration items and configuration items to be verified, if the keywords are the same but the keyword values ​​are different, the baseline configuration items can be regarded as differential configuration items.

[0071] Configuration items whose keywords do not exist in the baseline configuration items but exist in the configuration items to be verified can be considered as redundant configuration items.

[0072] A baseline configuration item whose keyword exists in the baseline configuration item but not in the configuration item to be verified can be considered a missing configuration item.

[0073] Differential configuration items, redundant configuration items, and missing configuration items can be regarded as the distinguishing configuration items between the baseline configuration items and the configuration items to be verified.

[0074] To facilitate comparison with the baseline configuration items provided by the central configuration node, this embodiment uses a multi-level hash table to store the configuration items to be verified.

[0075] For example, the first level of the hash table uses the version number as the key, and the value is still a hash table. The second level hash table uses the configuration as the key, and the value is the operation code.

[0076] Thus, the hash table of the configuration items to be verified is traversed, and the version number and configuration are used as indexes to query the hash table of the base configuration item.

[0077] If the configuration item is not found in the hash table of the baseline configuration item, then the configuration item to be verified is a redundant configuration item.

[0078] If the operation code found in the hash table of the baseline configuration item is different from the operation code in the configuration to be verified, then the baseline configuration item compared with the configuration item to be verified is the difference configuration item. This comparison continues until all contents of the hash table of the configuration items to be verified have been traversed.

[0079] Traverse the hash table of the baseline configuration items again. If there is a baseline configuration item that has not been visited when traversing the hash table of the configuration items to be verified, then the baseline configuration item is a missing configuration item.

[0080] After two iterations, we obtain the differential configuration items, redundant configuration items, and missing configuration items.

[0081] In this way, consistency verification of the baseline configuration items provided by the edge nodes and the central configuration nodes can be achieved. Inconsistent configuration items are output and serve as the basis for subsequent corrections.

[0082] In step S106, the edge node executes the operation code in the differential configuration item for the configuration in the differential configuration item.

[0083] This allows you to operate on the configurations in the differentiated configuration items according to the operation methods corresponding to the operation codes in the differentiated configuration items.

[0084] In step S107, if there is no distinguishing configuration item in the historical configuration item set, the edge node stores the distinguishing configuration item in the historical configuration item set.

[0085] Alternatively, if the edge node has distinct configuration items in the historical configuration item set, then the distinct configuration items do not need to be stored repeatedly in the historical configuration item set.

[0086] This application enables the verification of newly added configurations that require verification in the central configuration node by adding operation codes and version numbers. Each verification does not require sorting multiple configurations, saving time, improving verification efficiency, and providing high real-time performance. It also saves system resources of edge nodes and avoids affecting the normal external service provided by edge nodes.

[0087] This application is particularly applicable when the central configuration node needs to distribute a large number of configurations to the edge nodes, and when the operation code corresponding to the same configuration in a large number of configurations is frequently changed, which can save verification time and improve verification efficiency.

[0088] In one embodiment of this application, there are multiple baseline configuration items. Any two baseline configuration items are different, which means that at least one of the following three elements—configuration, operation code, and version number—is different in any two baseline configuration items.

[0089] The version numbers in multiple baseline configuration items are not unique. For example, after removing duplicate version numbers from multiple baseline configuration items, there are at least two different version numbers. Additionally, there can be multiple distinguishing configuration items.

[0090] Thus, in step S106, when executing the operation code in the distinguished configuration item, it is possible to detect whether there are at least two distinguished configuration items that contain the same configuration but different version numbers among multiple distinguished configuration items.

[0091] If there are at least two different configuration items that include the same configuration but different version numbers among multiple different configuration items, find the one with the latest version number among the at least two different configuration items that include the same configuration but different version numbers.

[0092] In this application, the configuration version number can be progressively increased, for example, version 1.0, version 2.0, version 3.0, and version 4.0, etc., increasing sequentially. The latest version number can be understood as the largest version number. For example, at least two distinguishing configuration items have distinguishing configuration item 1 and distinguishing configuration item 2. The configuration in distinguishing configuration item 1 is the same as the configuration in distinguishing configuration item 2. The version number in distinguishing configuration item 1 is version 1.0, and the version number in distinguishing configuration item 2 is version 2.0. Since version 2.0 is greater than version 1.0 and version 2.0 is newer than version 1.0, the distinguishing configuration item with the latest version number included is distinguishing configuration item 2.

[0093] Then, execute the operation code in the found differential configuration items for the configurations in the differential configuration items.

[0094] In this embodiment, among at least two distinguishing configuration items with the same configuration but different version numbers, the time when the operations and maintenance personnel set the distinguishing configuration item with the latest version number is often later than the time when the operations and maintenance personnel set the distinguishing configuration item with a non-latest version number. The distinguishing configuration item with the latest version number is often set by the operations and maintenance personnel according to the actual needs at present. Thus, the validity, priority, or practicality of the distinguishing configuration item with the latest version number is greater than that of the distinguishing configuration item with a non-latest version number. Therefore, among at least two distinguishing configuration items with the same configuration but different version numbers, since the configuration is the same, the edge node needs to be verified based on the distinguishing configuration item with the latest version number, which can improve the accuracy of the verification configuration.

[0095] In other words, even if the operation code in the configuration of the included non-latest version number difference configuration item is executed, since the operation code in the included latest version number difference configuration item also needs to be executed later, the edge node will ultimately take the latest version number difference configuration item as the standard. Thus, the previous operation of "executing the operation code in the included non-latest version number difference configuration item" is essentially an invalid operation, wasting the system resources of the edge node.

[0096] This embodiment does not perform the invalid operation of "executing the operation code in the differential configuration item whose version number is not the latest" for the configuration in the differential configuration item whose version number is not the latest, thereby saving system resources of the edge node.

[0097] Accordingly, in step S107, if there is no distinguishing configuration item in the historical configuration item set, the distinguishing configuration item is stored in the historical configuration item set; if there is no found distinguishing configuration item in the historical configuration item set, the found distinguishing configuration item is stored in the historical configuration item set.

[0098] In this embodiment, the latest version of the distinguishing configuration items included in the historical configuration item set is stored, while the non-latest version of the distinguishing configuration items (invalid configuration items) are not stored in the historical configuration item set. This can save storage space on edge nodes.

[0099] In one embodiment of this application, there are multiple baseline configuration items. Any two baseline configuration items are different, which means that at least one of the following three elements—configuration, operation code, and version number—is different in any two baseline configuration items.

[0100] The version numbers in multiple baseline configuration items are not unique. For example, after removing duplicate version numbers from multiple baseline configuration items, there are at least two different version numbers. Additionally, there can be multiple distinguishing configuration items.

[0101] Thus, in step S106, when executing the operation code in the distinguished configuration item, it is possible to detect whether there are at least two distinguished configuration items that contain the same configuration and the same version number among multiple distinguished configuration items.

[0102] In this application, the configuration version number can be progressively increasing, such as version 1.0, version 2.0, version 3.0, and version 4.0, etc., increasing sequentially. For example, at least two distinguishing configuration items include distinguishing configuration item 1 and distinguishing configuration item 2. The configuration in distinguishing configuration item 1 is the same as the configuration in distinguishing configuration item 2, and the version number in distinguishing configuration item 1 is the same as the version number in distinguishing configuration item 2. The version number in distinguishing configuration item 1 is version 2.0, and the version number in distinguishing configuration item 2 is version 2.0. Version 2.0 equals version 2.0. Therefore, the at least two distinguishing configuration items that have the same configuration and the same version number are distinguishing configuration item 1 and distinguishing configuration item 2.

[0103] Then, if there are at least two different configuration items with the same configuration and version number among the multiple different configuration items, find at least two candidate configuration items located in the multiple baseline configuration items among the at least two different configuration items with the same configuration and version number.

[0104] Among at least two distinguishing configuration items that have the same configuration and version number, some distinguishing configuration items are located in multiple base configuration items, that is, some distinguishing configuration items are the same as some base configuration items in multiple base configuration items, and other distinguishing configuration items are not located in multiple base configuration items, that is, other distinguishing configuration items are different from all base configuration items in multiple base configuration items.

[0105] Among at least two distinguishing configuration items that have the same configuration and version number, we need to find the distinguishing configuration item located in multiple baseline configuration items and select it as a candidate configuration item.

[0106] If at least two candidate configuration items are found, the ranking order of each candidate configuration item among multiple baseline configuration items is obtained.

[0107] Among them, there is a positional sorting order among multiple baseline configuration items, which can be specified by the operation and maintenance personnel in the central configuration node according to actual needs.

[0108] For example, before the central configuration node sends multiple baseline configuration items to the edge nodes, for any one of the baseline configuration items, the operations and maintenance personnel can add a sequence field to that baseline configuration item, recording its position and order among the multiple baseline configuration items (the position and order can be represented by numbers; for example, the number "1" represents the first position, the number "2" represents the second position, the number "3" represents the third position, and so on, with larger numbers corresponding to a later position and smaller numbers corresponding to a earlier position). The same process is applied to each of the other baseline configuration items. Then, the central configuration node sends the multiple baseline configuration items to the edge nodes.

[0109] Thus, when obtaining the position and sorting order of each candidate configuration item among multiple benchmark configuration items, the order field of each candidate configuration item can be obtained to record its respective position and sorting order among multiple benchmark configuration items.

[0110] Then, among at least two candidate configuration items, select the candidate configuration item that is last in the sorting order among the multiple baseline configuration items.

[0111] As mentioned earlier, the order field in each of the multiple baseline configuration items records its position and sorting order in the multiple baseline configuration items through numbers. The candidate configuration item with the largest number in the included order field can be selected as the last candidate configuration item in the position and sorting order among the multiple baseline configuration items.

[0112] Then, the operation code in the selected candidate configuration item is executed on the selected candidate configuration item.

[0113] In this embodiment, among at least two distinguishing configuration items with the same configuration and version number, the time when the operations and maintenance personnel set the candidate configuration item that is last in the sorting order among the multiple baseline configuration items is often later than the time when the operations and maintenance personnel set the candidate configuration item that is not last in the sorting order among the multiple baseline configuration items. The candidate configuration item that is last in the sorting order among the multiple baseline configuration items is often set by the operations and maintenance personnel according to the actual needs at present. Thus, the validity, priority, or practicality of the candidate configuration item that is last in the sorting order among the multiple baseline configuration items is greater than the validity, priority, or practicality of the candidate configuration item that is not last in the sorting order among the multiple baseline configuration items. Therefore, among at least two distinguishing configuration items with the same configuration and version number, since the configuration and version number are the same, the edge node needs to be verified based on the candidate configuration item that is last in the sorting order among the multiple baseline configuration items, which can improve the accuracy of the verification configuration.

[0114] In other words, even if the operation code in the candidate configuration item that is not the last in the sorting order of the multiple baseline configuration items is executed, since the operation code in the candidate configuration item that is the last in the sorting order of the multiple baseline configuration items needs to be executed later, the edge node will ultimately be based on the candidate configuration item that is the last in the sorting order of the multiple baseline configuration items. Thus, the previous operation of "executing the operation code in the candidate configuration item that is not the last in the sorting order of the multiple baseline configuration items" is essentially an invalid operation, which wastes the system resources of the edge node.

[0115] This embodiment does not perform the invalid operation of "executing the operation code in the candidate configuration item whose position sorting order is not the last in the multiple benchmark configuration items", thereby saving system resources of the edge node.

[0116] Accordingly, in step S107, when there is no distinguishing configuration item in the historical configuration item set, the distinguishing configuration item is stored in the historical configuration item set; when there is no selected candidate configuration item in the historical configuration item set, the selected candidate configuration item is stored in the historical configuration item set.

[0117] In this embodiment, candidate configuration items that are last in the position sorting order among multiple baseline configuration items are stored in the historical configuration item set, while candidate configuration items that are not last in the position sorting order among multiple baseline configuration items (invalid configuration items) are not stored in the historical configuration item set. In this way, storage space of edge nodes can be saved.

[0118] In one embodiment of this application, regardless of whether there is one or more baseline configuration items, when obtaining the difference configuration item between the baseline configuration item and the configuration item to be verified in step S105, for any baseline configuration item, if the version number in the baseline configuration item is the same as the version number in one of the configuration items to be verified (there may be one or more configuration items to be verified), the configuration in the baseline configuration item is the same as the configuration in one of the configuration items to be verified, and the operation code in the baseline configuration item is different from the operation code in one of the configuration items to be verified, then the baseline configuration item is determined as a difference configuration item. The baseline configuration item can be regarded as a difference configuration item. Subsequently, the configuration in the edge node needs to be verified based on the baseline configuration item, instead of verifying the configuration in the edge node based on one of the configuration items to be verified.

[0119] For example, when executing the operation code in the difference configuration item for the configuration in the difference configuration item in step S106, the operation code in the base configuration item can be executed for the configuration in the base configuration item.

[0120] Furthermore, in step S107, when storing a distinguishing configuration item in the historical configuration item set if no distinguishing configuration item exists in the historical configuration item set, the base configuration item can be stored in the historical configuration item set if no base configuration item exists in the historical configuration item set.

[0121] Secondly, if one of the configuration items to be verified exists in the historical configuration item set, it can be deleted from the historical configuration item set to save storage space.

[0122] In one embodiment of this application, regardless of whether there is one or more baseline configuration items, when obtaining the difference configuration items between the baseline configuration items and the configuration items to be verified in step S105, if for any configuration item to be verified, if each baseline configuration item does not simultaneously have the configuration and version number of the configuration item to be verified (the configuration item to be verified may be one or more), then the configuration item to be verified can be regarded as a redundant configuration item. Then, in the preset operation code pair, another operation code that is different from the operation code in the configuration item to be verified can be selected.

[0123] The preset operation code pair has two operation codes, and the two operation codes correspond to different operation methods.

[0124] For example, the two operation codes correspond to opposite operation methods.

[0125] For example, if an operation code corresponds to the operation method of "add", after the edge node executes the operation code on a configuration, the configuration will be added to the edge node. For example, assuming the configuration is a blacklisted IP address, after the edge node executes the operation code on the blacklisted IP address, the blacklisted IP address will be added to the blacklist in the edge node.

[0126] For example, another operation code corresponds to the operation method of deletion. After the edge node executes another operation code on a configuration, it will delete the configuration in the edge node. For example, assuming the configuration is a blacklisted IP address, after the edge node executes another operation code on the blacklisted IP address, it will delete the blacklisted IP address in the blacklist of the edge node.

[0127] Then, another operation code can be used to replace the operation code in the configuration item to be verified, resulting in a new configuration item, which is then identified as the distinguishable configuration item. Subsequent verification of the edge node configuration should be based on this new configuration item, rather than on the original configuration item.

[0128] For example, if the operation code in the configuration item to be verified corresponds to the operation method of "add", then the operation code in the new configuration item corresponds to the operation method of "delete".

[0129] For example, if the operation code in the configuration item to be verified corresponds to the operation method of deletion, then the operation code in the new configuration item corresponds to the operation method of addition.

[0130] In this application, the central configuration node does not perform useless updates, such as updating deletion operations directly when there is no addition operation. Thus, another operation code can be used to replace the operation code in the configuration item to be verified.

[0131] Alternatively, in another embodiment, the validity of the redundant configuration item that was deleted can be verified, i.e., it can be verified whether the same configuration has been added before. If so, the redundant configuration item can be reloaded.

[0132] For example, when executing the operation code in the different configuration item for the configuration in the different configuration item in step S106, the operation code in the new configuration item can be executed for the configuration in the new configuration item.

[0133] Furthermore, in step S107, when storing a distinguishing configuration item in the historical configuration item set if no distinguishing configuration item exists in the historical configuration item set, and when storing a new configuration item in the historical configuration item set if no new configuration item exists in the historical configuration item set, a new configuration item is stored in the historical configuration item set.

[0134] Secondly, if the configuration item to be verified exists in the historical configuration item set, it can be deleted from the historical configuration item set to save storage space.

[0135] In one embodiment of this application, regardless of whether there is one or more baseline configuration items, when obtaining the distinguishing configuration items between the baseline configuration items and the configuration items to be verified in step S105, if for any baseline configuration item, each configuration item to be verified (which may be one or more) does not simultaneously possess both the configuration and version number of the baseline configuration item, then the baseline configuration item is determined as a distinguishing configuration item. This baseline configuration item can be regarded as a missing configuration item, and the configuration in the edge nodes needs to be verified based on this baseline configuration item in the future.

[0136] For example, when executing the operation code in the difference configuration item for the configuration in the difference configuration item in step S106, the operation code in the base configuration item can be executed for the configuration in the base configuration item.

[0137] Furthermore, in step S107, when storing a distinguishing configuration item in the historical configuration item set if no distinguishing configuration item exists in the historical configuration item set, the base configuration item can be stored in the historical configuration item set if no base configuration item exists in the historical configuration item set.

[0138] In another embodiment of this application, in the set of historical configuration items, it is detected whether there are at least two historical configuration items that have the same configuration but different version numbers. This can be done periodically, and the periodicity can be determined according to the actual situation. This application does not limit this.

[0139] If there are at least two historical configuration items in the historical configuration item set, find duplicate configuration items among the at least two historical configuration items. Duplicate configuration items are configuration items among the at least two historical configuration items other than the historical configuration item with the latest version number included in them.

[0140] In the historical configuration item set, duplicate configuration items are deleted, so that the configurations of any two configuration items in the historical configuration item set are different.

[0141] Since at least two historical configuration items contain the latest version number, configuration items other than the latest version number of the included historical configuration items will no longer be effective. Thus, deleting duplicate configuration items from the historical configuration item set can save storage space on edge nodes.

[0142] After a subsequent restart, the edge node does not need to reload configuration items from at least two historical configuration items, except for the one with the latest version number, thus saving storage resources on the edge node.

[0143] Furthermore, in another embodiment of this application, if the operation code in the historical configuration item with the latest version number, which is one of the at least two historical configuration items, corresponds to a deletion operation, then the historical configuration item with the latest version number, which is one of the at least two historical configuration items, is often an invalid configuration item. Even if the invalid configuration item is loaded after the edge node is restarted, the configuration in the invalid configuration item will not actually perform a valid operation, but it will waste the system resources of the edge node and waste time.

[0144] Furthermore, in the historical configuration item set, at least two historical configuration items, including the one with the latest version number, can be deleted. This can save time, save system resources of edge nodes, and further save storage space of edge nodes.

[0145] It should be noted that, for the sake of simplicity, the method embodiments are all described as a series of actions. However, those skilled in the art should understand that this application is not limited to the described order of actions, because according to this application, some steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also understand that the embodiments described in the specification are all optional embodiments, and the actions involved are not necessarily required by this application.

[0146] Reference Figure 2 This application illustrates a configuration verification device for use at an edge node, the device comprising:

[0147] The receiving module 11 is used to receive the baseline configuration items sent by the central configuration node. The baseline configuration items include: baseline configuration, operation code corresponding to the baseline configuration, and version number of the baseline configuration. The baseline configuration is the configuration added in the central configuration node.

[0148] The lookup module 12 is used to search for the configuration item to be verified in the set of historical configuration items stored in the edge node. The configuration item to be verified includes: the configuration to be verified, the operation code corresponding to the configuration to be verified, and the version number of the configuration to be verified; the version number in the configuration item to be verified is the same as the version number in the baseline configuration item.

[0149] The first acquisition module 13 is used to acquire the difference configuration items between the baseline configuration items and the configuration items to be verified.

[0150] Execution module 14 is used to execute the operation code in the differential configuration item on the configuration in the differential configuration item;

[0151] Storage module 15 is used to store the distinguishable configuration item in the historical configuration item set when there is no distinguishable configuration item in the historical configuration item set.

[0152] Among them, there are multiple baseline configuration items, and the version numbers of these multiple baseline configuration items are not unique; there are also multiple distinguishing configuration items.

[0153] The execution module includes:

[0154] The detection unit is used to detect, among multiple distinguishing configuration items, whether there are at least two distinguishing configuration items that have the same configuration but different version numbers;

[0155] The lookup unit is used to find the differential configuration item with the latest version number among at least two differential configuration items that have the same configuration but different version numbers, when there are at least two differential configuration items that have the same configuration but different version numbers among multiple differential configuration items.

[0156] The first execution unit is used to execute the operation code in the found distinguished configuration items.

[0157] Accordingly, the storage module includes:

[0158] The first storage unit is used to store the found distinguishing configuration item in the historical configuration item set when the distinguishing configuration item is not found in the historical configuration item set.

[0159] The first acquisition module includes:

[0160] The first determining unit is configured to determine the benchmark configuration item as a distinguishing configuration item if, for any benchmark configuration item, the version number in the benchmark configuration item is the same as the version number in one of the configuration items to be verified, the configuration in the benchmark configuration item is the same as the configuration in one of the configuration items to be verified, and the operation code in the benchmark configuration item is different from the operation code in one of the configuration items to be verified.

[0161] Accordingly, the execution module includes:

[0162] The second execution unit is used to execute the operation code in the baseline configuration item on the configuration in the baseline configuration item;

[0163] Accordingly, the storage module includes:

[0164] The second storage unit is used to store the baseline configuration item in the historical configuration item set when the baseline configuration item does not exist in the historical configuration item set.

[0165] The first acquisition module includes:

[0166] The filtering unit is used to filter out another operation code that is different from the operation code in the configuration item to be verified if each baseline configuration item does not simultaneously have the configuration and version number in the configuration item to be verified. The preset operation code pair has two operation codes, and the two operation codes correspond to different operation methods.

[0167] The replacement unit is used to replace the operation code in the configuration item to be verified with the other operation code to obtain a new configuration item, and to identify the new configuration item as the distinguishable configuration item.

[0168] Accordingly, the execution module includes:

[0169] The third execution unit is used to execute the operation code in the new configuration item on the configuration in the new configuration item;

[0170] Accordingly, the storage module includes:

[0171] The third storage unit is used to store the new configuration item in the historical configuration item set when the new configuration item does not exist in the historical configuration item set.

[0172] The first acquisition module includes:

[0173] The second determining unit is used to determine the benchmark configuration item as a distinguishing configuration item if, for any benchmark configuration item, each configuration item to be verified does not simultaneously have the configuration and version number in the benchmark configuration item.

[0174] Accordingly, the execution module includes:

[0175] The fourth execution unit is used to execute the operation code in the benchmark configuration item on the configuration in the benchmark configuration item;

[0176] Accordingly, the storage module includes:

[0177] The fourth storage unit is used to store the baseline configuration item in the historical configuration item set when the baseline configuration item does not exist in the historical configuration item set.

[0178] This application enables the verification of newly added configurations that require verification in the central configuration node by adding operation codes and version numbers. Each verification does not require sorting multiple configurations, saving time, improving verification efficiency, and providing high real-time performance. It also saves system resources of edge nodes and avoids affecting the normal external service provided by edge nodes.

[0179] Reference Figure 3 This application illustrates a configuration verification device for a central configuration node, the device comprising:

[0180] The second acquisition module 21 is used to acquire the baseline configuration item, which includes: baseline configuration, operation code corresponding to the baseline configuration, and version number of the baseline configuration. The baseline configuration is the configuration added in the central configuration node.

[0181] The sending module 22 is used to send baseline configuration items to edge nodes; enabling edge nodes to receive baseline configuration items sent by the central configuration node; searching for a configuration item to be verified in the historical configuration item set stored in the edge node; the configuration item to be verified includes: the configuration to be verified, the operation code corresponding to the configuration to be verified, and the version number of the configuration to be verified, the version number in the configuration item to be verified is the same as the version number in the baseline configuration item; obtaining the difference configuration item between the baseline configuration item and the configuration item to be verified; executing the operation code in the difference configuration item on the configuration in the difference configuration item; and storing the difference configuration item in the historical configuration item set if the difference configuration item does not exist in the historical configuration item set.

[0182] This application enables the verification of newly added configurations that require verification in the central configuration node by adding operation codes and version numbers. Each verification does not require sorting multiple configurations, saving time, improving verification efficiency, and providing high real-time performance. It also saves system resources of edge nodes and avoids affecting the normal external service provided by edge nodes.

[0183] Optionally, this application also provides an electronic device, including: a processor, a memory, and a computer program stored in the memory and executable on the processor. When the computer program is executed by the processor, it implements the various processes of the above method embodiments and achieves the same technical effect. To avoid repetition, it will not be described again here.

[0184] This application also provides a computer-readable storage medium storing a computer program. When the computer program is executed by a processor, it implements the various processes of the above-described method embodiments and achieves the same technical effects. To avoid repetition, it will not be described again here. The computer-readable storage medium may be a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.

[0185] Figure 4 This is a block diagram illustrating an electronic device 800. For example, the electronic device 800 may be a mobile phone, computer, digital broadcasting terminal, messaging device, game console, tablet device, medical device, fitness equipment, personal digital assistant, etc.

[0186] Reference Figure 4 The electronic device 800 may include one or more of the following components: a processing component 802, a memory 804, a power supply component 806, a multimedia component 808, an audio component 810, an input / output (I / O) interface 812, a sensor component 814, and a communication component 816.

[0187] Processing component 802 typically controls the overall operation of electronic device 800, such as operations associated with display, telephone calls, data communication, camera operation, and recording operations. Processing component 802 may include one or more processors 820 to execute instructions to complete all or part of the steps of the methods described above. Furthermore, processing component 802 may include one or more modules to facilitate interaction between processing component 802 and other components. For example, processing component 802 may include a multimedia module to facilitate interaction between multimedia component 808 and processing component 802.

[0188] Memory 804 is configured to store various types of data to support the operation of device 800. Examples of this data include instructions for any application or method operating on electronic device 800, contact data, phonebook data, messages, images, videos, etc. Memory 804 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.

[0189] Power supply component 806 provides power to various components of electronic device 800. Power supply component 806 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to electronic device 800.

[0190] Multimedia component 808 includes a screen that provides an output interface between the electronic device 800 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touchscreen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensors may not only sense the boundaries of touch or swipe actions but also monitor the duration and pressure associated with the touch or swipe operation. In some embodiments, multimedia component 808 includes a front-facing camera and / or a rear-facing camera. When the device 800 is in an operating mode, such as a shooting mode or a video mode, the front-facing camera and / or the rear-facing camera may receive external multimedia data. Each front-facing camera and rear-facing camera may be a fixed optical lens system or have focal length and optical zoom capabilities.

[0191] Audio component 810 is configured to output and / or input audio signals. For example, audio component 810 includes a microphone (MIC) configured to receive external audio signals when electronic device 800 is in an operating mode, such as call mode, recording mode, and voice recognition mode. The received audio signals may be further stored in memory 804 or transmitted via communication component 816. In some embodiments, audio component 810 also includes a speaker for outputting audio signals.

[0192] I / O interface 812 provides an interface between processing component 802 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to, home buttons, volume buttons, power buttons, and lock buttons.

[0193] Sensor assembly 814 includes one or more sensors for providing status assessments of various aspects of electronic device 800. For example, sensor assembly 814 may monitor the on / off state of device 800, the relative positioning of components such as the display and keypad of electronic device 800, changes in position of electronic device 800 or a component of electronic device 800, the presence or absence of user contact with electronic device 800, the orientation or acceleration / deceleration of electronic device 800, and temperature changes of electronic device 800. Sensor assembly 814 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. Sensor assembly 814 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, sensor assembly 814 may also include an accelerometer, gyroscope, magnetometer, pressure sensor, or temperature sensor.

[0194] Communication component 816 is configured to facilitate wired or wireless communication between electronic device 800 and other devices. Electronic device 800 can access wireless networks based on communication standards, such as WiFi, carrier networks (such as 2G, 3G, 4G, or 5G), or combinations thereof. In one exemplary embodiment, communication component 816 receives broadcast signals or broadcast operation information from an external broadcast management system via a broadcast channel. In one exemplary embodiment, communication component 816 also includes a near-field communication (NFC) module to facilitate short-range communication. For example, the NFC module may be implemented based on radio frequency identification (RFID) technology, Infrared Data Association (IRDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.

[0195] In an exemplary embodiment, the electronic device 800 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field-programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the methods described above.

[0196] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, such as a memory 804 including instructions, which can be executed by a processor 820 of an electronic device 800 to perform the above-described method. For example, the non-transitory computer-readable storage medium may be a ROM, random access memory (RAM), CD-ROM, magnetic tape, floppy disk, and optical data storage device, etc.

[0197] Figure 5 This is a block diagram of an electronic device 1900 shown in this application. For example, the electronic device 1900 can be provided as a server.

[0198] Reference Figure 5 The electronic device 1900 includes a processing component 1922, which further includes one or more processors, and memory resources represented by memory 1932 for storing instructions, such as application programs, that can be executed by the processing component 1922. The application programs stored in memory 1932 may include one or more modules, each corresponding to a set of instructions. Furthermore, the processing component 1922 is configured to execute instructions to perform the methods described above.

[0199] Electronic device 1900 may also include a power supply component 1926 configured to perform power management of electronic device 1900, a wired or wireless network interface 1950 configured to connect electronic device 1900 to a network, and an input / output (I / O) interface 1958. Electronic device 1900 can operate on an operating system stored in memory 1932, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™, or similar.

[0200] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.

[0201] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal (which may be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in the various embodiments of this application.

[0202] The embodiments of this application have been described above with reference to the accompanying drawings. However, this application is not limited to the specific embodiments described above. The specific embodiments described above are merely illustrative and not restrictive. Those skilled in the art can make many other forms under the guidance of this application without departing from the spirit and scope of the claims, and all of these forms are within the protection scope of this application.

[0203] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed in this application can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0204] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.

[0205] In the embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative. For instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.

[0206] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0207] In addition, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.

[0208] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, ROM, RAM, magnetic disks, or optical disks.

[0209] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. A configuration verification method, characterized in that, Applied to edge nodes, the method includes: Receive the baseline configuration items sent by the central configuration node; the baseline configuration items include: baseline configuration, the operation code corresponding to the baseline configuration, and the version number of the baseline configuration. The baseline configuration is the configuration added in the central configuration node. In the set of historical configuration items stored in the edge node, find the configuration item to be verified. The configuration item to be verified includes: the configuration to be verified, the operation code corresponding to the configuration to be verified, and the version number of the configuration to be verified. The version number in the configuration item to be verified is the same as the version number in the base configuration item. Obtain the configuration items that differ between the baseline configuration items and the configuration items to be verified; Execute the operation code in the differentiated configuration item for the configuration in the differentiated configuration item; If no distinguishing configuration item exists in the historical configuration item set, the distinguishing configuration item is stored in the historical configuration item set.

2. The method according to claim 1, characterized in that, There are multiple baseline configuration items, and the version numbers of these multiple baseline configuration items are not unique. There are multiple distinguishing configuration items; The step of executing the operation code in the differentiated configuration item includes: Among multiple distinguishing configuration items, check if there are at least two distinguishing configuration items that have the same configuration but different version numbers; If there are at least two different configuration items that include the same configuration but different version numbers among multiple different configuration items, find the different configuration item with the latest version number among the at least two different configuration items that include the same configuration but different version numbers. Execute the operation code in the found distinguished configuration items for the specified configurations; Accordingly, storing the distinguishing configuration item in the historical configuration item set when no distinguishing configuration item exists in the historical configuration item set includes: If the found distinguishing configuration item is not found in the historical configuration item set, the found distinguishing configuration item is stored in the historical configuration item set.

3. The method according to claim 1, characterized in that, The configuration items that distinguish the baseline configuration items from the configuration items to be verified include: For any baseline configuration item, if the version number in the baseline configuration item is the same as the version number in one of the configuration items to be verified, the configuration in the baseline configuration item is the same as the configuration in one of the configuration items to be verified, and the operation code in the baseline configuration item is different from the operation code in one of the configuration items to be verified, then the baseline configuration item is determined as a distinguishable configuration item. Accordingly, executing the operation code in the differentiated configuration item on the differentiated configuration item includes: Execute the operation code in the benchmark configuration item for the configuration in the benchmark configuration item; Accordingly, storing the distinguishing configuration item in the historical configuration item set when no distinguishing configuration item exists in the historical configuration item set includes: If the baseline configuration item does not exist in the historical configuration item set, the baseline configuration item is stored in the historical configuration item set.

4. The method according to claim 1, characterized in that, The configuration items that distinguish the baseline configuration items from the configuration items to be verified include: For any configuration item to be verified, if each baseline configuration item does not simultaneously have the configuration and version number of the configuration item to be verified, in the preset operation code pair, another operation code that is different from the operation code in the configuration item to be verified is selected. The preset operation code pair has two operation codes, and the two operation codes correspond to different operation methods. Replace the operation code in the configuration item to be verified with the other operation code to obtain a new configuration item, and identify the new configuration item as the distinguishable configuration item; Accordingly, executing the operation code in the differentiated configuration item on the differentiated configuration item includes: Execute the operation code in the new configuration item for the configuration in the new configuration item; Accordingly, storing the distinguishing configuration item in the historical configuration item set when no distinguishing configuration item exists in the historical configuration item set includes: If the new configuration item does not exist in the historical configuration item set, the new configuration item is stored in the historical configuration item set.

5. The method according to claim 1, characterized in that, The configuration items that distinguish the baseline configuration items from the configuration items to be verified include: For any baseline configuration item, if each configuration item to be verified does not simultaneously possess the configuration and version number of the baseline configuration item, then the baseline configuration item is determined as a distinguishing configuration item. Accordingly, executing the operation code in the differentiated configuration item on the differentiated configuration item includes: Execute the operation code in the benchmark configuration item for the configuration in the benchmark configuration item; Accordingly, storing the distinguishing configuration item in the historical configuration item set when no distinguishing configuration item exists in the historical configuration item set includes: If the baseline configuration item does not exist in the historical configuration item set, the baseline configuration item is stored in the historical configuration item set.

6. A configuration verification method, characterized in that, Applied to a central configuration node, the method includes: Retrieve the baseline configuration item, which includes: the baseline configuration, the operation code corresponding to the baseline configuration, and the version number of the baseline configuration. The baseline configuration is the configuration added in the central configuration node. Send a baseline configuration item to the edge node; enable the edge node to receive the baseline configuration item sent by the central configuration node; search for the configuration item to be verified in the historical configuration item set stored in the edge node. The configuration item to be verified includes: the configuration to be verified, the operation code corresponding to the configuration to be verified, and the version number of the configuration to be verified. The version number in the configuration item to be verified is the same as the version number in the baseline configuration item; obtain the difference configuration item between the baseline configuration item and the configuration item to be verified; execute the operation code in the difference configuration item for the configuration in the difference configuration item; if the difference configuration item does not exist in the historical configuration item set, store the difference configuration item in the historical configuration item set.

7. A configuration verification device, characterized in that, Applied to edge nodes, the device includes: The receiving module is used to receive the baseline configuration items sent by the central configuration node. The baseline configuration items include: baseline configuration, operation code corresponding to the baseline configuration, and version number of the baseline configuration. The baseline configuration is the configuration added in the central configuration node. The lookup module is used to search for the configuration item to be verified in the set of historical configuration items stored in the edge node. The configuration item to be verified includes: the configuration to be verified, the operation code corresponding to the configuration to be verified, and the version number of the configuration to be verified; the version number in the configuration item to be verified is the same as the version number in the baseline configuration item. The first acquisition module is used to acquire the difference configuration items between the baseline configuration items and the configuration items to be verified. The execution module is used to execute the operation code in the differentiated configuration items. The storage module is used to store the distinguishable configuration items in the historical configuration item set when there are no distinguishable configuration items in the historical configuration item set.

8. A configuration verification device, characterized in that, The device, applied to a central configuration node, includes: The second acquisition module is used to acquire the baseline configuration item. The baseline configuration item includes: baseline configuration, operation code corresponding to the baseline configuration, and version number of the baseline configuration. The baseline configuration is the configuration added in the central configuration node. The sending module is used to send baseline configuration items to edge nodes; enabling edge nodes to receive baseline configuration items sent by the central configuration node; searching for a configuration item to be verified in the historical configuration item set stored in the edge node; the configuration item to be verified includes: the configuration to be verified, the corresponding operation code, and the version number of the configuration to be verified, and the version number in the configuration item to be verified is the same as the version number in the baseline configuration item; obtaining the difference configuration item between the baseline configuration item and the configuration item to be verified; executing the operation code in the difference configuration item on the configuration in the difference configuration item; and storing the difference configuration item in the historical configuration item set if the difference configuration item does not exist in the historical configuration item set.

9. An electronic device, characterized in that, include: A processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the method as described in any one of claims 1 to 6.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the method as described in any one of claims 1 to 6.

Citation Information

Patent Citations

  • Configuration file verification method and device, storage medium and electronic equipment

    CN116436784A

  • Method for verifying configuration consistency between controller and network element in SDN (Software Defined Network)

    CN118714009A