Fault handling method, device, network equipment and storage medium
By detecting HUB node failures in the SHHS architecture and switching routes to standby devices, the problem of slow routing speed is solved, and faster network recovery and higher network performance is achieved.
Patent Information
- Application Number
- CN202410020936.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-01-05
- Publication Date
- 2025-02-11
- Estimated Expiration
- 2044-01-05
AI Technical Summary
In the SHHS architecture, when a HUB node fails, the routing switching speed is slow, affecting network performance.
By detecting whether the second network device has a fault, and when the fault occurs, the route in the first data transmission direction is directed to the backup device of the third network device, and the backup device is directly instructed to make the route pointing change through control signaling.
It effectively improves the routing switching speed, reduces the impact of device failure on network performance, and avoids the dependence on BGP routing convergence speed.
Smart Images

Figure CN117914777B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of communication technology, and in particular to a fault handling method, apparatus, network equipment and storage medium. Background Art
[0002] In the current network environment, people have increasing requirements for network transmission reliability and business continuity, and the SHHS (SPOKE-HUB-HUB-SPOKE) architecture has emerged. In the SHHS architecture, the risk of single point failure is avoided by using multiple HUB nodes, the stability of data transmission and the distributed load are improved, thereby increasing the reliability and stability of the network.
[0003] In traditional technology, in the SHHS architecture, when a HUB node fails, BGP can be used to automatically converge and repair routing, so that other devices can still communicate through other HUB nodes. However, this method has a slow convergence speed and network performance is still affected. Summary of the invention
[0004] Based on this, it is necessary to provide a fault handling method, device, network equipment and storage medium that can improve the routing switching speed in response to the above technical problems.
[0005] In a first aspect, the present application provides a fault handling method, which is applied to a first network device, and the method includes:
[0006] Detecting whether a second network device fails, where the second network device is the next hop of the first network device in the first data transmission direction and the second network device is a main device;
[0007] In the event that the second network device fails, the route in the first data transmission direction is directed to a third network device, and a first control signaling is sent to the third network device. The third network device represents a backup device for the second network device. The first control signaling is used to control the route in the first data transmission direction in the third network device to point to a fourth network device. The fourth network device is the next hop on the second network device in the first data transmission direction.
[0008] In a possible implementation, the first control signaling is also used to control the routing in the second data transmission direction in the third network device to point to the first network device, and to control the routing in the second data transmission direction in the fourth network device to point to the third network device, wherein the second data transmission direction indicates a data transmission direction opposite to the first data transmission direction.
[0009] In a possible implementation, the method further includes:
[0010] Detecting whether the failure of the second network device is restored;
[0011] When the failure of the second network device is recovered and the recovery duration reaches a preset threshold, the route in the first data transmission direction is directed to the second network device, and a second control signaling is sent to the second network device, wherein the second control signaling is used to control the route in the first data transmission direction in the second network device to be directed to the fourth network device and the route in the second data transmission direction in the fourth network device to be directed to the second network device.
[0012] In a possible implementation manner, the detecting whether the second network device fails includes:
[0013] Detecting a link between the first network device and the second network device;
[0014] When the quality of the link between the first network device and the second network device does not meet a preset condition, determining that a fault occurs in the second network device;
[0015] and / or,
[0016] In the case that the second network device is unreachable, it is determined that a failure occurs in the second network device.
[0017] A second aspect provides a fault handling method, which is applied to a third network device, and includes:
[0018] receiving a first control signaling sent by a first network device, where the first control signaling is generated when a second network device fails, the second network device is a next hop of the first network device in a first data transmission direction, the second network device is an active device, and the third network device represents a backup device of the second network device;
[0019] In response to the first control signaling, the route in the first data transmission direction is directed to a fourth network device, and the fourth network device is the next hop of the second network device in the first data transmission direction.
[0020] In a possible implementation, the method further includes:
[0021] In response to the first control signaling, the route in the second data transmission direction is directed to the first network device, and a third control signaling is sent to the fourth network device, wherein the third control signaling is used to control the route in the second data transmission direction in the fourth network device to point to the third network device, and the second data transmission direction represents a data transmission direction opposite to the first data transmission direction.
[0022] In a third aspect, the present application further provides a fault handling device, which is applied to a first network device, and includes:
[0023] A first detection module, used to detect whether a second network device fails, the second network device being the next hop of the first network device in a first data transmission direction, and the second network device being a main device;
[0024] The first routing module is used to point the route in the first data transmission direction to a third network device and send a first control signaling to the third network device when a failure occurs in the second network device. The third network device represents a backup device of the second network device. The first control signaling is used to control the route in the first data transmission direction in the third network device to point to a fourth network device. The fourth network device is the next hop on the second network device in the first data transmission direction.
[0025] In a possible implementation, the first control signaling is also used to control the routing in the second data transmission direction in the third network device to point to the first network device, and to control the routing in the second data transmission direction in the fourth network device to point to the third network device, wherein the second data transmission direction indicates a data transmission direction opposite to the first data transmission direction.
[0026] In a possible implementation manner, the device further includes:
[0027] A second detection module, used to detect whether the fault of the second network device is restored;
[0028] A second routing module is used to point the route in the first data transmission direction to the second network device when the fault of the second network device is recovered and the recovery duration reaches a preset threshold, and send a second control signaling to the second network device, wherein the second control signaling is used to control the route in the first data transmission direction in the second network device to point to the fourth network device and the route in the second data transmission direction in the fourth network device to point to the second network device.
[0029] In a possible implementation manner, the first detection module is further configured to:
[0030] Detecting a link between the first network device and the second network device;
[0031] When the quality of the link between the first network device and the second network device does not meet a preset condition, determining that a fault occurs in the second network device;
[0032] and / or,
[0033] In the case that the second network device is unreachable, it is determined that a failure occurs in the second network device.
[0034] In a fourth aspect, the present application further provides a fault handling device, which is applied to a third network device, and includes:
[0035] A receiving module, configured to receive a first control signaling sent by a first network device, wherein the first control signaling is generated when a second network device fails, the second network device is a next hop of the first network device in a first data transmission direction, the second network device is an active device, and the third network device represents a backup device of the second network device;
[0036] The first routing module is configured to, in response to the first control signaling, direct the route in the first data transmission direction to a fourth network device, where the fourth network device is the next hop of the second network device in the first data transmission direction.
[0037] In a possible implementation manner, the device further includes:
[0038] A second routing module is used to point the route in the second data transmission direction to the first network device in response to the first control signaling, and to send a third control signaling to the fourth network device, wherein the third control signaling is used to control the route in the second data transmission direction in the fourth network device to point to the third network device, and the second data transmission direction represents a data transmission direction opposite to the first data transmission direction.
[0039] In a fifth aspect, the present application also provides a network device, comprising a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the fault handling method of the above first aspect or second aspect, or any possible implementation method of the first aspect or the second aspect is implemented.
[0040] In a sixth aspect, the present application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the fault handling method of the above first aspect or second aspect, or any possible implementation method of the first aspect or the second aspect.
[0041] In the seventh aspect, the present application also provides a computer program product, including a computer program, which, when executed by a processor, implements the fault handling method of the above first aspect or second aspect, or any possible implementation method of the first aspect or the second aspect.
[0042] In the above fault handling method, device, network device and storage medium, when the first network device detects that the second network device as the next hop fails, it points its own route to the backup device of the second network device, and controls the route on the first data transmission direction of the backup device to point to the next hop of the second network device by sending control signaling to the backup device. In this way, the backup device is directly instructed to change the route direction through the control signaling, so that the route direction change does not depend on the convergence speed of the BGP route, effectively improving the route switching speed, thereby reducing the impact of the device failure on the network performance. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the related technologies, the drawings required for use in the embodiments or the related technical descriptions are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0044] Figure 1 A schematic diagram showing an exemplary SHHS architecture provided in an embodiment of the present application;
[0045] Figure 2 An interactive flow chart of a fault handling method provided in an embodiment of the present application is shown;
[0046] Figure 3 A schematic diagram of a flow chart of a fault handling method in an embodiment;
[0047] Figure 4 A schematic diagram showing an application of the fault handling method provided in an embodiment of the present application;
[0048] Figure 5 A schematic diagram showing an application of the fault handling method provided in an embodiment of the present application;
[0049] Figure 6 A schematic diagram showing an application of the fault handling method provided in an embodiment of the present application;
[0050] Figure 7 is a structural block diagram of a fault handling device in an embodiment;
[0051] Figure 8 is a structural block diagram of a fault handling device in an embodiment;
[0052] Fig. 9 FIG. 4 is a diagram showing the internal structure of a network device in one embodiment. DETAILED DESCRIPTION
[0053] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0054] In the SHHS (SPOKE-HUB-HUB-SPOKE) architecture, the risk of single point failure is avoided by using multiple HUB nodes. Specifically, the SHHS architecture includes SPOKE nodes and HUB nodes. HUB nodes can communicate with each other, and communication between SPOKE nodes needs to go through HUB nodes. Among them, HUB nodes can be divided into main HUB nodes and redundant HUB nodes. The redundant HUB nodes serve as backups for the main HUB nodes, avoiding the risk of single point failure. In the SHHS architecture, the SPOKE node can be a user edge device (Customer Edge, CE) or a provider edge device (Provider Edge, PE). Similarly, the HUB node can be a CE or a PE.
[0055] Figure 1 FIG. 1 is a schematic diagram showing an exemplary SHHS architecture provided in an embodiment of the present application. Figure 1 As shown in FIG. 1 , the SHHS architecture includes two CEs (i.e., C1 and C2) and four PEs (i.e., P1, P2, P3, and P4). The two CEs are SPOKE nodes, the four PEs are HUB nodes, and P1 and P2 are primary HUB nodes, P3 is a redundant HUB node of P1, and P4 is a redundant HUB node of P2. Figure 1 As shown, HUB nodes can communicate directly with each other, while communication between SPOKE nodes needs to go through the HUB node. Figure 1 A, B, C, D, E, F, G, H, I and J are communication links. When there are no failures in network devices and communication links, the network devices and communication links through which the data transmission path from C1 to C2 passes are C1, A, P1, B, P2, C and C2 in sequence.
[0056] It should be noted that the above is only an exemplary description of the SHHS architecture. The SHHS architecture may include more or fewer SPOKE nodes and HUB nodes, and the embodiments of the present application do not limit this.
[0057] Figure 2 The interactive flow chart of the fault handling method provided by the embodiment of the present application is shown. The method can be applied to the SHHS architecture, for example, Figure 1 In the SHHS architecture shown in Figure 2 As shown, the method may include:
[0058] Step S201: The first network device detects whether a second network device fails.
[0059] The first network device may represent any network device in the SHHS architecture, and the first network device may be a SPOKE node or a HUB node. Figure 1 C1, C2, P1 or P2 shown in.
[0060] The second network device may be the next hop of the first network device in the first data transmission direction, and the second network device is a primary device. In other words, the second network device is a HUB node, and is a primary HUB node. For example, see Figure 1 Assuming that the first data transmission direction is from C1 to C2, when the first network device is C1, the second network device is P1, and when the first network device is P1, the second network device is P2.
[0061] The first data transmission direction may represent any data transmission direction. For example, see Figure 1 The first output transmission direction may be from C1 to C2, or from C2 to C1. The second data transmission direction may represent a data transmission direction opposite to the first data transmission direction. Figure 1 , if the first data transmission direction is from C1 to C2, then the second data transmission direction is from C2 to C1; if the first data transmission direction is from C2 to C1, then the second data transmission direction is from C1 to C2.
[0062] That is, in the embodiment of the present application, the first network device can detect whether the next hop in each data transmission direction fails. Figure 1 As shown, assuming that P1 is the first network device, P1 can detect whether C1 fails, and can also detect whether P2 fails.
[0063] In a possible implementation, step S201 may include: detecting a link between the first network device and the second network device; when the quality of the link between the first network device and the second network device does not meet a preset condition, the first network device may determine that a fault has occurred in the second network device.
[0064] Among them, the preset conditions can be used to measure the link quality, and the preset conditions can be set as needed. For example, the preset conditions can include one or more of a packet loss rate less than a certain threshold, a bandwidth greater than a certain threshold, a jitter less than a certain threshold, and a delay less than a certain threshold, etc., and this embodiment of the present application is not limited to this. If the quality of the link between the first network device and the second network device is not satisfied with the preset conditions, it indicates that the link quality is poor, and the effect of transmitting data packets between the first network device and the second network device is poor. Therefore, the first network device can determine that the second network device has a fault, so that the first network device needs to bypass the link between the first network device and the second network device to receive or send data packets.
[0065] In a possible implementation, step S201 may include: detecting a link between the first network device and the second network device; and determining that a fault occurs in the second network device when the second network device is unreachable.
[0066] When the second network device is unreachable, the first network device may determine that the second network device fails, so that the first network device needs to bypass the link between the first network device and the second network device when receiving or sending data packets.
[0067] In a possible implementation manner, the first network device may detect the quality of the link between the first network device and the second network device and / or detect whether the second network device is reachable by sending information such as a ping message or a heartbeat.
[0068] Step S202: when a failure occurs on the second network device, direct the route in the first data transmission direction to the third network device.
[0069] Step S203: The first network device sends a first control signaling to the third network device.
[0070] The third network device may represent a backup device for the second network device. Figure 1 As shown, assuming that the second network device is P1, the third network device is P3; assuming that the second network device is P2, the third network device is P4.
[0071] In the event that the second network device fails, the first network device needs to bypass the second network device when transmitting data to ensure reliable data transmission. At this time, the first network device can point the route in the first data transmission direction to the third network device. In this way, when the first network device receives a data packet in the first data transmission direction (which can be referred to as the first data packet), the first network device can send the first data packet to the third network device according to the routing instruction, thereby bypassing the second network device for transmission.
[0072] In the case where the second network device fails, the first network device may also send a first control signaling to the third network device. The first control signaling may be used to control the route in the first data transmission direction in the third network device to point to the fourth network device.
[0073] The fourth network device may be the next hop on the second network device in the first data transmission direction.
[0074] Before the second network device fails, the first network device first sends the first data packet to the second network device, and then the second network device sends the first data packet to the fourth network device.
[0075] After the second network device fails, the first network device no longer sends the first data packet to the second network device, but sends it to the third network device instead. At this time, the third network device needs to send the first data packet to the fourth network device. Therefore, the first network device can send the first control information to the third network device so that the third network device points the route in the first data transmission direction to the fourth network device. In this way, after receiving the first data packet, the third network device can send the first data packet to the fourth network device. That is to say, in the case of a failure of the second network device, the first network device first sends the first data packet to the third network device, and then the third network device sends the first data packet to the fourth network device.
[0076] In a possible implementation, the first control signaling is further used to control the route in the second data transmission direction in the third network device to point to the first network device, and to control the route in the second data transmission direction in the fourth network device to point to the third network device.
[0077] Since the first data transmission direction and the second data transmission direction are opposite data transmission directions, the second network device is the next hop of the first network device in the first data transmission direction, and the first network device is the next hop of the second network device in the second data transmission direction. The fourth network device is the next hop of the second network device in the first data transmission direction, and the second network device is the next hop of the fourth network device in the second data transmission direction.
[0078] Before the second network device fails, the fourth network device first sends the second data packet (ie, the data packet in the second data transmission direction) to the second network device, and then the second network device sends the second data packet to the fourth network device.
[0079] After the second network device fails, the fourth network device first sends the second data packet to the third network device, and then the third network device sends the second data packet to the first network device.
[0080] Comparing the two data transmission directions, after the failure of the second network device: the transmission path of the first data packet in the first data transmission direction is the first network device, the third network device and the fourth network device; the transmission path of the second data packet in the second data transmission direction is the fourth network device, the third network device and the first network device. It can be seen that in the embodiment of the present application, the modification of the path is bidirectional. After the failure occurs, the paths for sending and receiving data will be modified together, thereby avoiding the occurrence of network problems with inconsistent back and forth paths.
[0081] In the above fault handling method, when the first network device detects that the second network device as the next hop fails, it points its own route to the backup device of the second network device, and controls the route on the first data transmission direction of the backup device to point to the next hop of the second network device by sending control signaling to the backup device. In this way, the backup device is directly instructed to change the route direction through the control signaling, so that the route direction change does not depend on the convergence speed of the BGP route, effectively improving the route switching speed, thereby reducing the impact of device failure on network performance.
[0082] Step S204: The third network device directs the route in the first data transmission direction to the fourth network device in response to the first control signaling.
[0083] It can be seen from step S201 and step S202 that the first control signaling is generated when the second network device fails. The second network device can be the next hop of the first network device in the first data transmission direction, and the second network device is the main device. The third network device represents the backup device of the second network device. That is, when the first network device detects that the second network device fails, the first network device generates the first control signaling and sends the first control information to the third network device as the backup device of the second network device, so that the third network device replaces the second network device to perform data transmission.
[0084] The fourth network device may represent the next hop of the second network device in the first data transmission direction.
[0085] Step S205: In response to the first control signaling, the third network device directs the route in the second data transmission direction to the first network device, and sends a third control signaling to the fourth network device.
[0086] The third control signaling can be used to control the route in the second data transmission direction in the fourth network device to point to the third network device. Here, the route in the first data transmission direction in the fourth network device does not need to be changed and can still follow the previous path.
[0087] Step S206: The fourth network device directs the route in the second data transmission direction to the third network device in response to the third control signaling.
[0088] In this way, after receiving the second data packet, the fourth network device can send the second data packet to the third network device, and then the third network device sends the second data packet to the first network device.
[0089] In addition, if the fourth network device is a HUB node, then after step S206, the fourth network device can continue to send the third control signaling to the next hop device in the first direction, so that it directs the route in the second data transmission direction to the fourth network device. If the fourth network device is a SPOKE node, then after step S206, the fourth network device does not need to continue to send the third control signaling. In other words, the third control signaling starts from the fourth network device (i.e., the next hop of the failed second network device in the first data transmission direction) to the SPOKE node, and is sent sequentially in the network along the first data direction.
[0090] Step S207: The first network device detects whether the fault of the second network device is restored.
[0091] When the quality of the link between the first network device and the second network device meets the preset condition or the second network device is reachable, the first network device can determine that the fault of the second network device has been recovered. For details, please refer to step S201 and no further description is given here.
[0092] Step S208: When the fault of the second network device is recovered and the duration reaches a preset threshold, the first network device directs the route in the first data transmission direction to the second network device.
[0093] The first network device may start timing when detecting that the second network device has recovered from a fault, and if the timing duration reaches a preset threshold, the route in the first data transmission direction is directed to the second network device. If the first network device detects that the second network device has failed again before the timing duration reaches the preset threshold, the first network device will reset the timing until the second network device is detected to have recovered from a fault again and then restart the timing.
[0094] The preset threshold can be set as needed, for example, the preset threshold can be set to 300 seconds. When the preset threshold is large, the probability of repeated switching of the routing line is low. When the preset threshold is small, the time for the routing line to recover is short.
[0095] In the embodiment of the present application, by switching the routing line after a period of time after the failure of the second network device is recovered, it is possible to prevent the failure of the link or device from repeatedly causing the routing to switch back and forth and affect traffic transmission.
[0096] Step S209: The first network device sends a second control signaling to the second network device.
[0097] The second control signaling may be used to control the route in the first data transmission direction in the second network device to point to the fourth network device, and the route in the second data transmission direction in the fourth network device to point to the second network device.
[0098] Step S210: The second network device directs the route in the first data transmission direction to the fourth network device in response to the second control signaling.
[0099] Step S211: The second network device sends a fourth control signaling to a fourth network device in response to the second control signaling.
[0100] The fourth control signaling is used to control the fourth network device to direct the route in the second data transmission direction to the second network device.
[0101] Step S212: The fourth network device directs the route in the second data transmission direction to the second network device in response to the fourth control signaling.
[0102] After the failure of the second network device is recovered, the transmission path in the first data transmission direction becomes the first network device, the second network device and the fourth network device; the transmission path in the second data transmission direction becomes the fourth network device, the second network device and the first network device.
[0103] In a possible implementation, each network device in the embodiment of the present application can change the route direction by filtering the route by the prefix list. For example, the first network device can point the route in the first data transmission direction to the third network device by rejecting the route of the second network device in the prefix list in the local first data transmission direction. The fourth network device can point the route in the second data transmission direction to the third network device by rejecting the route of the second network device in the prefix list in the local second data transmission direction. Of course, each network device can change the route direction by other means, such as modifying the forwarding table, routing table, etc., and the embodiment of the present application does not limit this.
[0104] In the embodiment of the present application, the first network device can detect in real time through a probe whether the second network device has a fault. Once the second network device has a fault, the route switching is automatically triggered without manual intervention, thereby realizing the automation of the entire switching process.
[0105] The automatic BGP convergence after the failure of the current SHHS architecture will only repair the single-way routing, which will lead to problems such as unequal routing or inconsistent routing paths. In the embodiment of the present application, the bidirectional routing will be modified at the same time to determine the stability and reliability of the routing.
[0106] In the embodiment of the present application, the switching speed of routing selection is greatly accelerated by controlling the signaling to indicate the modification of the route. Compared with the traditional automatic routing convergence, the switching time from the probe triggering task to the routing selection is controlled at the millisecond level, which improves the response speed and availability of the network.
[0107] In the current SHHS architecture, after the network line or HUB failure is restored, BGP will reconverge and then restore the original route. However, in this process, there may be continuous link fluctuations and repeated availability. In the embodiment of the present application, after the faulty line or device is restored, continuous detection for a period of time is performed to determine whether the line or device is normal before switching back to the original line, thereby ensuring the stability and availability of the overall network.
[0108] In summary, the embodiments of the present application optimize the availability and usability of the architecture and greatly increase the advantages of the overall architecture.
[0109] In an exemplary embodiment, Figure 3 The flowchart of the fault handling method provided by the embodiment of the present application is shown. Figure 3 As shown, the method may include:
[0110] Step S301: The first network device uses a probe to continuously detect the underlying line.
[0111] Step S302: The first network device detects whether a fault occurs in the second network device. If so, step S303 is executed; otherwise, step S307 is executed.
[0112] Step S303: The first network device modifies the local routing.
[0113] Step S304: The first network device sends a first control signaling to the third network device.
[0114] Step S305: The third network device modifies local routing in response to the first control signaling.
[0115] Step S306, the first network device determines whether the fault of the second network device is restored. If yes, execute step S301; otherwise, execute step S307.
[0116] Steps S303 to S306 may refer to steps S202 to S210 and will not be described in detail here.
[0117] Step S307: the first network device performs normal data forwarding.
[0118] Application Examples
[0119] Figure 4 The following is a schematic diagram showing the application of the fault handling method provided in the embodiment of the present application. Figure 4 As shown, in Figure 1 Based on the above, C1 (i.e., the first network device) detects that A (i.e., the link between the first network device and the second network device) fails, then C1 modifies its own routing from C1 to C2 to point to P3, and sends a first control signaling to P3 (i.e., the third network device). In response to the first control signaling, P3 modifies its own routing from C1 to C2 to point to P2, and sends a third control signaling to P2. In response to the third control signaling, P4 modifies its own routing from C2 to C1 to point to P4. Figure 4 As shown, in the case of fault A, the data transmission path from C1 to C2 passes through C1, D, P3, H, P2, C and C2 in sequence.
[0120] Figure 5 The following is a schematic diagram showing the application of the fault handling method provided in the embodiment of the present application. Figure 5 As shown, in Figure 1 Based on the above, P1 detects that B fails, then P1 modifies its own routing from C1 to C2 to point to P4, and sends a first control signaling to P4. In response to the first control signaling, P4 modifies its own routing from C1 to C2 to point to C2, and sends a third control signaling to C2. In response to the third control signaling, C2 modifies its own routing from C2 to C1 to point to P4. Figure 4 As shown, in the case of fault B, the data transmission path from C1 to C2 passes through: C1, A, P1, G, P4, F and C2 in sequence.
[0121] Figure 6 The following is a schematic diagram showing the application of the fault handling method provided in the embodiment of the present application. Figure 6As shown, C1 detects that P1 fails, then C1 modifies its own routing from C1 to C2 to point to P3, and sends a first control signaling to P3. P3 responds to the first control signaling and modifies its own routing from C1 to C2 to point to P2, and sends a third control signaling to P2. P2 responds to the second control signaling and modifies its own routing from C2 to C1 to point to P3. Figure 4 As shown, in the case of a failure of P1, the data transmission path from C1 to C2 passes through C1, D, P3, H, P2, C and C2 in sequence.
[0122] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.
[0123] Based on the same inventive concept, the embodiment of the present application also provides a fault handling device for implementing the fault handling method involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in one or more fault handling device embodiments provided below can refer to the limitations on the fault handling method above, and will not be repeated here.
[0124] In an exemplary embodiment, Figure 7 As shown, a fault handling device is provided. The device 700 can be applied to a first network device. The device 700 may include: a first detection module 701 and a first routing module 702, wherein:
[0125] A first detection module, used to detect whether a second network device fails, the second network device being the next hop of the first network device in a first data transmission direction, and the second network device being a main device;
[0126] The first routing module is used to point the route in the first data transmission direction to a third network device and send a first control signaling to the third network device when a failure occurs in the second network device. The third network device represents a backup device of the second network device. The first control signaling is used to control the route in the first data transmission direction in the third network device to point to a fourth network device. The fourth network device is the next hop on the second network device in the first data transmission direction.
[0127] In a possible implementation, the first control signaling is also used to control the routing in the second data transmission direction in the third network device to point to the first network device, and to control the routing in the second data transmission direction in the fourth network device to point to the third network device, wherein the second data transmission direction indicates a data transmission direction opposite to the first data transmission direction.
[0128] In a possible implementation manner, the device further includes:
[0129] A second detection module, used to detect whether the fault of the second network device is restored;
[0130] A second routing module is used to point the route in the first data transmission direction to the second network device when the fault of the second network device is recovered and the recovery duration reaches a preset threshold, and send a second control signaling to the second network device, wherein the second control signaling is used to control the route in the first data transmission direction in the second network device to point to the fourth network device and the route in the second data transmission direction in the fourth network device to point to the second network device.
[0131] In a possible implementation manner, the first detection module is further configured to:
[0132] Detecting a link between the first network device and the second network device;
[0133] When the quality of the link between the first network device and the second network device does not meet a preset condition, determining that a fault occurs in the second network device;
[0134] and / or,
[0135] In the case that the second network device is unreachable, it is determined that a failure occurs in the second network device.
[0136] In an exemplary embodiment, Figure 8As shown, a fault handling device is provided. The device 800 can be applied to a first network device. The device 800 may include: a receiving module 801 and a first routing module 802, wherein:
[0137] A receiving module, configured to receive a first control signaling sent by a first network device, wherein the first control signaling is generated when a second network device fails, the second network device is a next hop of the first network device in a first data transmission direction, the second network device is an active device, and the third network device represents a backup device of the second network device;
[0138] The first routing module is configured to, in response to the first control signaling, direct the route in the first data transmission direction to a fourth network device, where the fourth network device is the next hop of the second network device in the first data transmission direction.
[0139] In a possible implementation manner, the device further includes:
[0140] A second routing module is used to point the route in the second data transmission direction to the first network device in response to the first control signaling, and to send a third control signaling to the fourth network device, wherein the third control signaling is used to control the route in the second data transmission direction in the fourth network device to point to the third network device, and the second data transmission direction represents a data transmission direction opposite to the first data transmission direction.
[0141] Each module in the above fault handling device can be implemented in whole or in part by software, hardware, or a combination thereof. Each module can be embedded in or independent of a processor in a network device in the form of hardware, or can be stored in a memory in the network device in the form of software, so that the processor can call and execute operations corresponding to each module.
[0142] In an exemplary embodiment, a network device is provided. The network device may be a server, and its internal structure diagram may be as shown in FIG. Fig. 9As shown. The network device includes a processor, a memory, an input / output interface (Input / Output, referred to as I / O) and a communication interface. The processor, the memory and the input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. The processor of the network device is used to provide computing and control capabilities. The memory of the network device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the network device is used to store routing data. The input / output interface of the network device is used to exchange information between the processor and an external device. The communication interface of the network device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a fault handling method is implemented.
[0143] Those skilled in the art will understand that Fig. 9 The structure shown in the figure is only a block diagram of a partial structure related to the scheme of the present application, and does not constitute a limitation on the network device to which the scheme of the present application is applied. The specific network device may include more or fewer components than shown in the figure, or combine certain components, or have a different arrangement of components.
[0144] In an exemplary embodiment, a network device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above-mentioned method embodiments when executing the computer program.
[0145] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments are implemented.
[0146] In one embodiment, a computer program product is provided, including a computer program, which implements the steps in the above method embodiments when executed by a processor.
[0147] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.
[0148] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0149] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A fault handling method, characterized in that: The method is applied to a first network device, and the method includes: Detecting whether a second network device fails, where the second network device is the next hop of the first network device in the first data transmission direction and the second network device is a main device; In the event that the second network device fails, the route in the first data transmission direction is directed to a third network device, and a first control signaling is sent to the third network device, the third network device represents a backup device of the second network device, and the first control signaling is used to control the route in the first data transmission direction in the third network device to point to a fourth network device, and the fourth network device is the next hop on the second network device in the first data transmission direction; the first control signaling is also used to control the route in the second data transmission direction in the third network device to point to the first network device, and to control the route in the second data transmission direction in the fourth network device to point to the third network device, the second data transmission direction represents a data transmission direction opposite to the first data transmission direction.
2. The method according to claim 1, characterized in that The method further comprises: Detecting whether the failure of the second network device is restored; When the failure of the second network device is recovered and the recovery duration reaches a preset threshold, the route in the first data transmission direction is directed to the second network device, and a second control signaling is sent to the second network device, wherein the second control signaling is used to control the route in the first data transmission direction in the second network device to be directed to the fourth network device and the route in the second data transmission direction in the fourth network device to be directed to the second network device.
3. The method according to claim 1, characterized in that The detecting whether the second network device fails comprises: Detecting a link between the first network device and the second network device; When the quality of the link between the first network device and the second network device does not meet a preset condition, determining that a fault occurs in the second network device; and / or, In the case that the second network device is unreachable, it is determined that a failure occurs in the second network device.
4. A fault handling method, characterized in that: The method is applied to a third network device, and the method includes: receiving a first control signaling sent by a first network device, where the first control signaling is generated when a second network device fails, the second network device is a next hop of the first network device in a first data transmission direction, the second network device is an active device, and the third network device represents a backup device of the second network device; In response to the first control signaling, the route in the first data transmission direction is directed to a fourth network device, and the route in the second data transmission direction is directed to the first network device, and a third control signaling is sent to the fourth network device, wherein the third control signaling is used to control the route in the second data transmission direction in the fourth network device to point to the third network device, the second data transmission direction represents a data transmission direction opposite to the first data transmission direction, and the fourth network device is the next hop of the second network device in the first data transmission direction.
5. A fault handling device, characterized in that: The device is applied to a first network device, and the device includes: A first detection module, used to detect whether a second network device fails, the second network device being the next hop of the first network device in a first data transmission direction, and the second network device being a main device; The first routing module is used to point the route in the first data transmission direction to a third network device and send a first control signaling to the third network device when a failure occurs in the second network device. The third network device represents a backup device of the second network device. The first control signaling is used to control the route in the first data transmission direction in the third network device to point to a fourth network device. The fourth network device is the next hop on the second network device in the first data transmission direction. The first control signaling is also used to control the route in the second data transmission direction in the third network device to point to the first network device, and control the route in the second data transmission direction in the fourth network device to point to the third network device. The second data transmission direction represents a data transmission direction opposite to the first data transmission direction.
6. A fault handling device, characterized in that: The device is applied to a third network device, and the device includes: A receiving module, configured to receive a first control signaling sent by a first network device, wherein the first control signaling is generated when a second network device fails, the second network device is a next hop of the first network device in a first data transmission direction, the second network device is an active device, and the third network device represents a backup device of the second network device; The first routing module is used to, in response to the first control signaling, direct the route in the first data transmission direction to the fourth network device, direct the route in the second data transmission direction to the first network device, and send a third control signaling to the fourth network device, wherein the third control signaling is used to control the route in the second data transmission direction in the fourth network device to point to the third network device, the second data transmission direction represents a data transmission direction opposite to the first data transmission direction, and the fourth network device is the next hop of the second network device in the first data transmission direction.
7. A network device, comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, the processor implements the steps of the method according to any one of claims 1 to 3, or implements the steps of the method according to claim 4.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the computer program implements the steps of the method according to any one of claims 1 to 3, or implements the steps of the method according to claim 4.
Citation Information
Patent Citations
Transmission path fault processing method, device and system
CN112995029A