A BFD session maintenance system, method and device

By establishing a mechanism for transferring agent item information between the main control board and the business board, the problem of BFD session interruption caused by failure of the main business board is solved, and the rapid switching and maintenance of BFD sessions is realized, and the speed of link failure detection is improved. and accuracy.

CN115766407BActive Publication Date: 2025-02-21NEW H3C TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211182009.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-27
Publication Date
2025-02-21
Estimated Expiration
2042-09-27

AI Technical Summary

Technical Problem

In the case of a failure of the main service board, the BFD session in the prior art will be interrupted, resulting in the speed of link failure detection between network devices based on the BFD protocol.

Method used

By establishing a mechanism for transferring agent item information between the main control board and the business board, the slave business board can update and maintain a BFD session state consistent with the main business board. When the main business board fails, the main control board selects a slave business board as the new main business board and sends switching information to all business boards to ensure the continuity of the BFD session.

Benefits of technology

In the event of a failure of the main business board, it can quickly switch to the slave business board and continue to maintain the BFD session, avoiding session interruption and improving the speed and accuracy of link failure detection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115766407B_ABST
    Figure CN115766407B_ABST
Patent Text Reader

Abstract

The embodiment of the present invention provides a BFD session maintenance system, method and device, the system comprising: a main control board and at least two service boards; the main service board is used to receive a first BFD message and update its own BFD session state, send BFD session information to the main control board, and send a second BFD message to the opposite device; the main control board is used to generate and store proxy table entry information according to the BFD session information, and send the proxy table entry information to each slave service board; each slave service board is used to update its own BFD session state according to the proxy table entry information; the main control board is also used to select a slave service board as a new master service board when determining that the current master service board fails, and send switching information to each service board; each service board is also used to determine the new master service board according to the switching information. By applying the solution provided by the embodiment of the present invention, the network equipment can ensure link fault detection based on the BFD protocol.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of communication technology, and in particular to a BFD session maintenance system, method and device. Background Art

[0002] The BFD (Bidirectional Forwarding Detection) protocol is used to quickly detect the connectivity of communication links in the network. The specific method is: after two network devices in the network establish a BFD session, each network device periodically sends a BFD data packet to the other network device, that is, the peer device, so that the peer device determines that the current communication link is connected. If one of the network devices does not receive the BFD data packet within the agreed time, it can be determined that the communication link between the network devices is faulty. The BFD protocol can achieve millisecond-level link detection, greatly improving the detection speed and recovery speed of link failures.

[0003] The network equipment includes a main control board and multiple service boards. When the interface for receiving BFD messages is a global interface shared by all service boards, each service board can work through the global interface. The main control board needs to select a service board as the main service board to be responsible for sending and receiving BFD messages and maintaining the BFD session. Other service boards serve as slave service boards. However, in the event of a failure in the main service board, the current BFD session will be interrupted. In the prior art, data interaction is required between the slave service boards to select a slave service board as the new main service board to re-establish and maintain the BFD session. This process takes a long time, which affects the link fault detection based on the BFD protocol between network devices. Summary of the invention

[0004] The purpose of the embodiments of the present invention is to provide a BFD session maintenance system, method and device, so that when the main service board fails, link fault detection can be performed between network devices based on the BFD protocol. The specific technical solution is as follows:

[0005] In a first aspect, an embodiment of the present invention provides a BFD session maintenance system, the system comprising: a main control board and at least two service boards, wherein the main control board is connected to each service board respectively, the service board is divided into a main service board and at least one slave service board, each service board includes a global interface, and the global interface is: an interface shared by each service board;

[0006] The main business board is used to receive a first BFD message sent by a peer device from the global interface, update its own BFD session state according to the first state information in the first BFD message, send BFD session information to the main control board, and send a second BFD message to the peer device, wherein the first state information represents: the BFD session state of the peer device, the BFD session information and the second BFD message include second state information, and the second state information represents: the BFD session state after the main business board is updated;

[0007] The main control board is used to generate and store proxy table entry information according to the BFD session information, and send the proxy table entry information to each slave service board, wherein the proxy table entry information includes the BFD session information;

[0008] Each slave service board is used to update its own BFD session state according to the proxy entry information;

[0009] The main control board is further used to select a slave business board as a new master business board when it is determined that the current master business board fails, and send switching information to each business board respectively, wherein the switching information indicates: the selected slave business board is used as the new master business board;

[0010] Each service board is also used to determine a new main service board according to the switching information.

[0011] In a second aspect, an embodiment of the present invention provides a BFD session maintenance method, which is applied to a BFD session maintenance system, wherein the BFD session maintenance system includes: a main control board and at least two service boards, wherein the main control board is connected to each service board respectively, and the service board is divided into a main service board and at least one slave service board, and each service board includes a global interface, and the global interface is: an interface shared by each service board, and the method includes:

[0012] Receiving a first BFD message sent by a peer device from the global interface through the main business board, updating its own BFD session state according to the first state information in the first BFD message, sending BFD session information to the main control board, and sending a second BFD message to the peer device, wherein the first state information indicates: the BFD session state of the peer device, the BFD session information and the second BFD message include second state information, and the second state information indicates: the BFD session state after the main business board is updated;

[0013] Generate and store proxy table entry information according to the BFD session information by the main control board, and send the proxy table entry information to each slave service board, wherein the proxy table entry information includes the BFD session information;

[0014] Each slave service board updates its own BFD session state according to the proxy entry information;

[0015] When the main control board determines that the current main business board fails, a slave business board is selected as a new main business board, and switching information is sent to each business board respectively, wherein the switching information indicates: the selected slave business board is used as the new main business board;

[0016] A new main service board is determined by each service board according to the switching information.

[0017] In a third aspect, an embodiment of the present invention provides a BFD session maintenance device, which is applied to a BFD session maintenance system, wherein the BFD session maintenance system includes: a main control board and at least two service boards, wherein the main control board is connected to each service board respectively, and the service board is divided into a main service board and at least one slave service board, and each service board includes a global interface, and the global interface is: an interface shared by each service board, and the device includes:

[0018] A first sending module, configured to receive a first BFD message sent by a peer device from the global interface through the main business board, update its own BFD session state according to the first state information in the first BFD message, send BFD session information to the main control board, and send a second BFD message to the peer device, wherein the first state information indicates: the BFD session state of the peer device, the BFD session information and the second BFD message include second state information, and the second state information indicates: the BFD session state after the main business board is updated;

[0019] A second sending module, configured to generate and store proxy table entry information according to the BFD session information through the main control board, and send the proxy table entry information to each slave service board, wherein the proxy table entry information includes the BFD session information;

[0020] An updating module, configured to update the BFD session state of each slave service board according to the proxy entry information;

[0021] A selection module is used to select a slave business board as a new master business board through the main control board when determining that the current master business board fails, and send switching information to each business board respectively, wherein the switching information indicates: the selected slave business board is used as the new master business board;

[0022] A determination module is used to determine a new main business board through each business board according to the switching information.

[0023] In a fourth aspect, an embodiment of the present invention provides an electronic device, including a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus;

[0024] Memory, used to store computer programs;

[0025] The processor is used to implement any method step described in the second aspect when executing the program stored in the memory.

[0026] In a fifth aspect, an embodiment of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, any method step described in the second aspect is implemented.

[0027] In a sixth aspect, an embodiment of the present invention further provides a computer program product comprising instructions, which, when executed on a computer, enables the computer to execute any one of the method steps described in the second aspect.

[0028] Beneficial effects of the embodiments of the present invention:

[0029] An embodiment of the present invention provides a BFD session maintenance system, the system comprising: a main control board and at least two service boards, wherein the main control board is connected to each service board respectively, the service boards are divided into a main service board and at least one slave service board, each service board includes a global interface, and the global interface is: an interface shared by each service board. The main service board is used to receive a first BFD message sent by a peer device from the global interface, update its own BFD session state according to the first state information in the first BFD message, send BFD session information to the main control board, and send a second BFD message to the peer device, wherein the first state information indicates: the BFD session state of the peer device, the BFD session information and the second BFD message include second state information, and the second state information indicates: the BFD session state after the main service board is updated; the main control board is used to update the BFD session state according to the BFD session information , generate and store proxy table entry information, send the above proxy table entry information to each slave business board, wherein the above proxy table entry information includes the above BFD session information; each slave business board is used to update its own BFD session state according to the above proxy table entry information; the above main control board is also used to select a slave business board as a new master business board when it is determined that the current master business board fails, and send switching information to each business board respectively, wherein the above switching information indicates: the selected slave business board is used as the new master business board; each business board is also used to determine the new master business board according to the above switching information.

[0030] In the solution provided by the embodiment of the present invention, the main business board responsible for maintaining the BFD session updates the current BFD session state by receiving the first BFD message sent by the opposite device, and sends the current BFD session state to the main control board, which sends the BFD session state of the main business board to all slave business boards, so that all slave business boards update their own BFD session states to the BFD session state of the main business board, that is, the BFD session states of the main business board and the slave business boards are kept consistent. When the main business board fails, the main control board selects one from the slave business boards to become a new main business board responsible for maintaining the BFD session. Since the BFD session states of all business boards are consistent, when the new main business board receives the new BFD message sent by the opposite device, the new main business board can directly send a BFD message to the opposite device, and the BFD message is the same as the BFD message that the original main business board will send to the opposite device after receiving the BFD message. Therefore, in the event of a failure of the main service board, the slave service board selected by the main control board can replace the original main service board to send and receive BFD messages, so that the BFD session will not be interrupted, and there is no need to re-create the BFD session. This will not affect the link fault detection based on the BFD protocol between devices, and can improve the rapid convergence capability of the BFD session. BRIEF DESCRIPTION OF THE DRAWINGS

[0031] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present invention. For ordinary technicians in this field, other embodiments can also be obtained based on these drawings.

[0032] Figure 1 A schematic diagram of the structure of a first BFD session maintenance system provided in an embodiment of the present invention;

[0033] Figure 2 A flowchart of a first BFD session maintenance method provided in an embodiment of the present invention;

[0034] Figure 3 A flowchart of a second BFD session maintenance method provided in an embodiment of the present invention;

[0035] Figure 4 A schematic diagram of the structure of a second BFD session maintenance system provided in an embodiment of the present invention;

[0036] Figure 5 A flowchart of a third BFD session maintenance method provided in an embodiment of the present invention;

[0037] Figure 6 A flowchart of a fourth BFD session maintenance method provided in an embodiment of the present invention;

[0038] Figure 7 A flowchart of a fifth BFD session maintenance method provided in an embodiment of the present invention;

[0039] Figure 8 A flowchart of a sixth BFD session maintenance method provided by an embodiment of the present invention;

[0040] Fig. 9 A flowchart of a seventh BFD session maintenance method provided in an embodiment of the present invention;

[0041] Fig.10 A schematic diagram of the structure of a BFD session maintenance device provided in an embodiment of the present invention;

[0042] Fig.11 A schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0043] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field based on the present invention belong to the scope of protection of the present invention.

[0044] In order to ensure that link fault detection can be performed between network devices based on the BFD protocol, an embodiment of the present invention provides a BFD session maintenance system, method and apparatus.

[0045] An embodiment of the present invention provides a BFD session maintenance system, which includes: a main control board and at least two business boards, wherein the main control board is connected to each business board respectively, and the business boards are divided into a main business board and at least one slave business board, and each business board includes a global interface, and the global interface is: an interface shared by each business board.

[0046] The main service board is configured to receive a first BFD message sent by a peer device from the global interface, update its own BFD session state according to the first state information in the first BFD message, send BFD session information to the main control board, and send a second BFD message to the peer device;

[0047] The main control board is used to generate and store proxy table entry information according to the BFD session information, and send the proxy table entry information to each slave service board;

[0048] Each slave service board is used to update its own BFD session state according to the above proxy entry information;

[0049] The main control board is also used to select a slave service board as a new master service board when it is determined that the current master service board fails, and send switching information to each service board respectively;

[0050] Each service board is also used to determine a new main service board according to the above switching information.

[0051] In the solution provided by the embodiment of the present invention, the main business board responsible for maintaining the BFD session updates the current BFD session state by receiving the first BFD message sent by the opposite device, and sends the current BFD session state to the main control board, which sends the BFD session state of the main business board to all slave business boards, so that all slave business boards update their own BFD session states to the BFD session state of the main business board, that is, the BFD session states of the main business board and the slave business boards are kept consistent. When the main business board fails, the main control board selects one from the slave business boards to become a new main business board responsible for maintaining the BFD session. Since the BFD session states of all business boards are consistent, when the new main business board receives the new BFD message sent by the opposite device, the new main business board can directly send a BFD message to the opposite device, and the BFD message is the same as the BFD message that the original main business board will send to the opposite device after receiving the BFD message. Therefore, in the event of a failure of the main service board, the slave service board selected by the main control board can replace the original main service board to send and receive BFD messages, so that the BFD session will not be interrupted, and there is no need to re-create the BFD session. This will not affect the link fault detection based on the BFD protocol between devices, and can improve the rapid convergence capability of the BFD session.

[0052] Figure 1 The structural diagram of the first BFD session maintenance system provided in the embodiment of the present invention, the system includes a main control board 101 and at least two service boards, wherein the main control board 101 is connected to each service board respectively, and the service boards are divided into a main service board 102 and at least one slave service board 103. The BFD session maintenance system shown in the figure is only an embodiment, and the number of slave service boards 103 in the embodiment of the present invention can be one or more, and there is no limitation on this. Each service board includes a global interface, and the global interface is: an interface shared by each service board.

[0053] Specifically, the main control board 101 is responsible for coordinating and controlling all business boards. The main business board 102 and the slave business board 103 both include global interfaces. The main business board 102 is the business board selected by the main control board 101 to be responsible for maintaining the BFD session, that is, the business board that receives and sends BFD packets. The slave business board 103 includes a global interface but does not receive and send BFD packets through the global interface.

[0054] In addition, a network device that performs link detection through the BFD protocol needs to periodically send BFD messages to other network devices and receive BFD messages sent by other network devices. Therefore, the above-mentioned BFD session maintenance system is configured in any network device that can communicate through a BFD session.

[0055] Figure 2 The present invention provides a flow chart of a first BFD session maintenance method according to an embodiment of the present invention. The method includes the following steps S201-S209.

[0056] Step S201: The main service board 102 receives a first BFD message sent by a peer device from the global interface, and updates its own BFD session state according to first state information in the first BFD message.

[0057] The first status information indicates: the BFD session status of the opposite device.

[0058] Specifically, since the first BFD message includes the first status information representing the BFD session status of the peer device, the main business board 102 can obtain the BFD session status of the peer device by receiving the first BFD message sent by the peer device, and then change its own BFD session status according to the BFD session status of the peer device and the BFD session status before the main business board 102 receives the first BFD message. That is, the BFD session status of the main business board 102 after the update is jointly determined by the BFD session status of the peer device and the original BFD session status of the main business board 102.

[0059] The first BFD message is periodically sent from the peer device to the main service board 102, and the sending period is in milliseconds. The sending period is not specifically limited in the embodiment of the present invention. Therefore, the main service board 102 can obtain the BFD session state of the peer device in time and change its own BFD session state.

[0060] In addition, the above BFD session states include: Down (disconnected), Init (establishing), Up (successfully established), and AdminDown (administratively disconnected).

[0061] In one embodiment of the present invention, the global interface includes at least one of the following interfaces: Vlan (Virtual Local Area Network) virtual interface, routing aggregation interface, routing aggregation sub-interface, Loopback interface, and Layer 2 aggregation interface.

[0062] Specifically, the main service board 102 can receive and send BFD packets through the above-mentioned global interface, and the slave service board 103 should also include the same global interface as the main service board 102 .

[0063] In addition, the interface shared by all other service boards may also be used as a global interface. The embodiment of the present invention only provides an example of a global interface and does not limit the specific interface form of the global interface.

[0064] The solution provided by the embodiment of the present invention can be applied to various types of global interfaces, so that the application scenarios of the BFD session maintenance system are more diverse.

[0065] Step S202: The main service board 102 sends a second BFD message to the opposite device.

[0066] The second BFD message includes second status information, and the second status information indicates: the updated BFD session status of the main service board 102 .

[0067] Specifically, the main service board 102 informs the peer device of the updated BFD session state of itself through the second BFD message, so that the peer device can also timely obtain the BFD session state of the main service board 102. The BFD session between the main service board and the peer device can be maintained by receiving the first BFD message from the peer device and sending the second BFD message to the peer device through the main service board.

[0068] Step S203 , the main service board 102 sends BFD session information to the main control board 101 .

[0069] The BFD session information includes the second state information.

[0070] Specifically, after the main business board 102 updates its own BFD session status according to the first BFD message, it sends the BFD session information containing the second status information representing the updated BFD session status of the main business board 102 to the main control board 101, so that the main control board 101 can synchronously determine the BFD session status of the main business board 102.

[0071] In addition, the opposite device periodically sends the first BFD message, and the main service board 102 sends BFD session information to the main control board 101 every time after receiving the first BFD message, that is, periodically sends BFD session information to the main control board 101.

[0072] Step S204: the main control board 101 generates and stores proxy entry information according to the BFD session information.

[0073] The proxy entry information includes the BFD session information.

[0074] Specifically, the main control board 101 obtains the second state information by receiving the BFD session information sent by the main service board 102. The second state information contained in the above BFD session information is read as the BFD session state information contained in the proxy table entry information. The above proxy table entry information also includes information on the service board type and service board identification information that can identify different service boards. The above service board type is divided into a main service board and a slave service board. The service board type and service board identification information of each service board are different and are pre-set information. For example, the above service board identification information may include a service board number, a service board interface, etc.

[0075] See Table 1, which is an example table of the above proxy entry information.

[0076] Table 1

[0077] Business board type Business board number Service board interface BFD Session Status M Slot0 Route1 1.1.1.1 S Slot1 Route1 1.1.1.1 S Slot2 Route1 1.1.1.1

[0078] The above-mentioned proxy table entry information indicates that the BFD session state of each slave service board 103 is the BFD session state updated by the master service board 102. For example, the BFD session states of all service boards in Table 1 are the same. In addition, in Table 1, different service boards can be represented by service board type, service board number, and service board interface. Among them, the service board type includes master service board and slave service board, M represents the master service board, and S represents the slave service board; the service board number is the number set by the master control board for each service board, for example, the master service board is numbered Slot 0, and the slave service board is numbered Slot1 and Slot2; the service board interface represents the interface connecting the master control board to each service board, for example, the service board interface of each service board in Table 1 is the same.

[0079] The above Table 1 is only an example. In the embodiment of the present invention, there is no limitation on the representation of the service board type, the method and form of setting the service board number, and the service board interface of different service boards.

[0080] In addition, after the main control board 101 generates the above-mentioned proxy table entry information, the above-mentioned proxy table entry information is stored in the main control board 101 so as to be sent to the service board.

[0081] In addition, the main control board 101 generates proxy entry information according to the latest received second state information each time after receiving the second state information, that is, the main control board 101 will continue to generate proxy entry information, and the latest generated proxy entry information matches the latest received second state information.

[0082] Step S205 , the main control board 101 sends the proxy entry information to each slave service board 103 .

[0083] Specifically, the main control board 101 sends the proxy entry information including the BFD session state of the service board to the slave service board 103 , so that the slave service board 103 obtains the second state information in the proxy entry information.

[0084] Step S206: Each slave service board 103 updates its own BFD session state according to the proxy entry information.

[0085] Specifically, the slave service board 103 receives the proxy table entry information sent by the main control board 101, which includes the second state information indicating the updated BFD session state of the main service board 102. The slave service board 103 can update its own BFD session state according to the proxy table entry information, so that its own BFD session state is the same as the updated BFD session state of the main service board 102, that is, the BFD session states of all service boards are the same. Therefore, if the main control board 101 controls the slave service board 103 to also receive and send BFD messages and the BFD messages received by the main service board 102 are the same as those received by the slave service board 103, the slave service board 103 can send the same BFD message sent by the main service board 102 to the opposite device, so that the slave service board 103 can also maintain the BFD session by sending and receiving BFD messages.

[0086] In one embodiment of the present invention, steps S203-S206 may be executed before step S202, may be executed after step S202, or may be executed simultaneously, and the order of the steps is not limited.

[0087] Step S207 , when the main control board 101 determines that the current main service board 102 fails, it selects a slave service board as a new main service board.

[0088] Specifically, if the main control board 101 determines that the main service board 102 fails, the main service board 102 cannot continue to maintain the BFD session. Since the BFD session status of the main service board 102 and the slave service board 103 are the same, the main control board 101 can arbitrarily select a slave service board as a new main service board to maintain the BFD session, and the BFD session will not be interrupted due to the failure of the main service board originally responsible for maintaining the BFD session.

[0089] In addition, the main control board 101 can number each service board, and when selecting a slave service board as a new master service board, selection can be made based on the number. For example, the slave service board with the smallest or largest number is selected as the new master service board.

[0090] Step S208: the main control board 101 sends switching information to each service board respectively.

[0091] The above switching information indicates that the selected slave business board is used as the new master business board.

[0092] Specifically, after the main control board 101 selects a new main business board, it generates switching information containing relevant information of the new main business board, and sends the switching information to all business boards, so that all business boards can determine the current new main business board through the switching information. The switching information may contain an identifier of the new main business board, and the identifier may be a number of the new main business board, etc.

[0093] Step S209: Each service board determines a new main service board according to the above switching information.

[0094] Specifically, according to the switching information, each service board can obtain the information of the new master service board selected by the main control board, and judge whether it is responsible for receiving and sending BFD messages through the switching information. After receiving the switching information, the slave service board selected by the main control board becomes the new master service board 102 and executes steps S201-S202.

[0095] In the solution provided by the embodiment of the present invention, the main business board responsible for maintaining the BFD session updates the current BFD session state by receiving the first BFD message sent by the opposite device, and sends the current BFD session state to the main control board, which sends the BFD session state of the main business board to all slave business boards, so that all slave business boards update their own BFD session states to the BFD session state of the main business board, that is, the BFD session states of the main business board and the slave business boards are kept consistent. When the main business board fails, the main control board selects one from the slave business boards to become a new main business board responsible for maintaining the BFD session. Since the BFD session states of all business boards are consistent, when the new main business board receives the new BFD message sent by the opposite device, the new main business board can directly send a BFD message to the opposite device, and the BFD message is the same as the BFD message that the original main business board will send to the opposite device after receiving the BFD message. Therefore, in the event of a failure of the main service board, the slave service board selected by the main control board can replace the original main service board to send and receive BFD messages, so that the BFD session will not be interrupted, and there is no need to re-create the BFD session. This will not affect the link fault detection based on the BFD protocol between devices, and can improve the rapid convergence capability of the BFD session.

[0096] Figure 3 A flow chart of a second BFD session maintenance method provided in an embodiment of the present invention, which is similar to the above Figure 2 Compared with the illustrated embodiment, the above step S207 can be determined by step S207A.

[0097] Step S207A: When the waiting time reaches the preset switching time, the main control board 101 determines that the current main service board fails and selects a slave service board as a new main service board.

[0098] The waiting time is: the time from the time when the main control board 101 last received the BFD session information to the current time.

[0099] Specifically, the above-mentioned preset switching duration can be manually set. Since the main business board 102 periodically sends BFD session information to the main control board 101, when the time from the time when the main control board 101 last received the BFD session information to the current time reaches the preset switching duration, it can be determined that the main business board 102 has not sent BFD session information to the main control board 101 for a long time, so the main control board 101 can determine that the main business board 102 has a fault and needs to be switched.

[0100] In addition, the above-mentioned main control board 101 also needs to record the duration from the time when the BFD session information was last received to the current time. Specifically, the main control board 101 can start the timer after receiving the BFD session information. If the timing duration has not reached the preset switching duration, but the BFD session information has been received again, the timer can be cleared and restarted. If the timing duration reaches the preset switching duration but the BFD session information is not received, it is determined that the main business board 102 has a fault.

[0101] By applying the solution provided in the embodiment of the present invention, the main control board can determine whether the main business board has a fault by judging whether the time from the last time the BFD session information was received to the current time reaches the preset switching time. In this way, it is possible to quickly and conveniently determine whether the main business board has a fault, thereby solving problems such as packet loss timeout due to the failure of the main business board, and maintaining the rapid convergence capability of link fault detection based on the BFD protocol.

[0102] In one embodiment of the present invention, the preset switching duration is determined based on at least one of the first duration, the second duration, and the third duration.

[0103] Among them, the first duration is the duration required for the main business board 102 to send BFD session information to the main control board 101, the second duration is the duration required for the main control board 101 to send proxy table information to the slave business board 103, and the third duration is the duration required for the main business board 102 to send a second BFD message to the opposite device.

[0104] Specifically, since the overall structure of the BFD session maintenance system remains unchanged during actual operation, the first duration required for the main business board 102 to send BFD session information to the main control board 101 each time is often the same, the second duration required for the main control board 101 to send proxy table entry information to the slave business board 103 each time is often the same, and the third duration required for the main business board 102 to send the second BFD message to the opposite device is often the same.

[0105] Therefore, the time required for the main business board 102 to send BFD session information to the main control board 101 once can be counted as the first time, the time required for the main control board 101 to send proxy table entry information to the slave business board 103 once can be counted as the second time, and the time required for the main business board 102 to send a second BFD message to the opposite device can be counted as the third time. Alternatively, the average time required for the main business board 102 to send multiple BFD session information to the main control board 101 can be counted as the first time, the average time required for the main control board 101 to send proxy table entry information to the slave business board 103 once can be counted as the second time, and the average time required for the main business board 102 to send a second BFD message to the opposite device can be counted as the third time.

[0106] In addition, the first duration, the second duration and the third duration may also be manually set by the staff based on their experience.

[0107] In one embodiment of the present invention, when the preset switching duration is determined only based on the first duration, the preset switching duration may be less than the first duration; when the preset switching duration is determined only based on the second duration, the preset switching duration may be less than the second duration; when the preset switching duration is determined only based on the third duration, the preset switching duration may be less than the third duration; when the preset switching duration is determined only based on the first duration and the second duration, the preset switching duration may be less than the sum of the first duration and the second duration; when the preset switching duration is determined only based on the first duration and the third duration, the preset switching duration may be less than the sum of the first duration and the third duration; when the preset switching duration is determined only based on the second duration and the third duration, the preset switching duration may be less than the sum of the second duration and the third duration.

[0108] In another embodiment of the present invention, the longest total time required for the above-mentioned BFD session maintenance system to receive and send a BFD message is the total time obtained by adding the first time, the second time and the third time. The preset switching time can be set to any time less than the above-mentioned total time, so that the main control board 101 can promptly discover the failure of the main business board 102 and select a new main business board, and the new main business board sends a second BFD message to the opposite device. Therefore, the opposite device can promptly receive the second BFD message sent by the new main business board to the opposite device, and the BFD session will not be interrupted and the failure of the original main business board is imperceptible to the opposite device.

[0109] In the solution provided by the embodiment of the present invention, a preset switching duration is set based on the actual time required for the BFD session maintenance system to receive and send BFD messages, which serves as a judgment threshold for the main business board failure, so that the above-mentioned preset switching duration is consistent with the time required for the BFD session maintenance system to actually process the BFD message, thereby ensuring that the main control board can promptly discover the failure of the main business board, so that the opposite device can promptly receive the second BFD message and cannot perceive the failure of the main business board.

[0110] Figure 4 The structural diagram of the second BFD session maintenance system provided for the embodiment of the present invention, the above-mentioned main business board 102 includes a main CPU 102A, a main FPGA (Field Programmable Gate Array) 102B and a global interface 102C, and the above-mentioned slave business board 103 includes a slave CPU 103A, a slave FPGA 103B and a global interface 103C. The BFD session maintenance system shown in the figure is only an embodiment. In the embodiment of the present invention, the number of slave business boards 103 can be one or more, and there is no limitation on this.

[0111] Specifically, in the main service board 102, the main CPU 102A is connected to the global interface 102C via the main FPGA 102B. In the slave service board 103, the slave CPU 103A is connected to the global interface 103C via the slave FPGA 103B, and the service board is connected to other service boards and the main control board via the CPU.

[0112] Figure 5 A flow chart of a third BFD session maintenance method provided in an embodiment of the present invention is shown in the figure. Figure 3 Compared with the illustrated embodiment, the above step S201 can be implemented through S201A, the above step S202 can be implemented through S202A, the above step S203 can be implemented through S203A-S203B, the above step S206 can be implemented through S206A-S206B, and the above step S209 can be implemented through S209A-S209E.

[0113] In step S201A, the master FPGA 102B receives a first BFD message sent by a peer device from the global interface 102C, and updates its own BFD session state according to the first state information in the first BFD message.

[0114] Step S202A: the master FPGA 102B sends a second BFD message to the peer device.

[0115] Step S203A: the master FPGA 102B sends BFD session information to the master CPU 102A.

[0116] Step S203B: the main CPU 102A sends the BFD session information to the main control board 101 .

[0117] Step S206A: Each slave CPU sends the above proxy entry information to the slave FPGA.

[0118] Step S206B: Each slave FPGA updates its own BFD session state according to the proxy entry information.

[0119] In step S209A, the main CPU 102A receives the switching information sent by the main control board 101 .

[0120] In step S209B, the master CPU 102A sends the switching information to the master FPGA 102B.

[0121] Step S209C: each slave CPU receives the switching information sent by the main control board 101.

[0122] Step S209D: Each slave CPU sends the above switching information to the slave FPGA respectively.

[0123] Step S209E: the master FPGA 102B and each slave FPGA determine a new master service board according to the switching information.

[0124] With the above Figure 2 Compared with the embodiment shown in the figure, the embodiment of the present invention describes in detail the device for implementing the aforementioned embodiment. The specific implementation method of the embodiment can be found in the above Figure 2 The contents shown will not be repeated here.

[0125] By applying the solution provided by the embodiment of the present invention, various devices in the main service board, the slave service board and the main control board work together to complete the process of BFD session maintenance.

[0126] Figure 6 A schematic diagram of a flow chart of a fourth BFD session maintenance method provided in an embodiment of the present invention.

[0127] Step A1: The main FPGA receives a first BFD message sent by a peer device through a global interface.

[0128] Step A2: The master FPGA sends a second BFD message to the peer device.

[0129] Step A3: The master FPGA sends BFD session information to the master CPU.

[0130] Step A4: The main CPU sends the BFD session information to the main control board.

[0131] Step A5: The main control board sends the proxy table entry information to the slave CPU.

[0132] Step A6: Send proxy entry information from the CPU to the slave FPGA.

[0133] Specifically, the above steps A1-A6 are similar to the various embodiments of the BFD session maintenance system described above, and are not described again here.

[0134] Figure 7 A schematic diagram of a fifth BFD session maintenance method provided in an embodiment of the present invention.

[0135] Step B1: The main control board sends switching information to the new main CPU.

[0136] Step B2: The new master CPU sends switching information to the new master FPGA.

[0137] Step B3: the main control board sends switching information to the slave CPU.

[0138] Step B4, the slave CPU sends switching information to the slave FPGA.

[0139] Specifically, the above steps B1-B4 are similar to the various embodiments of the BFD session maintenance system described above, and are not described in detail here.

[0140] Based on the same inventive concept, corresponding to the above-mentioned BFD session maintenance system, the embodiment of the present invention also provides a BFD session maintenance method, such as Figure 8 As shown, a flow chart of the sixth BFD session maintenance method provided in an embodiment of the present invention is applied to a BFD session maintenance system, wherein the BFD session maintenance system comprises: a main control board and at least two service boards, wherein the main control board is connected to each service board respectively, and the service boards are divided into a main service board and at least one slave service board, and each service board includes a global interface, and the global interface is: an interface shared by each service board, and the method comprises the following steps S801-S805.

[0141] Step S801, receiving the first BFD message sent by the opposite device from the above-mentioned global interface through the above-mentioned main business board, updating its own BFD session state according to the first state information in the above-mentioned first BFD message, sending BFD session information to the above-mentioned main control board, and sending a second BFD message to the above-mentioned opposite device.

[0142] The first status information indicates: the BFD session status of the opposite device, the BFD session information and the second BFD message include second status information, and the second status information indicates: the BFD session status after the main service board is updated.

[0143] Step S802: Generate and store proxy entry information through the main control board according to the BFD session information, and send the proxy entry information to each slave service board.

[0144] The proxy entry information includes the BFD session information.

[0145] Step S803: Each slave service board updates its own BFD session state according to the above proxy entry information.

[0146] Step S804: When the main control board determines that the current main service board fails, it selects a slave service board as a new main service board and sends switching information to each service board.

[0147] The above switching information indicates that the selected slave business board is used as the new master business board.

[0148] Step S805: Determine a new main service board through each service board according to the above switching information.

[0149] In the solution provided by the embodiment of the present invention, the main business board responsible for maintaining the BFD session updates the current BFD session state by receiving the first BFD message sent by the opposite device, and sends the current BFD session state to the main control board, which sends the BFD session state of the main business board to all slave business boards, so that all slave business boards update their own BFD session states to the BFD session state of the main business board, that is, the BFD session states of the main business board and the slave business boards are kept consistent. When the main business board fails, the main control board selects one from the slave business boards to become a new main business board responsible for maintaining the BFD session. Since the BFD session states of all business boards are consistent, when the new main business board receives the new BFD message sent by the opposite device, the new main business board can directly send a BFD message to the opposite device, and the BFD message is the same as the BFD message that the original main business board will send to the opposite device after receiving the BFD message. Therefore, in the event of a failure of the main service board, the slave service board selected by the main control board can replace the original main service board to send and receive BFD messages, so that the BFD session will not be interrupted, and there is no need to re-create the BFD session. This will not affect the link fault detection based on the BFD protocol between devices, and can improve the rapid convergence capability of the BFD session.

[0150] In one embodiment of the present invention, step C may be used to determine whether the current main service board fails.

[0151] Step C, when the waiting time reaches the preset switching time, determine that the current main business board has failed, select a slave business board as the new main business board, and send switching information to each business board respectively, so that each business board determines the new main business board according to the above switching information.

[0152] The waiting time is: the time from the time when the main control board last received the BFD session information to the current time.

[0153] By applying the solution provided in the embodiment of the present invention, the main control board can determine whether the main business board has a fault by judging whether the time from the last time the BFD session information was received to the current time reaches the preset switching time. In this way, it is possible to quickly and conveniently determine whether the main business board has a fault, thereby solving problems such as packet loss timeout due to the failure of the main business board, and maintaining the rapid convergence capability of link fault detection based on the BFD protocol.

[0154] In one embodiment of the present invention, the preset switching duration is determined based on at least one of a first duration, a second duration, and a third duration, wherein the first duration is the duration required for the master business board to send BFD session information to the main control board, the second duration is the duration required for the master control board to send proxy table information to the slave business board, and the third duration is the duration required for the master business board to send a second BFD message to the opposite device.

[0155] By applying the solution provided in the embodiment of the present invention, a preset switching duration is set based on the actual duration required for the BFD session maintenance system to receive and send BFD messages, as a judgment threshold for the main business board failure, so that the above-mentioned preset switching duration is consistent with the duration actually required for the BFD session maintenance system to process the BFD messages, thereby ensuring that the main control board can promptly discover the failure of the main business board, so that the opposite device can promptly receive the second BFD message and cannot perceive the failure of the main business board.

[0156] In one embodiment of the present invention, the master service board includes a master CPU, a master FPGA and a global interface, and the slave service board includes a slave CPU, a slave FPGA and a global interface. Fig. 9 As shown, it is a flow chart of the seventh BFD session maintenance method provided in an embodiment of the present invention, wherein the above step S801 can be implemented through steps S801A-S801B, the above step S803 includes the following steps S803A-S803B, and the above step S805 includes the following steps S805A-S805C.

[0157] Step S801A, receiving the first BFD message sent by the peer device from the above-mentioned global interface through the above-mentioned main FPGA, updating its own BFD session state according to the first state information in the above-mentioned first BFD message, sending BFD session information to the above-mentioned main CPU, and sending a second BFD message to the above-mentioned peer device.

[0158] Step S801B: Send the BFD session information to the main control board through the main CPU.

[0159] Step S803A: Send the proxy entry information to the slave FPGA through each slave CPU.

[0160] Step S803B: Each slave FPGA updates its own BFD session state according to the proxy entry information.

[0161] Step S805A: receiving the switching information sent by the main control board through the main CPU, and sending the switching information to the main FPGA.

[0162] Step S805B: each slave CPU receives the switching information sent by the master control board and sends the switching information to the slave FPGA.

[0163] Step S805C: Determine a new main service board through the main FPGA and each slave FPGA according to the switching information.

[0164] By applying the solution provided by the embodiment of the present invention, various devices in the main service board, the slave service board and the main control board work together to complete the process of BFD session maintenance.

[0165] In one embodiment of the present invention, the global interface includes at least one of the following interfaces: a Vlan virtual interface, a routing aggregation interface, a routing aggregation sub-interface, a Loopback interface, and a Layer 2 aggregation interface.

[0166] The solution provided by the embodiment of the present invention can be applied to various types of global interfaces, so that the application scenarios of the BFD session maintenance system are more diverse.

[0167] Based on the same inventive concept, corresponding to the above-mentioned BFD session maintenance system, the embodiment of the present invention further provides a BFD session maintenance device, such as Fig.10 As shown, it is a structural schematic diagram of a BFD session maintenance device provided by an embodiment of the present invention, which is applied to the BFD session maintenance system. The BFD session maintenance system includes: a main control board and at least two service boards, wherein the main control board is connected to each service board respectively, and the service board is divided into a main service board and at least one slave service board, each service board includes a global interface, and the global interface is: an interface shared by each service board, and the device includes:

[0168] The first sending module 1001 is used to receive a first BFD message sent by a peer device from the global interface through the main business board, update its own BFD session state according to the first state information in the first BFD message, send BFD session information to the main control board, and send a second BFD message to the peer device, wherein the first state information represents: the BFD session state of the peer device, the BFD session information and the second BFD message include second state information, and the second state information represents: the BFD session state after the main business board is updated;

[0169] The second sending module 1002 is used to generate and store proxy table entry information according to the BFD session information through the main control board, and send the proxy table entry information to each slave service board, wherein the proxy table entry information includes the BFD session information;

[0170] An updating module 1003 is used to update the BFD session state of each slave service board according to the proxy entry information;

[0171] The selection module 1004 is used to select a slave business board as a new master business board through the main control board when determining that the current master business board fails, and send switching information to each business board respectively, wherein the switching information indicates: the selected slave business board is used as the new master business board;

[0172] The determination module 1005 is used to determine a new main service board through each service board according to the switching information.

[0173] In the solution provided by the embodiment of the present invention, the main business board responsible for maintaining the BFD session updates the current BFD session state by receiving the first BFD message sent by the opposite device, and sends the current BFD session state to the main control board, which sends the BFD session state of the main business board to all slave business boards, so that all slave business boards update their own BFD session states to the BFD session state of the main business board, that is, the BFD session states of the main business board and the slave business boards are kept consistent. When the main business board fails, the main control board selects one from the slave business boards to become a new main business board responsible for maintaining the BFD session. Since the BFD session states of all business boards are consistent, when the new main business board receives the new BFD message sent by the opposite device, the new main business board can directly send a BFD message to the opposite device, and the BFD message is the same as the BFD message that the original main business board will send to the opposite device after receiving the BFD message. Therefore, in the event of a failure of the main service board, the slave service board selected by the main control board can replace the original main service board to send and receive BFD messages, so that the BFD session will not be interrupted, and there is no need to re-create the BFD session. This will not affect the link fault detection based on the BFD protocol between devices, and can improve the rapid convergence capability of the BFD session.

[0174] In one embodiment of the present invention, the selection module 1004 is further configured to determine whether the current main service board fails by:

[0175] When the waiting time reaches the preset switching time, it is determined that the current main service board fails, wherein the waiting time is: the time from the time when the main control board last received the BFD session information to the current time.

[0176] By applying the solution provided in the embodiment of the present invention, the main control board can determine whether the main business board has a fault by judging whether the time from the last time the BFD session information was received to the current time reaches the preset switching time. In this way, it is possible to quickly and conveniently determine whether the main business board has a fault, thereby solving problems such as packet loss timeout due to the failure of the main business board, and maintaining the rapid convergence capability of link fault detection based on the BFD protocol.

[0177] In one embodiment of the present invention, the master service board includes a master CPU, a master FPGA and a global interface, the slave service board includes a slave CPU, a slave FPGA and a global interface, and the first sending module 1001 is specifically used for:

[0178] receiving, through the master FPGA, a first BFD message sent by a peer device from the global interface, updating its own BFD session state according to first state information in the first BFD message, sending BFD session information to the master CPU, and sending a second BFD message to the peer device;

[0179] Sending the BFD session information to the main control board through the main CPU;

[0180] The updating module 1003 is specifically used for:

[0181] Sending the proxy table entry information to the slave FPGA through each slave CPU;

[0182] Each slave FPGA updates its own BFD session state according to the proxy entry information;

[0183] The determining module 1005 is specifically used for:

[0184] Receiving the switching information sent by the main control board through the main CPU, and sending the switching information to the main FPGA;

[0185] Receiving the switching information sent by the main control board through each slave CPU, and sending the switching information to the slave FPGA;

[0186] A new main service board is determined by the main FPGA and each slave FPGA according to the switching information.

[0187] By applying the solution provided by the embodiment of the present invention, various devices in the main service board, the slave service board and the main control board work together to complete the process of BFD session maintenance.

[0188] Based on the same inventive concept, corresponding to the above-mentioned BFD session maintenance system, the embodiment of the present invention further provides a BFD session maintenance device, such as Fig.11, which is a schematic diagram of the structure of an electronic device provided by an embodiment of the present invention, includes a processor 1101, a communication interface 1102, a memory 1103 and a communication bus 1104, wherein the processor 1101, the communication interface 1102, and the memory 1103 communicate with each other through the communication bus 1104.

[0189] Memory 1103, used for storing computer programs;

[0190] The processor 1101 is used to implement the following steps when executing the program stored in the memory 1103:

[0191] The main business board receives a first BFD message sent by a peer device from the global interface, updates its own BFD session state according to the first state information in the first BFD message, sends BFD session information to the main control board, and sends a second BFD message to the peer device, wherein the first state information indicates: the BFD session state of the peer device, the BFD session information and the second BFD message include second state information, and the second state information indicates: the updated BFD session state of the main business board;

[0192] The main control board generates and stores proxy table entry information according to the BFD session information, and sends the proxy table entry information to each slave service board, wherein the proxy table entry information includes the BFD session information;

[0193] Each slave service board updates its own BFD session state according to the proxy entry information;

[0194] When the main control board determines that the current main business board fails, the main control board selects a slave business board as a new main business board, and sends switching information to each business board respectively, wherein the switching information indicates: the selected slave business board is used as the new main business board;

[0195] Each service board determines a new main service board according to the switching information.

[0196] In the solution provided by the embodiment of the present invention, the main business board responsible for maintaining the BFD session updates the current BFD session state by receiving the first BFD message sent by the opposite device, and sends the current BFD session state to the main control board, which sends the BFD session state of the main business board to all slave business boards, so that all slave business boards update their own BFD session states to the BFD session state of the main business board, that is, the BFD session states of the main business board and the slave business boards are kept consistent. When the main business board fails, the main control board selects one from the slave business boards to become a new main business board responsible for maintaining the BFD session. Since the BFD session states of all business boards are consistent, when the new main business board receives the new BFD message sent by the opposite device, the new main business board can directly send a BFD message to the opposite device, and the BFD message is the same as the BFD message that the original main business board will send to the opposite device after receiving the BFD message. Therefore, in the event of a failure of the main service board, the slave service board selected by the main control board can replace the original main service board to send and receive BFD messages, so that the BFD session will not be interrupted, and there is no need to re-create the BFD session. This will not affect the link fault detection based on the BFD protocol between devices, and can improve the rapid convergence capability of the BFD session.

[0197] Based on the same inventive concept, corresponding to the above-mentioned BFD session maintenance system, an embodiment of the present invention further provides a computer-readable storage medium, in which a computer program is stored. When the computer program is executed by a processor, the steps of any of the above-mentioned BFD session maintenance methods are implemented.

[0198] In the solution provided by the embodiment of the present invention, the main business board responsible for maintaining the BFD session updates the current BFD session state by receiving the first BFD message sent by the opposite device, and sends the current BFD session state to the main control board, which sends the BFD session state of the main business board to all slave business boards, so that all slave business boards update their own BFD session states to the BFD session state of the main business board, that is, the BFD session states of the main business board and the slave business boards are kept consistent. When the main business board fails, the main control board selects one from the slave business boards to become a new main business board responsible for maintaining the BFD session. Since the BFD session states of all business boards are consistent, when the new main business board receives the new BFD message sent by the opposite device, the new main business board can directly send a BFD message to the opposite device, and the BFD message is the same as the BFD message that the original main business board will send to the opposite device after receiving the BFD message. Therefore, in the event of a failure of the main service board, the slave service board selected by the main control board can replace the original main service board to send and receive BFD messages, so that the BFD session will not be interrupted, and there is no need to re-create the BFD session. This will not affect the link fault detection based on the BFD protocol between devices, and can improve the rapid convergence capability of the BFD session.

[0199] Based on the same inventive concept, corresponding to the above-mentioned BFD session maintenance system, the present invention also provides a computer program product including instructions, which, when executed on a computer, enables the computer to execute any BFD session maintenance method in the above-mentioned embodiments.

[0200] In the solution provided by the embodiment of the present invention, the main business board responsible for maintaining the BFD session updates the current BFD session state by receiving the first BFD message sent by the opposite device, and sends the current BFD session state to the main control board, which sends the BFD session state of the main business board to all slave business boards, so that all slave business boards update their own BFD session states to the BFD session state of the main business board, that is, the BFD session states of the main business board and the slave business boards are kept consistent. When the main business board fails, the main control board selects one from the slave business boards to become a new main business board responsible for maintaining the BFD session. Since the BFD session states of all business boards are consistent, when the new main business board receives the new BFD message sent by the opposite device, the new main business board can directly send a BFD message to the opposite device, and the BFD message is the same as the BFD message that the original main business board will send to the opposite device after receiving the BFD message. Therefore, in the event of a failure of the main service board, the slave service board selected by the main control board can replace the original main service board to send and receive BFD messages, so that the BFD session will not be interrupted, and there is no need to re-create the BFD session. This will not affect the link fault detection based on the BFD protocol between devices, and can improve the rapid convergence capability of the BFD session.

[0201] The communication bus mentioned in the above electronic device can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The communication bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus.

[0202] The communication interface is used for communication between the above electronic device and other devices.

[0203] The memory may include a random access memory (RAM) or a non-volatile memory (NVM), such as at least one disk memory. Optionally, the memory may also be at least one storage device located away from the aforementioned processor.

[0204] The above description is only a preferred embodiment of the present invention and is not intended to limit the protection scope of the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention are included in the protection scope of the present invention.

Claims

1. A BFD session maintenance system, characterized in that: The system comprises: a main control board and at least two service boards, wherein the main control board is connected to each service board respectively, the service board is divided into a main service board and at least one slave service board, each service board comprises a global interface, and the global interface is an interface shared by each service board; The main business board is used to receive a first bidirectional forwarding detection BFD message sent by a peer device from the global interface, update its own BFD session state according to the BFD session state of the peer device represented by the first state information in the first BFD message and the original BFD session state of the main business board, send BFD session information to the main control board, and send a second BFD message to the peer device, wherein the first state information represents: the BFD session state of the peer device, the BFD session information and the second BFD message include second state information, and the second state information represents: the updated BFD session state of the main business board; The main control board is used to generate and store proxy table entry information according to the BFD session information, and send the proxy table entry information to each slave service board, wherein the proxy table entry information includes the BFD session information; Each slave service board is used to update its own BFD session state according to the proxy entry information; The main control board is further used to select a slave business board as a new master business board when it is determined that the current master business board fails, and send switching information to each business board respectively, wherein the switching information indicates: the selected slave business board is used as the new master business board; Each service board is also used to determine a new main service board according to the switching information.

2. The system according to claim 1, characterized in that The main control board is specifically used for: When the waiting time reaches the preset switching time, it is determined that the current main service board fails, wherein the waiting time is: the time from the time when the main control board last received the BFD session information to the current time.

3. The system according to claim 2, characterized in that The preset switching duration is determined based on at least one of a first duration, a second duration, and a third duration, wherein the first duration is the duration required for the master business board to send BFD session information to the main control board, the second duration is the duration required for the master control board to send proxy table information to the slave business board, and the third duration is the duration required for the master business board to send a second BFD message to the opposite device.

4. The system according to claim 1, characterized in that The master service board includes a master CPU, a master field programmable gate array FPGA and a global interface, and the slave service board includes a slave CPU, a slave FPGA and a global interface, wherein: The master FPGA is configured to receive a first BFD message sent by a peer device from the global interface, update its own BFD session state according to the first state information in the first BFD message, send BFD session information to the master CPU, and send a second BFD message to the peer device; The main CPU is used to send the BFD session information to the main control board; Each slave CPU is used to send the proxy table entry information to the slave FPGA; Each slave FPGA is used to update its own BFD session state according to the proxy entry information; The main CPU is further used to receive the switching information sent by the main control board, and send the switching information to the main FPGA; Each slave CPU is further used to receive the switching information sent by the master control board and send the switching information to the slave FPGA; The master FPGA and each slave FPGA are used to determine a new master service board according to the switching information.

5. The system according to any one of claims 1 to 4, characterized in that: The global interface includes at least one of the following interfaces: a virtual local area network (Vlan) virtual interface, a routing aggregation interface, a routing aggregation sub-interface, a loopback interface, and a layer 2 aggregation interface.

6. A BFD session maintenance method, characterized in that: The method is applied to a bidirectional forwarding detection (BFD) session maintenance system, the BFD session maintenance system comprising: a main control board and at least two service boards, wherein the main control board is connected to each service board respectively, the service board is divided into a main service board and at least one slave service board, each service board comprises a global interface, and the global interface is an interface shared by each service board. The method comprises: Receive a first BFD message sent by a peer device from the global interface through the main business board, update its own BFD session state according to the BFD session state of the peer device represented by the first state information in the first BFD message and the original BFD session state of the main business board, send BFD session information to the main control board, and send a second BFD message to the peer device, wherein the first state information represents: the BFD session state of the peer device, the BFD session information and the second BFD message include second state information, and the second state information represents: the updated BFD session state of the main business board; Generate and store proxy table entry information according to the BFD session information by the main control board, and send the proxy table entry information to each slave service board, wherein the proxy table entry information includes the BFD session information; Each slave service board updates its own BFD session state according to the proxy entry information; When the main control board determines that the current main business board fails, a slave business board is selected as a new main business board, and switching information is sent to each business board respectively, wherein the switching information indicates: the selected slave business board is used as the new main business board; A new main service board is determined by each service board according to the switching information.

7. The method according to claim 6, characterized in that Determine whether the current main service board is faulty by the following methods: When the waiting time of the main control board reaches the preset switching time, it is determined that the current main service board has failed, wherein the waiting time is: the time from the time when the main control board last received the BFD session information to the current time.

8. The method according to claim 7, characterized in that The preset switching duration is determined based on at least one of a first duration, a second duration, and a third duration, wherein the first duration is the duration required for the master business board to send BFD session information to the main control board, the second duration is the duration required for the master control board to send proxy table information to the slave business board, and the third duration is the duration required for the master business board to send a second BFD message to the opposite device.

9. The method according to claim 6, characterized in that The main service board includes a main CPU, a main field programmable gate array FPGA and a global interface, the slave service board includes a slave CPU, a slave FPGA and a global interface, the receiving, through the main service board, a first bidirectional forwarding detection BFD message sent by a peer device from the global interface, updating its own BFD session state according to first state information in the first BFD message, sending BFD session information to the main control board, and sending a second BFD message to the peer device, including: receiving, through the master FPGA, a first BFD message sent by a peer device from the global interface, updating its own BFD session state according to first state information in the first BFD message, sending BFD session information to the master CPU, and sending a second BFD message to the peer device; Sending the BFD session information to the main control board through the main CPU; The updating of the BFD session state of each slave service board according to the proxy entry information includes: Sending the proxy table entry information to the slave FPGA through each slave CPU; Each slave FPGA updates its own BFD session state according to the proxy entry information; The determining a new main service board according to the switching information by each service board includes: Receiving the switching information sent by the main control board through the main CPU, and sending the switching information to the main FPGA; Receiving the switching information sent by the main control board through each slave CPU, and sending the switching information to the slave FPGA; A new main service board is determined by the main FPGA and each slave FPGA according to the switching information.

10. The method according to any one of claims 6 to 9, characterized in that: The global interface includes at least one of the following interfaces: a virtual local area network (Vlan) virtual interface, a routing aggregation interface, a routing aggregation sub-interface, a loopback interface, and a layer 2 aggregation interface.

11. A BFD session maintenance device, characterized in that: Applied to a bidirectional forwarding detection BFD session maintenance system, the BFD session maintenance system includes: a main control board and at least two service boards, wherein the main control board is connected to each service board respectively, the service board is divided into a main service board and at least one slave service board, each service board includes a global interface, and the global interface is: an interface shared by each service board, and the device includes: A first sending module is used to receive a first BFD message sent by a peer device from the global interface through the main business board, update its own BFD session state according to the BFD session state of the peer device represented by the first state information in the first BFD message and the original BFD session state of the main business board, send BFD session information to the main control board, and send a second BFD message to the peer device, wherein the first state information represents: the BFD session state of the peer device, the BFD session information and the second BFD message include second state information, and the second state information represents: the updated BFD session state of the main business board; A second sending module, configured to generate and store proxy table entry information according to the BFD session information through the main control board, and send the proxy table entry information to each slave service board, wherein the proxy table entry information includes the BFD session information; An updating module, configured to update the BFD session state of each slave service board according to the proxy entry information; A selection module is used to select a slave business board as a new master business board through the main control board when determining that the current master business board fails, and send switching information to each business board respectively, wherein the switching information indicates: the selected slave business board is used as the new master business board; A determination module is used to determine a new main business board through each business board according to the switching information.

Citation Information

Patent Citations

  • Distributed bidirectional forwarding detection method and device

    CN101079759A

  • Method and device for triggering main and standby interface board inverse switch

    CN101465859A