CN114389949B - Route upgrading method, electronic equipment and storage medium - Google Patents

Route upgrading method, electronic equipment and storage medium Download PDF

Info

Publication number
CN114389949B
CN114389949B CN202210068288.0A CN202210068288A CN114389949B CN 114389949 B CN114389949 B CN 114389949B CN 202210068288 A CN202210068288 A CN 202210068288A CN 114389949 B CN114389949 B CN 114389949B
Authority
CN
China
Prior art keywords
backup
routing
routing table
upgrade
route
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.)
Active
Application number
CN202210068288.0A
Other languages
Chinese (zh)
Other versions
CN114389949A (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.)
Wangsu Science and Technology Co Ltd
Original Assignee
Wangsu Science and Technology 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 Wangsu Science and Technology Co Ltd filed Critical Wangsu Science and Technology Co Ltd
Priority to CN202210068288.0A priority Critical patent/CN114389949B/en
Publication of CN114389949A publication Critical patent/CN114389949A/en
Application granted granted Critical
Publication of CN114389949B publication Critical patent/CN114389949B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/56Routing software
    • H04L45/563Software download or update
    • 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
    • H04L41/082Configuration 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 the network equipment and comprises the following steps: receiving a backup instruction of the central controller, and backing up a current main routing table according to the backup instruction; receiving an upgrade instruction sent by a central controller under the condition that all network devices are successfully backed up, wherein the central controller is in communication connection with all network devices; the routing software is upgraded according to the upgrade instruction, and in the process of upgrading the routing software, routing is carried out according to the backup main routing table; 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 service flow interruption and the like caused by route loss due to restarting and other processes when the dynamic routing software is upgraded are avoided, and the dynamic routing software of the network equipment is smoothly upgraded.

Description

Route upgrading method, electronic equipment and storage medium
Technical Field
The present invention relates to the field of communications technologies, and in particular, to a route upgrade method, an electronic device, and a storage medium.
Background
In a network built based on a software-defined wide area network (SD-WAN, software Defined Wide Area Network), by using dynamic routing software, multiple network devices in an enterprise can realize actions of autonomous dynamic route learning.
When dynamic routing software is updated/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 exist in the upgrading process, which may cause the loss or the mistake of the routing information, affect the routing action in operation, and also may cause the interruption of the routing of the service traffic, for example, in the restarting process after the upgrading is completed. If an enterprise has a plurality of network devices to be networked, dynamic routing software needs to be updated/replaced, multiple errors or interruption of the business flow of the enterprise can be caused.
Disclosure of Invention
The main purpose of the embodiments of the present application is to provide a route upgrade method, an electronic device, and a storage medium, which are used for ensuring normal operation of service traffic, and avoiding traffic errors or interruption.
In order to achieve the above objective, an embodiment of the present application provides a route upgrade method, which is applied to a network device, and includes: receiving a backup instruction of the central controller, and backing up a current main routing table according to the backup instruction; receiving an upgrade instruction sent by a central controller under the condition that all network devices are successfully backed up, wherein the central controller is in communication connection with all network devices; the routing software is upgraded according to the upgrade instruction, and in the process of upgrading the routing software, routing is carried out according to the backup main routing table; 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 objective, an embodiment of the present application further provides a route upgrade method, which is applied to a central controller, including: sending a backup instruction to the network equipment, and enabling the network equipment to backup the current main routing table according to the backup instruction; acquiring the backup state of each network device, and sending an upgrade instruction to each network device under the condition that each network device is successfully backed up, so that the network device upgrades the routing software according to the upgrade instruction and routes according to the backup main routing table in the process of upgrading 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; the switching instruction is used for indicating the network equipment to route according to the routing table generated by the updated routing software.
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; the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the routing upgrade method applied to the network device or to perform the routing upgrade method applied to the central controller.
To achieve the above objective, an embodiment of the present application further provides a computer readable storage medium storing a computer program, where the computer program when executed by a processor implements the above routing upgrade method applied to a network device, or can implement the above routing upgrade method applied to a central controller.
In the application, the route upgrading is performed by receiving and executing the instruction issued by the central controller, including informing all devices to backup the dynamic route table into the static route table before upgrading, so that the business flow of the enterprise is cut into the backup route table in the upgrading process. The updating process does not influence the transmission of the service flow, the original service is routed according to the backup routing table, the routing software is switched into the routing table generated by the routing software after updating after finishing updating, the problems of service flow interruption and the like caused by the process of 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. In addition, the central controller determines whether to advance the next step according to the feedback state of each network device in each upgrading stage, so that the upgrading progress of each network device is kept consistent, compared with a gradual upgrading scheme in the prior art, the upgrading state of each network device of an enterprise is kept consistent, the condition that part of upgrading is successful and part of upgrading is not successful or fails is avoided, and further the influence on service flow caused by inconsistent device states in the whole upgrading process is avoided.
Drawings
FIG. 1 is a flow chart of a route upgrade method provided according to one embodiment of the present application;
FIG. 2 is a schematic diagram of a route upgrade method provided according to one embodiment of the present application;
FIG. 3 is a flow chart of a route upgrade method 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 according to one embodiment of the present application.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the embodiments of the present application more apparent, the embodiments of the present application will be described in detail below with reference to the accompanying drawings. However, as will be appreciated by those of ordinary skill in the art, in the various embodiments of the present application, numerous technical details have been set forth in order to provide a better understanding of the present application. However, the technical solutions claimed in the present application can be implemented without these technical details and with various changes and modifications based on the following embodiments. The following embodiments are divided for convenience of description, and should not be construed as limiting the specific implementation of the present application, and the embodiments may be mutually combined and referred to without contradiction.
The terms "first", "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 defining "a first" or "a second" may explicitly or implicitly include at least one such feature. In the description of the present application, the terms "comprise" and "have," along with any variations thereof, are intended to cover non-exclusive inclusions. For example, a system, article, or apparatus that comprises a list of elements is not limited to only those elements or units listed but may alternatively include other elements not listed or inherent to such article, or apparatus. In the description of the present application, the meaning of "plurality" means at least two, for example, two, three, etc., unless specifically defined otherwise.
quagga/frr is dynamic routing software that implements routing protocols such as RIP (Routing Information Protocol ), OSPF (Open Shortest Path First, open shortest path first), BGP (Border Gateway Protocol ), and the like. Based on the network built by the SD-WAN (Software Defined Wide Area Network, software Defined Wide Area Network (SDWAN), through using the quagga/frr software, the automatic dynamic route learning of a plurality of network devices of an enterprise is realized, and networking is completed. However, upgrading/replacing dynamic routing software can cause the route from other devices to the device to be lost, thereby causing interruption of traffic flow; if an enterprise has a plurality of networking devices, dynamic routing software needs to be updated/replaced, the enterprise service flow can be interrupted for a plurality of times in a piece-by-piece updating mode.
One embodiment of the invention relates to a route upgrade method. The method is applied to network equipment, and the specific flow is shown in fig. 1.
Step 101, receiving a backup instruction of the central controller, and backing up the current main routing table according to the backup instruction.
Step 102, receiving an upgrade instruction sent by the central controller under the condition that all network devices are successfully backed up, wherein the central controller is in communication connection with all network devices.
Step 103, the routing software is upgraded according to the upgrade instruction, and in the process of upgrading the routing software, the routing is performed according to the backup main routing table.
Step 104, after receiving the switching instruction sent by the central controller under the condition that each network device is successfully upgraded, routing is performed according to the routing table generated by the upgraded routing software.
The following details of implementation of the route upgrading method of the present embodiment are specifically described, and the following details are provided for understanding only, and are not necessary for implementing the present embodiment.
In step 101, a backup command of the central controller is received, and the current main routing table is backed up according to the backup command. That is, the central controller can determine the progress of the upgrade process, and the network device performs the preliminary backup after receiving the instruction of the central controller. The backup result is used for routing the data to be transmitted when the route upgrade is performed. Optionally, when the central controller determines that all network devices to be upgraded are normally connected with the central processor, or all network devices to be upgraded are online, the process in this example is restarted, so as to avoid the influence of external problems such as communication connection on the upgrading efficiency.
In one example, the priority of the backed up primary routing table is higher than the priority of the current primary routing table. When the priority of the backup main routing table is higher than that of the current main routing table, after the backup main routing table is generated, the data routing is realized by the backup main routing table due to the priority, namely, the original main routing table (the current main routing table) is automatically switched into the backup main routing table, and the data routing is realized by the information in the backup main routing table.
In one example, after backing up the current main routing table according to the backup instruction, the method further includes: if a backup deleting instruction sent by the central controller under the condition that the backup in each network device fails is received, deleting the backed-up main routing table data according to the backup deleting instruction, and ending the upgrading. That is, since the number of upgrading devices is not limited and a plurality of devices/devices (or a communication network formed by a plurality of devices) are allowed to be upgraded together, when a plurality of network devices are backed up together, partial devices may be not successfully backed up, and the backed up data needs to be deleted at this time; for example, deleting parameters in network equipment which is successful in backup and failed in backup, so that the backup is not affected by the data failed in the backup when the backup is re-executed next time; meanwhile, the backup data is emptied, and route errors caused by switching of the route parts after the backup is completed can be avoided.
In one example, after backing up the current main routing table according to the backup instruction, the method further includes: sending a backup state to the central controller, wherein the backup state comprises backup success or backup failure; or receiving and replying to a first inquiry message sent by the central controller, wherein the first inquiry message is used for inquiring the backup state of the network equipment; after the routing software is upgraded according to the upgrade instruction, the method further comprises the following steps: determining an upgrade state based on the number of destination IPs of the dynamic route generated after the upgrade route software is completed; the method comprises the steps of sending an upgrade state to a central controller, wherein the upgrade state comprises upgrade success or upgrade failure; or receiving and replying to a second inquiry message sent by the central controller, wherein the second inquiry message is used for inquiring the upgrading state of the network equipment. That is, the information interaction between the central controller and each network device can be requested to perform active request to the network device through the central processor, and the active request is fed back to the central processor through each network device; or each network device actively transmits the state to the central processing unit, wherein the state comprises a backup state and an upgrade 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. That is, the information interaction between the central processing unit and the network device is not limited to the initiation of one party, and both parties can be used as the initiator of the information interaction, so that the way of state feedback/acquisition is increased.
For the determination of the upgrade status, the upgrade status may be determined by the number of destination IPs of the dynamic route after the upgrade of the routing software is completed, 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 in the backup main routing table, the routing software upgrade is judged to be successful. When the feedback of the upgrade state is carried out, the network equipment can directly feed back the upgrade state, namely the upgrade is successful or the upgrade is failed, or the network equipment can feed back the number of the destination IPs of the dynamic route, the number of the destination IPs of the original main route table or the backup main route table, so that the CPU can carry out judgment processing to reduce the operation pressure of the network equipment; further, the network device may receive and reply to a third query message sent by the central controller, where the third query message is used to query the number of destination IPs of the dynamic route, the number of destination IPs of the original primary routing table or the backup primary routing table, so as to allow the central processor to perform judgment processing.
In addition, if the number of the destination IPs of the dynamic route after the upgrade is different from the number of the destination IPs of the original main routing table or the number of the destination IPs obtained from the backup main routing table, the periodic inspection is entered, and if the number of the destination IPs is inconsistent within the second time threshold or other preset time, the feedback routing software upgrade fails.
In step 102, an upgrade instruction sent by the central controller when all network devices are successfully backed up is received, and the central controller is in communication connection with all network devices. When the central processing unit obtains the information that each network device is successfully backed up, an upgrade instruction is issued, namely, each network device is pushed to enter the next stage of upgrade.
In step 103, the routing software is updated according to the update instruction, and in the process of updating the routing software, routing is performed according to the backup main routing table.
And the route upgrading is completed according to an upgrading instruction issued by the central controller, wherein the route is carried out along the backup main route table while the upgrading is carried out because the backup is completed in the previous stage, so that the route process is not influenced by the upgrading operation. Specifically, the conditions of route data replacement, loss, incompleteness and the like may occur in the route upgrading process, and the process of data routing is not enough to be guaranteed to be the same with a non-upgrading period, so that the route requirement cannot be met by adopting an original main routing table in route upgrading; however, in this embodiment, a backup process exists before the upgrade, and a backup main routing table is used for routing during the upgrade, so that the data routing requirement can be achieved while the routing upgrade is completed.
In step 104, after receiving a switching instruction sent by the central controller under the condition that each network device is successfully upgraded, routing is performed according to a routing table generated by the upgraded routing software. That is, after the route upgrade is completed, the backup main routing table is switched to the routing table generated by the upgraded routing software for routing.
In one example, after receiving a handover 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 includes: after receiving a switching instruction sent by the central controller under the condition that each network device is successfully upgraded, deleting the backup 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 updated routing software for routing. Namely, the switching of the routing table can 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 updated routing software is automatically searched for routing. For example, when the priority of the backup main routing table is higher than that of the original main routing table and also higher than that of the routing table generated by the updated routing software, if the routing software is successfully updated to generate a new routing table, the backup main routing table with the high priority is deleted, and the backup main routing table can be automatically switched to the new routing table for routing.
In addition, after the deletion operation is finished, the network device may feed back a deletion status, such as deletion success or deletion failure, to the central controller; if the deletion fails, a re-deletion instruction issued by the central controller is received until the deletion is successful. The deletion operation may also add a time threshold as one of criteria for success or failure.
In one example, the backup is successful, further comprising: completing backup within a preset first time threshold; successful upgrade, further comprising: and finishing upgrading within a preset second time threshold. Namely, setting a time threshold for the backup and upgrading processes, completing the backup/upgrading in the corresponding time, and determining failure if the backup/upgrading is successful and exceeds the corresponding time threshold; the time used in the backup and upgrading processes is restricted, the situation that the upgrade or the backup result cannot be concluded yet for a long time is avoided, and the execution efficiency is improved. That is, the judgment standard of the completion of the execution of the backup or upgrade state is included in the preset time to ensure the execution efficiency of the scheme. It will be appreciated that the relationship between the first time threshold and the second time threshold is not limited, and may be the same or different, allowing adjustment according to actual requirements.
For ease of understanding, the following description will be given of the above embodiment in terms of a practical implementation. It will be appreciated that these examples are for illustrative purposes only and are not intended to be limiting in nature. Reference may be made to fig. 2, including but not limited to:
s1, the central controller informs all network devices of an enterprise of carrying out a first upgrading stage: and (5) backing up the route.
S2, the equipment receives a backup route instruction of the central controller, copies the current main route table of the equipment into a strategy route table with higher priority (namely the backup main route table), and automatically cuts the traffic of the equipment into the strategy route table with higher priority. Because the policy routing table is static and is not affected by the upgrade of the routing software, the service flow is ensured not to be interrupted.
S3, after the backup routing operation is completed by all the devices, reporting the backup result to the central controller, and after receiving the message that all the devices are normally backed up, notifying all the devices to carry out the second stage by the central controller: and replacing the routing software. If the network equipment does not backup successfully in the first stage or the central controller does not receive the backup route result reported by the equipment within a set time, the central controller does not inform the network equipment to perform the second stage.
S4, after all the devices of the enterprise receive the command of replacing the routing software of the central controller, the routing software is updated, and the replacement of the routing software can be realized, for example, the qugga software is replaced by frr software: the frr software is installed first, then the configuration file of the quagga is copied to the configuration file catalog of the frr, and the quagga component of the enterprise is closed first and then the frr software is started because the monitoring port used by the frr and the quaga component is the same.
S5, after qugga software of an enterprise is replaced by frr software, the frr software automatically generates and learns a dynamic route, and after the frr is updated, whether the dynamic route generated by the frr software is normal or not is checked: comparing the number of the destination IP sections of the dynamic route of the main routing table with the number of the destination IP sections of the policy routing table copied in the first stage, and if so, judging that the upgrade is successful, and if not, judging 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 upgrading process is adopted, the steps of different software replacement are not generated, and only the route software is automatically upgraded.
S6, after receiving the message that all network devices are normally upgraded, the central controller informs all network devices to carry out a third stage: and deleting the backup route. If the network equipment is not successfully upgraded in the second stage or the central controller does not receive the upgrading result reported by the network equipment in the set time, the central controller does not inform all the equipment to perform the third stage, the traffic continues to run the policy routing table backed up in the first stage, and the traffic is not affected.
S7, after all network devices of the enterprise receive the backup route deleting command of the central controller, the backup route deleting operation is started, after the complete route list is deleted, the traffic automatically rewrites the main route list generated after the upgrading, and all network devices delete the backup route list and report the deleting result to the central controller.
And S8, after receiving the message that all the network devices delete the backup route normally, the central controller finishes the upgrading process and sets the upgrading result as success.
In this embodiment, route upgrade is performed by receiving and executing an instruction issued by the central controller, which includes notifying all devices to backup the dynamic routing table into a static routing table before upgrade, so that enterprise traffic is cut to the backup routing table in the upgrade process. The updating process does not influence the transmission of the service flow, the original service is routed according to the backup routing table, the routing software is switched into the routing table generated by the routing software after updating after finishing updating, the problems of service flow interruption and the like caused by the process of 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. In addition, the central controller determines whether to advance the next step according to the feedback state of each network device in each upgrading stage, so that the upgrading progress of each network device is kept consistent, compared with a gradual upgrading scheme in the prior art, the upgrading state of each network device of an enterprise is kept consistent, the condition that part of upgrading is successful and part of upgrading is not successful or fails is avoided, and further the influence on service flow caused by inconsistent device states in the whole upgrading process is avoided.
The above steps of the methods are divided, for clarity of description, and may be combined into one step or split into multiple steps when implemented, so long as they include the same logic relationship, and they are all within the protection scope of this patent; it is within the scope of this patent to add insignificant modifications to the algorithm or flow or introduce insignificant designs, but not to alter the core design of its algorithm and flow.
One embodiment of the invention relates to a route upgrade method. The method is applied to a central controller, and the specific flow is shown in fig. 3.
Step 201, a backup instruction is sent to the network equipment, so that the network equipment backs up the current main routing table according to the backup instruction;
step 202, obtaining the backup state of each network device, and sending an upgrade instruction to each network device under the condition that each network device is successfully backed up, so that the network device upgrades the routing software according to the upgrade instruction and routes according to the backup main routing table in the process of upgrading the routing software. The method for obtaining the backup state of each network device comprises the following steps: receiving a backup state sent by each network device, wherein the backup state comprises backup success or backup failure; or sending the first query message to each network device, and receiving a reply of each network device to the first query message; the first query message is used to query the backup status of the network device. That is, both the network device and the central processing unit are allowed to act as active initiators for status acquisition/feedback, and the way for the central processing unit to acquire the backup status is increased.
Step 203, obtaining the upgrade state of each network device, and sending a switching instruction to each network device under the condition that each network device is successfully upgraded; the switching instruction is used for indicating the network equipment to route according to the routing table generated by the updated routing software. The method for acquiring the upgrade state of each network device comprises the following steps: receiving upgrade states sent by each network device, wherein the upgrade states comprise upgrade success or upgrade failure; or sending the second inquiry message to each network device, and receiving the reply of each network device to the second inquiry message; the second query message is used for querying the upgrade status of the network device. That is, both the network device and the central processing unit are allowed to act as active initiators for status acquisition/feedback, and the way for the central processing unit to acquire the upgrade status is increased.
For ease of understanding, the following description will be given of the above embodiment in terms of a practical implementation. It will be appreciated that these examples are for illustrative purposes only and are not intended to be limiting in nature.
Beijing headquarters and Xiamen branches of enterprise 1 establish long connections with central controllers through SD-WAN (enterprise networking equipment has CPE (Customer Premise Equipment, transliterated as customer premise equipment), POP (Point of Presence, access point)), receive, report messages CPE, POP establish tunnels with POP, POP-POP, and generate dynamic routes through dynamic routing software to implement inter-equipment interconnection (each equipment has routes to any other equipment). Referring to FIG. 4, specific upgrade 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 with the central controller, the state is online, and when all the network devices of the enterprise are online, the central controller starts an upgrading process.
A2, the central controller sends a backup instruction to all CPE and POP devices of the enterprise 1, and the backup instruction is used for realizing the backup of the main routing table.
A3, the CPE and the POP equipment receive the backup routing information, firstly check whether a routing table with the highest priority in the ip rule, such as a table252, exists or not, or delete the routing table (ip rule del table) when the routing table exists, and empty the routing table (ip route flush table) before the backup routing operation, so as to ensure that the routing table has no previous residual routing. The main routing table is backed up by copying the destination IP address segment of the main routing table and the next hop to the routing table252, and after copying all routes, checking whether the main routing table is consistent with the strategy routing table (namely the main routing table after backup); confirming whether destination network segments of main table routing exist in the policy routing table or not, if yes, the backup operation is successful, otherwise, the backup is considered to be failed, and the routing table252 is added after the backup is successful, because the priority of the routing table252 is higher than that of the main routing table (the linux system determines the priority according to the id of the routing table, the id of the main routing table is usually 254 and the priority is lower than that of the routing table 252), and after the routing table252 is added, all traffic is cut to the routing table 252. The policy routing table (backup routing table) id is set to 252 because traffic originally traveling the main routing table is routed to the policy routing table, but traffic is not affected to other policy routing tables.
And A4, after the CPE and the POP devices respectively finish the backup operation, reporting the result of the backup operation to the central controller.
And A5, after receiving the backup success message of all the devices, the central controller judges that the backup route of the first stage is successful, and the replacement dynamic routing software of the second stage can be performed, and informs all the devices to replace the dynamic routing software. If the device backup route fails in the first stage, the central controller informs all network devices to delete the backup route list, and the network devices are restored to the state before upgrading, the upgrading of the round is finished, and the upgrading result is failure.
A6, the CPE and the POP equipment receive the message [ replacing dynamic routing software ] issued by the central controller, and execute the operation of replacing the dynamic software. Taking the example of performing the replacement from quatga to frr, the flow of the replacement routing software for the CPE and POP devices is different:
the CPE device performs the steps of: installing dynamic routing software frr, and copying the configuration file of the original routing software quagga to the configuration file directory of the frr software. Since the listening ports of the two software are identical, the software quagga is turned off first and then frr is started.
The POP device performs the steps of: routing software runs on the POP equipment 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: and copying the configuration file under the enterprise ID directory of quagga to the enterprise ID configuration file directory of frr software. And (3) the quatga process kill of the enterprise is started, the frr process of the enterprise is started, and the processes of other enterprises cannot operate or directly stop quatgga.
A7, closing the quagga software (CPE)/closing the quagga process (POP) of the enterprise, wherein the dynamic route learned by the original main routing table disappears, but the traffic walks the backup strategy routing table at the moment, so that the traffic is not interrupted. After the frr process is started, the frr automatically relearns the dynamic route to the main table, checks whether the destination IP address segment of the dynamic route table of the main table is consistent with the backup strategy route table every preset time (for example, 5 s), and the consistency indicates that the switching route software is successful, reports success information to the central controller, is inconsistent, periodically checks, sets the longest checking time threshold, for example, checks 90s at the longest, and if the destination IP address segment of the main route table is inconsistent with the backup strategy route table after 90s, reports failure of replacing the route software.
And A8, after receiving the message that all the devices successfully replace the routing software, the central controller judges that the second stage (replacing the routing software) is successful, and the third stage (deleting the backup routing table) can be performed, and informs all the devices to delete the backup routing table. If the equipment fails to replace the routing software in the second stage, human intervention is needed, after the reason of failure is checked, the routing software of the equipment is normally replaced, and then the central controller is used for informing all network elements to delete the backup routing table in the third stage.
A9, CPE and POP device receive the message of deleting the backup route table, firstly delete the route table252, then empty all routes of the route table252, and switch the flow back to the main route table. And each device reports the operation result of deleting the backup routing table to the central controller.
A10, after receiving the successful message of deleting the routing table of all the devices, the central controller judges that the process of deleting the backup routing table in the third stage is successful, and finishes upgrading all the devices of the enterprise, and the upgrading result is successful.
In this embodiment, the central processing unit performs route upgrade on the instruction issued by the network device, including notifying all devices to backup the dynamic routing table into the static routing table before upgrade, so that the business traffic of the enterprise is cut to the backup routing table in the upgrade process. The updating process does not influence the transmission of the service flow, the original service is routed according to the backup routing table, the routing software is switched into the routing table generated by the routing software after updating after finishing updating, the problems of service flow interruption and the like caused by the process of 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. And the central controller can determine whether to advance the next step according to the feedback state of each network device in each upgrading stage, so that the upgrading progress of each network device is kept consistent, and compared with a gradual upgrading scheme in the prior art, the upgrading state of each network device of an enterprise is kept consistent, the state that part of upgrading is successful and part of upgrading is not successful or fails is avoided, and further the influence on service flow caused by inconsistent device states in the whole upgrading process is avoided. In the embodiment, the whole upgrading process is controlled by the central controller, and all network devices are informed of backing up the dynamic routing table into the static routing table with high priority before upgrading, so that enterprise service traffic is cut into the backup routing table and then is upgraded, the problem of service traffic interruption caused by route loss when the 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; the memory 302 stores instructions executable by the at least one processor 301, where the instructions are executed by the at least one processor 301, so that the at least one processor 301 can perform the above-mentioned route upgrade method applied to a network device or can perform a route upgrade method applied to a central controller.
Where the memory and the processor are connected by a bus, the bus may comprise any number of interconnected buses and bridges, the buses connecting the various circuits of the one or more processors and the memory together. The bus may also connect various other circuits such as peripherals, voltage regulators, and power management circuits, which are well known in the art, and therefore, will not be described any further herein. The bus interface provides an interface between the bus and the transceiver. The transceiver may be one element or may be 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 the wireless medium via the 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 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 implements the above-described method embodiments when executed by a processor.
That is, it will be understood by those skilled in the art that all or part of the steps in implementing the methods of the embodiments described above may be implemented by a program stored in a storage medium, where the program includes several instructions for causing a device (which may be a single-chip microcomputer, a chip or the like) or a processor (processor) to perform all or part of the steps in the methods of the embodiments described herein. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, or an optical disk, or 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 of 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.

Claims (10)

1. A method of route upgrade, applied to a network device, comprising:
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 all network devices are successfully backed up, wherein the central controller is in communication connection with all network devices;
updating the routing software according to the updating instruction, and routing according to the backup main routing table in the updating process of the routing software;
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;
the backup main routing table is a static routing table, the routing software is dynamic routing software, and the current main routing table is a routing table currently provided by the routing software.
2. The route upgrade method according to claim 1, wherein the priority of the backed up primary routing table is higher than the priority of the current primary routing table.
3. The route upgrade method according to claim 2, wherein after receiving a handover command sent by the central controller in case that each of the network devices is successfully upgraded, the route is performed according to a routing table generated by the upgraded routing software, including:
after receiving a switching instruction sent by the central controller under the condition that each network device is successfully upgraded, deleting the backup 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 updated routing software for routing.
4. The route upgrade method according to claim 1, wherein after the current main routing table is backed up according to the backup instruction, further comprising:
and if a backup deleting instruction sent by the central controller under the condition that backup failure exists in each network device is received, deleting the backed-up main routing table data according to the backup deleting instruction, and ending the upgrading.
5. The route upgrade method according to claim 1, wherein after the current main routing table is backed up according to the backup instruction, further comprising:
sending a backup state to the central controller, wherein the backup state comprises successful backup or failed backup;
or receiving and replying to a first query message sent by the central controller, where the first query message is used to query the backup state of the network device;
after the routing software is updated according to the updating instruction, the method further comprises the following steps:
determining an upgrade state based on the number of destination IPs of the dynamic route generated after the upgrade route software is completed;
the upgrading state is sent to the central controller, and the upgrading state comprises upgrading success or upgrading failure;
or receiving and replying to a second inquiry message sent by the central controller, wherein the second inquiry message is used for inquiring the upgrading state of the network equipment.
6. The route upgrade method according to any one of claims 1-5, wherein the backup is successful, further comprising: completing backup within a preset first time threshold;
the upgrade is successful, further comprising: and finishing upgrading within a preset second time threshold.
7. A route upgrade method applied to a central controller, comprising:
sending a backup instruction to network equipment, wherein the network equipment backups a current main routing table according to the backup instruction;
acquiring the backup state of each network device, and sending an upgrade instruction to each network device under the condition that each network device is successfully backed up, so that the network device upgrades the routing software according to the upgrade instruction and routes according to a backup 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; the switching instruction is used for indicating the network equipment to route according to a routing table generated by the updated routing software;
the backup main routing table is a static routing table, the routing software is dynamic routing software, and the current main routing table is a routing table currently provided by the routing software.
8. The method of route upgrade according to claim 7, wherein the obtaining the backup status of each of the network devices comprises:
receiving a backup state sent by each network device, wherein the backup state comprises backup success or backup failure;
or sending a first query message to each network device, and receiving a 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 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; the method comprises the steps of,
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 route upgrade method of any one of claims 1 to 6 or to perform the route upgrade method of any one of claims 7-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.
CN202210068288.0A 2022-01-20 2022-01-20 Route upgrading method, electronic equipment and storage medium Active CN114389949B (en)

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 CN114389949A (en) 2022-04-22
CN114389949B true 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 (12)

* Cited by examiner, † Cited by third party
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
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
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
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
CN113055196A (en) * 2019-12-28 2021-06-29 华为技术有限公司 Message processing method, network device and computer readable storage medium

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8135815B2 (en) * 2001-03-27 2012-03-13 Redseal Systems, Inc. Method and apparatus for network wide policy-based analysis of configurations of devices
US8364843B2 (en) * 2006-01-09 2013-01-29 Cisco Technology, Inc. Method and system for minimizing disruption during in-service software upgrade
US7944855B2 (en) * 2008-09-04 2011-05-17 Verizon Patent And Licensing Inc. Digital subscriber line (DSL) network upgrade tool
IL218046B (en) * 2012-02-12 2018-11-29 Elta Systems Ltd Multi-directional relay architecture and apparatus and methods of operation useful in conjunction therewith
TWI497415B (en) * 2013-06-21 2015-08-21 Wistron Neweb Corp Methods for upgrading firmware and apparatuses using the same
US11184824B2 (en) * 2019-01-24 2021-11-23 Hewlett Packard Enterprise Development Lp Wireless device upgrade
CN112688974A (en) * 2019-10-17 2021-04-20 伊姆西Ip控股有限责任公司 Method, apparatus and computer program product for managing backup systems

Patent Citations (12)

* Cited by examiner, † Cited by third party
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
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
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
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)

* Cited by examiner, † Cited by third party
Title
网络路由备份技术设计及实验仿真;孔艺权;;实验室研究与探索;20120515(05);全文 *

Also Published As

Publication number Publication date
CN114389949A (en) 2022-04-22

Similar Documents

Publication Publication Date Title
JP4021841B2 (en) Control packet processing apparatus and method in spanning tree protocol
CN104320475B (en) A kind of device updating method and device
CN107153660B (en) Fault detection processing method and system for distributed database system
CN104486394B (en) In-service Software Upgrade method and device
CN100450015C (en) Method for updating and recovering terminal device data in device management
WO2018177417A1 (en) Method of upgrading distributed system, distributed system, and upgrade management device
JP2009251786A (en) Data processing method, storage apparatus, and storage system
CN110109772B (en) CPU restarting method, communication equipment and readable storage medium
CN111371680B (en) Route management method, device, equipment and storage medium for dual-computer hot standby
WO2007063716A1 (en) Communication apparatus, apparatus activation control method, communication control method, and communication control program
CN106161086A (en) Control method that master control borad is restarted and device
CN109189403B (en) Operating system OS batch installation method and device and network equipment
CN114389949B (en) Route upgrading method, electronic equipment and storage medium
JP4580372B2 (en) Network system
CN110995498A (en) Port starting method and device
JP4645435B2 (en) Information processing apparatus, communication load distribution method, and communication load distribution program
KR102033489B1 (en) Method and server for managing server cluster
CN112543230B (en) Method, device, equipment and medium for communication between controller host and cloud platform
US10764140B2 (en) Communication system, communication device, and communication method
KR101628219B1 (en) Method and apparatus for operating controller of software defined network
JP3989447B2 (en) Communication switching method and data communication apparatus
KR20010065409A (en) Master machine selecting method in distribution type intelligent network system
JP6514801B1 (en) Information processing system and communication connection switching method at power failure in information processing system
JP3589433B2 (en) Database guarantee method
US20140059164A1 (en) Apparatus and method for managing terminal 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