CN114598643B - Data backup method and device - Google Patents

Data backup method and device Download PDF

Info

Publication number
CN114598643B
CN114598643B CN202210057358.2A CN202210057358A CN114598643B CN 114598643 B CN114598643 B CN 114598643B CN 202210057358 A CN202210057358 A CN 202210057358A CN 114598643 B CN114598643 B CN 114598643B
Authority
CN
China
Prior art keywords
interface board
board
dependency
interface
backup
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
CN202210057358.2A
Other languages
Chinese (zh)
Other versions
CN114598643A (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.)
New H3C Technologies Co Ltd
Original Assignee
New H3C Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by New H3C Technologies Co Ltd filed Critical New H3C Technologies Co Ltd
Priority to CN202210057358.2A priority Critical patent/CN114598643B/en
Publication of CN114598643A publication Critical patent/CN114598643A/en
Application granted granted Critical
Publication of CN114598643B publication Critical patent/CN114598643B/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/60Router architectures
    • 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/06Management of faults, events, alarms or notifications
    • H04L41/0654Management of faults, events, alarms or notifications using network fault recovery
    • H04L41/0659Management of faults, events, alarms or notifications using network fault recovery by isolating or reconfiguring faulty entities
    • H04L41/0661Management of faults, events, alarms or notifications using network fault recovery by isolating or reconfiguring faulty entities by reconfiguring faulty entities
    • 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/06Management of faults, events, alarms or notifications
    • H04L41/0654Management of faults, events, alarms or notifications using network fault recovery
    • H04L41/0668Management of faults, events, alarms or notifications using network fault recovery by dynamic selection of recovery network elements, e.g. replacement by the most appropriate element after failure
    • 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/06Management of faults, events, alarms or notifications
    • H04L41/069Management of faults, events, alarms or notifications using logs of notifications; Post-processing of notifications
    • 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 application provides a data backup method and a device, the method is applied to a first interface board, the first interface board is positioned in a router, the router also comprises a second interface board and an optical board, the optical board establishes physical connection with the first interface board and the second interface board respectively, the method comprises: judging a board dependence role between the first interface board and the optical board after a business process is started in the first interface board; if the board dependence role indicates that the first interface board is a main dependence interface board, the first interface board is used as a server according to the address identification of the first interface board and the port identification of the first interface board; if a connection request sent by a second interface board serving as a client is detected, sending backup data of the business process to the second interface board through a first unicast channel established with the second interface board; wherein the board role of the second interface board is to be a backup dependent interface board.

Description

Data backup method and device
Technical Field
The present application relates to the field of communications technologies, and in particular, to a data backup method and apparatus.
Background
Currently, in order to provide a low-cost network router, some manufacturers independently develop a novel router frame, for example, a novel router frame developed by some H manufacturer, i.e., an M frame. The frame adopts the structure form of a main and standby main control board and a main and standby forwarding board, and supports light boards comprising 8/16 surface board ports (or called interfaces) respectively. The optical plate is physically connected with the main and standby forwarding plates, so that the optical plate is attached to the main and standby forwarding plates at the same time.
The above-mentioned active/standby forwarding boards do not include any output panel ports, are set to be in an interface board role on a software level, and serve as a dependency board of the optical board to configure issuing and forwarding functions for the output panel port processing of the optical board. Referring to fig. 1, fig. 1 is a schematic diagram of a current M8 machine frame.
In FIG. 1, slots 0-1 are primary and secondary main control boards, slots 2-3 are primary and secondary interface boards, and slots 4-11 can be plugged with 8 light boards. In the M8 machine frame, the traditional interface board using the mother board and the daughter card is replaced by the optical board and the interface board, so that the router cost is reduced, and the networking cost is reduced for customers.
However, compared with the prior router frame, forwarding entries and operation data of certain service processes are stored in an interface board where an interface is located, namely, a motherboard or an interface board where an interface is located, and each interface depends on one interface board where the interface is located. Since the interfaces do not depend on multiple interface boards at the same time, the prior router chassis does not have the need to synchronize the interface board data.
For the novel router frame, as the main and standby forwarding boards are set to be in the roles of the interface boards on the software level, the optical boards with the panel outlets are attached to the main and standby interface boards at the same time, and in order to ensure that the data can be backed up between the main and standby interface boards, the forwarding list items and the operation data need to be backed up in batches or backed up in real time.
Disclosure of Invention
In view of this, the application provides a data backup method and device, which realizes batch backup and real-time backup between the main and standby forwarding boards in the novel router frame.
In a first aspect, the present application provides a data backup method, where the method is applied to a first interface board, where the first interface board is located in a router, the router further includes a second interface board and an optical board, where the optical board establishes physical connection with the first interface board and the second interface board respectively, and the method includes:
judging a board dependence role between the first interface board and the optical board after a business process is started in the first interface board;
if the board dependence role indicates that the first interface board is a main dependence interface board, the first interface board is used as a server according to the address identification of the first interface board and the port identification of the first interface board;
If a connection request sent by a second interface board serving as a client is detected, sending backup data of the business process to the second interface board through a first unicast channel established with the second interface board;
wherein the board role of the second interface board is to be a backup dependent interface board.
In a second aspect, the present application provides a data backup device, the device being applied to a first interface board, the first interface board being located in a router, the router further including a second interface board and an optical board, the optical board establishing physical connection with the first interface board and the second interface board, respectively, the device including:
the judging unit is used for judging the board dependence roles between the first interface board and the optical board after the business process is started in the first interface board;
the execution unit is used for taking the first interface board as a server according to the address identification of the first interface board and the port identification of the first interface board if the board dependency role indicates that the first interface board is a main dependency interface board;
a sending unit, configured to send backup data of the service process to a second interface board through a first unicast channel established with the second interface board if a connection request sent by the second interface board as a client is detected;
Wherein the board role of the second interface board is to be a backup dependent interface board.
In a third aspect, the application provides a network device comprising a processor and a machine-readable storage medium storing machine-executable instructions executable by the processor to cause the processor to perform the method provided by the first aspect of the application.
Therefore, by applying the data backup method and the data backup device provided by the application, after the business process is started in the first interface board, the first interface board judges the board dependence roles between itself and the optical board; if the board dependence role indication is a main dependence interface board, the first interface board takes the board itself as a server according to the address identification of the board itself and the port identification of the board itself; if a connection request sent by a second interface board serving as a client is detected, the first interface board sends backup data of a business process to the second interface board through a first unicast channel established with the second interface board; wherein the board role of the second interface board is to be a backup dependent interface board.
Thus, as the master-slave dependency interface board of the optical board, after verifying the board dependency roles of the master-slave dependency interface board, the master-slave dependency interface board synchronizes the backup data of the business process to the slave-slave dependency interface board. The method realizes batch backup and real-time backup between the main and standby interface boards in the novel router, ensures that the running data on the main and standby interface boards are synchronous and timely, and ensures that the optical board interfaces can work continuously.
Drawings
FIG. 1 is a schematic diagram of a current M8 machine frame;
FIG. 2 is a flowchart of a data backup method according to an embodiment of the present application;
FIG. 3 is a schematic diagram of data backup between dependent boards of an M machine frame in an IRF stacking environment according to an embodiment of the present application;
FIG. 4 is a block diagram of a data backup device according to an embodiment of the present application;
fig. 5 is a hardware structure of a network device according to an embodiment of the present application.
Detailed Description
Reference will now be made in detail to exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, the same numbers in different drawings refer to the same or similar elements, unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present application. Rather, they are merely examples of apparatus and methods consistent with aspects of the application as detailed in the accompanying claims.
The terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. As used in this specification and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will also be understood that the term "and/or" as used herein refers to and encompasses any or all possible combinations of one or more of the corresponding listed items.
It should be understood that although the terms first, second, third, etc. may be used herein to describe various information, these information should not be limited by these terms. These terms are only used to distinguish one type of information from another. For example, first information may also be referred to as second information, and similarly, second information may also be referred to as first information, without departing from the scope of the application. The word "if" as used herein may be interpreted as "at … …" or "at … …" or "responsive to a determination", depending on the context.
The data backup method provided by the embodiment of the application is described in detail below. Referring to fig. 2, fig. 2 is a flowchart of a data backup method according to an embodiment of the present application. The method is applied to a first interface board. The data backup method provided by the embodiment of the application can comprise the following steps.
Step 210, after the business process is started in the first interface board, judging the board dependency roles between the first interface board and the optical board.
Specifically, the router frame (which may also be referred to as a router, hereinafter referred to as a router) includes a control board, a forwarding board, and an optical board.
The control board specifically refers to a main control board and a standby control board, and the main control board and the standby main control board respectively establish physical full connection with the forwarding board; the forwarding board does not include a physical interface (i.e. does not include a panel outlet), is set to be in an interface board role on a software layer, and concretely refers to a main interface board and a standby interface board, and the interface board is used as a light board and depends on the board to perform functions of issuing and forwarding for the processing configuration of the interface (i.e. the panel outlet) of the light board; the optical board comprises a plurality of interfaces, the number of the interfaces can be 8 or 16, and the optical board is respectively in physical connection with the main interface board and the standby interface board.
In this step, a first interface board, a second interface board, and an optical board (the number of which may be not limited) are described as an example. The optical board is respectively in physical connection with the first interface board and the second interface board.
A service process, for example, an LLDP service, has been configured in the first interface board. After the business process is started in the first interface board, the first interface board judges the board dependence roles between itself and the optical board. In the embodiment of the application, the board dependency roles comprise a main dependency interface board and a standby dependency interface board.
The board dependency roles may be that a user previously divides a relationship between each interface board and an optical board, for example, a first interface board is divided into a main dependency board of the optical board, a second interface board is divided into a standby dependency board of the optical board, and then the user issues a configuration instruction to each board card in the router, where the configuration instruction includes the board dependency roles of each interface board. Each board card may store the board-dependent roles of each interface board within the hardware infrastructure.
If the board dependency role indicates that the first interface board is the master dependency board, then the first interface board performs step 220.
Step 220, if the board dependency role indicates that the first interface board is a master dependency interface board, the first interface board is used as a server according to the address identifier of the first interface board and the port identifier of the first interface board.
Specifically, according to the description of step 210, if the board dependency role indicates that the first interface board is the master dependency board, the first interface board obtains its own address identifier and a port identifier. The address identifier is specifically a slot number of the interface board. It will be appreciated that the slot number of each interface board is fixed. The port indicated by the port identifier is a logical port, which is a port that is not automatically allocated by the system (i.e., fixedly allocated), and the function of the port and the port identifier have uniqueness locally, for example, a Socket communication port.
Thus, according to the address identification and the port identification of the first interface board, the first interface board takes the first interface board as a Server.
It will be appreciated that the first interface board acts as a Server (Server) that periodically probes the ports indicated by the port identification and waits for a connection request sent by the second interface board acting as a client.
And if the service process is started in the second interface board, the second interface board also judges the board dependence roles between the second interface board and the optical board. When the own board dependency role is determined to be indicated as the backup dependency interface board, the second interface board acquires the address identification and the port identification of the main dependency interface board (i.e. the first interface board) from the local hardware infrastructure. And generating and initiating a connection request to a port indicated by the port identification of the first interface board by the second interface board according to the address identification and the port identification of the second interface board and the address identification and the port identification of the first interface board. After receiving the connection request, the first interface board creates a first unicast channel (in the embodiment of the present application, the unicast channel is specifically a Socket connection) that communicates with the second interface board. At this time, the second interface board uses itself as a Client (Client) of the first unicast channel, and the first interface board uses itself as a Server (Server) of the first unicast channel.
The user sends the configuration instruction to each board card and simultaneously carries the address identification and the port identification of each interface board in the configuration instruction. Each board card may store an address identification, a port identification, and a corresponding board dependency role for each interface board within the hardware infrastructure.
In the embodiment of the application, the address identifier of the second interface board is the same as the address identifier of the first interface board, and is also the slot number of the interface board. The port identification of the second interface board is the same as the port identification of the first interface board, which is also a port that is not automatically allocated (i.e., fixedly allocated) by the system and the function of the port and the port identification are locally unique, for example, socket communication ports.
Step 230, if a connection request sent by a second interface board as a client is detected, sending backup data of the service process to the second interface board through a first unicast channel established with the second interface board.
Specifically, according to the description of step 220, the first interface board periodically detects whether the port indicated by the port identification receives the connection request sent by the second interface board. And if the first interface board receives the connection request, creating a first unicast channel communicated with the second interface board.
In the embodiment of the application, the connection request comprises a service process identifier and a backup indication, which are used for requesting the first interface board to synchronize backup data of the service process. If the port receives the connection request, the first interface board acquires backup data of the corresponding service process, and sends the backup data to the second interface board through the first unicast channel.
Further, in the embodiment of the present application, the first interface board as the server may backup data to the second interface board in real time or in batch according to the service requirement. In general, after the first interface board detects a connection request sent by the second interface board, data is backed up to the second service board in batches, and then the data can be backed up to the second interface board in real time according to service requirements.
It should be noted that, because the optical board establishes physical connection with the first interface board and the second interface board at the same time, similar to the steps 210-230 described above, the interface data of the plurality of interfaces included in the optical board may also be synchronously backed up between the first interface board and the second interface board through the created unicast channel.
Therefore, by applying the data backup method and the data backup device provided by the application, after the business process is started in the first interface board, the first interface board judges the board dependence roles between itself and the optical board; if the board dependence role indication is a main dependence interface board, the first interface board takes the board itself as a server according to the address identification of the board itself and the port identification of the board itself; if a connection request sent by a second interface board serving as a client is detected, the first interface board sends backup data of a business process to the second interface board through a first unicast channel established with the second interface board; wherein the board role of the second interface board is to be a backup dependent interface board.
Thus, as the master-slave dependency interface board of the optical board, after verifying the board dependency roles of the master-slave dependency interface board, the master-slave dependency interface board synchronizes the backup data of the business process to the slave-slave dependency interface board. The method realizes batch backup and real-time backup between the main and standby interface boards in the novel router, ensures that the running data on the main and standby interface boards are synchronous and timely, and ensures that the optical board interfaces can work continuously.
Optionally, in the foregoing determining process of step 210, a process of creating a unicast channel by the first interface board and sending a connection request to the master dependency interface board when the board dependency role indicates that the first interface board is a backup dependency interface board is further included.
Specifically, according to the description of step 210, if the board dependency role indicates that the first interface board is a backup dependency interface board, the first interface board obtains its own address identifier and a port identifier. The address identifier is the same as the address identifier described in the previous step 220, and the port identifier is the same as the port identifier described in the previous step 220, and will not be repeated here. For example, the port identification of the Socket communication port.
From the description of step 220, the first interface board also obtains the address identifier and the port identifier of the board-dependent role-based dependency interface board from the hardware infrastructure.
Thus, the first interface board takes itself as a Client (Client) according to the address identifier and the port identifier of itself. The first interface board generates and initiates a connection request to a port indicated by the port identification of the master dependent interface board. It will be appreciated that the process of the first interface board sending a connection request to the master dependency interface board is also referred to as the process of the first interface board creating a second unicast channel for communication with the master dependency interface board.
The master dependency interface board periodically detects whether the port indicated by the port identification receives a connection request sent by the first interface board. If the port of the master dependency interface board receives the connection request, the master dependency interface board creates a second unicast channel for communication with the first interface board.
Further, the connection request includes a business process identification and a backup indication for requesting backup data of the synchronized business process from the primary dependency interface board. And the main dependence interface board acquires backup data of the corresponding business process according to the business process identifier and the backup instruction, and sends the backup data to the first interface board through the second unicast channel.
Optionally, in the embodiment of the present application, if the primary dependency interface board fails or is abnormal, the primary dependency interface board is downgraded into a new backup dependency interface board, and one backup dependency interface board is reelected from the original multiple backup dependency interface boards to upgrade into the primary dependency interface board. The specific election process may refer to the existing active-standby switching process, and will not be repeated here.
In the embodiment of the application, the board dependence role of the first interface board is updated from the backup dependence interface board to the new master dependence interface board. At this time, the first interface board closes the aforementioned Client (Client) that uses itself as the second unicast channel. Because the board dependence role of the first interface board is the main dependence interface board, the first interface board acquires the address identifier and a port identifier of the first interface board. The address identifier is the same as the address identifier described in the previous step 220, and the port identifier is the same as the port identifier described in the previous step 220, and will not be repeated here. For example, the port identification of the Socket communication port.
After the active/standby dependent interface boards are switched, the user issues configuration instructions again to each board card in the router, where the configuration instructions include board dependent roles of each interface board (the board dependent roles are new roles of each interface board), address identifiers, and port identifiers. Each board card may store the board-dependent roles, address identifications, port identifications of each interface board within the hardware infrastructure.
Thus, according to the address identification and the port identification of the first interface board, the first interface board takes the first interface board as a Server.
It can be understood that the first interface board acts as a Server (Server) that periodically probes the ports indicated by the port identifiers and waits for a connection request sent by the third interface board acting as a client.
If the service process is started in the third interface board, the third interface board also judges the board dependence roles between the third interface board and the optical board. When the own board dependency role is determined to be indicated as the backup dependency interface board, the third interface board also acquires the address identification and the port identification of the main dependency interface board (i.e. the first interface board) from the local hardware infrastructure again. And generating and initiating a connection request to a port indicated by the port identification of the first interface board by the third interface board according to the address identification and the port identification of the third interface board as well as the address identification and the port identification of the first interface board. After receiving the connection request, the first interface board creates a third unicast channel for communication with the first interface board. At this time, the third interface board uses itself as a Client (Client) of the third unicast channel, and the first interface board uses itself as a Server (Server) of the first unicast channel.
The first interface board periodically detects whether the port indicated by the port identification receives a connection request sent by the third interface board. And if the first interface board receives the connection request, creating a third unicast channel communicated with the third interface board.
In the embodiment of the application, the connection request comprises a service process identifier and a backup indication, which are used for requesting the first interface board to synchronize backup data of the service process. If the port receives the connection request, the first interface board acquires backup data of the corresponding service process, and sends the backup data to the third interface board through the third unicast channel.
Further, in the embodiment of the present application, before the primary/secondary dependency interface board is switched, the primary/secondary dependency interface board may synchronize the backup data of the service process by using the established unicast channel in the manner of step 210-step 230. Therefore, after the main and standby dependent interface boards are switched, the new main dependent interface board can continue to process the service according to the data backed up before, and the service is ensured not to be interrupted.
Optionally, in the embodiment of the present application, if the first interface board with the board dependency role as the master dependency interface board fails or is abnormal, the first interface board is downgraded into a new backup dependency interface board, and one backup dependency interface board is reelected from the original multiple backup dependency interface boards to be upgraded into the master dependency interface board. The specific election process may refer to the existing active-standby switching process, and will not be repeated here.
In an embodiment of the application, the board dependency roles of the first interface board are downgraded from the master dependency interface board to the new backup dependency interface board. At this time, the first interface board closes the Server (Server) using itself as the first unicast channel.
The first interface board obtains its own address identification and a port identification. The address identifier is the same as the address identifier described in the previous step 220, and the port identifier is the same as the port identifier described in the previous step 220, and will not be repeated here. For example, the port identification of the Socket communication port.
The first interface board again obtains the address identification and port identification of the board dependency role as the new master dependency interface board from the hardware infrastructure.
Thus, the first interface board takes itself as a Client (Client) according to the address identifier and the port identifier of itself. The first interface board generates and initiates a connection request to a port indicated by the port identification of the master dependent interface board. It will be appreciated that the process of the first interface board sending a connection request to the new master dependency interface board is also referred to as the process of the first interface board creating a fourth unicast channel for communication with the new master dependency interface board.
The new master dependency interface board periodically detects whether the port indicated by the port identification receives the connection request sent by the first interface board. If the port of the new master dependency interface board receives the connection request, the new master dependency interface board creates a fourth unicast channel for communication with the first interface board.
Further, the connection request includes a business process identification and a backup indication for requesting backup data of the synchronized business process from the new primary dependency interface board. And the new main dependency interface board acquires backup data of the corresponding business process according to the business process identifier and the backup instruction, and sends the backup data to the first interface board through the fourth unicast channel.
Optionally, in the embodiment of the present application, if the primary dependency interface board fails or is abnormal, the primary dependency interface board is downgraded into a new backup dependency interface board, and one backup dependency interface board is reelected from the original multiple backup dependency interface boards to upgrade into the primary dependency interface board. The specific election process may refer to the existing active-standby switching process, and will not be repeated here.
In the embodiment of the application, the board dependency roles of the first interface board are still maintained as the backup dependency interface board. At this time, the first interface board closes the aforementioned Client (Client) that uses itself as the second unicast channel.
The first interface board again obtains the address identification and port identification of the new master dependent interface board from the hardware infrastructure.
The first interface board obtains its own address identification and a port identification. The address identifier is the same as the address identifier described in the previous step 220, and the port identifier is the same as the port identifier described in the previous step 220, and will not be repeated here. For example, the port identification of the Socket communication port.
In this way, the first interface board takes itself as a Client (Client) again according to its address identifier and port identifier. The first interface board generates and initiates a connection request to a port indicated by the port identification of the new master dependent interface board. It will be appreciated that the process by which the first interface board sends a connection request to the new master dependency interface board is also referred to as the process by which the first interface board creates a fifth unicast channel for communication with the new master dependency interface board.
The new master dependency interface board periodically detects whether the port indicated by the port identification receives the connection request sent by the first interface board. If the port of the new master dependency interface board receives the connection request, the new master dependency interface board creates a fifth unicast channel for communication with the first interface board.
Further, the connection request includes a business process identification and a backup indication for requesting backup data of the synchronized business process from the new primary dependency interface board. And the new main dependency interface board acquires backup data of the corresponding business process according to the business process identifier and the backup instruction, and sends the backup data to the first interface board through the fifth unicast channel.
Optionally, in the embodiment of the present application, a case of failure of the unicast channel may also occur, and at this time, the master dependency interface board may decide the processing policy by the master control board by reporting the master control board.
Specifically, according to the description of step 210, a main control board is also included in the router. The master control board establishes a physical connection with the master dependency interface board.
The master dependency interface board periodically detects the working state of the unicast channel, and if the unicast channel fails, namely the working state of the unicast channel is abnormal or fails, the master dependency interface board acquires the failure reason of the unicast channel failure and generates notification messages. The notification message includes a failure cause of the unicast channel failure.
The master dependency interface board sends a notification message to the master control board. After receiving the notification message, the main control board acquires the failure reason of the unicast channel failure from the notification message, and selects a corresponding processing strategy according to the failure reason.
Further, the processing policy may include restarting the master dependency interface board, the standby dependency interface board, or the master and standby dependency interface boards, respectively, or displaying a hint message to hint that a user needs to make a decision to restore the approach.
For example, the working state of the unicast channel is abnormal, the abnormal is caused by the port of the backup dependent interface board, and then the processing strategy restarts the backup dependent interface board. And if the working state of the unicast channel is a fault and the fault cause cannot be determined, the processing strategy is to display prompt information.
Optionally, in the embodiment of the present application, backup data of the service process may be synchronized between the active and standby dependency interface boards in a manner of not establishing a unicast channel.
Specifically, according to the description of step 210, a main control board is also included in the router. The main control board establishes physical connection with the main dependent interface board and the standby dependent interface board respectively,
After the first interface board executes step 210, if the board dependency role indicates that the first interface board is a master dependency interface board, the first interface board sends backup data of the service process to the master control board. And after receiving the backup data of the service process, the main control board forwards the backup data of the service process to the backup dependent interface boards, so that the data backup between the main and backup dependent interface boards is realized.
Optionally, the router in the embodiment of the present application may be adapted to be used in an IRF stacking environment, as shown in fig. 3, where fig. 3 is a schematic diagram of data backup between dependency boards in the IRF stacking environment for an M subrack provided in the embodiment of the present application.
In fig. 3, the first frame may be embodied as a first router frame including various types of cards constituting the first router therein, and the second frame may be embodied as a second router frame including various types of cards constituting the second router therein. The first router and the second router form an IRF stacking environment. Each frame comprises a main control board and a standby control board. The master control board establishes physical full connection with the master-slave dependent interface boards respectively.
And each frame comprises a main dependency interface board and a standby dependency interface board, and unicast channels are created between the main dependency interface boards and the standby dependency interface boards. The master dependency interface board is a Server side (Server) of a unicast channel, and the standby dependency interface board is a Client side (Client) of the unicast channel. The backup dependent interface board can acquire the address identification, port identification and other information of the main dependent interface board of the frame from the hardware underlying structure of the backup dependent interface board, and is appointed to be connected with the main dependent interface board in the frame.
Within each frame, the optical boards establish physical connections with the master and slave dependent interface boards, respectively. An IRF stacking link can be established between an interface included in the light plate in the frame and an interface included in the light plate in the adjacent frame.
It will be appreciated that the process of performing a data synchronization backup between the primary and secondary dependent interface boards may refer to the descriptions of steps 210-230 and the descriptions of the optional steps described above, and will not be repeated here.
Based on the same inventive concept, the embodiment of the application also provides a data backup device corresponding to the data backup method. Referring to fig. 4, fig. 4 is a block diagram of a data backup device according to an embodiment of the present application. The device is applied to a first interface board, the first interface board is positioned in a router, the router further comprises a second interface board and an optical board, the optical board respectively establishes physical connection with the first interface board and the second interface board, and the device comprises:
a judging unit 410, configured to judge a board dependency role between the first interface board and the optical board after a business process is started in the first interface board;
an execution unit 420, configured to, if the board dependency role indicates that the first interface board is a master dependency interface board, take the first interface board as a server according to an address identifier of the first interface board and a port identifier of the first interface board;
A sending unit 430, configured to send backup data of the service process to a second interface board through a first unicast channel established with the second interface board if a connection request sent by the second interface board as a client is detected;
wherein the board role of the second interface board is to be a backup dependent interface board
Optionally, the apparatus further comprises: an obtaining unit (not shown in the figure) configured to obtain an address identifier of a master dependency interface board and a port identifier of the master dependency interface board in the router if the board dependency role indicates that the first interface board is a backup dependency interface board;
the execution unit 420 is further configured to use the first interface board as the client according to the address identifier of the first interface board and the port identifier of the first interface board;
the sending unit 430 is further configured to send a connection request to a port corresponding to the master dependency interface board through a second unicast channel established with the master dependency interface board;
the apparatus further comprises: and a receiving unit (not shown in the figure) configured to receive, through the second unicast channel, backup data of the service process sent by the primary dependency interface board according to the connection request.
Optionally, the apparatus further comprises: a closing unit (not shown in the figure) for closing the client when the board dependency character of the first interface board is updated from the backup dependency interface board to a new master dependency interface board;
the execution unit 420 is further configured to use the first interface board as the server according to the address identifier of the first interface board and the port identifier of the first interface board;
the sending unit 430 is further configured to send, if a connection request sent by a third interface board that is a client is detected, backup data of the service process to the third interface board through a third unicast channel established with the third interface board;
and the board dependency roles of the third interface board are the backup dependency interface boards.
Optionally, the closing unit (not shown in the figure) is further configured to close the server when the board dependency role of the first interface board is downgraded from the master dependency interface board to a new dependency interface board;
the acquiring unit (not shown in the figure) is further configured to acquire an address identifier of the new host dependent interface board and a port identifier of the new host dependent interface board;
the execution unit 420 is further configured to use the first interface board as the client according to the address identifier of the first interface board and the port identifier of the first interface board;
The sending unit 430 is further configured to send a connection request to a port corresponding to the new master dependency interface board through a fourth unicast channel established with the new master dependency interface board;
the sending unit 430 is further configured to receive, through the fourth unicast channel, backup data of the service process sent by the new primary dependency interface board according to the connection request.
Optionally, the closing unit (not shown in the figure) is further configured to close the client when the master dependency interface board has been downgraded to a standby dependency interface board and the board dependency role of the first interface board is maintained as a standby dependency interface board;
the acquiring unit (not shown in the figure) is further configured to acquire an address identifier of the new host dependent interface board and a port identifier of the new host dependent interface board;
the execution unit 420 is further configured to take the first interface board as the client again according to the address identifier of the first interface board and the port identifier of the first interface board;
the sending unit 430 is further configured to send a connection request to a port corresponding to the new master dependency interface board through a fifth unicast channel established with the new master dependency interface board;
The sending unit 430 is further configured to receive, through the fifth unicast channel, backup data of the service process sent by the new master dependency interface board according to the connection request.
Optionally, the apparatus further comprises: and the establishing unit (not shown in the figure) is used for establishing a unicast channel with the standby dependent interface board or the main dependent interface board if the interface board determines that the board dependent role of the interface board is the main dependent interface board or the standby dependent interface board.
Optionally, the router further comprises a main control board, and the main control board establishes physical connection with the main dependent interface board;
the sending unit 430 is further configured to send a notification message to the main control board if the unicast channel fails, where the notification message includes a failure reason for the unicast channel failure, so that the main control board selects a corresponding processing policy according to the failure reason.
Optionally, the router further includes a main control board, and the main control board establishes physical connection with the main dependency interface board and the standby dependency interface board respectively;
the sending unit 430 is further configured to send backup data of the service process to the main control board if the board dependency role indicates that the first interface board is a master dependency interface board, so that the main control board forwards the backup data of the service process to the backup dependency interface board.
Optionally, the backup data includes batch backup data of the business process, or real-time backup data of the business process.
Therefore, by applying the data backup device provided by the application, after the business process is started in the first interface board, the first interface board judges the board dependent roles between itself and the optical board; if the board dependence role indication is a main dependence interface board, the first interface board takes the board itself as a server according to the address identification of the board itself and the port identification of the board itself; if a connection request sent by a second interface board serving as a client is detected, the first interface board sends backup data of a business process to the second interface board through a first unicast channel established with the second interface board; wherein the board role of the second interface board is to be a backup dependent interface board.
Thus, as the master-slave dependency interface board of the optical board, after verifying the board dependency roles of the master-slave dependency interface board, the master-slave dependency interface board synchronizes the backup data of the business process to the slave-slave dependency interface board. The method realizes batch backup and real-time backup between the main and standby interface boards in the novel router, ensures that the running data on the main and standby interface boards are synchronous and timely, and ensures that the optical board interfaces can work continuously.
Based on the same inventive concept, the embodiment of the present application also provides a network device, as shown in fig. 5, including a processor 510, a transceiver 520, and a machine-readable storage medium 530, where the machine-readable storage medium 530 stores machine executable instructions capable of being executed by the processor 510, and the processor 510 is caused by the machine executable instructions to perform the data backup method provided by the embodiment of the present application. The data backup device shown in fig. 4 may be implemented by using a hardware structure of a network device as shown in fig. 5.
The computer readable storage medium 530 may include a random access Memory (hereinafter referred to as "RAM") or a nonvolatile Memory (hereinafter referred to as "Non-volatile Memory") such as at least one magnetic disk Memory. Optionally, the computer readable storage medium 530 may also be at least one storage device located remotely from the aforementioned processor 510.
The processor 510 may be a general-purpose processor, including a central processing unit (Central Processing Unit, CPU), a network processor (Network Processor, NP), etc.; it may also be a digital signal processor (English: digital Signal Processor; DSP; for short), an application specific integrated circuit (English: application Specific Integrated Circuit; ASIC; for short), a Field programmable gate array (English: field-Programmable Gate Array; FPGA; for short), or other programmable logic device, discrete gate or transistor logic device, discrete hardware components.
In an embodiment of the present application, processor 510 is enabled by reading machine-executable instructions stored in machine-readable storage medium 530, which cause processor 510 itself to be implemented and transceiver 520 to be invoked to perform the data backup method described in the previous embodiment of the present application.
Additionally, embodiments of the present application provide a machine-readable storage medium 530, the machine-readable storage medium 530 storing machine-executable instructions that, when invoked and executed by the processor 510, cause the processor 510 itself and the invoking transceiver 520 to perform the data backup method described in the previous embodiments of the present application.
The implementation process of the functions and roles of each unit in the above device is specifically shown in the implementation process of the corresponding steps in the above method, and will not be described herein again.
For the device embodiments, reference is made to the description of the method embodiments for the relevant points, since they essentially correspond to the method embodiments. The apparatus embodiments described above are merely illustrative, wherein the elements illustrated as separate elements may or may not be physically separate, and the elements shown as elements may or may not be physical elements, may be located in one place, or may be distributed over a plurality of network elements. Some or all of the modules may be selected according to actual needs to achieve the purposes of the present application. Those of ordinary skill in the art will understand and implement the present application without undue burden.
For the data backup device and the machine-readable storage medium embodiments, since the method content involved is substantially similar to the method embodiments described above, the description is relatively simple, and reference will only be made to the description of some of the method embodiments for relevant points.
The foregoing description of the preferred embodiments of the application is not intended to be limiting, but rather to enable any modification, equivalent replacement, improvement or the like to be made within the spirit and principles of the application.

Claims (10)

1. A data backup method, characterized in that a router includes a primary and a secondary forwarding boards, the primary and secondary forwarding boards are set to interface board roles on a software level, and the optical boards respectively establish physical connection with a first interface board and a second interface board, and the method is applied to the first interface board, and the method includes:
judging a board dependence role between the first interface board and the optical board after a business process is started in the first interface board;
if the board dependence role indicates that the first interface board is a main dependence interface board, the first interface board is used as a server according to the address identification of the first interface board and the port identification of the first interface board;
If a connection request sent by a second interface board serving as a client is detected, sending backup data of the business process to the second interface board through a first unicast channel established with the second interface board;
wherein the board role of the second interface board is to be a backup dependent interface board.
2. The method according to claim 1, wherein the method further comprises:
if the board dependence role indicates that the first interface board is a standby dependence interface board, acquiring an IP address of a main dependence interface board and a port identification of the main dependence interface board in the router;
taking the first interface board as the client according to the address identification of the first interface board and the port identification of the first interface board;
sending a connection request to a port corresponding to the main dependence interface board through a second unicast channel established with the main dependence interface board;
and receiving backup data of the business process sent by the main dependency interface board according to the connection request through the second unicast channel.
3. The method according to claim 2, wherein the method further comprises:
when the board dependency roles of the first interface board are updated from the standby dependency interface board to a new main dependency interface board, closing the client;
According to the address identification of the first interface board and the port identification of the first interface board, the first interface board is used as the server side;
if a connection request sent by a third interface board serving as a client is detected, sending backup data of the business process to the third interface board through a third unicast channel established with the third interface board;
and the board dependency roles of the third interface board are the backup dependency interface boards.
4. The method according to claim 1, wherein the method further comprises:
when the board dependency roles of the first interface board are degraded from the main dependency interface board to the new standby dependency interface board, closing the server side;
acquiring an address identifier of a new main dependency interface board and a port identifier of the new main dependency interface board;
taking the first interface board as the client according to the address identification of the first interface board and the port identification of the first interface board;
sending a connection request to a port corresponding to the new master dependency interface board through a fourth unicast channel established with the new master dependency interface board;
and receiving backup data of the business process sent by the new main dependency interface board according to the connection request through the fourth unicast channel.
5. The method according to claim 2, wherein the method further comprises:
closing the client when the master dependency interface board has been downgraded to a new standby dependency interface board and the board dependency role of the first interface board is maintained as a standby dependency interface board;
acquiring an address identifier of a new main dependency interface board and a port identifier of the new main dependency interface board;
according to the address identification of the first interface board and the port identification of the first interface board, the first interface board is used as the client again;
transmitting a connection request to a port corresponding to the new master dependency interface board through a fifth unicast channel established with the new master dependency interface board;
and receiving backup data of the business process sent by the new main dependency interface board according to the connection request through the fifth unicast channel.
6. The method according to any one of claims 1-5, further comprising:
if the interface board determines that the board dependency role of the interface board is the main dependency interface board or the standby dependency interface board, a unicast channel is established with the standby dependency interface board or the main dependency interface board.
7. The method of claim 6, wherein the router further comprises a master control board, the master control board establishing a physical connection with the master dependency interface board; the method comprises the following steps:
If the unicast channel fails, a notification message is sent to the main control board, wherein the notification message comprises the failure reason of the unicast channel failure, so that the main control board selects a corresponding processing strategy according to the failure reason.
8. The method of claim 1, wherein the router further comprises a master control board, the master control board establishing physical connections with the master dependency interface board and the backup dependency interface board, respectively;
after the determining of the board dependent role between the first interface board and the light board, the method further comprises:
and if the board dependence role indicates that the first interface board is a main dependence interface board, sending backup data of the business process to the main control board so that the main control board forwards the backup data of the business process to the backup dependence interface board.
9. The method of claims 1-5, or 8, wherein the backup data comprises bulk backup data of the business process or real-time backup data of the business process.
10. A data backup device, characterized in that a router includes a primary and a backup forwarding boards and an optical board, the primary and backup forwarding boards are set to an interface board role on a software level, the optical board establishes physical connection with a first interface board and a second interface board, respectively, the device is applied to the first interface board, and the device includes:
The judging unit is used for judging the board dependence roles between the first interface board and the optical board after the business process is started in the first interface board;
the execution unit is used for taking the first interface board as a server according to the address identification of the first interface board and the port identification of the first interface board if the board dependency role indicates that the first interface board is a main dependency interface board;
a sending unit, configured to send backup data of the service process to a second interface board through a first unicast channel established with the second interface board if a connection request sent by the second interface board as a client is detected;
wherein the board role of the second interface board is to be a backup dependent interface board.
CN202210057358.2A 2022-01-19 2022-01-19 Data backup method and device Active CN114598643B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210057358.2A CN114598643B (en) 2022-01-19 2022-01-19 Data backup method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210057358.2A CN114598643B (en) 2022-01-19 2022-01-19 Data backup method and device

Publications (2)

Publication Number Publication Date
CN114598643A CN114598643A (en) 2022-06-07
CN114598643B true CN114598643B (en) 2023-10-13

Family

ID=81804459

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210057358.2A Active CN114598643B (en) 2022-01-19 2022-01-19 Data backup method and device

Country Status (1)

Country Link
CN (1) CN114598643B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104852858A (en) * 2015-03-24 2015-08-19 杭州华三通信技术有限公司 Traffic forwarding method and equipment
CN109600270A (en) * 2019-01-25 2019-04-09 新华三技术有限公司 Network equipment control method and the network equipment
CN109831326A (en) * 2019-01-25 2019-05-31 新华三技术有限公司 Network equipment control method and the network equipment
CN113485877A (en) * 2021-06-17 2021-10-08 新华三信息安全技术有限公司 Detection method and device

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102223304B (en) * 2011-06-16 2014-08-27 杭州华三通信技术有限公司 Method and device for continuously forwarding after main/standby switch

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104852858A (en) * 2015-03-24 2015-08-19 杭州华三通信技术有限公司 Traffic forwarding method and equipment
CN109600270A (en) * 2019-01-25 2019-04-09 新华三技术有限公司 Network equipment control method and the network equipment
CN109831326A (en) * 2019-01-25 2019-05-31 新华三技术有限公司 Network equipment control method and the network equipment
CN113485877A (en) * 2021-06-17 2021-10-08 新华三信息安全技术有限公司 Detection method and device

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于热备份的主备倒换在高端路由器中的应用;张玉峰;孙知信;;计算机技术与发展(第03期);全文 *

Also Published As

Publication number Publication date
CN114598643A (en) 2022-06-07

Similar Documents

Publication Publication Date Title
CN107919994B (en) Method and server for realizing hot standby of network service dual-computer
CN104615455B (en) A kind of the IPMC program remote upgrading methods and device of ATCA frameworks
EP3787232A1 (en) Network configuration method, device, and system
CN106982133B (en) Method, equipment and system for changing configuration information of virtual network card
CN108199962B (en) Address migration method and device, network equipment and readable storage medium
CN104503861A (en) Abnormality handling method and system, agency device and control device
CN111585835B (en) Control method and device for out-of-band management system and storage medium
CN113794587A (en) Port configuration method and device
CN114297296A (en) Server active-standby switching system for broadcasting
CA3138764A1 (en) Data processing method, device, computer equipment and storage medium
EP4030776A1 (en) Method and apparatus for triggering vomci function from olt to send omci messages
CN112000444B (en) Database transaction processing method and device, storage medium and electronic equipment
CN112019614B (en) Method, system and processor for communication and communication synchronization between two systems
CN114598643B (en) Data backup method and device
CN110958287A (en) Operation object data synchronization method, device and system
US11128558B2 (en) Automatic routing configuration between hosts and network layer devices
CN110795212B (en) Main/standby main control configuration synchronization method and device based on frame type equipment
CN113821334A (en) Method, device and system for configuring edge side equipment
CN112714035A (en) Monitoring method and system
CN110890989A (en) Channel connection method and device
CN111510336B (en) Network equipment state management method and device
CN115426258B (en) Information configuration method, device, switch and readable storage medium
CN112671561B (en) Network card configuration method and equipment of cloud host
CN115001950A (en) Database cluster fault processing method, storage medium and equipment
CN117714276A (en) Redis cluster deployment method and device, storage medium and electronic equipment

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