CN112769585A - Network equipment management method, device and system - Google Patents

Network equipment management method, device and system Download PDF

Info

Publication number
CN112769585A
CN112769585A CN201911002749.9A CN201911002749A CN112769585A CN 112769585 A CN112769585 A CN 112769585A CN 201911002749 A CN201911002749 A CN 201911002749A CN 112769585 A CN112769585 A CN 112769585A
Authority
CN
China
Prior art keywords
configuration
identification information
information
state
network device
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201911002749.9A
Other languages
Chinese (zh)
Other versions
CN112769585B (en
Inventor
王建平
王启俊
阎丽芳
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201911002749.9A priority Critical patent/CN112769585B/en
Priority to PCT/CN2020/116938 priority patent/WO2021077967A1/en
Publication of CN112769585A publication Critical patent/CN112769585A/en
Application granted granted Critical
Publication of CN112769585B publication Critical patent/CN112769585B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/02Details
    • H04L12/12Arrangements for remote connection or disconnection of substations or of equipment thereof
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0803Configuration setting
    • H04L41/0813Configuration setting characterised by the conditions triggering a change of settings
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/02Standardisation; Integration
    • H04L41/0246Exchanging or transporting network management information using the Internet; Embedding network management web servers in network elements; Web-services-based protocols
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0803Configuration setting
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/50Reducing energy consumption in communication networks in wire-line communication networks, e.g. low power modes or reduced link rate

Abstract

The embodiment of the application discloses a method, a device and a system for managing network equipment, and belongs to the field of communication. The method comprises the following steps: the network equipment receives a recovery message sent by the management equipment, wherein the recovery message comprises first identification information, and the first identification information is used for identifying a first configuration operation executed on a configuration database of the network equipment; acquiring an operation object and an operation type corresponding to the first identification information from the identification information and the corresponding relation between the operation object and the operation type, wherein the operation type is the type of the first configuration operation, and the operation object is the object operated by the first configuration operation; and restoring the configuration database from a first state to a second state according to the operation object and the operation type, wherein the first state is the state of the configuration database after the first configuration operation is executed, and the second state is the state of the configuration database before the first configuration operation is executed. By the aid of the method and the device, recovery efficiency of the configuration data can be improved.

Description

Network equipment management method, device and system
Technical Field
The present application relates to the field of communications, and in particular, to a method, an apparatus, and a system for managing a network device.
Background
The Restconf protocol defines a set of management operations for network devices, which may be switches or routers, etc. The management operation includes at least one operation of adding configuration information of the network device, deleting configuration information of the network device, or modifying configuration information of the network device. The configuration information of the network device is stored in a configuration database of the network device, and a user can modify the configuration database of the network device by using the set of management operation, so that the state of the network device reaches the state expected by the user.
The modification of the configuration database comprises adding configuration information in the configuration database, deleting the configuration information stored in the configuration database or modifying the content of the configuration information in the configuration database. Sometimes, after a user modifies a configuration database of a network device, the user finds that the modification is wrong, which causes a fault in the state of the network device, and at this time, the user needs to modify back the configuration information stored in the configuration database to recover the configuration information stored in the configuration database before modification, thereby recovering the original state of the network device. Or, sometimes, after the network device runs for a period of time using the modified configuration database, the user needs to restore the original state of the network device, and at this time, the user also needs to modify the configuration database.
At present, a user is required to manually modify a configuration database to recover the configuration database, and the manual modification usually needs a long time, so that the recovery efficiency of the configuration database is low.
Disclosure of Invention
The application provides a management method, a device and a system of network equipment, which are used for improving the recovery efficiency of configuration data, and the technical scheme is as follows:
in a first aspect, the present application provides a method for managing a network device, in which: the network device receives a recovery message sent by the management device, and the recovery message includes first identification information, and the first identification information is used for identifying a first configuration operation executed on a configuration database of the network device. The network device obtains the operation object and the operation type corresponding to the first identification information from the identification information and the corresponding relation between the operation object and the operation type, wherein the operation type is the type of the first configuration operation, and the operation object is the object operated by the first configuration operation. And the network equipment restores the configuration database from a first state to a second state according to the operation object and the operation type, wherein the first state is the state of the configuration database after the first configuration operation is executed, and the second state is the state of the configuration database before the first configuration operation is executed. Therefore, when the configuration database is restored, an administrator only needs to input the first identification information into the management equipment, the management equipment sends a restoration message containing the first identification information to the network equipment, and the network equipment automatically restores the configuration database in the second state according to the first identification information, so that the efficiency of restoring the configuration data is improved.
In a possible implementation manner, the network device receives a configuration message sent by the management device, where the configuration message includes the first identification information, the operation type of the first configuration operation, and the operation object. The network device stores the first identification information, the operation object and the operation type in correspondence to the identification information, the correspondence between the operation object and the operation type, and executes a first configuration operation corresponding to the operation type on the configuration database according to the operation object. Since the network device stores the corresponding relationship between the first identification information, the operation object and the operation type, when the configuration database is restored, automatic restoration can be performed based on the stored corresponding relationship.
In another possible implementation manner, the network device receives a first commissioning request, where the first commissioning request includes first identification information, and operates according to the configuration database in the first state in a first commissioning period corresponding to a first configuration operation identified by the first identification information, where a start time of the first commissioning period is a time for executing the first configuration operation, and a time length of the first commissioning period is equal to a time threshold. And when the network equipment receives the recovery message in the first commissioning period, acquiring the operation type and the operation object corresponding to the first identification information from the corresponding relation among the first identification information, the operation object and the operation type. The network equipment performs trial operation according to the configuration database in the first state in the first trial operation period, so that whether the modification of the configuration database is wrong or not can be detected in the first trial operation period, and the configuration database is requested to be restored in time under the condition of the mistake, so that the influence of the network equipment on the service can be reduced.
In another possible implementation manner, the configuration message further includes a commissioning identifier, the network device operates according to the configuration database in the first commissioning period corresponding to the first configuration operation under the trigger of the commissioning identifier, the start time of the first commissioning period is time for executing the first configuration operation, and the time length of the first commissioning period is equal to the time threshold. And when the network equipment receives the recovery message in the first commissioning period, acquiring the operation type and the operation object corresponding to the first identification information from the corresponding relation among the first identification information, the operation object and the operation type. The network equipment performs trial operation according to the configuration database in the first state in the first trial operation period, so that whether the modification of the configuration database is wrong or not can be detected in the first trial operation period, and the configuration database is requested to be restored in time under the condition of the mistake, so that the influence of the network equipment on the service can be reduced.
In another possible implementation manner, the network device receives a second commissioning request, where the second commissioning request includes second identification information, and the second identification information is used to identify a second configuration operation, where the second configuration operation is an operation that the network device has performed on the configuration database. The network device operates according to the configuration database in a third state in a second commissioning period corresponding to the second configuration operation, the starting time of the second commissioning period is the time for executing the second configuration operation, the time length of the second commissioning period is equal to the time length threshold, and the third state is the state of the configuration database after executing the second configuration operation. And when the network equipment receives the confirmation message in the second commissioning period, the confirmation message comprises second identification information, and the record comprising the second identification information is deleted from the corresponding relation among the identification information, the operation object and the operation type. Therefore, the configuration database can be confirmed in time if the modification of the configuration database is detected to be correct in the second commissioning period, and the network equipment is prevented from automatically recovering the configuration database when the second commissioning period is finished.
In another possible implementation manner, the network device receives a third commissioning request, where the third commissioning request includes third identification information, and the third identification information is used to identify a third configuration operation, where the third configuration operation is an operation that the network device has performed on the configuration database. The network device operates according to the configuration database in a fourth state in a third commissioning period corresponding to the third configuration operation, the starting time of the third commissioning period is the time for executing the third configuration operation, the time length of the third commissioning period is equal to the time length threshold, and the fourth state is the state of the configuration database after executing the third configuration operation. And when the network device does not receive the message including the third identification information in the third commissioning period, restoring the configuration database from the fifth state to the fourth state according to the operation type and the operation object corresponding to the third configuration operation at the end of the third commissioning period, wherein the fifth state is the state of the configuration database after the third configuration operation is executed. Therefore, if the configuration database is modified wrongly, the administrator does not need to trigger any operation on the network equipment, and the network equipment automatically restores the configuration database only after the third trial run period is finished, so that the restoring efficiency is improved, and the user experience is also improved.
In another possible implementation manner, the network device obtains recovery information according to the operation object, where the recovery information is used to describe content that changes in a process configuration database that performs the first configuration operation on the configuration database. And the network equipment restores the configuration database from the first state to the second state according to the operation type and the restoration information. In this way, the modified content of the configuration database by the first configuration operation is recovered according to the recovery information, and the modification of the configuration database by other configuration operations can still be reserved.
In another possible implementation manner, the recovery packet is a packet that includes recovery identification information and first identification information, where the recovery identification information is used to identify that the type of the packet is a recovery packet.
In a second aspect, the present application provides a method for managing a network device, in which the network device receives a recovery packet sent by a management device, the recovery packet includes first identification information, the first identification information is used to identify first configuration information, the first configuration information is configuration information stored in a configuration database of the network device before a first configuration operation is performed, and the first configuration operation is an operation that the network device has performed on the configuration database. The network equipment acquires first configuration information corresponding to the first identification information from the corresponding relation between the identification information and the configuration information. The network device updates the contents of the configuration database to the first configuration information. Therefore, when the configuration database before the first configuration operation is executed is restored, the administrator only needs to input the first identification information, the management device sends the restoration message including the first identification information to the network device, and the network device automatically restores the configuration database before the first configuration operation is executed according to the first identification information, so that the efficiency of restoring the configuration data is improved.
In a possible implementation manner, the network device receives a configuration message sent by the management device, where the configuration message includes the first identification information, the operation type of the first configuration operation, and the operation object. The network equipment acquires the content in the configuration database to obtain first configuration information; correspondingly storing the first identification information and the first configuration information in the corresponding relation between the identification information and the configuration information, and executing the first configuration operation corresponding to the operation type on the configuration database according to the operation object. Since the network device stores the correspondence between the first identification information and the first configuration information, when the configuration database is restored, automatic restoration can be performed based on the stored correspondence.
In a third aspect, the present application provides a management apparatus for a network device, configured to execute the method in the first aspect or any one of the possible implementation manners of the first aspect. In particular, the apparatus comprises means for performing the method of the first aspect or any one of its possible implementations. Alternatively, the apparatus comprises means for performing the second aspect or a method of one possible implementation of the second aspect.
In a fourth aspect, an embodiment of the present application provides an apparatus for managing a network device, where the apparatus includes: a transceiver, a processor, and a memory. The processor, the memory and the transceiver can be connected through a bus system. The memory is configured to store one or more programs, and the processor is configured to execute the one or more programs in the memory to perform the method of the first aspect or any possible implementation manner of the first aspect; alternatively, the processor is configured to execute one or more programs in the memory to perform the method of the second aspect or one possible implementation manner of the second aspect.
In a fifth aspect, the present application provides a computer-readable storage medium having stored therein instructions, which, when executed on a processor, cause the processor to perform the method of the first aspect or any possible implementation manner of the first aspect; or cause a processor to perform the method of the second aspect described above or one possible implementation of the second aspect, when run on the processor.
In a sixth aspect, the present application provides a computer program product comprising instructions which, when run on a processor, cause the processor to perform the method of the first aspect or any possible implementation of the first aspect; or cause a processor to perform the method of the second aspect described above or one possible implementation of the second aspect, when run on the processor.
In a seventh aspect, the present application provides a management system for a network device, the system comprising a management device and a network device,
the management device is configured to send a recovery packet to the network device, where the recovery packet includes first identification information, and the first identification information is used to identify a first configuration operation that has been performed on a configuration database of the network device. The network device is used for acquiring an operation object and an operation type corresponding to the first identification information from the identification information and the corresponding relation between the operation object and the operation type, wherein the operation type is the type of the first configuration operation, and the operation object is the object operated by the first configuration operation; and restoring the configuration database from a first state to a second state according to the operation object and the operation type, wherein the first state is the state of the configuration database after the first configuration operation is executed, and the second state is the state of the configuration database before the first configuration operation is executed. Therefore, when the configuration database is restored, an administrator only needs to input the first identification information into the management equipment, the management equipment sends a restoration message comprising the first identification information to the network equipment, and the network equipment automatically restores the configuration database in the second state according to the first identification information, so that the efficiency of restoring the configuration data is improved.
In an eighth aspect, the present application provides a management system for a network device, the system including: a management device and a network device; the management device is used for sending a recovery message to the network device, wherein the recovery message comprises first identification information, the first identification information is used for identifying first configuration information, the first configuration information is configuration information stored in a configuration database of the network device before a first configuration operation is executed, and the first configuration operation is an operation executed on the configuration database by the network device; the network equipment is used for acquiring first configuration information corresponding to the first identification information from the corresponding relation between the identification information and the configuration information; the contents of the configuration database are updated to the first configuration information. Therefore, when the configuration database before the first configuration operation is executed is restored, the administrator only needs to input the first identification information into the management equipment, the management equipment sends the restoration message including the first identification information to the network equipment, and the network equipment automatically restores the configuration database before the first configuration operation is executed according to the first identification information, so that the efficiency of restoring the configuration data is improved.
Drawings
Fig. 1 is a schematic structural diagram of a management system of a network device according to an embodiment of the present application;
fig. 2 is a flowchart of a management method for a network device according to an embodiment of the present application;
FIG. 3 is a schematic view of a first interface provided by an embodiment of the present application;
FIG. 4 is a schematic view of another first interface provided by an embodiment of the present application;
FIG. 5 is a schematic view of another first interface provided by an embodiment of the present application;
FIG. 6 is a schematic diagram of a second interface provided by an embodiment of the present application;
FIG. 7 is a schematic illustration of a third interface provided by an embodiment of the present application;
fig. 8 is a flowchart of another management method for a network device according to an embodiment of the present application;
FIG. 9 is a schematic view of a fourth interface provided by an embodiment of the present application;
FIG. 10 is a schematic diagram of a fifth interface provided by an embodiment of the present application;
fig. 11 is a schematic structural diagram of a management apparatus of a network device according to an embodiment of the present application;
fig. 12 is a schematic structural diagram of another management apparatus for network devices according to an embodiment of the present application;
fig. 13 is a schematic structural diagram of another management apparatus for network devices according to an embodiment of the present application.
Detailed Description
Referring to fig. 1, an embodiment of the present application provides a management system for a network device, where the management system includes:
the network device comprises a management device and a network device, and network connection can be established between the management device and the network device.
The network device includes a configuration database for storing configuration information. The network device operates according to the configuration information in the configuration database.
Alternatively, the network device may be a router or a switch, etc. The configuration information may be routing information of the network traffic, so that the network device forwards the network traffic according to the routing information of the network traffic stored in the configuration database when receiving the network traffic.
The routing information of the network traffic includes identification information and next hop information of the network traffic. For example, referring to the configuration database shown in table 1 below, it is assumed that the configuration database includes two pieces of configuration information, the first piece of configuration information is routing information of network traffic 1, including identification information "11" and next hop information "192.168.10.1" of network traffic 1; the second piece of configuration information is routing information of network traffic 2, including identification information "12" and next hop information "192.168.10.2" of network traffic 2. Thus, when receiving the network traffic 1, the network device forwards the network traffic 1 according to the first piece of configuration information, and when receiving the network traffic 2, the network device forwards the network traffic 2 according to the second piece of configuration information.
TABLE 1
Figure BDA0002241836600000051
The management device may modify the configuration database of the network device using a set of configuration operations, and then the network device operates according to the modified configuration database. Because the configuration database before modification is different from the configuration database after modification, the running state of the network device running according to the configuration database before modification is different from the running state of the network device running according to the configuration information after modification.
Optionally, the set of configuration operations may include at least one of an adding operation for adding configuration information to the configuration database, a modifying operation for modifying configuration information in the configuration database, or a deleting operation for deleting configuration information in the configuration database, and the like.
In this way, the management device may add at least one piece of configuration information to the configuration database of the network device using an addition operation, or modify at least one piece of configuration information included in the configuration database of the network device using a modification operation, or delete at least one piece of configuration information included in the configuration database of the network device using a deletion operation, when modifying the configuration database of the network device.
Alternatively, the management device may modify the configuration database of the network device under the trigger of the administrator. Generally, when an administrator needs to change the operation state of a network device, the administrator can select a configuration operation to be performed in the management device. The management device then performs the configuration operation on the configuration database of the network device to effect modification of the configuration database of the network device. And the network equipment operates according to the modified configuration database, so that the operation state of the network equipment is changed.
For example, still taking the network traffic as an example, assuming that the administrator needs to adjust a forwarding path of the network device for forwarding the network traffic, the administrator may configure new routing information corresponding to the network traffic and a selected configuration operation in the management device as a modification operation. Then, the management device modifies the routing information of the network traffic stored in the configuration database of the network device into the new routing information, and when the network device receives the network traffic, the network device forwards the network traffic according to the new routing information stored in the configuration database, thereby realizing the adjustment of the forwarding path of the network traffic.
Alternatively, the management device may run a client for managing the network device, through which an administrator may modify the configuration database of the network device.
The administrator modifies the configuration database of the network device through the management device, and part of the content in the configuration database changes. The running state of the network device running according to the modified configuration database may be the same as the running state required by the administrator or different from the running state required by the administrator. When the running state of the network equipment is the same as the running state required by the administrator, the method indicates that the administrator modifies the configuration database correctly, and when the running state of the network equipment is different from the running state required by the administrator, the method indicates that the administrator modifies the configuration database of the network equipment wrongly. For example, still taking the network traffic as an example, the network device forwards the network traffic according to the new routing information stored in the configuration database, where a forwarding path of the network traffic is the same as a forwarding path expected by an administrator and indicates that the modification of the configuration database is correct, and a forwarding path of the network traffic is different from a forwarding path expected by an administrator and indicates that the modification of the configuration database is incorrect.
When the modification of the configuration database is wrong, the changed content in the configuration database needs to be recovered. In order to implement the recovery configuration database, a commissioning capability set may be defined in the network device, so that the network device has a commissioning function. The commissioning function is that after the configuration operation is performed on the configuration database of the network device, the network device may be run for a period of time according to the modified configuration database. If the configuration database is found to be modified incorrectly within the period of time, the management device may request the network device to recover the changed content in the configuration database.
In this way, the administrator may not be able to determine whether the configuration database is correctly modified when modifying the configuration database, so that after the administrator modifies the configuration database of the network device through the management device, the network device may try to run for a period of time according to the modified configuration database. In the period of commissioning, if the administrator finds that the running state of the network device is incorrect or the management device detects that the running state of the network device is incorrect, the administrator may trigger the network device to recover the changed content in the configuration database through the management device, or the management device directly triggers the network device to recover the changed content in the configuration database. In the period of commissioning, if the administrator finds that the operation state of the network device is correct or the management device detects that the operation state of the network device is correct, the administrator may confirm the modification of the configuration database through the management device, or the management device directly confirms the modification of the configuration database. After confirming the modification of the configuration database, the network device continues to operate according to the modified configuration database within the remaining time of the period of time and after the period of time is over. The detailed process flow of the test run can be referred to the embodiment shown in fig. 2, and will not be described in detail.
When modifying the configuration database, the administrator can determine that the modification of the configuration database is correct, and after modifying the configuration database, the network device operates according to the modified configuration database. After the network device operates for a period of time according to the modified configuration database, an administrator may need to restore the operating state of the network device to the operating state before modifying the configuration database, and to meet the requirement, a fallback capability set is defined in the network device, so that the network device has a fallback function. The rollback function is that after the configuration operation is performed on the configuration database of the network device, the network device can restore the content in the modified configuration database to the content stored in the configuration database before the configuration operation is performed.
Thus, the administrator can trigger the network device to restore the content of the configuration database to the content before modification through the management device, so that the running state of the network device is restored to the running state before modification of the configuration database. The detailed flow of the process can be seen in the embodiment shown in fig. 8, and will not be described in detail.
Referring to fig. 2, an embodiment of the present application provides a management method for a network device, which may be applied to the network architecture shown in fig. 1. In the method, the content changed in the configuration database can be recovered by using a commissioning function of the network device. The method comprises the following steps:
step 101: the management equipment sends a configuration message to the network equipment, wherein the configuration message comprises a commissioning identifier, first identifier information, an operation type and an operation object of a configuration operation to be executed.
The first identification information is used for identifying the configuration operation, and the commissioning identification is used for indicating the network device to run according to the configuration database in the first state in the commissioning period corresponding to the configuration operation. The first state is a state that the configuration database of the network device is in after performing the configuration operation on the configuration database. The starting time of the commissioning period is the time for executing the configuration operation, and the time length of the commissioning period is equal to the time length threshold.
The configuration message may not include a commissioning identifier, and the management device further sends a commissioning request to the network device when sending the configuration message, or sends the commissioning request to the network device before sending the configuration message, where the commissioning request includes the first identifier information. The commissioning request is used for requesting the network device to run according to the configuration database in the first state in the commissioning period corresponding to the configuration operation.
The administrator may input to the management device an identification of the network device, an operation type and an operation object of the configuration operation, and first identification information for identifying the configuration operation. Then, the management device acquires the first identification information, the operation type and the operation object of the configuration operation, generates a configuration message comprising the commissioning identification, the first identification information, the operation type and the operation object of the configuration operation, and sends the configuration message to the network device according to the identification information of the network device; or generating a configuration message including the first identification information, the operation type of the configuration operation and the operation object, generating a commissioning request including the first identification information, sending the configuration message to the network device according to the identification information of the network device, and sending the commissioning request.
Optionally, the commissioning identifier may also be input into the management device by an administrator, or the management device includes the commissioning identifier. The identifier of the network device may be an Internet Protocol (IP) address and the like of the interconnection between the networks of the network device.
The commissioning identifier may be preset information, or may be information agreed in advance by the management device and the network device.
Optionally, under the condition that the configuration packet includes the commissioning identifier, the configuration packet further includes a duration threshold. Alternatively, the commissioning request further includes a duration threshold.
The duration threshold may be a threshold entered into the management device by the administrator. Alternatively, the time length threshold may be a threshold previously stored in the management apparatus.
Optionally, in a case that the configuration packet includes the commissioning identifier, the configuration packet may not include the duration threshold; alternatively, the commissioning request may not include the duration threshold, but the network device may include the duration threshold, and the duration threshold included in the network device may be a threshold agreed with the management device in advance.
Alternatively, the configuration operation is an operation that an administrator needs to perform on a configuration database of the network device. The operation type of the configuration operation may be an addition operation for adding configuration information to the configuration database, a modification operation for modifying configuration information in the configuration database, or a deletion operation for deleting configuration information in the configuration database, or the like.
When the operation type is a modification operation, the operation object includes an identifier of the configuration information to be modified and first content, and the first content is content modified by the administrator on the configuration information to be modified. When the operation type is an adding operation, the operation object includes configuration information to be added, and the configuration information to be added includes an identifier and content of the configuration information to be added. When the operation type is a delete operation, the operation object may include an identifier of configuration information to be deleted.
Alternatively, the identifier of the configuration information may be a component of the configuration information, and the other part of the configuration information may be referred to as the content of the configuration information. For example, referring to the first piece of configuration information shown in table 1 above, the first piece of configuration information includes identification information "11" and next hop information "192.168.10.1" of network traffic 1, and the identification information "11" may be used as an identification of the first piece of configuration information, and the next hop information "192.168.10.1" may be used as the content of the first piece of configuration information.
In this step, a set of configuration operations defined by the Restconf protocol may be used, and the configuration operations defined by the Restconf protocol include at least one of post, create, and delete. post, create, delete are modify, add, delete operations, respectively. After acquiring the first identification information, the operation type of the configuration operation and the operation object, the management device generates a message including the commissioning identification, the first identification information, the operation type of the configuration operation and the operation object, and the generated message includes the operation type, so that the message type of the generated message is the configuration message.
Optionally, in this step, the generated message includes a first parameter and a second parameter, and when the message is generated, the value of the first parameter is set as the first identifier information, and the value of the second parameter is set as the trial operation identifier, so that the generated message includes the first identifier information and the trial operation identifier.
Optionally, in this step, the generated message further includes a third parameter, and a value of the third parameter is set as the duration threshold in generating the message, so that the generated message includes the duration threshold.
Optionally, in this step, the management device may display a first interface to the administrator, and the administrator may input information such as an identifier of the network device, first identifier information, an operation type and an operation object of the configuration operation to the management device through the first interface. And inputting information such as a trial operation identifier or the time threshold and the like into the management equipment through the first interface.
For example, referring to fig. 3, the first interface includes a selection button 1 for selecting an operation type, a first input interface 2 for inputting first identification information, a second input interface 3 for inputting a commissioning identification, a third input interface 4 for inputting a duration threshold, a fourth input interface 5 for inputting an operation object, and a fifth input interface 6 for inputting an identification of a network device.
The selection button 1 may be a pull-down button, and the selection button 1 includes at least one operation type of the configuration operation, and the operation type of the configuration operation includes post, create, and delete.
The administrator can select the operation type of the configuration operation to be performed in the selection button 1. Referring to the first interface shown in fig. 3, it is assumed that an administrator needs to modify the first piece of configuration information in the configuration database shown in table 1, where the first piece of configuration information is routing information of network traffic 1, and the administrator needs to modify the next hop information in the routing information from "192.168.10.1" to "192.168.10.3". At this time, the administrator selects the operation type of the configuration operation to be performed as the modification operation post, inputs the first identification information abc in the first input interface 2, inputs the commissioning identification a in the second input interface 3, inputs the duration threshold value 180 in the third input interface 4, inputs the operation object including the identification "11" of the configuration information to be modified and the first content "192.168.10.3" of the configuration information to be modified in the fourth input interface 5, and inputs the identification of the network device as the IP1 in the fifth input interface 6. The unit of the time length threshold value can be seconds or minutes.
The management device may read, from the first interface shown in fig. 3, the operation type post of the configuration operation, the first identification information abc, the commissioning identification a, the duration threshold of 180, the identification "11" of the configuration information to be modified, the first content "192.168.10.3" of the configuration information to be modified, and the identification of the network device being IP 1. The configuration message generated by the management device based on the read information may be represented as:
post http:// { IP1} { Port }: restconf/systemlnfoil ═ A & persistence-id ═ abc & timeout ═ 180(Port is the Port number of the network device)
<routeInfo>
< Id info 11</Id info > (identification of configuration information to be modified)
< Next hop >192.168.10.3</Next hop > (first content of configuration information to be modified)
</routeInfo>
And the management equipment sends the configuration message.
For another example, referring to the first interface shown in fig. 4, assume that an administrator needs to add a piece of configuration information to the configuration database of the network device, and assume that the configuration information is the routing information of network traffic 3, and the routing information includes identification information "13" and next hop information "192.168.10.4" of network traffic 3. At this time, the administrator selects the operation type of the configuration operation to be performed as the increase operation create, inputs the first identification information abc in the first input interface 2, inputs the trial operation identification a in the second input interface 3, inputs the duration threshold value 180 in the third input interface 4, inputs the operation object including the identification "13" of the configuration information to be added and the content "192.168.10.4" of the configuration information to be added in the fourth input interface 5, and inputs the identification of the network device as the IP1 in the fifth input interface 6.
The management device may read, from the first interface shown in fig. 4, the operation type create of the configuration operation, the first identification information abc, the commissioning identification a, the duration threshold 180, the identification "13" of the configuration information to be added, the content "192.168.10.4" of the configuration information to be added, and the identification of the network device being IP 1. The configuration message generated by the management device based on the read information may be represented as:
create http://{IP1}{Port}:/restconf/systemInfotrail=A&persist-id=abc&timeout=180
<routeInfo>
< Id info >13</Id info > (identification of configuration information to be added)
< Next hop >192.168.10.4</Next hop > (content to which configuration information is to be added)
</routeInfo>
And the management equipment sends the configuration message.
For another example, referring to the first interface shown in fig. 5, assume that the administrator needs to delete the second piece of configuration information in the configuration database shown in table 1, where the second piece of configuration information is the routing information of network traffic 2, and the routing information includes identification information "12" and next hop information "192.168.10.2". At this time, the administrator selects the operation type of the configuration operation to be executed as the delete operation delete, inputs the first identification information abc in the first input interface 2, inputs the commissioning identification a in the second input interface 3, inputs the duration threshold value 180 in the third input interface 4, inputs the operation object including the identification "12" of the configuration information to be deleted in the fourth input interface 5, and inputs the identification of the network device as IP1 in the fifth input interface 6.
The management device may read, from the first interface shown in fig. 5, the operation type delete of the configuration operation, the first identification information abc, the commissioning identification a, the duration threshold 180, the identification "12" to which the configuration information is to be added, and the identification of the network device being IP 1. The configuration message generated by the management device based on the read information may be represented as:
delete http://{IP1}{Port}:/restconf/systemInfotrail=A&persist-id=abc&timeout=180
<routeInfo>
< Id info 12</Id info > (identification of configuration information to be deleted)
</routeInfo>
And the management equipment sends the configuration message.
Step 102: the network equipment receives the configuration message, correspondingly stores the first identification information, the operation object and the operation type into the corresponding relation of the identification information, the operation object and the operation type, and executes the configuration operation corresponding to the operation type on the configuration database according to the operation object.
In this step, the network device receives the configuration packet, extracts the value of the first parameter in the configuration packet to obtain the first identifier information, extracts the value of the second parameter to obtain the commissioning identifier, extracts the operation object and the operation type included in the configuration packet, correspondingly stores the first identifier information, the operation object and the operation type in the corresponding relationship between the identifier information and the operation object and the operation type, and executes the first configuration operation corresponding to the operation type on the configuration database according to the operation object.
Optionally, under the condition that the configuration packet further includes a duration threshold, the network device may further extract a value of the third parameter from the configuration packet to obtain the duration threshold.
Optionally, the network device further receives the commissioning request when the configuration message does not include the commissioning identifier and the management device sends the commissioning request.
Optionally, when the operation type is an add operation, the operation object includes configuration information to be added, and the configuration information to be added includes an identifier and content of the configuration information to be added. The network device may save the configuration information to be added to the configuration database according to the operation type.
For example, assume that the configuration message received by the network device may be represented as:
create http://{IP1}{Port}:/restconf/systemInfotrail=A&persist-id=abc&timeout=180
<routeInfo>
< Id info >13</Id info > (identification of configuration information to be added)
< Next hop >192.168.10.4</Next hop > (content to which configuration information is to be added)
</routeInfo>
Extracting the operation type as an adding operation create from the configuration message, extracting the operation object as configuration information to be added, wherein the configuration information to be added comprises an identifier '13' of the configuration information to be added and content '192.168.10.4' of the configuration information to be added, extracting a value abc of a first parameter persistence-id from the configuration message to obtain first identifier information, extracting a value A of a second parameter trial to obtain a trial run identifier, and extracting a value 180 of a third parameter timeout to obtain a duration threshold. The first identification information abc, the operation type create, and the operation object are stored in correspondence with each other in the correspondence relationship between the identification information, the operation type, and the operation object shown in table 2 below. The network device saves the configuration information to be added in the configuration database as shown in table 3 below according to the operation type create. The configuration database shown in table 3 below is the configuration database in the first state after the add operation is performed.
TABLE 2
Identification information Type of operation Operation object
abc create 13、192.168.10.4
…… …… ……
TABLE 3
Figure BDA0002241836600000101
Optionally, when the operation type is a delete operation, the operation object includes an identifier of configuration information to be deleted. Before executing the deleting operation, the network device acquires the configuration information to be deleted from the configuration database according to the identifier of the configuration information to be deleted, and stores the configuration information to be deleted in the recovery information table. The network device then deletes the configuration information to be deleted from the configuration database.
For example, assume that the configuration message received by the network device may be represented as:
delete http://{IP1}{Port}:/restconf/systemInfotrail=A&persist-id=abc&timeout=180
<routeInfo>
< Id info 12</Id info > (identification of configuration information to be deleted)
</routeInfo>
Extracting the operation type of deletion operation delete from the configuration message, extracting the operation object as the identifier '12' of the configuration information to be deleted, extracting the value abc of the first parameter persistence-id from the configuration message to obtain first identifier information, extracting the value A of the second parameter trial to obtain a trial operation identifier, and extracting the value 180 of the third parameter timeout to obtain a duration threshold. The first identification information abc, the operation type delete and the operation object are correspondingly stored in the corresponding relationship between the identification information, the operation type and the operation object as shown in the following table 4.
TABLE 4
Identification information Type of operation Operation object
abc delete 12
…… …… ……
The network device obtains the configuration information to be deleted from the configuration database shown in table 1 according to the identifier "12" of the configuration information to be deleted, where the configuration information to be deleted includes the identifier "12" of the configuration information to be deleted and the content "192.168.10.2" of the configuration information to be deleted, and stores the configuration information to be deleted in the recovery information table shown in table 5 below. Then, the network device deletes the configuration information to be deleted from the configuration database shown in table 1, and the obtained configuration database is shown in table 6 below. The configuration database shown in table 6 below is the configuration database in the first state after the deletion operation is performed.
TABLE 5
12、192.168.10.2
……
TABLE 6
Figure BDA0002241836600000111
Optionally, in a case that the operation type is a modification operation, the operation object includes an identifier of configuration information to be modified and first content. Before executing the modification operation, the network device acquires the configuration information to be modified from the configuration database according to the identifier of the configuration information to be modified, the acquired configuration information to be modified comprises the identifier of the configuration information to be modified and second content, and the acquired configuration information to be modified is stored in the recovery information table. Then, the network device updates the second content of the configuration information to be modified to the first content in the configuration database.
For example, assume that the configuration message received by the network device may be represented as:
post http://{IP1}{Port}:/restconf/systemInfotrail=A&persist-id=abc&timeout=180
<routeInfo>
< Id info 11</Id info > (identification of configuration information to be modified)
< Next hop >192.168.10.3</Next hop > (first content of configuration information to be modified)
</routeInfo>
Extracting the operation type as a modification operation post from the configuration message, extracting the operation object as an identifier '11' and a first content as '192.168.10.3' of the configuration information to be modified, extracting the value abc of a first parameter persistence-id from the configuration message to obtain first identifier information, extracting the value A of a second parameter trial to obtain a trial operation identifier, and extracting the value 180 of a third parameter timeout to obtain a duration threshold. The first identification information abc, the operation type post and the operation object are stored in correspondence with each other in the correspondence relationship between the identification information, the operation type and the operation object shown in table 7 below.
TABLE 7
Identification information Type of operation Operation object
abc post 11、192.168.10.3
…… …… ……
The network device obtains the configuration information to be modified from the configuration database shown in table 1 according to the identifier "11" of the configuration information to be modified, where the configuration information to be modified includes the identifier "11" and the second content "192.168.10.1" of the configuration information to be modified, and stores the identifier "11" and the second content "192.168.10.1" of the configuration information to be modified in the recovery information table shown in table 8 below. Then, the network device updates the second content "192.168.10.1" of the configuration information to be modified to the first content "192.168.10.3" from the configuration database shown in table 1 above, and the resulting configuration database is shown in table 9 below. The configuration database shown in table 9 below is the configuration database in the first state after performing the modification operation.
TABLE 8
11、192.168.10.1
……
TABLE 9
Figure BDA0002241836600000121
Optionally, after the network device performs the configuration operation on the configuration database, a notification message may be sent to the management device, and the management device displays the notification message to the administrator.
Step 103: the network device runs according to the configuration database in the first state in the commissioning period of the configuration operation under the triggering of the commissioning identifier, the starting time of the commissioning period is the time for executing the configuration operation, and the time length of the commissioning period is the time threshold.
Optionally, when the network device receives the commissioning request, the network device reads the first identification information from the commissioning request, and operates according to the configuration database in the first state during the commissioning period of the configuration operation identified by the first identification information.
Optionally, the network device times the configuration operation under the trigger of the commissioning identifier or the trigger of the commissioning request. The network device may start a timer for the configuration operation, use the timer to time for the configuration operation, and correspondingly store a corresponding relationship between the timer and the first identification information.
Optionally, the timer started by the network device is a countdown timer, and the initial time value of the countdown timer is equal to the duration threshold.
After the countdown timer is started, the countdown timer gradually decreases the initial value of time, and when the countdown timer decreases the initial value of time to a value of 0, the countdown timer overflows, and the length of time between the time when the countdown timer is started and the time when the countdown timer overflows equals the duration threshold.
Optionally, the management device may allow the administrator to continue to perform another configuration operation on the configuration database of the network device during the commissioning period corresponding to the configuration operation, and the performing process may refer to the processes of 101 to 103 described above. Alternatively, the management device may not allow the administrator to continue to perform another configuration operation on the configuration database of the network device during the commissioning period corresponding to the configuration operation.
In the trial run period corresponding to the configuration operation, if the administrator or the management terminal finds that the running state of the network device running according to the configuration database in the first state is wrong, the configuration database of the network device can be restored from the first state to the second state, and the second state is the state of the configuration database of the network device before the configuration operation is executed. The detailed implementation process includes the operations 104 to 105 as follows.
Step 104: the management device sends a recovery message to the network device, wherein the recovery message comprises first identification information.
Optionally, the management device generates a packet including the first identification information and recovery identification information, where the recovery identification information is used to identify the type of the packet as a recovery packet.
When the management device generates a message, the management device may set a value of a first parameter in the message as the first identification information, and set a value of a second parameter in the message as the recovery identification information, so as to generate a message including the first identification information and the recovery identification information.
The administrator finds that the running state of the network equipment is wrong, can determine which configuration operation executed on a configuration database of the network equipment has a problem according to the running state of the network equipment, and inputs recovery identification information, first identification information for identifying the configuration operation and identification of the network equipment to the management equipment. The management device generates a message including the first identification information and the recovery identification information, and sends the recovery message to the network device according to the identification of the network device.
Optionally, the recovery identification information is preset information or information agreed in advance by the management device and the network device. The restoration identification information may be included in the management apparatus so that the administrator may not input the restoration identification information.
Optionally, the management device may display a second interface to the administrator, and the administrator inputs the first identification information and the recovery identification information to the management device through the second interface.
For example, referring to the second interface shown in fig. 6, the second interface includes a first input interface 2 for inputting first identification information, a sixth input interface 7 for inputting restoration identification information, and a fifth input interface 6 for inputting an identification of a network device. The administrator may enter the first identification information abc in the first input interface 2 and the recovery identification information B in the sixth input interface 7 and the identification IP1 of the network device in the fifth input interface 6. The management device reads the first identification information abc, the recovery identification information B and the identification IP1 of the network device from the second interface, and a recovery message generated based on the read information may be represented as: and sending the recovery message to the network equipment, wherein the recovery message comprises http:// { IP1} { Port }: restconf/systemInfopersistence-id ═ abc & ternary ═ B'.
Step 105: the network equipment receives the recovery message, acquires the operation object and the operation type corresponding to the first identification information from the corresponding relation among the identification information, the operation object and the operation type, and recovers the configuration database from the first state to the second state according to the operation object and the operation type.
The second state is a state in which the configuration database was prior to performing the configuration operation identified by the first identification information.
In this step, the network device extracts the first identification information and the recovery identification information from the recovery packet, and under the trigger of the recovery identification information, obtains the operation object and the operation type corresponding to the first identification information from the corresponding relationship among the identification information, the operation object and the operation type; and acquiring recovery information according to the operation object and the operation type, wherein the recovery information is used for describing the changed content in the process configuration database for executing the configuration operation in the configuration database, and recovering the configuration database from the first state to the second state according to the recovery information and the operation type.
The network device also deletes the first identification information and the timer corresponding to the first identification information from the corresponding relation between the identification information and the timer.
Optionally, when the operation type corresponding to the first identification information is an add operation, the operation object corresponding to the first identification information is added configuration information, the acquired recovery information is an identifier of the added configuration information according to the operation object and the add operation, and the added configuration information is deleted from the configuration database according to the identifier of the added configuration information, so that the configuration database is restored from the first state to the second state.
For example, in the case where the configuration operation to be performed in step 101 is an add operation, the network device saves the identification information, the correspondence relationship between the operation type and the operation object as shown in table 3, and saves the configuration database in the first state as shown in table 4. The network device extracts the first identification information abc and the recovery identification information B from a recovery message "http:// { IP1} { Port }: restconf/systemlnfoperst-id & tertiary & B". Under the trigger of the recovery identification information B, the operation type and the operation object corresponding to the first identification information abc are obtained from the identification information, the correspondence between the operation type and the operation object shown in table 3, the operation type is an incremental operation create, the operation object includes an identifier 13 of the incremental configuration information, and the incremental configuration information is deleted from the configuration database in the first state shown in table 4 according to the identifier 192.168.10.3, so that the configuration database in the second state shown in table 1 is obtained.
Optionally, when the operation type corresponding to the first identification information is a delete operation, the operation object corresponding to the first identification information includes an identifier of deleted configuration information, the deleted configuration information is obtained from the recovery information table according to the identifier of the deleted configuration information, and the deleted configuration information is added to the configuration database, so that the configuration database is recovered from the first state to the second state.
For example, in the case where the configuration operation to be performed in step 101 is a delete operation, the network device holds the identification information, the correspondence relationship of the operation type and the operation object as shown in table 5, the restoration information table as shown in table 6, and the configuration database in the first state as shown in table 7. The network device extracts the first identification information abc and the recovery identification information B from a recovery message "http:// { IP1} { Port }: restconf/systemlnfoperst-id & tertiary & B". Under the trigger of the recovery identification information B, the operation type and the operation object corresponding to the first identification information abc are obtained from the identification information shown in table 5, the corresponding relation between the operation type and the operation object, the operation type is a delete operation table, the operation object includes an identifier 12 of deleted configuration information, the deleted configuration information is obtained from the recovery information table shown in table 6 according to the identifier 12, the deleted configuration information includes "12" and "192.168.10.2", and the deleted configuration information is added to the configuration database in the first state shown in table 7, so that the configuration database in the second state shown in table 1 is obtained.
Optionally, when the operation type corresponding to the first identification information is a modification operation, the operation object corresponding to the first identification information is an identifier of the modified configuration information, the second content before the configuration information is modified is obtained from the recovery information table according to the identifier of the configuration information, and the first content after the configuration information is modified, which is stored in the configuration database, is updated to the second content according to the identifier of the configuration information, so that the configuration database is recovered from the first state to the second state.
For example, in the case where the configuration operation to be performed in step 101 is a modify operation, the network device saves the identification information, the correspondence relationship of the operation type and the operation object as shown in table 8, the restoration information table as shown in table 9, and the configuration database in the first state as shown in table 10. The network device extracts the first identification information abc and the recovery identification information B from a recovery message "http:// { IP1} { Port }: restconf/systemlnfoperst-id & tertiary & B". Under the trigger of the recovery identification information B, the operation type and the operation object corresponding to the first identification information abc are obtained from the correspondence relationship between the identification information, the operation type and the operation object shown in table 8, the operation type is a modification operation post, the operation object includes an identifier 11 of the modified configuration information, the second content before the configuration information is modified is "192.168.10.1" obtained from the recovery information table shown in table 9 according to the identifier 11, the first content "192.168.10.3" after the configuration information is modified is updated to the second content "192.168.10.1" in the configuration database of the first state shown in table 10, and the configuration database of the second state shown in table 1 is obtained.
When the configuration database is recovered, the administrator can trigger the network device to automatically recover the configuration database from the first state to the second state only by inputting the first identification information and the recovery identification information, so that the recovery efficiency is improved.
In the trial run period corresponding to the configuration operation, if the administrator or the management device finds that the running state of the network device running according to the configuration database in the first state is correct, the configuration database of the network device may be confirmed, so as to avoid that the network device automatically restores the configuration database from the first state to the second state after the trial run period of the configuration operation is finished. The detailed implementation process includes the operations 106 to 107 as follows.
Step 106: the management equipment sends a confirmation message to the network equipment, wherein the confirmation message comprises the first identification information.
Optionally, the management device generates a message including the first identification information and confirmation identification information, where the confirmation identification information is used to identify that the type of the message is a confirmation message.
When the management device generates a message, the management device may set a value of a first parameter in the message as the first identification information, and set a value of a second parameter in the message as the confirmation identification information, so as to generate a message including the first identification information and the confirmation identification information.
The administrator finds that the running state of the network equipment is correct, can determine which configuration operation executed on the configuration database of the network equipment needs to be confirmed according to the running state of the network equipment, and inputs confirmation identification information, first identification information used for identifying the configuration operation and identification of the network equipment to the management equipment. And generating a message comprising the confirmation identification information and the first identification information to obtain a confirmation message, and sending the confirmation message to the network equipment according to the identification of the network equipment.
Optionally, the identification information is determined to be preset information, or information agreed in advance by the management device and the network device.
Optionally, the management device may display a third interface to the administrator, and the administrator inputs the first identification information and the confirmation identification information to the management device through the third interface.
For example, referring to the third interface shown in fig. 7, the third interface includes the first input interface 2 for inputting the first identification information, and the seventh input interface 8 for inputting the confirmation identification information. The administrator may enter the first identification information abc in the first input interface 2, the confirmation identification information C in the seventh input interface 8, and the identification IP1 of the network device in the fifth input interface 6. The management device reads the first identification information abc and the confirmation identification information C from the third interface, and a confirmation message generated based on the read information may be represented as: "http:// { IP1} { Port }: restconf/systemInfo? And sending the confirmation message to the network equipment.
Step 107: and the network equipment receives the confirmation message and deletes the record comprising the first identification information from the corresponding relation among the identification information, the operation object and the operation type.
In this step, the network device receives the confirmation message, where the confirmation message includes confirmation identification information and first identification information, stops timing the configuration operation identified by the first identification information under the trigger of the confirmation identification information, and deletes the record including the first identification information from the correspondence between the identification information, the operation object, and the operation type.
Before deleting the record including the first identification information, the network device may further obtain an operation object and an operation type corresponding to the first identification information from a corresponding relationship among the identification information, the operation object, and the operation type, where the operation object includes an identification of the configuration information, and in a case where the operation type is a deletion operation or a modification operation, delete the configuration information including the identification of the configuration information from the recovery information table.
The network device may delete the first identification information and the timer corresponding to the first identification information from the correspondence between the timer and the identification information, thereby stopping timing the configuration operation of the first identification information identifier.
For example, in the case where the configuration operation to be performed in step 101 is an add operation, the network device stores the correspondence relationship of the identification information, the operation type, and the operation object as shown in table 3. The network device extracts the first identification information abc and the confirmation identification information C from a confirmation message "http:// { IP1} { Port }: restconf/systemlnfoperst-id ═ abc & tertiary ═ C". Under the trigger of confirming the identification information C, the operation type and the operation object corresponding to the first identification information abc are acquired from the corresponding relation among the identification information, the operation type and the operation object shown in table 3, the operation type is an increase operation create, and the record including the first identification information abc is deleted from the corresponding relation among the identification information, the operation type and the operation object shown in table 3.
As another example, in the case where the configuration operation to be performed in step 101 is a delete operation, the network device stores the identification information, the correspondence relationship of the operation type and the operation object, as shown in table 5, and the restoration information table, as shown in table 6. The network device extracts the first identification information abc and the confirmation identification information C from a confirmation message "http:// { IP1} { Port }: restconf/systemlnfoperst-id ═ abc & tertiary ═ C". Under the trigger of confirming the identification information C, the operation type and the operation object corresponding to the first identification information abc are acquired from the corresponding relationship among the identification information, the operation type and the operation object shown in table 6, the operation type is a delete operation delete, the operation object comprises an identification "12" of the deleted configuration information, the configuration information comprising the "12" is deleted from the recovery information table shown in table 6, and the record comprising the first identification information abc is deleted from the corresponding relationship among the identification information, the operation type and the operation object shown in table 5.
As another example, in the case where the configuration operation to be performed in step 101 is a modify operation, the network device stores the identification information, the correspondence relationship between the operation type and the operation object, as shown in table 8, and the restoration information table, as shown in table 9. The network device extracts the first identification information abc and the confirmation identification information C from a confirmation message "http:// { IP1} { Port }: restconf/systemlnfoperst-id ═ abc & tertiary ═ C". Under the trigger of confirming the identification information C, the operation type and the operation object corresponding to the first identification information abc are obtained from the corresponding relation among the identification information, the operation type and the operation object shown in table 8, the operation type is a modification operation post, the operation object comprises an identification '11' of modified configuration information, the configuration information comprising '11' is deleted from the recovery information table shown in table 9, and the record comprising the first identification information abc is deleted from the corresponding relation among the identification information, the operation type and the operation object shown in table 8.
Optionally, if the network device does not receive the recovery packet including the first identification information or does not receive the confirmation packet including the first identification information during the commissioning period of the configuration operation, when the commissioning period of the configuration operation is finished, the configuration database is recovered from the first state to the second state according to the operation type and the operation object corresponding to the configuration operation.
Because the network device does not receive the recovery message including the first identification information or the confirmation message including the first identification information in the commissioning period of the configuration operation, when the commissioning period of the configuration operation is finished, the timer corresponding to the first identification information is still stored in the corresponding relationship between the identification information and the timer, the timing duration of the timer reaches the duration threshold, and the timer triggers the network device. At this time, under the trigger of the timer, the network device obtains the operation type and the operation object corresponding to the configuration operation from the corresponding relationship among the identification information, the operation type and the operation object according to the first identification information corresponding to the timer, and then restores the configuration database from the first state to the second state. Wherein the timer is a countdown timer, at which time the timer overflows and triggers the network device.
The detailed implementation process of the network device for restoring the configuration database from the first state to the second state can be referred to the above related content in step 105, and will not be described in detail here.
In the embodiment of the application, a network device receives a configuration message sent by a management device, where the configuration message includes a commissioning identifier, first identifier information, an operation type and an operation object of a configuration operation to be executed, and a configuration database in the network device is in a second state before the configuration operation is executed; and correspondingly storing the first identification information, the operation object and the operation type into the corresponding relation of the identification information, the operation object and the operation type, and executing the configuration operation corresponding to the operation type on the configuration database of the network equipment according to the operation object to obtain the configuration database in the first state. After the configuration operation is executed, the configuration database is operated according to the first state in a commissioning period corresponding to the configuration operation. The configuration database in the first state is found to be wrong in the trial run period, the administrator only needs to input the first identification information to the management equipment, the management equipment sends a recovery message including the first identification information to the network equipment, and therefore the network equipment obtains the operation type and the operation object of the configuration operation identified by the first identification information from the corresponding relation among the identification information, the operation object and the operation type according to the first identification information in the recovery message, and recovers the configuration database in the second state according to the operation type and the operation object, and therefore the content of change in the configuration database does not need to be edited, and recovery efficiency is improved.
Referring to fig. 8, an embodiment of the present application provides a management method for a network device, which may be applied to the network architecture shown in fig. 1. In the method, a fallback capability set may be defined in the network device, enabling the network device to have a fallback function. The rollback function is that after the configuration operation is performed on the configuration database of the network device, if the network device needs to be configured, the management device may request the network device to recover the changed content in the configuration database. The method comprises the following steps:
step 201: the management equipment sends a configuration message to the network equipment, wherein the configuration message comprises first identification information, an operation type and an operation object of a configuration operation to be executed.
The first identification information is used for identifying the configuration operation to be executed.
Optionally, the management device displays a fourth interface to the administrator, and the administrator inputs the identifier of the network device, the operation type and the operation object of the configuration operation, and the first identifier information for identifying the configuration operation to the management device through the fourth interface. Then, the management device obtains the input identifier of the network device, the first identifier information, the operation type of the configuration operation and the operation object, generates a configuration message including the first identifier information, the operation type of the configuration operation and the operation object, and sends the configuration message to the network device according to the identifier of the network device.
The detailed implementation process of the administrator inputting the identifier of the network device, the operation type and the operation object of the configuration operation into the management device and the management device generating the configuration message may refer to the related content in step 101, and will not be described in detail here.
In this step, a first parameter is added to the configuration packet, and the value of the first parameter is set to be equal to the first identification information, so that the generated configuration packet includes the first identification information.
For example, the management apparatus displays a fourth interface as shown in fig. 9, the fourth interface including a selection button 1 for selecting an operation type, a first input interface 2 for inputting first identification information, a fourth input interface 5 for inputting an operation object, and a fifth input interface 6 for inputting an identification of a network apparatus. The selection button 1 may be a pull-down button, and the selection button 1 includes at least one operation type of the configuration operation, and the operation type of the configuration operation includes post, create, and delete.
Referring to fig. 9, it is assumed that an administrator needs to modify the first piece of configuration information in the configuration database shown in table 1, where the first piece of configuration information is routing information of network traffic 1, and the administrator needs to modify the next hop information in the routing information from "11" to "192.168.10.3". At this time, the administrator selects the operation type of the configuration operation to be performed as the modification operation post, inputs the first identification information abc in the first input interface 2, inputs the operation object including the identification "11" of the configuration information to be modified and the first content "192.168.10.3" of the configuration information to be modified in the fourth input interface 5, and inputs the identification of the network device as the IP1 in the fifth input interface 6.
The management device may read, from the fourth interface shown in fig. 9, the operation type post of the configuration operation, the first identification information abc, the identification "11" of the configuration information to be modified, the first content "192.168.10.3" of the configuration information to be modified, and the identification of the network device as IP 1. The configuration message generated by the management device based on the read information may be represented as:
post http://{IP1}{Port}:/restconf/systemInfoconifig-id=abc&timeout=180
<routeInfo>
< Id info 11</Id info > (identification of configuration information to be modified)
< Next hop >192.168.10.3</Next hop > (first content of configuration information to be modified)
</routeInfo>
And if the config-id in the configuration message is the first parameter, the network equipment sends the configuration message again.
Step 202: the network equipment receives the configuration message, acquires the content in a configuration database of the network equipment to obtain first configuration information, correspondingly stores the first identification information and the first configuration information in the corresponding relation between the identification information and the configuration information, and executes configuration operation corresponding to the operation type on the configuration database according to the operation object.
In this step, the network device receives the configuration packet, copies the content in the configuration database to obtain the first configuration information stored in the configuration database, correspondingly stores the first identification information and the first configuration information in the corresponding relationship between the identification information and the configuration information, and executes the first configuration operation corresponding to the operation type on the configuration database according to the operation object.
The detailed implementation process of the network device performing the first configuration operation corresponding to the operation type on the configuration database may refer to relevant contents in step 102 in the embodiment shown in fig. 2.
Still referring to the example in step 201, the network device receives the following configuration message:
post http://{IP1}{Port}:/restconf/systemInfoconifig-id=abc&timeout=180
<routeInfo>
<Id info>11</Id info>
<Next hop>192.168.10.3</Next hop>
</routeInfo>
extracting the operation type as a modification operation post from the configuration message, extracting the operation object as an identifier '11' and a first content as '192.168.10.3' of the configuration information to be modified, and extracting a value abc of a first parameter config-id from the configuration message to obtain first identifier information. Copying the configuration database shown in table 1 to obtain first configuration information, and correspondingly storing the first identification information and the first configuration information in the corresponding relationship between the identification information and the configuration information. The network device obtains the configuration information to be modified from the configuration database shown in table 1 according to the identifier "11" of the configuration information to be modified, where the configuration information to be modified includes the identifier "11" and the second content "192.168.10.1", and then, the network device updates the second content "192.168.10.1" of the configuration information to be modified from the configuration database shown in table 1 to the first content "192.168.10.3", and the obtained configuration database is as shown in table 9.
After the network device executes the configuration operation on the configuration database, the network device operates according to the configuration database. In addition, if the administrator still needs to perform the configuration operation on the configuration database, the administrator may input the identification of the network device, the operation type and the operation object of the configuration operation, and the identification information for identifying the configuration operation into the management device, and then the management device and the network device re-perform the operations of steps 201 to 202.
Sometimes an administrator may need to restore the operational state of a network device to the operational state prior to performing a certain configuration operation, at which point the configuration information stored in the configuration database of the network device needs to be restored to the configuration information stored in the configuration database prior to performing the configuration operation. Among other things, to meet this requirement, it can be implemented as the following steps 203 to 204.
Step 203: the management device sends a recovery message to the network device, wherein the recovery message comprises first identification information.
Optionally, the management device generates a message including the first identification information and rollback identification information, where the rollback identification information is used to identify the type of the message as a recovery message.
When the management device generates a message, the management device may set a value of a first parameter in the message as first identification information, and add rollback identification information to the message, thereby generating a message including the first identification information and the rollback identification information.
Optionally, the rollback identification information is preset information or information agreed in advance by the management device and the network device.
Optionally, the management device may display a fifth interface to the administrator, and the administrator inputs the first identification information and the rollback identification information to the management device through the fifth interface.
For example, referring to the fifth interface shown in fig. 10, the fifth interface includes a first input interface 2 for inputting first identification information, a fourth input interface 5 for inputting an identification of a network device, rollback identification information "rollback", and an eighth input interface 9 for a user to confirm whether to input the rollback identification information. When the administrator confirms to input the rollback identification information, the eighth input interface 9 may select to input the rollback identification information (for example, input a value indicating that the administrator selects to input the rollback identification information), and input the first identification information abc in the first input interface 2 and the identification IP1 of the network device in the fourth input interface 5. The management device reads the first identification information abc, the rollback identification information "rollback" and the identification IP1 of the network device from the second interface, and a recovery message generated based on the read information may be represented as: "http:// { IP1} { Port }: restconf/systemlnfoconfiguration-id ═ abc & rollback", the recovery message is sent to the network device.
Step 204: the network equipment receives the recovery message, acquires first configuration information corresponding to the first identification information from the corresponding relation between the identification information and the configuration information, and updates the content of the configuration database into the first configuration information.
In this step, the network device extracts first identification information from the value of the first parameter from the recovery packet to extract rollback identification information from the recovery packet, and acquires, in response to triggering of the rollback identification information, first configuration information corresponding to the first identification information from a correspondence between the identification information and the configuration information, and updates the content of the configuration database to the first configuration information.
For example, from the recovery message "http:// { IP1} { Port },/restconf/systemInfo? Extracting a value abc of a first parameter contig-id from abc & rollback "to obtain first identification information, so as to extract rollback identification information" rollback "from the recovery message, under the trigger of the rollback identification information" rollback ", acquiring first configuration information corresponding to the first identification information abc from a corresponding relation between the identification information and the configuration information, wherein the first configuration information corresponding to the first identification information abc is the configuration information stored in the configuration database shown in table 1, updating the content of the configuration database shown in table 9 to the first configuration information, and obtaining the configuration database shown in table 1, thereby realizing recovery of the configuration database before executing the configuration operation identified by the first identification information abc.
In the embodiment of the application, a network device receives a configuration message sent by a management device, where the configuration message includes first identification information, an operation type and an operation object of a configuration operation to be executed; acquiring content in a configuration database to obtain first configuration information; and correspondingly storing the first identification information and the first configuration information in the corresponding relation between the identification information and the configuration information, and then executing the configuration operation corresponding to the operation type on the configuration database according to the operation object. When the administrator needs to restore the configuration database before executing the configuration operation, the administrator only needs to input the first identification information to the management device, and the management device sends a recovery message including the first identification information to the network device, so that the network device obtains the first configuration information corresponding to the first identification information from the corresponding relation between the identification information and the configuration information according to the first identification information in the recovery message, and updates the configuration database into the first configuration information, so that the changed content in the configuration database does not need to be edited, and the recovery efficiency is improved.
Referring to fig. 11, an embodiment of the present application provides a management apparatus 300 for a network device, where the apparatus 300 may be deployed in the network device in the embodiment described in fig. 1 or fig. 2, and includes:
a receiving unit 301, configured to receive a recovery packet sent by a management device, where the recovery packet includes first identification information, and the first identification information is used to identify a first configuration operation that has been performed on a configuration database of a network device;
a processing unit 302, configured to obtain an operation object and an operation type corresponding to the first identification information from a corresponding relationship between the identification information and the operation object and the operation type, where the operation type is a type of the first configuration operation, and the operation object is an object operated by the first configuration operation;
the processing unit 302 is further configured to restore the configuration database from a first state to a second state according to the operation object and the operation type, where the first state is a state in which the configuration database is located after the first configuration operation is performed, and the second state is a state in which the configuration database is located before the first configuration operation is performed.
Optionally, the detailed implementation process of the processing unit 302 for restoring the configuration database from the first state to the second state may refer to relevant contents in step 105 of the embodiment shown in fig. 2.
Optionally, the receiving unit 301 is further configured to receive a configuration packet sent by the management device, where the configuration packet includes the first identification information, the operation type of the first configuration operation, and an operation object;
the processing unit 302 is further configured to store the first identification information, the operation object, and the operation type in a corresponding relationship between the identification information and the operation object and the operation type, and execute a first configuration operation corresponding to the operation type on the configuration database according to the operation object.
Optionally, the processing unit 302 stores the first identification information, the corresponding relationship between the operation object and the operation type, and performs a detailed implementation process of the first configuration operation on the configuration database, which may refer to relevant contents in step 102 in the embodiment shown in fig. 2.
Optionally, the receiving unit 301 is further configured to receive a first commissioning request, where the first commissioning request includes first identification information;
a processing unit 302, configured to run according to a configuration database in a first state in a first commissioning period corresponding to a first configuration operation identified by first identification information, where a starting time of the first commissioning period is a time for executing the first configuration operation, and a time length of the first commissioning period is equal to a time threshold; and when the recovery message is received in the first commissioning period, acquiring the operation type and the operation object corresponding to the first identification information from the corresponding relation among the first identification information, the operation object and the operation type.
Optionally, the processing unit 302 tries to run a detailed implementation process of the configuration database in the first state, which may refer to relevant contents in step 103 of the embodiment shown in fig. 2.
Optionally, the receiving unit 301 is further configured to receive a second commissioning request, where the second commissioning request includes second identification information, where the second identification information is used to identify a second configuration operation, and the second configuration operation is an operation that has been performed on the configuration database by the apparatus 300;
the processing unit 302 is further configured to run according to the configuration database in a third state in a second commissioning period corresponding to the second configuration operation, where a starting time of the second commissioning period is a time for executing the second configuration operation, a time length of the second commissioning period is equal to a time threshold, and the third state is a state in which the configuration database is located after the second configuration operation is executed; when receiving unit 301 receives the confirmation message in the second commissioning period, the confirmation message includes the second identification information, and the record including the second identification information is deleted from the correspondence between the identification information, the operation object, and the operation type.
Optionally, the receiving unit 301 is further configured to receive a third commissioning request, where the third commissioning request includes third identification information, where the third identification information is used to identify a third configuration operation, and the third configuration operation is an operation that the apparatus 300 has performed on the configuration database;
the processing unit 302 is further configured to run according to the configuration database in a fourth state in a third commissioning period corresponding to the third configuration operation, where a starting time of the third commissioning period is a time for executing the third configuration operation, a time length of the third commissioning period is equal to a time threshold, and the fourth state is a state in which the configuration database is located after the third configuration operation is executed; when the receiving unit 301 does not receive the packet including the third identification information in the third commissioning period, the configuration database is restored from the fifth state to the fourth state according to the operation type and the operation object corresponding to the third configuration operation at the end of the third commissioning period, where the fifth state is a state in which the configuration database is located after the third configuration operation is performed.
Optionally, the processing unit 302 is configured to:
acquiring recovery information according to the operation object, wherein the recovery information is used for describing the content changed in a process configuration database for executing the first configuration operation in the configuration database;
and restoring the configuration database from the first state to the second state according to the operation type and the restoration information.
Optionally, the detailed implementation process of the processing unit 302 obtaining the recovery information and recovering the configuration database from the first state to the second state may refer to relevant contents in step 105 of the embodiment shown in fig. 2.
Optionally, the recovery packet is a packet including recovery identification information and the first identification information, and the recovery identification information is used to identify the type of the packet as the recovery packet.
In this embodiment of the present application, a receiving unit receives a recovery packet sent by a management device, where the recovery packet includes first identification information, and the first identification information is used to identify a first configuration operation that has been performed on a configuration database of a network device. The processing unit acquires an operation object and an operation type corresponding to the first identification information from the identification information and the corresponding relation between the operation object and the operation type, wherein the operation type is the type of the first configuration operation, and the operation object is an object operated by the first configuration operation. And the processing unit restores the configuration database from a first state to a second state according to the operation object and the operation type, wherein the first state is a state in which the configuration database is positioned after the first configuration operation is executed, and the second state is a state in which the configuration database is positioned before the first configuration operation is executed. Therefore, when the configuration database is restored, the administrator only needs to input the first identification information, the management equipment sends the restoration message containing the first identification information to the network equipment, and the processing unit automatically restores the configuration database in the second state according to the first identification information, so that the efficiency of restoring the configuration data is improved.
Referring to fig. 12, an embodiment of the present application provides a management apparatus 400 for a network device, where the apparatus 400 may be deployed in the network device in the embodiment described in fig. 1 or fig. 8, and includes:
a receiving unit 401, configured to receive a recovery packet sent by a management device, where the recovery packet includes first identification information, where the first identification information is used to identify first configuration information, where the first configuration information is configuration information stored in a configuration database of a network device before a first configuration operation is performed, and the first configuration operation is an operation that has been performed on the configuration database by the apparatus 400;
a processing unit 402, configured to obtain first configuration information corresponding to the first identification information from a corresponding relationship between the identification information and the configuration information; the contents of the configuration database are updated to the first configuration information.
Optionally, the detailed implementation process of the processing unit 402 obtaining the first configuration information and updating the content of the configuration database to the first configuration information may refer to the relevant content in step 204 of the embodiment shown in fig. 8.
Optionally, the receiving unit 401 is further configured to receive a configuration message sent by the management device, where the configuration message includes the first identification information, the operation type of the first configuration operation, and an operation object;
the processing unit 402 is further configured to obtain content in the configuration database, and obtain first configuration information; correspondingly storing the first identification information and the first configuration information in the corresponding relation between the identification information and the configuration information, and executing the first configuration operation corresponding to the operation type on the configuration database according to the operation object.
Optionally, the processing unit 402 stores the corresponding relationship between the first identification information and the first configuration information, and performs a detailed implementation process of the first configuration operation on the configuration database, as shown in the relevant content in step 202 of the embodiment shown in fig. 2.
In this embodiment of the present application, a receiving unit receives a recovery packet sent by a management device, where the recovery packet includes first identification information, where the first identification information is used to identify first configuration information, the first configuration information is configuration information stored in a configuration database of a network device before a first configuration operation is performed, and the first configuration operation is an operation that has been performed on the configuration database by the network device. The processing unit acquires first configuration information corresponding to the first identification information from the corresponding relation between the identification information and the configuration information. And the processing unit updates the content of the configuration database to the first configuration information. Therefore, when the configuration database before the first configuration operation is executed is restored, the administrator only needs to input the first identification information, the management device sends the restoration message including the first identification information to the network device, and the processing unit automatically restores the configuration database before the first configuration operation is executed according to the first identification information, so that the efficiency of restoring the configuration data is improved.
Referring to fig. 13, fig. 13 is a schematic diagram illustrating a management apparatus 500 of a network device according to an embodiment of the present application. The apparatus 500 comprises at least one processor 501, a bus system 502, a memory 503 and at least one transceiver 504.
The apparatus 500 is a hardware structure apparatus, and can be used to implement the functional modules in the apparatus 300 shown in fig. 11 or the functional modules in the apparatus 400 shown in fig. 12. For example, one skilled in the art may appreciate that the processing unit 302 in the apparatus 300 shown in fig. 11 or the processing unit 402 in the apparatus 400 shown in fig. 12 may be implemented by the at least one processor 501 calling code in the memory 503, and the receiving unit 301 in the apparatus 300 shown in fig. 11 or the receiving unit 401 in the apparatus 400 shown in fig. 12 may be implemented by the transceiver 504.
Optionally, the apparatus 500 may also be used to implement the functions of the collection and analysis device in any of the above embodiments.
Alternatively, the processor 501 may be a general processing unit (CPU), a Network Processor (NP), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits for controlling the execution of the program according to the present disclosure.
The bus system 502 may include a path that carries information between the components.
The transceiver 504 is used to communicate with other devices or communication networks.
The memory 503 may be a read-only memory (ROM) or other types of static storage devices that can store static information and instructions, a Random Access Memory (RAM) or other types of dynamic storage devices that can store information and instructions, an electrically erasable programmable read-only memory (EEPROM), a compact disc read-only memory (CD-ROM) or other optical disk storage, optical disk storage (including compact disc, laser disc, optical disc, digital versatile disc, blu-ray disc, etc.), magnetic disk storage media or other magnetic storage devices, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer, but is not limited to these. The memory may be self-contained and coupled to the processor via a bus. The memory may also be integral to the processor.
The memory 503 is used for storing application program codes for executing the scheme of the application, and the processor 501 controls the execution. The processor 501 is configured to execute application program code stored in the memory 503 to implement the functions of the method of the present patent.
In particular implementations, processor 501 may include one or more CPUs such as CPU0 and CPU1 in fig. 13 as an example.
In one implementation, the apparatus 500 may comprise a plurality of processors, such as the processor 501 and the processor 507 in fig. 13, for example. Each of these processors may be a single-core (single-CPU) processor or a multi-core (multi-CPU) processor. A processor herein may refer to one or more devices, circuits, and/or processing cores for processing data (e.g., computer program instructions).
It will be understood by those skilled in the art that all or part of the steps for implementing the above embodiments may be implemented by hardware, or may be implemented by a program instructing relevant hardware, where the program may be stored in a computer-readable storage medium, and the above-mentioned storage medium may be a read-only memory, a magnetic disk or an optical disk, etc.
The above description is only one embodiment of the present application and should not be taken as limiting the present application, and any modifications, equivalents, improvements, etc. made within the principle of the present application should be included in the protection scope of the present application.

Claims (20)

1. A method for managing a network device, the method comprising:
the method comprises the steps that network equipment receives a recovery message sent by management equipment, wherein the recovery message comprises first identification information, and the first identification information is used for identifying a first configuration operation executed on a configuration database of the network equipment;
the network device obtains an operation object and an operation type corresponding to the first identification information from a corresponding relation among identification information, the operation object and the operation type, wherein the operation type is the type of the first configuration operation, and the operation object is an object operated by the first configuration operation;
and the network equipment restores the configuration database from a first state to a second state according to the operation object and the operation type, wherein the first state is the state of the configuration database after the first configuration operation is executed, and the second state is the state of the configuration database before the first configuration operation is executed.
2. The method of claim 1, wherein before the network device receives the recovery packet sent by the management device, the method further comprises:
the network equipment receives a configuration message sent by the management equipment, wherein the configuration message comprises first identification information, an operation type and an operation object of the first configuration operation;
and the network equipment correspondingly stores the first identification information, the operation object and the operation type to the corresponding relation of the identification information, the operation object and the operation type, and executes the first configuration operation corresponding to the operation type on the configuration database according to the operation object.
3. The method of claim 2, wherein prior to performing the first configuration operation corresponding to the operation type on the configuration database according to the operation object, further comprising:
the network equipment receives a first commissioning request, wherein the first commissioning request comprises the first identification information, and operates according to the configuration database in the first state in a first commissioning period corresponding to a first configuration operation identified by the first identification information, the starting time of the first commissioning period is the time for executing the first configuration operation, and the time length of the first commissioning period is equal to a time threshold;
the network device obtains the operation type and the operation object corresponding to the first identification information from the corresponding relation between the first identification information, the operation object and the operation type, and the method comprises the following steps:
and when the network equipment receives the recovery message in the first commissioning period, acquiring the operation type and the operation object corresponding to the first identification information from the corresponding relation among the first identification information, the operation object and the operation type.
4. The method of any of claims 1 to 3, further comprising:
the network device receives a second commissioning request, wherein the second commissioning request includes second identification information, the second identification information is used for identifying a second configuration operation, and the second configuration operation is an operation that the network device has performed on the configuration database;
the network device operates according to a configuration database in a third state in a second commissioning period corresponding to the second configuration operation, wherein the starting time of the second commissioning period is the time for executing the second configuration operation, the time length of the second commissioning period is equal to a time length threshold, and the third state is the state of the configuration database after executing the second configuration operation;
and when the network equipment receives a confirmation message in the second commissioning period, the confirmation message comprises second identification information, and the record comprising the second identification information is deleted from the corresponding relation among the identification information, the operation object and the operation type.
5. The method of any of claims 1 to 4, further comprising:
the network device receives a third commissioning request, where the third commissioning request includes third identification information, where the third identification information is used to identify a third configuration operation, and the third configuration operation is an operation that the network device has performed on the configuration database;
the network device operates according to a configuration database in a fourth state in a third commissioning period corresponding to the third configuration operation, wherein the starting time of the third commissioning period is the time for executing the third configuration operation, the time length of the third commissioning period is equal to a time length threshold, and the fourth state is the state of the configuration database after executing the third configuration operation;
and when the network device does not receive the message including the third identification information in the third commissioning period, restoring the configuration database from a fifth state to the fourth state according to the operation type and the operation object corresponding to the third configuration operation when the third commissioning period is finished, wherein the fifth state is a state in which the configuration database is located after the third configuration operation is executed.
6. The method of any of claims 1 to 5, wherein the network device restoring the configuration database from the first state to the second state based on the operation object and the operation type comprises:
the network equipment acquires recovery information according to the operation object, wherein the recovery information is used for describing the content changed in the configuration database in the process of executing the first configuration operation on the configuration database;
and the network equipment restores the configuration database from the first state to the second state according to the operation type and the restoration information.
7. The method according to any of claims 1 to 6, wherein the recovery packet is a packet comprising recovery identification information and the first identification information, the recovery identification information identifying the type of the packet as a recovery packet.
8. A method for managing a network device, the method comprising:
a network device receives a recovery message sent by a management device, wherein the recovery message comprises first identification information, the first identification information is used for identifying first configuration information, the first configuration information is configuration information stored in a configuration database of the network device before a first configuration operation is executed, and the first configuration operation is an operation executed on the configuration database by the network device;
the network equipment acquires first configuration information corresponding to the first identification information from the corresponding relation between the identification information and the configuration information;
and the network equipment updates the content of the configuration database into the first configuration information.
9. The method of claim 8, wherein before the network device receives the recovery packet sent by the management device, the method further comprises:
the network equipment receives a configuration message sent by the management equipment, wherein the configuration message comprises first identification information, an operation type and an operation object of the first configuration operation;
the network equipment acquires the content in the configuration database to obtain the first configuration information;
and the network equipment correspondingly stores the first identification information and the first configuration information in the corresponding relation between the identification information and the configuration information, and executes the first configuration operation corresponding to the operation type on the configuration database according to the operation object.
10. An apparatus for managing a network device, the apparatus comprising:
a receiving unit, configured to receive a recovery packet sent by a management device, where the recovery packet includes first identification information, and the first identification information is used to identify a first configuration operation that has been executed on a configuration database of the network device;
a processing unit, configured to obtain an operation object and an operation type corresponding to the first identification information from a correspondence between identification information and the operation object and the operation type, where the operation type is a type of the first configuration operation, and the operation object is an object operated by the first configuration operation;
the processing unit is further configured to restore the configuration database from a first state to a second state according to the operation object and the operation type, where the first state is a state in which the configuration database is located after the first configuration operation is performed, and the second state is a state in which the configuration database is located before the first configuration operation is performed.
11. The apparatus of claim 10,
the receiving unit is further configured to receive a configuration packet sent by the management device, where the configuration packet includes first identification information, an operation type and an operation object of the first configuration operation;
the processing unit is further configured to store the first identification information, the operation object, and the operation type in a corresponding relationship between the identification information, the operation object, and the operation type, and execute the first configuration operation corresponding to the operation type on the configuration database according to the operation object.
12. The apparatus of claim 11,
the receiving unit is further configured to receive a first commissioning request, where the first commissioning request includes the first identification information;
the processing unit is configured to run according to the configuration database in the first state in a first commissioning period corresponding to a first configuration operation identified by the first identification information, where a start time of the first commissioning period is a time for executing the first configuration operation, and a time length of the first commissioning period is equal to a time threshold; and when the receiving unit receives the recovery message in the first commissioning period, acquiring the operation type and the operation object corresponding to the first identification information from the corresponding relation among the first identification information, the operation object and the operation type.
13. The apparatus of any one of claims 10 to 12,
the receiving unit is further configured to receive a second commissioning request, where the second commissioning request includes second identification information, and the second identification information is used to identify a second configuration operation, where the second configuration operation is an operation that has been performed on the configuration database by the apparatus;
the processing unit is further configured to run according to a configuration database in a third state in a second commissioning period corresponding to the second configuration operation, where a starting time of the second commissioning period is a time for executing the second configuration operation, a time length of the second commissioning period is equal to a time threshold, and the third state is a state in which the configuration database is located after the second configuration operation is executed; and when the receiving unit receives a confirmation message in the second commissioning period, the confirmation message comprises second identification information, and the record comprising the second identification information is deleted from the corresponding relation among the identification information, the operation object and the operation type.
14. The apparatus of any one of claims 10 to 13,
the receiving unit is further configured to receive a third commissioning request, where the third commissioning request includes third identification information, where the third identification information is used to identify a third configuration operation, and the third configuration operation is an operation that has been performed on the configuration database by the apparatus;
the processing unit is further configured to run according to a configuration database in a fourth state in a third commissioning period corresponding to the third configuration operation, where a starting time of the third commissioning period is a time for executing the third configuration operation, a time length of the third commissioning period is equal to a time threshold, and the fourth state is a state in which the configuration database is located after the third configuration operation is executed; and when the receiving unit does not receive the message including the third identification information in the third commissioning period, restoring the configuration database from a fifth state to the fourth state according to the operation type and the operation object corresponding to the third configuration operation at the end of the third commissioning period, where the fifth state is a state in which the configuration database is located after the third configuration operation is executed.
15. The apparatus according to any of claims 10 to 14, wherein the processing unit is configured to:
acquiring recovery information according to the operation object, wherein the recovery information is used for describing the changed content in the configuration database in the process of executing the first configuration operation on the configuration database;
and restoring the configuration database from the first state to the second state according to the operation type and the restoration information.
16. The apparatus according to any of claims 10 to 15, wherein the recovery packet is a packet comprising recovery identification information and the first identification information, the recovery identification information identifying the type of the packet as a recovery packet.
17. An apparatus for managing a network device, the apparatus comprising:
a receiving unit, configured to receive a recovery packet sent by a management device, where the recovery packet includes first identification information, where the first identification information is used to identify first configuration information, where the first configuration information is configuration information stored in a configuration database of the network device before a first configuration operation is performed, and the first configuration operation is an operation that has been performed on the configuration database by the apparatus;
the processing unit is used for acquiring first configuration information corresponding to the first identification information from the corresponding relation between the identification information and the configuration information; updating the contents of the configuration database to the first configuration information.
18. The apparatus of claim 17,
the receiving unit is further configured to receive a configuration packet sent by the management device, where the configuration packet includes first identification information, an operation type and an operation object of the first configuration operation;
the processing unit is further configured to obtain content in the configuration database to obtain the first configuration information; correspondingly storing the first identification information and the first configuration information in the corresponding relation between the identification information and the configuration information, and executing the first configuration operation corresponding to the operation type on the configuration database according to the operation object.
19. A management system of a network device, the system comprising a management device and a network device,
the management device is configured to send a recovery packet to the network device, where the recovery packet includes first identification information, and the first identification information is used to identify a first configuration operation that has been performed on a configuration database of the network device;
the network device is configured to obtain an operation object and an operation type corresponding to the first identifier information from a corresponding relationship between identifier information, the operation object, and the operation type, where the operation type is a type of the first configuration operation, and the operation object is an object operated by the first configuration operation; restoring the configuration database from a first state to a second state according to the operation object and the operation type, wherein the first state is a state in which the configuration database is positioned after the first configuration operation is executed, and the second state is a state in which the configuration database is positioned before the first configuration operation is executed.
20. A management system for network devices, the system comprising: a management device and a network device;
the management device is configured to send a recovery packet to the network device, where the recovery packet includes first identification information, where the first identification information is used to identify first configuration information, where the first configuration information is configuration information stored in a configuration database of the network device before a first configuration operation is performed, and the first configuration operation is an operation that has been performed on the configuration database by the network device;
the network device is used for acquiring first configuration information corresponding to the first identification information from the corresponding relation between the identification information and the configuration information; updating the contents of the configuration database to the first configuration information.
CN201911002749.9A 2019-10-21 2019-10-21 Method, device and system for managing network equipment Active CN112769585B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201911002749.9A CN112769585B (en) 2019-10-21 2019-10-21 Method, device and system for managing network equipment
PCT/CN2020/116938 WO2021077967A1 (en) 2019-10-21 2020-09-22 Network device management method, apparatus, and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911002749.9A CN112769585B (en) 2019-10-21 2019-10-21 Method, device and system for managing network equipment

Publications (2)

Publication Number Publication Date
CN112769585A true CN112769585A (en) 2021-05-07
CN112769585B CN112769585B (en) 2022-12-30

Family

ID=75620382

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911002749.9A Active CN112769585B (en) 2019-10-21 2019-10-21 Method, device and system for managing network equipment

Country Status (2)

Country Link
CN (1) CN112769585B (en)
WO (1) WO2021077967A1 (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020161863A1 (en) * 2001-04-30 2002-10-31 Mcguire Jacob Automated deployment and management of network devices
CN101136783A (en) * 2007-10-15 2008-03-05 中兴通讯股份有限公司 Backup, recovery method and apparatus for network management system to configure data
CN101547122A (en) * 2009-04-27 2009-09-30 深圳华为通信技术有限公司 Method, device and system for recovering terminal configuration
CN103973487A (en) * 2014-04-29 2014-08-06 上海上讯信息技术股份有限公司 Configuration backup system based on interactive scripts and configuration management method
CN104104547A (en) * 2014-07-24 2014-10-15 华为技术有限公司 Management method for network equipment configuration files, and network controller
CN104125089A (en) * 2013-04-28 2014-10-29 华为技术有限公司 Network transaction control method and execution method, and network controller and forwarding equipment

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100498796C (en) * 2007-09-30 2009-06-10 华为技术有限公司 Logic log generation method, database backup/ restoration method and system
CN101694637A (en) * 2009-11-06 2010-04-14 金蝶软件(中国)有限公司 Method and system for restoring database
US9348700B2 (en) * 2013-03-01 2016-05-24 Unisys Corporation Rollback counters for step records of a database
CN110347659B (en) * 2019-06-13 2023-03-28 创新先进技术有限公司 Data processing method and device and transaction data processing method and device

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020161863A1 (en) * 2001-04-30 2002-10-31 Mcguire Jacob Automated deployment and management of network devices
CN101136783A (en) * 2007-10-15 2008-03-05 中兴通讯股份有限公司 Backup, recovery method and apparatus for network management system to configure data
CN101547122A (en) * 2009-04-27 2009-09-30 深圳华为通信技术有限公司 Method, device and system for recovering terminal configuration
CN104125089A (en) * 2013-04-28 2014-10-29 华为技术有限公司 Network transaction control method and execution method, and network controller and forwarding equipment
CN103973487A (en) * 2014-04-29 2014-08-06 上海上讯信息技术股份有限公司 Configuration backup system based on interactive scripts and configuration management method
CN104104547A (en) * 2014-07-24 2014-10-15 华为技术有限公司 Management method for network equipment configuration files, and network controller

Also Published As

Publication number Publication date
WO2021077967A1 (en) 2021-04-29
CN112769585B (en) 2022-12-30

Similar Documents

Publication Publication Date Title
US7756953B2 (en) Method and apparatus for monitoring responses of configuration commands
EP3029566A1 (en) Application packaging device and method
US7870237B2 (en) Network configuration restoration method and system
CN110855460B (en) Scene recovery method, cloud platform and computer storage medium
CN106878072B (en) Message transmission method and device
CN110166299B (en) SDN controller configuration recovery method and device
CN107688489B (en) Method and system for scheduling tasks
CN109451078B (en) Transaction processing method and device under distributed architecture
WO2020232887A1 (en) Configuration modification method and apparatus for container application, and computer device and storage medium
CN110784549A (en) Network node selection method and device, first network node and storage medium
CN111082953B (en) Configuration method, device and related equipment
CN109361553B (en) Configuration rollback method and device
CN112769585B (en) Method, device and system for managing network equipment
CN110912725A (en) Configuration method and configuration device of OpenFlow virtual switch
CN114422576B (en) Session cleaning method and device, computer equipment and readable storage medium
CN114356357A (en) Mirror image file processing method and device and electronic equipment
CN115378815A (en) Data recovery method, device, network equipment and storage medium
CN111880949B (en) Service information processing method, system, device, server and terminal
CN110913416B (en) Terminal, networking method thereof and computer-readable storage medium
JP2001142810A (en) Device and method for judging terminal equipment action in directory server
CN111090853B (en) Account management method, system, electronic equipment and storage medium
US20050207347A1 (en) Provisioning control apparatus
CN112087337A (en) Switch configuration method and switch configuration system
CN113014615A (en) Data synchronization method, device and system
WO2024066658A1 (en) Travel code reporting method and device, system, storage medium, and electronic device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant