CN114389949A - Route upgrading method, electronic equipment and storage medium - Google Patents
Route upgrading method, electronic equipment and storage medium Download PDFInfo
- Publication number
- CN114389949A CN114389949A CN202210068288.0A CN202210068288A CN114389949A CN 114389949 A CN114389949 A CN 114389949A CN 202210068288 A CN202210068288 A CN 202210068288A CN 114389949 A CN114389949 A CN 114389949A
- Authority
- CN
- China
- Prior art keywords
- backup
- routing
- upgrading
- network device
- routing table
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 89
- 230000008569 process Effects 0.000 claims abstract description 42
- 238000004891 communication Methods 0.000 claims abstract description 9
- 238000004590 computer program Methods 0.000 claims description 6
- 230000005540 biological transmission Effects 0.000 abstract description 6
- 238000012217 deletion Methods 0.000 description 9
- 241000029811 Equus burchellii quagga Species 0.000 description 8
- 230000037430 deletion Effects 0.000 description 8
- 238000012545 processing Methods 0.000 description 8
- 230000006855 networking Effects 0.000 description 5
- 230000003068 static effect Effects 0.000 description 5
- 230000009471 action Effects 0.000 description 3
- 238000010586 diagram Methods 0.000 description 3
- 239000003999 initiator Substances 0.000 description 3
- 230000003993 interaction Effects 0.000 description 3
- 238000013461 design Methods 0.000 description 2
- 230000006870 function Effects 0.000 description 2
- 239000000463 material Substances 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 230000002093 peripheral effect Effects 0.000 description 2
- 238000005516 engineering process Methods 0.000 description 1
- 238000012544 monitoring process Methods 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 230000000737 periodic effect Effects 0.000 description 1
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L45/00—Routing or path finding of packets in data switching networks
- H04L45/56—Routing software
- H04L45/563—Software download or update
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/08—Configuration management of networks or network elements
- H04L41/0803—Configuration setting
- H04L41/0813—Configuration setting characterised by the conditions triggering a change of settings
- H04L41/082—Configuration setting characterised by the conditions triggering a change of settings the condition being updates or upgrades of network functionality
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
The embodiment of the application relates to the technical field of communication transmission and discloses a route upgrading method, electronic equipment and a storage medium. The route upgrading method is applied to network equipment and comprises the following steps: receiving a backup instruction of a central controller, and backing up a current main routing table according to the backup instruction; receiving an upgrading instruction sent by a central controller under the condition that all network equipment is successfully backed up, wherein the central controller is in communication connection with all the network equipment; upgrading the routing software according to the upgrading instruction, and routing according to the backup main routing table in the upgrading process of the routing software; and after receiving a switching instruction sent by the central controller under the condition that each network device is successfully upgraded, routing according to a routing table generated by the upgraded routing software. In the embodiment of the application, the problems of interruption of service flow and the like caused by route loss due to processes such as restarting and the like when the dynamic routing software is updated are avoided, and the dynamic routing software of the network equipment is smoothly updated.
Description
Technical Field
The present invention relates to the field of communication transmission technologies, and in particular, to a method for upgrading a route, an electronic device, and a storage medium.
Background
In a Network built based on a Software Defined Wide Area Network (SD-WAN), a plurality of Network devices in an enterprise can realize the action of independently performing dynamic route learning by using dynamic route Software.
When dynamic routing software is upgraded/replaced, there is a risk that routing information of the network device is wrong, for example, data deletion, data input, data update, and the like may exist in the upgrading process, which may cause loss or mistake of routing information, affect the routing action in operation, and also may cause routing interruption of service traffic, for example, in a process of restarting after the upgrading is completed. If an enterprise has a networking of multiple network devices and needs to upgrade/replace dynamic routing software, multiple errors or interruptions of business traffic of the enterprise can be caused.
Disclosure of Invention
The embodiment of the present application mainly aims to provide a route upgrading method, an electronic device, and a storage medium, which are used for ensuring normal operation of service traffic and avoiding situations such as traffic errors or interruption.
In order to achieve the above object, an embodiment of the present application provides a method for upgrading a route, which is applied to a network device, and includes: receiving a backup instruction of a central controller, and backing up a current main routing table according to the backup instruction; receiving an upgrading instruction sent by a central controller under the condition that all network equipment is successfully backed up, wherein the central controller is in communication connection with all the network equipment; upgrading the routing software according to the upgrading instruction, and routing according to the backup main routing table in the upgrading process of the routing software; and after receiving a switching instruction sent by the central controller under the condition that each network device is successfully upgraded, routing according to a routing table generated by the upgraded routing software.
In order to achieve the above object, an embodiment of the present application further provides a method for upgrading a route, which is applied to a central controller, and includes: sending a backup instruction to the network equipment, so that the network equipment can back up the current main routing table according to the backup instruction; the method comprises the steps of obtaining backup states of all network devices, sending upgrading instructions to all the network devices under the condition that all the network devices are successfully backed up, enabling the network devices to upgrade routing software according to the upgrading instructions and conducting routing according to a backed-up main routing table in the upgrading process of the routing software; acquiring the upgrading state of each network device, and sending a switching instruction to each network device under the condition that each network device is successfully upgraded; and the switching instruction is used for indicating the network equipment to carry out routing according to a routing table generated by the upgraded routing software.
In order to achieve the above object, an embodiment of the present application further provides an electronic device, including: at least one processor; and a memory communicatively coupled to the at least one processor; wherein the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the above-described route upgrade method applied to the network device or to perform the route upgrade method applied to the central controller.
In order to achieve the above object, an embodiment of the present application further provides a computer-readable storage medium, which stores a computer program, and the computer program, when executed by a processor, implements the above route upgrade method applied to a network device, or can implement the above route upgrade method applied to a central controller.
In the application, the route upgrading is carried out by receiving and executing the instruction issued by the central controller, and the route upgrading method comprises the steps of informing all devices to backup the dynamic route table into the static route table before upgrading, so that the enterprise service flow is switched to the route table after backup in the upgrading process. The upgrade process does not affect the transmission of the service flow, the original service is routed according to the backup routing table, and the routing software is switched into the routing table generated by the upgraded routing software after finishing the upgrade, so that the problems of service flow interruption and the like caused by route loss due to processes such as restart and the like when the dynamic routing software is upgraded are avoided, and the smooth upgrade of the dynamic routing software of the network equipment is realized. In addition, the central controller determines whether to advance the next step according to the state fed back by each network device in each upgrading stage, so that the upgrading progress of each network device is kept consistent.
Drawings
FIG. 1 is a flow chart of a method for route upgrade provided according to an embodiment of the present application;
FIG. 2 is a schematic diagram of a method for route upgrade provided in accordance with an embodiment of the present application;
FIG. 3 is a flow chart of a method for route upgrade provided in accordance with another embodiment of the present application;
fig. 4 is a schematic diagram of a route upgrade method provided in accordance with another embodiment of the present application;
FIG. 5 is a schematic diagram of an electronic device provided in accordance with an embodiment of the present application.
Detailed Description
To make the objects, technical solutions and advantages of the embodiments of the present application clearer, the embodiments of the present application will be described in detail below with reference to the accompanying drawings. However, it will be appreciated by those of ordinary skill in the art that in the examples of the present application, numerous technical details are set forth in order to provide a better understanding of the present application. However, the technical solution claimed in the present application can be implemented without these technical details and various changes and modifications based on the following embodiments. The following embodiments are divided for convenience of description, and should not constitute any limitation to the specific implementation manner of the present application, and the embodiments may be mutually incorporated and referred to without contradiction.
The terms "first" and "second" in the embodiments of the present application are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one such feature. In the description of the present application, the terms "comprise" and "have", as well as any variations thereof, are intended to cover a non-exclusive inclusion. For example, a system, product or apparatus that comprises a list of elements or components is not limited to only those elements or components but may alternatively include other elements or components not expressly listed or inherent to such product or apparatus. In the description of the present application, "plurality" means at least two, e.g., two, three, etc., unless explicitly specifically limited otherwise.
The quagga/frr is dynamic Routing software for implementing Routing protocols such as RIP (Routing Information Protocol), OSPF (Open Shortest Path First), BGP (Border Gateway Protocol), and the like. Based on a Network established by an SD-WAN (Software Defined Wide Area Network, which realizes interconnection networking), by using quagga/frr Software, automatic dynamic route learning of a plurality of Network devices of an enterprise is realized, and networking is completed. However, upgrading/replacing the dynamic routing software may cause the route from other devices to the device to be lost, thereby causing service traffic to be interrupted; if an enterprise has multiple networking devices needing to update/replace dynamic routing software, the mode of updating one by one can cause the business flow of the enterprise to be interrupted for multiple times.
One embodiment of the invention relates to a route upgrading method. The specific flow is shown in fig. 1, applied to a network device.
And 102, receiving an upgrading instruction sent by the central controller under the condition that the backup of each network device is successful, wherein the central controller is in communication connection with each network device.
And 103, upgrading the routing software according to the upgrading instruction, and routing according to the backup main routing table in the upgrading process of the routing software.
And step 104, after receiving a switching instruction sent by the central controller under the condition that each network device is successfully upgraded, performing routing according to a routing table generated by the upgraded routing software.
The following describes implementation details of the route upgrade method of the present embodiment in detail, and the following is only provided for easy understanding and is not necessary for implementing the present embodiment.
In step 101, a backup instruction of the central controller is received, and the current master routing table is backed up according to the backup instruction. That is, the central controller can determine the progress of the upgrade process, and the network device performs a preliminary backup after receiving an instruction of the central controller. The backup result is used for routing the data to be transmitted when the route upgrade is executed. Optionally, when the central controller determines that all the network devices to be upgraded are normally connected to the central processor, or all the network devices to be upgraded are online, the process in this embodiment is started again, so as to avoid the influence on the upgrading efficiency due to external problems such as communication connection.
In one example, the priority of the backed-up master routing table is higher than the priority of the current master routing table. Under the condition that the priority of the main routing table after backup is higher than that of the current main routing table, after the main routing table after backup is generated, due to the priority, the routing of the data can be realized by the main routing table after backup, that is, the original main routing table (the current main routing table) is automatically switched to the main routing table after backup, and the routing of the data is realized by the information in the main routing table after backup.
In one example, after backing up the current primary routing table according to the backup instruction, the method further includes: and if a backup deleting instruction sent by the central controller under the condition that the backup fails in each network device is received, deleting the backed-up main routing table data according to the backup deleting instruction, and finishing the upgrading. That is, since the number of upgrading devices is not limited, and multiple devices (or a communication network formed by multiple devices) are allowed to be upgraded together, when multiple network devices are backed up together, a situation that partial devices are not successfully backed up may occur, and at this time, the backed-up data needs to be deleted; for example, parameters in the network device which has been successfully backed up and failed in backup are deleted, so that the next time of performing backup again is not affected by the data which has failed in the backup; meanwhile, the backup data are cleared, and routing errors caused by the switching of the route part after the backup is finished can be avoided.
In one example, after backing up the current primary routing table according to the backup instruction, the method further includes: sending a backup state to the central controller, wherein the backup state comprises a backup success or a backup failure; or receiving and replying a first query message sent by the central controller, wherein the first query message is used for querying the backup state of the network equipment; after the routing software is upgraded according to the upgrading instruction, the method further comprises the following steps: determining an upgrading state based on the target IP number of the dynamic route generated after the route upgrading software is completed; sending an upgrading state to the central controller, wherein the upgrading state comprises upgrading success or upgrading failure; or receiving and replying a second query message sent by the central controller, wherein the second query message is used for querying the upgrading state of the network equipment. That is, the information interaction between the central controller and each network device can request the network device to make an active request through the central processor, and each network device feeds back the active request to the central processor; or each network device actively sends the state to the central processing unit, wherein the state comprises a backup state and an upgrading state. The central processing unit can send a first query message to the network equipment for querying the backup state of the network; a second query message may be sent to the network device for querying an upgrade status of the network. Namely, the information interaction between the central processing unit and the network device is not limited to be initiated by one party, and both parties can be used as initiators of the information interaction, so that a way for state feedback/acquisition is added.
For the determination of the upgrade state, the upgrade state may be determined by the number of destination IPs of the dynamic route after the upgrade is completed by the routing software, for example, when the number of destination IPs of the dynamic route is the same as the number of destination IPs of the original main routing table, or the number of destination IPs of the backup main routing table is the same, it is determined that the upgrade of the routing software is successful. When the upgrade state is fed back, the network device can directly feed back the upgrade state, that is, the upgrade is successful or failed, or the network device can feed back the number of the target IPs of the dynamic route, the number of the target IPs of the original main routing table or the backup main routing table, so as to be used for the central processing unit to perform judgment processing, so as to reduce the operation pressure of the network device; further, the network device may receive and reply a third query message sent by the central controller, where the third query message is used to query the number of the destination IPs of the dynamic route, the number of the destination IPs of the original master route table or the backup master route table, so as to be determined and processed by the central processor.
In addition, if the number of the target IP of the dynamic route after the upgrade is finished is different from that of the original main routing table or from that of the target IP of the backup main routing table, entering a periodic check, and if the number of the target IP of the dynamic route after the upgrade is finished is not the same as that of the target IP of the backup main routing table, failing to upgrade the feedback routing software within a second time threshold or other preset time.
In step 102, an upgrade instruction sent by the central controller when each network device is backed up successfully is received, and the central controller is in communication connection with each network device. When the central processing unit obtains the information that each network device is successfully backed up, an upgrading instruction is issued, namely each network device is pushed to enter the upgrading of the next stage.
In step 103, the routing software is upgraded according to the upgrade instruction, and in the process of upgrading the routing software, routing is performed according to the backup master routing table.
And finishing route upgrading according to an upgrading instruction sent by the central controller, wherein because the backup is finished in the previous stage, the route is carried out by using the backup main route table while the upgrading is executed, so that the route process is not influenced by the upgrading operation. Specifically, the situations of route data replacement, loss, incompleteness and the like may occur in the process of route upgrade, which is not enough to ensure that the process of data routing is the same as the non-upgrade time period, so that the original main routing table cannot meet the routing requirement in the process of route upgrade; however, in the embodiment, a backup process exists before the upgrade, and the backup main routing table is used for routing in the upgrade, so that the data routing requirement can be met while the routing upgrade is completed.
In step 104, after receiving a switching instruction sent by the central controller when each network device is successfully upgraded, routing according to a routing table generated by the upgraded routing software. That is, after the route upgrade is completed, the backup master routing table is switched to the routing table generated by the upgraded routing software for routing.
In one example, after receiving a switching instruction sent by a central controller when each network device is successfully upgraded, routing according to a routing table generated by upgraded routing software includes: after receiving a switching instruction sent by a central controller under the condition that each network device is successfully upgraded, deleting a backup main routing table according to the switching instruction; and after the backup main routing table is deleted, switching to a routing table generated by the upgraded routing software for routing. That is, the switching of the routing table may be realized by the action of deleting the backup main routing table, and after deleting the backup main routing table, the routing table generated by the upgraded routing software is autonomously searched for routing. For example, when the priority of the backup master routing table is higher than the original master routing table and higher than the routing table generated by the upgraded routing software, the backup master routing table with the high priority is deleted and the backup master routing table can be autonomously switched to the new routing table for routing when the routing software is successfully upgraded and the new routing table is generated.
In addition, after the deletion operation is finished, the network device may feed back a deletion status to the central controller, for example, the deletion is successful or the deletion is failed; and if the deletion fails, receiving a re-deletion instruction issued by the central controller until the deletion succeeds. Wherein, the deleting operation can also add a time threshold as one of the criteria for judging success or failure.
In one example, the backup is successful, further comprising: completing backup within a preset first time threshold; the upgrading is successful, and the method further comprises the following steps: and completing upgrading within a preset second time threshold. That is, a time threshold is set for the backup and upgrade processes, the backup/upgrade is successful only after the backup/upgrade is completed within the corresponding time, and the backup/upgrade is determined to be failed if the corresponding time threshold is exceeded; the time used in the backup and upgrade processes is restricted, the situation that the conclusion cannot be reached under the upgrade or backup result even if the time is long is avoided, and the execution efficiency is improved. That is, the judgment criterion for the completion of the execution of the backup or upgrade state is included in the preset time, so as to ensure the execution efficiency of the scheme. It is understood that the relationship between the first time threshold and the second time threshold is not limited, and may be the same or different, allowing for adjustment according to actual requirements.
For ease of understanding, the above embodiments are described below in terms of a practical implementation. It is to be understood that this is by way of illustration only and is not to be construed as a material limitation to the embodiments described above. Reference may be made to fig. 2, including but not limited to:
s1, the central controller informs all network devices of the enterprise to perform a first upgrade stage: and backing up the route.
And S2, the device receives the backup routing instruction of the central controller, copies the current main routing table of the device into the policy routing table with higher priority (namely the backup main routing table), and automatically switches the traffic of the device to the policy routing table with higher priority. Because the policy routing table is static and is not influenced by the updating of routing software, the service flow is not interrupted.
And S3, after all the devices finish the backup routing operation, reporting the backup result to the central controller, and after the central controller receives the message that all the devices are normally backed up, informing all the devices to perform the second stage: the routing software is replaced. If the network device is not successfully backed up in the first stage or the central controller does not receive the backup routing result reported by the device within the specified time, the central controller will not notify each network device to perform the second stage.
S4, after receiving the command of replacing the routing software from the central controller, all devices of the enterprise start upgrading the routing software, and can also replace the routing software, taking replacing the quga software with frr software as an example: the frr software is installed firstly, then the configuration file of the quagga is copied to a configuration file directory of the frr, and as the frr and the monitoring port used by the quaga component are the same, the quagga component of the enterprise needs to be closed firstly, and then the frr software is started.
S5, after replacing the quga software of the enterprise with frr software, the frr software automatically generates and learns the dynamic route, and after the frr is upgraded, whether the dynamic route generated by the frr software is normal is checked: and comparing the number of the target IP sections of the dynamic route of the generated main routing table to determine whether the number of the target IP sections is consistent with the number of the target IP sections of the strategy routing table copied in the first stage, if so, determining that the upgrade is successful, and if not, determining that the upgrade is failed. And each network device judges the upgrading result and reports the upgrading result to the central controller. If the route software is upgraded, the steps of replacing different software cannot be generated, and only the independent upgrade is needed.
S6, after receiving the message that all network devices are upgraded normally, the central controller notifies all network devices to perform the third stage: the backup route is deleted. If the network equipment is not successfully upgraded in the second stage or the central controller does not receive the upgrade result reported by the network equipment within the specified time, the central controller will not inform all the equipment to perform the third stage, the traffic will continue to run in the policy routing table backed up in the first stage, and the traffic will not be affected.
And S7, after receiving the command of deleting the backup routing from the central controller, all network devices of the enterprise start to delete the backup routing, after deleting the complete routing table, the flow automatically runs the main routing table generated after upgrading again, all the network devices delete the backup routing table, and the deletion result is reported to the central controller.
And S8, after receiving the message that all the network devices delete the backup route normally, the central controller ends the upgrading process and sets the upgrading result as successful.
In this embodiment, the route upgrade is performed by receiving and executing an instruction issued by the central controller, including notifying all devices to backup the dynamic routing table into the static routing table before the upgrade, so that the enterprise service traffic is switched to the route table after the backup in the upgrade process. The upgrade process does not affect the transmission of the service flow, the original service is routed according to the backup routing table, and the routing software is switched into the routing table generated by the upgraded routing software after finishing the upgrade, so that the problems of service flow interruption and the like caused by route loss due to processes such as restart and the like when the dynamic routing software is upgraded are avoided, and the smooth upgrade of the dynamic routing software of the network equipment is realized. In addition, the central controller determines whether to advance the next step according to the state fed back by each network device in each upgrading stage, so that the upgrading progress of each network device is kept consistent.
The steps of the above methods are divided for clarity, and the implementation may be combined into one step or split some steps, and the steps are divided into multiple steps, so long as the same logical relationship is included, which are all within the protection scope of the present patent; it is within the scope of the patent to add insignificant modifications to the algorithms or processes or to introduce insignificant design changes to the core design without changing the algorithms or processes.
One embodiment of the invention relates to a route upgrading method. The specific flow is shown in fig. 3, which is applied to the central controller.
Step 201, sending a backup instruction to the network device for the network device to backup the current main routing table according to the backup instruction;
For ease of understanding, the above embodiments are described below in terms of a practical implementation. It is to be understood that this is by way of illustration only and is not to be construed as a material limitation to the embodiments described above.
Beijing headquarters of Enterprise 1 and Xiamen branch company establish long connection with central controller through SD-WAN (enterprise networking Equipment has CPE (Customer Premise Equipment), POP (Point of Presence), CPE, POP and central controller, receive, report message, CPE establishes tunnel with POP, POP-POP, and generate dynamic route through dynamic route software, realize interconnection between the equipments (each Equipment has route to any other Equipment). refer to the structure of FIG. 4, the concrete upgrading process includes but is not limited to:
a1, the central controller judges whether all network devices of the enterprise are normally connected with the central controller, the network devices are normally connected, the state is on-line, and the controller starts the upgrading process when all the devices of the enterprise are on-line.
A2, the central controller sends backup instructions to all CPE and POP devices of enterprise 1 to realize the backup of the main routing table.
A3, CPE and POP equipment receive the backup routing message, firstly check whether a routing table with the highest priority in the ip rule, such as table252, exists or residual data exists, delete the routing table [ ip rule delta table252 ] if existing, and clear the routing table [ ip route flush table252 ] before the backup routing operation, so as to ensure that the routing table has no routes which are residual before. Backing up the main routing table, namely, checking whether the main table routing is consistent with the strategy routing table (namely, the backed-up main routing table) after all the routes are copied by copying the destination IP address section and the next hop of the main routing table to the routing table 252; and confirming whether the destination network segments of the main table routes exist in the strategy routing table or not, if not, the backup operation is successful, otherwise, the backup is considered to be failed, and adding the routing table252 after the backup is successful, wherein the priority of the routing table252 is higher than that of the main routing table (a linux system determines the priority according to the id of the routing table, the id of the main routing table is generally 254, and the priority is lower than that of the routing table 252), and after the routing table252 is added, all the traffic is switched to the routing table 252. The policy routing table (backup routing table) id is set to 252 because the traffic that originally went through the main routing table should go through the policy routing table, but should not affect the traffic to go through other policy routing tables.
And after the A4, the CPE and the POP equipment respectively complete the backup operation, respectively reporting the result of the backup operation to the central controller.
A5, after receiving the backup success message of all the devices, the central controller judges that the first stage [ backup route ] is successful, and can perform the second stage [ replace dynamic routing software ], and informs all the devices to replace dynamic routing software. If the equipment backup routing fails in the first stage, the central controller informs all the network equipment to delete the backup routing tables and restore the state before upgrading, and the upgrading is finished in the current round, and the upgrading result is failure.
And the A6, the CPE and the POP equipment receive the message (replacing the dynamic routing software) sent by the central controller and execute the operation of replacing the dynamic routing software. Taking the example of replacing from quagga to frr, the flow of the replacement routing software of the devices of CPE and POP is different:
the CPE device executes the steps of: and installing dynamic routing software frr, and copying the configuration file of the original routing software quadrga to a configuration file directory of the frr software. Since the snoop ports of both pieces of software are identical, the software quad is shut down first, and then frr is started.
The POP equipment executes the following steps: routing software is on POP equipment, and each enterprise operates in different processes. When the routing software is replaced for the first time, the dynamic routing software frr is installed firstly, and then the routing software of the current enterprise is replaced: the profiles under this enterprise ID directory for quagga are copied to the enterprise ID profile directory for frr software. The kills of the enterprise's quagga process, and then starts the frr process of the enterprise, the processes of other enterprises cannot be operated, and the stop of the process can not be made directly.
A7, closing the quagga software (CPE)/closing the quagga process (POP) of the enterprise, the dynamic route learned by the original main routing table will disappear, but the flow goes through the backup strategy routing table at the moment, so the flow interruption will not be caused. After starting the frr process, the frr automatically learns the dynamic routing to the main table again, checks whether the destination IP address field of the dynamic routing table of the main table is consistent with the backup policy routing table every preset time (for example, 5s), indicates that the switching of the routing software is successful, reports success information to the central controller, and reports inconsistency, periodically checks, sets the longest check time threshold, for example, checks for 90s at the longest time, reports that the destination IP address field of the main routing table is inconsistent with the backup policy routing table after 90s, and reports that the replacement routing software fails.
A8, after receiving the message that all devices successfully replace the routing software, the central controller determines that the second stage [ replace the routing software ] is successful, and can perform the third stage [ delete the backup routing table ], and informs all the devices to delete the backup routing table. If the second stage has the failure of replacing the routing software by the equipment, the manual intervention is needed, after the reason of the failure is checked, the routing software of the equipment is replaced normally, and then all network elements are informed to delete the backup routing table in the third stage through the central controller.
The a9, the CPE and the POP device receive the message (delete backup routing table), delete the routing table252 first, then clear all the routes in the routing table252, and switch the traffic back to the main routing table. And each device reports the operation result of deleting the backup routing table to the central controller.
And A10, after receiving the successful message of deleting the routing table of all the devices, the central controller judges that the third stage (deleting the backup routing table) is successful, finishes upgrading all the devices of the enterprise, and finishes upgrading until the upgrading result is successful.
In this embodiment, the central processing unit performs route upgrade on an instruction issued to the network device, including notifying all devices to backup the dynamic routing table into the static routing table before upgrade, so as to switch the enterprise service traffic to the routing table after backup in the upgrade process. The upgrade process does not affect the transmission of the service flow, the original service is routed according to the backup routing table, and the routing software is switched into the routing table generated by the upgraded routing software after finishing the upgrade, so that the problems of service flow interruption and the like caused by route loss due to processes such as restart and the like when the dynamic routing software is upgraded are avoided, and the smooth upgrade of the dynamic routing software of the network equipment is realized. And the central controller can determine whether to advance the next step according to the state fed back by each network device in each upgrading stage, so that the upgrading progress of each network device is kept consistent. In the embodiment, the central controller controls the whole upgrading process and informs all network devices to back up the dynamic routing table into the static routing table with high priority before upgrading, so that the enterprise service flow is upgraded after being switched to the running and backup routing table, the problem of service flow interruption caused by route loss when dynamic routing software is upgraded is solved, and the dynamic routing software of the network devices is smoothly upgraded.
One embodiment of the invention relates to an electronic device, as shown in FIG. 5, comprising at least one processor 301; and a memory 302 communicatively coupled to the at least one processor 301; wherein the memory 302 stores instructions executable by the at least one processor 301, the instructions being executable by the at least one processor 301 to enable the at least one processor 301 to perform the above-described route upgrade method applied to a network device or to perform the route upgrade method applied to a central controller.
Where the memory and processor are connected by a bus, the bus may comprise any number of interconnected buses and bridges, the buses connecting together one or more of the various circuits of the processor and the memory. The bus may also connect various other circuits such as peripherals, voltage regulators, power management circuits, and the like, which are well known in the art, and therefore, will not be described any further herein. A bus interface provides an interface between the bus and the transceiver. The transceiver may be one element or a plurality of elements, such as a plurality of receivers and transmitters, providing a means for communicating with various other apparatus over a transmission medium. The data processed by the processor is transmitted over a wireless medium via an antenna, which further receives the data and transmits the data to the processor.
The processor is responsible for managing the bus and general processing and may also provide various functions including timing, peripheral interfaces, voltage regulation, power management, and other control functions. And the memory may be used to store data used by the processor in performing operations.
One embodiment of the present invention relates to a computer-readable storage medium storing a computer program. The computer program realizes the above-described method embodiments when executed by a processor.
That is, as can be understood by those skilled in the art, all or part of the steps in the method for implementing the embodiments described above may be implemented by a program instructing related hardware, where the program is stored in a storage medium and includes several instructions to enable a device (which may be a single chip, a chip, or the like) or a processor (processor) to execute all or part of the steps of the method described in the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
It will be understood by those of ordinary skill in the art that the foregoing embodiments are specific examples for carrying out the invention, and that various changes in form and details may be made therein without departing from the spirit and scope of the invention in practice.
Claims (10)
1. A route upgrading method is applied to network equipment and comprises the following steps:
receiving a backup instruction of a central controller, and backing up a current main routing table according to the backup instruction;
receiving an upgrade instruction sent by the central controller under the condition that the backup of each network device is successful, wherein the central controller is in communication connection with each network device;
upgrading the routing software according to the upgrading instruction, and routing according to the backup main routing table in the upgrading process of the routing software;
and after receiving a switching instruction sent by the central controller under the condition that each network device is upgraded successfully, routing according to a routing table generated by the upgraded routing software.
2. The route upgrade method according to claim 1, wherein the priority of the backup master routing table is higher than the priority of the current master routing table.
3. The method for upgrading a route according to claim 2, wherein after receiving a switching instruction sent by the central controller when each of the network devices is upgraded successfully, performing routing according to a routing table generated by upgraded routing software, includes:
after receiving a switching instruction sent by the central controller under the condition that each network device is upgraded successfully, deleting the backed-up main routing table according to the switching instruction;
and after the backup main routing table is deleted, switching to the routing table generated by the upgraded routing software for routing.
4. The route upgrade method according to claim 1, wherein after the backing up the current primary routing table according to the backup instruction, the method further comprises:
and if a backup deleting instruction sent by the central controller under the condition that the backup fails in each network device is received, deleting the backed-up main routing table data according to the backup deleting instruction, and finishing the upgrading.
5. The route upgrade method according to claim 1, wherein after the backing up the current primary routing table according to the backup instruction, the method further comprises:
sending a backup state to the central controller, wherein the backup state comprises a backup success or a backup failure;
or receiving and replying a first query message sent by the central controller, wherein the first query message is used for querying the backup state of the network equipment;
after the routing software is upgraded according to the upgrading instruction, the method further comprises the following steps:
determining an upgrading state based on the target IP number of the dynamic route generated after the route upgrading software is completed;
sending the upgrading state to the central controller, wherein the upgrading state comprises upgrading success or upgrading failure;
or receiving and replying a second query message sent by the central controller, wherein the second query message is used for querying the upgrade state of the network equipment.
6. The route upgrade method according to any one of claims 1 to 5, wherein the backup is successful, further comprising: completing backup within a preset first time threshold;
the upgrading is successful, and the method further comprises the following steps: and completing upgrading within a preset second time threshold.
7. A route upgrading method is applied to a central controller and is characterized by comprising the following steps:
sending a backup instruction to network equipment, so that the network equipment can back up a current main routing table according to the backup instruction;
obtaining the backup state of each network device, sending an upgrading instruction to each network device under the condition that each network device is successfully backed up, so that the network devices can upgrade routing software according to the upgrading instruction and carry out routing according to a backed-up main routing table in the upgrading process of the routing software;
obtaining the upgrading state of each network device, and sending a switching instruction to each network device under the condition that each network device is upgraded successfully; and the switching instruction is used for indicating the network equipment to perform routing according to a routing table generated by the upgraded routing software.
8. The route upgrade method according to claim 7, wherein the obtaining the backup status of each of the network devices comprises:
receiving backup states sent by each network device, wherein the backup states comprise backup success or backup failure;
or sending a first query message to each network device, and receiving the reply of each network device to the first query message; the first query message is used for querying the backup state of the network equipment;
the obtaining of the upgrade status of each network device includes:
receiving an upgrade state sent by each network device, wherein the upgrade state comprises upgrade success or upgrade failure;
or sending a second query message to each network device, and receiving a reply of each network device to the second query message; the second query message is used for querying the upgrade status of the network device.
9. An electronic device, comprising:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform a route upgrade method as claimed in any one of claims 1 to 6, or to perform a route upgrade method as claimed in any one of claims 7 to 8.
10. A computer-readable storage medium, storing a computer program, wherein the computer program, when executed by a processor, implements the route upgrade method of any one of claims 1 to 6, or is capable of implementing the route upgrade method of any one of claims 7-8.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210068288.0A CN114389949B (en) | 2022-01-20 | 2022-01-20 | Route upgrading method, electronic equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210068288.0A CN114389949B (en) | 2022-01-20 | 2022-01-20 | Route upgrading method, electronic equipment and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN114389949A true CN114389949A (en) | 2022-04-22 |
CN114389949B CN114389949B (en) | 2024-04-12 |
Family
ID=81203374
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202210068288.0A Active CN114389949B (en) | 2022-01-20 | 2022-01-20 | Route upgrading method, electronic equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN114389949B (en) |
Citations (19)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6535924B1 (en) * | 2001-09-05 | 2003-03-18 | Pluris, Inc. | Method and apparatus for performing a software upgrade of a router while the router is online |
US20060129670A1 (en) * | 2001-03-27 | 2006-06-15 | Redseal Systems, Inc. | Method and apparatus for network wide policy-based analysis of configurations of devices |
US20070162565A1 (en) * | 2006-01-09 | 2007-07-12 | Cisco Technology, Inc. | Method and system for minimizing disruption during in-service software upgrade |
US20100054316A1 (en) * | 2008-09-04 | 2010-03-04 | Verizon Data Services Llc | Digital subscriber line (dsl) network upgrade tool |
CN101888304A (en) * | 2009-05-15 | 2010-11-17 | 华为技术有限公司 | Updating method, device and system for routing equipment |
CN102082730A (en) * | 2011-02-09 | 2011-06-01 | 中兴通讯股份有限公司 | Router upgrading method and router |
US20140071884A1 (en) * | 2011-03-10 | 2014-03-13 | Elta Systems Ltd. | Ip based cellular communication system utilizing advanced tunnels and encapsulation methods useful in conjunction therewith |
US20140380294A1 (en) * | 2013-06-21 | 2014-12-25 | Wistron Neweb Corp. | Methods for upgrading firmware and electronic devices using the same |
CN104486394A (en) * | 2014-12-10 | 2015-04-01 | 杭州华三通信技术有限公司 | Non-interrupting service software upgrading method and device |
CN104901840A (en) * | 2015-07-01 | 2015-09-09 | 冯旋宇 | Data updating method of router and router |
WO2016000107A1 (en) * | 2014-06-30 | 2016-01-07 | 华为技术有限公司 | Primary and secondary system handover method for dynamic route device, and apparatus thereof |
CN105306356A (en) * | 2014-07-30 | 2016-02-03 | 上海博达数据通信有限公司 | Method for realizing master-slave switching of multicast routing on distributed system |
WO2017000284A1 (en) * | 2015-07-01 | 2017-01-05 | 冯旋宇 | Router data update method and router |
CN106534401A (en) * | 2016-11-28 | 2017-03-22 | 国云科技股份有限公司 | Method for transforming host storage network IP from dynamic state to static state |
US20200245212A1 (en) * | 2019-01-24 | 2020-07-30 | Hewlett Packard Enterprise Development Lp | Wireless device upgrade |
CN111770169A (en) * | 2020-06-29 | 2020-10-13 | 百度在线网络技术(北京)有限公司 | Method, device, equipment and storage medium for upgrading equipment firmware |
CN112039718A (en) * | 2020-07-16 | 2020-12-04 | 视联动力信息技术股份有限公司 | Upgrade state detection method, server, device and storage medium |
US20210117279A1 (en) * | 2019-10-17 | 2021-04-22 | EMC IP Holding Company LLC | Method, apparatus and computer program product for managing backup system |
CN113055196A (en) * | 2019-12-28 | 2021-06-29 | 华为技术有限公司 | Message processing method, network device and computer readable storage medium |
-
2022
- 2022-01-20 CN CN202210068288.0A patent/CN114389949B/en active Active
Patent Citations (19)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20060129670A1 (en) * | 2001-03-27 | 2006-06-15 | Redseal Systems, Inc. | Method and apparatus for network wide policy-based analysis of configurations of devices |
US6535924B1 (en) * | 2001-09-05 | 2003-03-18 | Pluris, Inc. | Method and apparatus for performing a software upgrade of a router while the router is online |
US20070162565A1 (en) * | 2006-01-09 | 2007-07-12 | Cisco Technology, Inc. | Method and system for minimizing disruption during in-service software upgrade |
US20100054316A1 (en) * | 2008-09-04 | 2010-03-04 | Verizon Data Services Llc | Digital subscriber line (dsl) network upgrade tool |
CN101888304A (en) * | 2009-05-15 | 2010-11-17 | 华为技术有限公司 | Updating method, device and system for routing equipment |
CN102082730A (en) * | 2011-02-09 | 2011-06-01 | 中兴通讯股份有限公司 | Router upgrading method and router |
US20140071884A1 (en) * | 2011-03-10 | 2014-03-13 | Elta Systems Ltd. | Ip based cellular communication system utilizing advanced tunnels and encapsulation methods useful in conjunction therewith |
US20140380294A1 (en) * | 2013-06-21 | 2014-12-25 | Wistron Neweb Corp. | Methods for upgrading firmware and electronic devices using the same |
WO2016000107A1 (en) * | 2014-06-30 | 2016-01-07 | 华为技术有限公司 | Primary and secondary system handover method for dynamic route device, and apparatus thereof |
CN105306356A (en) * | 2014-07-30 | 2016-02-03 | 上海博达数据通信有限公司 | Method for realizing master-slave switching of multicast routing on distributed system |
CN104486394A (en) * | 2014-12-10 | 2015-04-01 | 杭州华三通信技术有限公司 | Non-interrupting service software upgrading method and device |
CN104901840A (en) * | 2015-07-01 | 2015-09-09 | 冯旋宇 | Data updating method of router and router |
WO2017000284A1 (en) * | 2015-07-01 | 2017-01-05 | 冯旋宇 | Router data update method and router |
CN106534401A (en) * | 2016-11-28 | 2017-03-22 | 国云科技股份有限公司 | Method for transforming host storage network IP from dynamic state to static state |
US20200245212A1 (en) * | 2019-01-24 | 2020-07-30 | Hewlett Packard Enterprise Development Lp | Wireless device upgrade |
US20210117279A1 (en) * | 2019-10-17 | 2021-04-22 | EMC IP Holding Company LLC | Method, apparatus and computer program product for managing backup system |
CN113055196A (en) * | 2019-12-28 | 2021-06-29 | 华为技术有限公司 | Message processing method, network device and computer readable storage medium |
CN111770169A (en) * | 2020-06-29 | 2020-10-13 | 百度在线网络技术(北京)有限公司 | Method, device, equipment and storage medium for upgrading equipment firmware |
CN112039718A (en) * | 2020-07-16 | 2020-12-04 | 视联动力信息技术股份有限公司 | Upgrade state detection method, server, device and storage medium |
Non-Patent Citations (1)
Title |
---|
孔艺权;: "网络路由备份技术设计及实验仿真", 实验室研究与探索, no. 05, 15 May 2012 (2012-05-15) * |
Also Published As
Publication number | Publication date |
---|---|
CN114389949B (en) | 2024-04-12 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106844399B (en) | Distributed database system and self-adaptive method thereof | |
US8607219B2 (en) | Information processing device and a firmware updating method of the information processing device | |
CN103580915B (en) | Method and device for determining main control node of trunking system | |
CN104486394B (en) | In-service Software Upgrade method and device | |
CN100450015C (en) | Method for updating and recovering terminal device data in device management | |
CN110109772B (en) | CPU restarting method, communication equipment and readable storage medium | |
CN104980296A (en) | OpenFlow multi-controller system and management method thereof | |
CN111371680B (en) | Route management method, device, equipment and storage medium for dual-computer hot standby | |
WO2006129277A2 (en) | Method and hardware node for customized upgrade control | |
CN106161086A (en) | Control method that master control borad is restarted and device | |
CN102420746A (en) | Forwarding method for multicast flow and network equipment therefor | |
CN109189403B (en) | Operating system OS batch installation method and device and network equipment | |
CN114389949B (en) | Route upgrading method, electronic equipment and storage medium | |
CN111385352A (en) | Instance control method, node, terminal and distributed storage system | |
CN107340973B (en) | Method and system for accessing asynchronous logic unit | |
US9769059B2 (en) | Fast interlayer forwarding | |
CN114598711A (en) | Data migration method, device, equipment and medium | |
JP3394189B2 (en) | Uninterrupted update system for program / data of any processor | |
CN108174417B (en) | Main/standby switching method and device, related electronic equipment and readable storage medium | |
CN111756562B (en) | Cluster takeover method, system and related components | |
CN112543230B (en) | Method, device, equipment and medium for communication between controller host and cloud platform | |
CN113326275B (en) | Data aging method and system for router | |
KR20010065409A (en) | Master machine selecting method in distribution type intelligent network system | |
CN116723088A (en) | State adjustment method and system for service cluster | |
JP3989447B2 (en) | Communication switching method and data communication apparatus |
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 |