CN110113259B - Path state notification method, path switching method, forwarding equipment and system - Google Patents

Path state notification method, path switching method, forwarding equipment and system Download PDF

Info

Publication number
CN110113259B
CN110113259B CN201910345906.XA CN201910345906A CN110113259B CN 110113259 B CN110113259 B CN 110113259B CN 201910345906 A CN201910345906 A CN 201910345906A CN 110113259 B CN110113259 B CN 110113259B
Authority
CN
China
Prior art keywords
forwarding
path
forwarding device
fault
equipment
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910345906.XA
Other languages
Chinese (zh)
Other versions
CN110113259A (en
Inventor
郭威
王伟
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hangzhou H3C Technologies Co Ltd
Original Assignee
Hangzhou H3C Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hangzhou H3C Technologies Co Ltd filed Critical Hangzhou H3C Technologies Co Ltd
Priority to CN201910345906.XA priority Critical patent/CN110113259B/en
Publication of CN110113259A publication Critical patent/CN110113259A/en
Application granted granted Critical
Publication of CN110113259B publication Critical patent/CN110113259B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/22Alternate routing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/28Routing or path finding of packets in data switching networks using route fault recovery

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)
  • Telephonic Communication Services (AREA)

Abstract

The application provides a path state notification method, a path switching method, forwarding equipment and a system, wherein the method is applied to first forwarding equipment and comprises the following steps: receiving a path detection notification sent by second forwarding equipment, and determining a target input interface for receiving a message sent by the second forwarding equipment; taking the next hop device in the target routing table entry of the first forwarding device as a third forwarding device, and simulating the fault of each forwarding path between the next hop device and the third forwarding device; recording a path combination which causes that an output interface corresponding to the target routing table entry is the same as the target input interface under the condition of simulating the forwarding path fault as a fault path combination which can generate message reflux; and when detecting that the forwarding path in the failure path combination generates a failure, sending a failure notice to the second forwarding equipment. Therefore, the second forwarding equipment can timely know the state of the forwarding path, so that coping strategies such as backup path switching and the like can be timely executed, and message congestion in a communication network is avoided.

Description

Path state notification method, path switching method, forwarding equipment and system
Technical Field
The present application relates to the field of network communication technologies, and in particular, to a path state notification method, a path switching method, a forwarding device, and a system.
Background
In a communication network, important forwarding nodes or forwarding links are backed up in order to improve the disaster tolerance of the network. For example, referring to fig. 1, Host1 is connected to forwarding device NE41, and forwarding device NE41 obtains routing information to Host1, and then advertises to forwarding devices NE31 and NE32, and then advertises to forwarding device NE11 through NE31 and NE 32. Thus, NE11 records two pieces of routing information about Host1, the next hops of which are NE31 and NE32, respectively, and the administrator can enable Fast Reroute (FRR) function on NE11, specify NE31 as the primary next hop of Host1 and NE32 as the standby next hop. NE11 establishes a Bidirectional Forwarding Detection (BFD) session with NE31, and detects whether the Forwarding path with NE31 is normal through continuous BFD packet interaction. When NE11 detects through BFD that the forwarding path between NE31 is normal, the packet sent by NE11 to Host1 is sent from the main path to NE41 through NE 31. Once NE11 detects a failure of the forwarding path with NE31 via BFD, FRR switching is initiated to switch the packet destined for Host1 to use the backup path to NE41 via NE 32.
Disclosure of Invention
In a first aspect, the present application provides a path status notification method, applied to a first forwarding device, where the first forwarding device communicates with a second forwarding device, where the method includes:
receiving a path detection notification sent by the second forwarding equipment, and determining a target input interface for receiving a message sent by the second forwarding equipment;
taking the next hop device in the target routing table entry of the first forwarding device as a third forwarding device, and simulating the fault of each forwarding path between the next hop device and the third forwarding device;
recording a path combination which causes that an output interface corresponding to the target routing table entry is the same as the target input interface under the condition of simulating the forwarding path fault as a fault path combination which can generate message reflux;
and when detecting that the forwarding path in the failure path combination generates a failure, sending a failure notification to the second forwarding equipment.
Optionally, in the above method, the step of recording, as a faulty path combination that would generate packet backflow, a path combination that causes the egress interface corresponding to the target routing table entry to be the same as the target ingress interface under the condition of the simulated forwarding path fault includes:
detecting whether a fault path combination which can cause the same fault path combination of the output interface corresponding to the target routing table entry and the target input interface exists or not;
if a fault path combination which can cause the output interface corresponding to the target routing table entry to be the same as the target input interface is detected to exist, recording the fault path combination and establishing a Bidirectional Forwarding Detection (BFD) session with the second forwarding equipment;
the step of sending a failure notification to the first forwarding device when detecting that a forwarding path in the failed path combination fails includes:
and when detecting that a forwarding path in the failure path combination has a failure, sending a BFD failure message aiming at the BFD session to the second forwarding equipment as the failure notification.
Optionally, in the above method, the step of recording, as a faulty path combination that would generate packet backflow, a path combination that causes the egress interface corresponding to the target routing table entry to be the same as the target ingress interface under the condition of the simulated forwarding path fault includes:
respectively aiming at each third forwarding device, detecting and recording the corresponding relation between the fault path combination which can lead the output interface corresponding to the target routing table entry to be the same as the target input interface and the third forwarding device;
the step of sending a failure notification to the second forwarding device when a failure is actually detected on a forwarding path in the failed path combination includes:
and when detecting that a forwarding path in any one of the failure path combinations has a failure, sending a corresponding failure notification to the second forwarding device for the third forwarding device corresponding to the failure path combination.
Optionally, in the above method, after the step of detecting and recording, for each third forwarding device, a corresponding relationship between a failure path combination and the third forwarding device, where the failure path combination would cause the outgoing interface corresponding to the target routing table entry to be the same as the target incoming interface, the method further includes:
and determining a third forwarding device corresponding to each fault path combination which can cause message backflow, and sending a corresponding relation between a host accessed to the third forwarding device and the third forwarding device to the second forwarding device.
Optionally, in the above method, the step of detecting and recording, for each third forwarding device, a corresponding relationship between a failure path combination and the third forwarding device, where the failure path combination would cause the outgoing interface corresponding to the target routing table entry to be the same as the target incoming interface, includes:
respectively aiming at each third forwarding device, detecting whether a fault path combination which can cause the same fault path combination of the output interface corresponding to the target routing table entry and the target input interface exists;
if a fault path combination which can cause the output interface corresponding to the target routing table entry to be the same as the target input interface is detected to exist, a BFD session is established with the second forwarding equipment, and messages of the BFD session are provided with state identifications corresponding to fault paths which respectively cause message reflux;
the step of sending a corresponding failure notification to the second forwarding device for the third forwarding device corresponding to the failed path combination when detecting that the forwarding path in any one of the failed path combinations has a failure includes:
and when detecting that a forwarding path in the failure path combination has a failure, sending a BFD status message carrying an identifier of a third forwarding device to the second forwarding device as the failure notification for the third forwarding device corresponding to the failure path combination.
Optionally, in the above method, the detecting and recording, for each of the third forwarding devices, a correspondence relationship between a failure path combination that would result in that an egress interface corresponding to the target routing table entry is the same as the target ingress interface and the third forwarding device includes:
respectively aiming at each third forwarding device, detecting whether a fault path combination which can cause the same fault path combination of the output interface corresponding to the target routing table entry and the target input interface exists;
if a fault path combination which can cause the output interface corresponding to the target routing table entry to be the same as the target input interface is detected to exist, establishing a BFD session aiming at the third forwarding equipment and the second forwarding equipment;
the step of sending a corresponding failure notification to the second forwarding device for the third forwarding device corresponding to the failed path combination when detecting that the forwarding path in any one of the failed path combinations has a failure includes:
when a forwarding path in the failure path combination is actually detected to have a failure, determining a third forwarding device corresponding to the failure path combination;
and sending a BFD fault message to the second forwarding equipment as the fault notification aiming at the BFD session corresponding to the third forwarding equipment.
Optionally, in the above method, if it is detected that there is a faulty path combination that causes the egress interface corresponding to the target routing table entry to be the same as the target ingress interface, the step of establishing a BFD session for the third forwarding device and the second forwarding device includes:
if the fault path combination which causes the outlet interface corresponding to the target routing table entry to be the same as the target inlet interface is detected to exist, a BFD session establishment request carrying a preset identifier is sent to the second forwarding equipment aiming at the third forwarding equipment so as to establish the BFD session with the second forwarding equipment.
Optionally, in the above method, the path detection notification includes a BFD session establishment request with a preset identifier; the step of receiving the path detection notification sent by the second forwarding device includes:
and receiving a BFD session establishment request with a preset identifier sent by the second forwarding equipment.
In a second aspect, the present application provides a path switching method, which is applied to a communication network including a first forwarding device and a second forwarding device; the method comprises the following steps:
the second forwarding equipment sends a path detection notice to the first forwarding equipment;
the first forwarding equipment determines a target access interface for receiving the message sent by the second forwarding equipment, and takes the next hop equipment in the target routing table item of the first forwarding equipment as third forwarding equipment according to the path detection notification, so as to simulate the fault of each forwarding path between the first forwarding equipment and the third forwarding equipment;
the first forwarding equipment identifies a path combination, which is the same as the target input interface, of an output interface corresponding to the target routing table entry under the condition that the simulated forwarding path fails, as a failure path combination which can cause message backflow;
when detecting that a forwarding path in the failure path combination has a failure, the first forwarding device sends a failure notification to the second forwarding device;
and the second forwarding equipment switches the message sent to the third forwarding equipment to the standby forwarding equipment corresponding to the first forwarding equipment according to the fault notification.
In a third aspect, the present application provides a forwarding device, including a machine-readable storage medium and a processor, where the machine-readable storage medium stores machine-executable instructions, and the processor, when executing the machine-executable instructions, causes the forwarding device to serve as a first forwarding device to implement the path state notification method provided in the present application.
In a fourth aspect, the present application provides a forwarding system, which includes a first forwarding device and a second forwarding device, where the first forwarding device and the second forwarding device cooperate with each other to implement the path switching method provided in the present application.
Compared with the prior art, the method has the following beneficial effects:
according to the path state notification method, the path switching method, the forwarding device and the system provided by the embodiment of the application, after the first forwarding device receives the path detection notification sent by the second forwarding device, the failure path combination which can cause the message sent by the second forwarding device to the third forwarding device to form message backflow is automatically detected in advance, and the second forwarding device is notified when the failure of the forwarding path in the failure path combination is actually detected, so that the second forwarding device can timely know the state of the forwarding path, and therefore coping strategies such as backup path switching can be timely executed.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are required to be used in the embodiments will be briefly described below, it should be understood that the following drawings only illustrate some embodiments of the present application and therefore should not be considered as limiting the scope, and for those skilled in the art, other related drawings can be obtained from the drawings without inventive effort.
FIG. 1 is a schematic diagram of prior art FRR switching;
FIG. 2 is a schematic diagram of an application scenario in which the present application is implemented;
fig. 3 is a schematic flowchart of a path state notification method according to an embodiment of the present application;
FIG. 4 is a second exemplary embodiment of the present application;
fig. 5 is a schematic flowchart of a path switching method according to an embodiment of the present application;
fig. 6 is a hardware schematic diagram of a forwarding device according to an embodiment of the present application.
Icon: 100-a forwarding device; 120-a machine-readable storage medium; 130-a processor.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some embodiments of the present application, but not all embodiments. The components of the embodiments of the present application, generally described and illustrated in the figures herein, can be arranged and designed in a wide variety of different configurations.
Thus, the following detailed description of the embodiments of the present application, presented in the accompanying drawings, is not intended to limit the scope of the claimed application, but is merely representative of selected embodiments of the application. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures.
In some embodiments, the path switching of FRR depends only on the BFD session state between two forwarding devices, and this switching strategy may not be able to trigger the backup path switching in time in a more complex networking environment.
For example, referring to fig. 2, in the networking environment shown in fig. 2, forwarding device NE11, forwarding device NE21 and NE22 are neighbors of each other, forwarding device NE21, forwarding device NE22 and NE31 are neighbors of each other, forwarding device NE22, forwarding device NE21 and NE32 are neighbors of each other, forwarding device NE31, forwarding device NE32 and forwarding device NE41 are neighbors of each other, and forwarding device NE32, forwarding device NE31 and NE41 are neighbors of each other.
NE41 gets the route of Host1, and advertises to NE31 and NE32, NE31 and NE32 advertises to the outside, and the next hop of the advertised route is modified to NE31 and NE32, respectively. The routes advertised by NE31 and NE32 are synchronized to NE11, where NE21 and NE22 do not modify the next hop of the route when advertising it to NE 11.
NE11 enables FRR, and the advertised routes form the active-standby next hop for Host1 on NE11, NE31 and NE32 respectively. NE11 may also establish a BFD session with NE31, and when detecting that the forwarding path between NE31 is normal through the BFD session, send a message with a destination address of Host1 to main next hop NE 31; when a forwarding path failure with the NE31 is detected through the BFD session, FRR switching is performed to send the message to the standby next hop NE 32.
Meanwhile, the NE31 also activates FRR, and for the packet sent to NE41 by NE31, the main path is L10 shown in fig. 2, and the backup path is L9-L8; and NE31 sends the message of NE32, and the main path is L9, and the reserve path is L5-L4-L6. That is, the packet sent from NE31 to NE41 has 3 path exits on NE31, which are L10, L9, and L5, respectively.
In this case, if L10 and L9 fail, but L5 and L3 are normal, NE11 considers that the forwarding path with NE31 is normal, and therefore FRR switching is not performed, and the message continues to be sent to NE 31. However, because L10 and L9 have failed at the same time, N31 will send the message to NE32 via L5-L4-L6, and then to NE41 via NE 32. That is, the message forms a reflux on L5, wasting L5 bandwidth. Although eventually NE11 may converge the forwarding path to send the message directly to NE32 through some mechanism, the convergence process takes a relatively long time, which may cause temporary message congestion on L5.
In some scenarios, an administrator may manually configure some detection policies according to the networking environment at NE31, so as to send notification to NE11 to trigger FRR switching when some forwarding paths fail, but this approach requires manual analysis and configuration by the administrator and requires configuration actions to be performed on NE31, which is inconvenient.
Based on the discovery of the above problems, the present embodiment provides a scheme for performing path status notification in a networking environment similar to that described above, and the scheme provided by the present embodiment is explained in detail below.
Referring to fig. 3, fig. 3 is a flowchart of a path status method provided in this embodiment, and the method may be applied to a first forwarding device in communication with a second forwarding device, for example, in the networking shown in fig. 2, the first forwarding device may be forwarding device NE31, the second forwarding device may be forwarding device NE11, and NE31 may communicate with NE11 through NE 21. The method including the respective steps will be described in detail below.
Step S110, receiving a path detection notification sent by the second forwarding device, and determining a target input interface for receiving a message sent by the second forwarding device.
In this embodiment, the second forwarding device may record a backup forwarding device corresponding to the first forwarding device. For example, in fig. 2, for Host1, NE11 has a backup forwarding device NE32 corresponding to NE31 recorded thereon.
The administrator may configure on the second forwarding device to send a path detection notification to the first forwarding device.
In this embodiment, the first forwarding device may use, after receiving the path detection notification, an interface that receives the packet sent by the second forwarding device as a target input interface. For example, an interface that receives a path detection notification may be targeted into the interface; or searching a data message with the source address being the address of the second forwarding device, and taking the inlet interface of the searched message as the target inlet interface.
Step S120, using the next hop device in the target routing table entry of the first forwarding device as a third forwarding device, and simulating a fault of each forwarding path between the first forwarding device and the third forwarding device.
Step S130, recording a path combination that the next hop is the same as the outgoing interface and the target incoming interface corresponding to the target routing table entry of the third forwarding device under the condition of the simulated forwarding path failure as a failure path combination that may generate message backflow.
After receiving the path detection notification, the first forwarding device queries its routing table entries as target routing table entries in sequence, and for each target routing table entry, takes the next hop of the target routing table entry as a third forwarding device, and simulates the failure of each forwarding path between the first forwarding device and the third forwarding device.
And then the first forwarding equipment detects whether the failure of the forwarding paths or the forwarding path combination can cause the message reflux of the message sent to the third forwarding equipment by the second forwarding equipment. For example, the first forwarding device simulates a certain forwarding path or a simultaneous failure of a plurality of forwarding paths, detects whether the outgoing interface corresponding to the target routing table entry after the forwarding path is switched due to the failure of the forwarding path is the same as the target incoming interface determined in step S110, and records the path combination that causes the outgoing interface corresponding to the target routing table entry to be the same as the target incoming interface as the failure path combination that will generate the message reflux.
For example, in the networking shown in fig. 2, NE31 first determines that a message from NE11 is received from an interface corresponding to L5. The next hop of the Host1 route recorded by NE31 comprises NE41, then NE31 emulates a forwarding path failure with NE 41. NE31 detects that when L10 and L9 fail at the same time, the outgoing interface corresponding to the routing table entry of the next hop, which is NE41, becomes the outgoing interface corresponding to L5, that is, a packet sent by NE11 to NE41 enters NE31 from L5 and is sent out from L5, then NE31 determines that when L10 and L9 fail at the same time, the packet sent by N11 to NE41 forms a reflux on NE31, and NE31 records the combination of the failed paths of L10 and L9.
Step S140, when detecting that the forwarding path in the failed path combination has failed, sending a failure notification to the second forwarding device.
After obtaining the faulty path combination through step S130, the first forwarding device may detect the forwarding path status in the faulty path combination in real time. Upon detecting a failure of a forwarding path in the failed path combination, the first forwarding device sends a failure notification to the second forwarding device. For example, in the networking shown in fig. 2, if NE31 detects that L10 and L9 fail simultaneously, it sends a failure notification to NE 11.
The second forwarding device may execute some changes of the forwarding policy in time after receiving the failure notification, so as to avoid the generation of message reflux. For example, the NE11 may directly perform FRR switching after receiving the failure notification sent by the NE31, to directly send the packet addressed to the Host1 to the NE32, so as to avoid the packet from generating packet backflow at the NE 31.
Through the above design, in the scheme provided in this embodiment, the first forwarding device learns the requirement that the second forwarding device needs to learn the path state through the path detection notification sent by the second forwarding device, then automatically detects and records, for the second forwarding device, that there is a failure path combination that may cause a packet sent from the second forwarding device to the third forwarding device to generate packet backflow, and notifies the second forwarding device when a forwarding path failure in the failure path combination is actually detected, so that the second forwarding device can timely execute a corresponding response action to avoid congestion caused by packet backflow, and reliability of the network is improved.
Optionally, in step S130, the first forwarding device may first detect whether there is a failure path combination that would cause the same egress interface corresponding to the target routing table entry as the target ingress interface.
If the fault path combination which can cause the same output interface and the same target input interface corresponding to the target routing table entry exists, recording the fault path combination and establishing a BFD session with the second forwarding equipment.
After that, when detecting that a forwarding path in the failed path combination has a failure, the first forwarding device may send, to the second forwarding device, a BFD failure packet for the BFD session as a failure notification.
In one implementation of this embodiment, the request for BFD session establishment may be initiated by the second forwarding device. For example, in step S110, the second forwarding device sends a BFD session establishment request carrying a preset field as a path detection notification. The predetermined field may be a flag (flag) type added in the BFD control message.
Then, in step S130, if it is detected that there is a faulty path combination that would cause the egress interface corresponding to the target routing table entry to be the same as the target ingress interface, the first forwarding device responds to the BFD session establishment request of the second forwarding device, so as to establish a BFD session with the second forwarding device, and associate the BFD session with the faulty path combination.
In another implementation of this embodiment, the BFD session request may also be initiated by the first forwarding device. For example, in step S110, the first forwarding device may send the path detection notification in any form of notification manner.
Then, in step S130, if it is detected that there is a faulty path combination that would cause the outgoing interface corresponding to the target routing table entry to be the same as the target incoming interface, the first forwarding device initiates a BFD session establishment request to the second forwarding device, so as to establish a BFD session associated with the faulty path combination.
After the first forwarding device and the second forwarding device establish the BFD session, once it is detected that the forwarding path in the failed path combination fails, the first forwarding device sends a BFD failure message to the second forwarding device as a failure notification, for example, the sending BFD message sets the local state to down.
The second forwarding device may associate the BFD session with the backup path switching action, trigger switching of the backup path after receiving the BFD failure message, and convert the message originally sent to the third forwarding device to the backup forwarding device corresponding to the first forwarding device.
Through the design, the failure information can be rapidly transferred in a BFD session mode, and the mechanism that the BFD session can be bound with the backup link switching action can enable the second forwarding equipment to automatically trigger the backup path switching action.
Optionally, in this embodiment, a plurality of target routing table entries different from the next hop device may exist in the routing table entry of the first forwarding device, that is, a plurality of target routing table entries corresponding to different third forwarding devices are configured in the first forwarding device, for example, referring to fig. 4, the NE31 records that the next hop corresponding to the Host1 includes the NE41, and also records that the next hop corresponding to the Host2 includes the NE 51.
In this case, in step S120, the first forwarding device may serve as a third forwarding device for each next-hop device, and simulate a failure of each forwarding path with the third forwarding devices.
Then, in step S130, for each third forwarding device, a corresponding relationship between a combination of a failure path and the third forwarding device, where the combination of the failure path and the third forwarding device is the same as the egress interface and the target ingress interface corresponding to the target routing table entry that causes the next hop to be the third forwarding device, is detected and recorded.
For example, in the networking shown in fig. 4, NE31 simulates the failure of a forwarding link for NE41 and NE51, respectively. According to the simulation results, NE31 records the correspondence of the failed path combination of L9 and L10 to NE41, and records the correspondence of the failed path combination of L9 and L11 to NE 51.
In step S140, when it is detected that a forwarding path in any one faulty path combination has failed, a fault notification corresponding to a third forwarding device corresponding to the faulty path combination is transmitted to the second forwarding device.
For example, if NE31 detects a simultaneous failure of L9 and L10, a failure notification is sent to NE11 for NE 41. If NE31 detects a simultaneous failure of L9 and L11, a failure notification is sent to NE11 for NE 51.
In an implementation manner of this embodiment, after step S130, the first forwarding device may further determine, for each faulty path combination that may cause packet backflow, a third forwarding device corresponding to the faulty path combination, determine that a next hop in the target routing table entry of the first forwarding device is a host of the third forwarding device, and notify a second forwarding device of a corresponding relationship between the hosts and the third forwarding device. For example, after detecting that the L9 and L10 failure would cause message backflow, the NE31 sends the corresponding relationship between the NE41 and the Host1 to the NE 11.
In this way, after the second forwarding device receives the failure notification corresponding to the third forwarding device, the switching of the backup link is performed for the corresponding host according to the correspondence notified by the first forwarding device.
In another implementation of this embodiment, NE41, when advertising the route of Host1, may add the route, originally generated by NE41, to the advertised route information. For example, NE41 advertises routes externally via Border Gateway Protocol (BGP) messages, and carries the routes in the extended community attribute of BGP route advertisement messages are generated by NE 41.
NE11, after receiving the route obtained from NE41 and announced by NE31, knows from the extended community attribute that the route is generated by NE41, and records the correspondence between Host1 and NE 41.
Alternatively, in step S110, the first forwarding device may send the path detection notification in any form of notification manner. In step S130, the first forwarding device may detect, for each third forwarding device, whether there is a failure path combination that causes the next hop to be the same as the egress interface and the target ingress interface corresponding to the target routing table entry of the third forwarding device.
And if the fault path combination which causes the next hop to be the same as the outgoing interface and the target incoming interface corresponding to the target routing table entry of the third forwarding device is detected to exist, establishing the BFD session aiming at the third forwarding device and the second forwarding device. For example, NE31 may initiate a BFD session establishment request to NE11 for NE41, where the request may carry identification information of NE41, so that the second forwarding device establishes a BFD session associated with NE 41; NE31 further initiates a BFD session establishment request to NE11 for NE51, where the request may carry identification information of NE51, so that the second forwarding device establishes a BFD session associated with NE 51.
Then, in step S140, when it is actually detected that a forwarding path in the failed path combination has a failure, a third forwarding device corresponding to the failed path combination is determined, and a BFD failure packet is sent to the second forwarding device as a failure notification for a BFD session corresponding to the third forwarding device. For example, upon detection of L9 and L10 failures, BFD failure messages are sent as failure notifications for BFD sessions associated with NE 41.
After receiving a BFD fault message of a BFD session, the second forwarding device determines a third forwarding device corresponding to the BFD session, determines hosts corresponding to the third forwarding device, and then performs backup path switching on the hosts. Therefore, FRR switching can be carried out only on the path which can generate message backflow, and other forwarding paths which normally work are not affected.
Optionally, in step S130, the first forwarding device may detect, for each third forwarding device, whether there is a failure path combination that causes the next hop to be the same as the outgoing interface and the target incoming interface corresponding to the target routing table entry of the third forwarding device.
And if the next hop is detected to be a fault path combination which can cause the next hop to be the same as the outgoing interface and the target incoming interface corresponding to the target routing table entry of the third forwarding equipment, establishing the BFD session with the second forwarding equipment. The message of the BFD session may include different status identifier fields corresponding to different third forwarding devices.
Then, in step S140, when detecting that a forwarding path in the failure path combination has a failure, the first forwarding device may send, to a third forwarding device corresponding to the failure path combination, a BFD status packet carrying an identifier of the third forwarding device as a failure notification to the second forwarding device. In other words, the first forwarding device may advertise path states of a plurality of third forwarding devices to the second forwarding device through the same BFD session.
For example, NE31 detects a faulty path combination that would cause message backflow, that is, establishes a BFD session with NE11, and when a session is established, NE31 may carry identification information of NE41 and NE51 in a BFD session establishment request message or a message responding to a session establishment request of NE 11. The control message of the BFD session respectively corresponds to two status flag bits of NE41 and NE51, and when NE31 detects that a forwarding path in a faulty path combination corresponding to NE41 or NE51 fails, NE11 may be notified of a barrier notification through the status flag bit of the BFD session.
Referring to fig. 5, fig. 5 is a schematic flow chart illustrating a path switching method provided in this embodiment, where the method may be applied to a communication network including a first forwarding device and a second forwarding device, for example, to a communication network including NE31 and NE11 shown in fig. 2. In this embodiment, the second forwarding device may record a primary and standby next hop route of the target host, where the primary next hop is the first forwarding device, and the standby next hop is the backup forwarding device corresponding to the first forwarding device. For example, in the networking shown in fig. 2, NE11 may record the route of Host1 advertised by NE31 and NE32 and form the master-standby next hop. The individual steps of the method are explained below.
Step S210, the second forwarding device sends a path detection notification to the first forwarding device.
Step S220, the first forwarding device determines a target ingress interface for receiving the message sent by the second forwarding device, and uses the next hop device in the target routing table entry of the first forwarding device as a third forwarding device according to the path detection notification, so as to simulate a fault of each forwarding path between the first forwarding device and the third forwarding device.
In step S230, the first forwarding device identifies, under the condition that the simulated forwarding path fails, a path combination that the outgoing interface corresponding to the target routing table entry is the same as the target incoming interface, as a failed path combination that would cause message backflow.
In step S240, the first forwarding device sends a failure notification to the second forwarding device when detecting that a forwarding path in the failed path combination fails.
Step S250, the second forwarding device switches the message sent to the third forwarding device to the standby forwarding device corresponding to the first forwarding device according to the failure notification.
In step S210, the second forwarding device may send a path detection notification to the first forwarding device under the operation control of the administrator.
Please refer to steps S120 to S140 shown in fig. 3 for the detailed process from step S220 to step S240, which is not described herein again.
The second forwarding device may automatically trigger a switching action according to the failure notification in step S250, for example, the FRR function is started on the second forwarding device, and may automatically trigger FRR switching according to the failure notification sent by the first forwarding device.
Referring to fig. 6, fig. 6 is a schematic diagram of a hardware structure of a forwarding device 100 according to this embodiment. The forwarding device 100 may include a processor 130 and a machine-readable storage medium 120. The processor 130 and the machine-readable storage medium 120 may communicate via a system bus. Also, the machine-readable storage medium 120 stores machine-executable instructions, and the processor 130 may perform the path state notification method described above by reading and executing the machine-executable instructions corresponding to the path state notification logic in the machine-readable storage medium 120.
A machine-readable storage medium as referred to herein may be any electronic, magnetic, optical, or other physical storage device that can contain or store information such as executable instructions, data, and the like. For example, the machine-readable storage medium may be: a RAM (random Access Memory), a volatile Memory, a non-volatile Memory, a flash Memory, a storage drive (e.g., a hard drive), a solid state drive, any type of storage disk (e.g., a compact disk, a DVD, etc.), or similar storage medium, or a combination thereof.
The embodiment also provides a forwarding system, which may include the first forwarding device and the second forwarding device, where the first forwarding device and the second forwarding device cooperate with each other to implement the method shown in fig. 5.
To sum up, according to the path state notification method, the path switching method, the forwarding device and the system provided in the embodiment of the present application, after receiving the path detection notification sent by the second forwarding device, the first forwarding device automatically detects in advance a failure path combination that causes a message sent by the second forwarding device to the third forwarding device to form a message reflux, and notifies the second forwarding device when it is actually detected that a failure occurs in a forwarding path in the failure path combination, so that the second forwarding device can timely know the state of the forwarding path, and thus timely execute a countermeasure policy such as backup path switching.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other ways. The apparatus embodiments described above are merely illustrative, and for example, the flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of apparatus, methods and computer program products according to various embodiments of the present application. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
In addition, functional modules in the embodiments of the present application may be integrated together to form an independent part, or each module may exist separately, or two or more modules may be integrated to form an independent part.
The functions, if implemented in the form of software functional modules and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application or portions thereof that substantially contribute to the prior art may be embodied in the form of a software product stored in a storage medium and including instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
It is noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The above description is only for various embodiments of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily conceive of changes or substitutions within the technical scope of the present application, and all such changes or substitutions are included in the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.

Claims (11)

1. A path status notification method applied to a first forwarding device, the first forwarding device communicating with a second forwarding device, the method comprising:
receiving a path detection notification sent by the second forwarding equipment, and determining a target input interface for receiving a message sent by the second forwarding equipment;
taking the next hop device in the target routing table entry of the first forwarding device as a third forwarding device, and simulating the fault of each forwarding path between the next hop device and the third forwarding device;
recording a path combination which causes that an output interface corresponding to the target routing table entry is the same as the target input interface under the condition of simulating the forwarding path fault as a fault path combination which can generate message reflux;
and when detecting that all forwarding paths in the faulty path combination simultaneously have faults, sending a fault notification to the second forwarding device, where the fault notification is used to inform the second forwarding device that a path currently sending a message to the third forwarding device may generate message reflux.
2. The method of claim 1,
the step of recording a path combination that causes the same output interface corresponding to the target routing table entry and the target input interface under the condition of the simulated forwarding path fault as a fault path combination that can generate message reflux includes:
detecting whether a fault path combination which can cause the same fault path combination of the output interface corresponding to the target routing table entry and the target input interface exists or not;
if a fault path combination which can cause the output interface corresponding to the target routing table entry to be the same as the target input interface is detected to exist, recording the fault path combination and establishing a Bidirectional Forwarding Detection (BFD) session with the second forwarding equipment;
the step of sending a failure notification to the second forwarding device when it is detected that all forwarding paths in the failed path combination have failed simultaneously includes:
and when detecting that all forwarding paths in the failure path combination simultaneously generate failures, sending a BFD failure message aiming at the BFD session to the second forwarding equipment as the failure notification.
3. The method of claim 1, wherein the first forwarding device is configured with a plurality of target routing table entries corresponding to different third forwarding devices;
the step of recording a path combination that causes the same output interface corresponding to the target routing table entry and the target input interface under the condition of the simulated forwarding path fault as a fault path combination that can generate message reflux includes:
respectively aiming at each third forwarding device, detecting and recording the corresponding relation between a fault path combination which can lead the next hop to be the same as the outlet interface corresponding to the target routing table entry of the third forwarding device and the target inlet interface and the third forwarding device;
the step of sending a failure notification to the second forwarding device when it is detected that all forwarding paths in the failed path combination have failed simultaneously includes:
and when detecting that all forwarding paths in any one of the failure path combinations simultaneously generate failures, sending a corresponding failure notification to the second forwarding device by aiming at the third forwarding device corresponding to the failure path combination.
4. The method according to claim 3, wherein after the step of detecting and recording, for each of the third forwarding devices, a corresponding relationship between a combination of a failed path and the third forwarding device that would result in a next hop being the same as the target ingress interface and an egress interface corresponding to the target routing table entry of the third forwarding device, the method further comprises:
and determining a third forwarding device corresponding to each fault path combination which can cause message backflow, and sending a corresponding relation between a host accessed to the third forwarding device and the third forwarding device to the second forwarding device.
5. The method of claim 3,
the step of detecting and recording, for each of the third forwarding devices, a correspondence between a failure path combination that would cause a next hop to be a failure path combination that is identical to the outgoing interface and the target incoming interface corresponding to the target routing table entry of the third forwarding device, and the third forwarding device, includes:
respectively aiming at each third forwarding device, detecting whether a fault path combination which can cause the next hop to be the same as the target input interface and the output interface corresponding to the target routing table entry of the third forwarding device exists;
if detecting that a fault path combination which can cause the next hop to be the same as the target input interface of the output interface corresponding to the target routing table entry of the third forwarding equipment exists, establishing a BFD session with the second forwarding equipment, wherein messages of the BFD session are provided with state identifications corresponding to fault paths which respectively cause message reflux;
the step of sending a corresponding failure notification to the second forwarding device for the third forwarding device corresponding to the failed path combination when it is detected that all forwarding paths in any one of the failed path combinations fail simultaneously includes:
and when detecting that all forwarding paths in the fault path combination simultaneously generate faults, sending a BFD status message carrying the identifier of the third forwarding device to the second forwarding device as the fault notification aiming at the third forwarding device corresponding to the fault path combination.
6. The method of claim 3,
the step of detecting and recording, for each of the third forwarding devices, a correspondence between a failure path combination that would cause a next hop to be a failure path combination that is identical to the outgoing interface and the target incoming interface corresponding to the target routing table entry of the third forwarding device, and the third forwarding device, includes:
respectively aiming at each third forwarding device, detecting whether a fault path combination which can cause the next hop to be the same as the target input interface and the output interface corresponding to the target routing table entry of the third forwarding device exists;
if the fault path combination which can cause the next hop to be the same as the target input interface of the output interface corresponding to the target routing table entry of the third forwarding equipment is detected to exist, a BFD session is established for the third forwarding equipment and the second forwarding equipment;
the step of sending a corresponding failure notification to the second forwarding device for the third forwarding device corresponding to the failed path combination when it is detected that all forwarding paths in any one of the failed path combinations fail simultaneously includes:
when it is actually detected that all forwarding paths in the faulty path combination simultaneously generate faults, determining third forwarding equipment corresponding to the faulty path combination;
and sending a BFD fault message to the second forwarding equipment as the fault notification aiming at the BFD session corresponding to the third forwarding equipment.
7. The method according to claim 6, wherein if it is detected that there is a faulty path combination that causes a next hop to be the same as an egress interface and the target ingress interface corresponding to the target routing table entry of the third forwarding device, the step of establishing the BFD session for the third forwarding device and the second forwarding device includes:
and if the fact that the next hop is a fault path combination which causes the next hop to be the same as the outlet interface and the target inlet interface corresponding to the target routing table entry of the third forwarding equipment is detected, sending a BFD session establishment request carrying a preset identifier to the second forwarding equipment aiming at the third forwarding equipment so as to establish the BFD session with the second forwarding equipment.
8. The method according to any of claims 1-6, wherein the path detection notification comprises a BFD session establishment request with a preset identification; the step of receiving the path detection notification sent by the second forwarding device includes:
and receiving a BFD session establishment request with a preset identifier sent by the second forwarding equipment.
9. A path switching method is characterized by being applied to a communication network comprising a first forwarding device and a second forwarding device; the method comprises the following steps:
the second forwarding equipment sends a path detection notice to the first forwarding equipment;
the first forwarding equipment determines a target access interface for receiving the message sent by the second forwarding equipment, and takes the next hop equipment in the target routing table item of the first forwarding equipment as third forwarding equipment according to the path detection notification, so as to simulate the fault of each forwarding path between the first forwarding equipment and the third forwarding equipment;
the first forwarding equipment identifies a path combination, which is the same as the target input interface, of an output interface corresponding to the target routing table entry under the condition that the simulated forwarding path fails, as a failure path combination which can cause message backflow;
when detecting that all forwarding paths in the failure path combination simultaneously generate failures, the first forwarding device sends a failure notification to the second forwarding device;
and the second forwarding equipment sends the message sent to the third forwarding equipment to the standby forwarding equipment corresponding to the first forwarding equipment according to the fault notification.
10. A forwarding device comprising a machine-readable storage medium having stored thereon machine-executable instructions and a processor, which when executed causes the forwarding device to perform the method of any one of claims 1-7 as a first forwarding device.
11. A forwarding system comprising a first forwarding device and a second forwarding device, wherein the first forwarding device and the second forwarding device cooperate to implement the method of claim 9.
CN201910345906.XA 2019-04-26 2019-04-26 Path state notification method, path switching method, forwarding equipment and system Active CN110113259B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910345906.XA CN110113259B (en) 2019-04-26 2019-04-26 Path state notification method, path switching method, forwarding equipment and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910345906.XA CN110113259B (en) 2019-04-26 2019-04-26 Path state notification method, path switching method, forwarding equipment and system

Publications (2)

Publication Number Publication Date
CN110113259A CN110113259A (en) 2019-08-09
CN110113259B true CN110113259B (en) 2021-08-06

Family

ID=67486982

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910345906.XA Active CN110113259B (en) 2019-04-26 2019-04-26 Path state notification method, path switching method, forwarding equipment and system

Country Status (1)

Country Link
CN (1) CN110113259B (en)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117459443A (en) * 2020-02-21 2024-01-26 华为技术有限公司 Method, equipment and system for sending message
CN112003782B (en) * 2020-09-02 2022-05-24 新华三信息安全技术有限公司 Fault processing method, device, network equipment and machine readable storage medium
CN116827855A (en) * 2020-11-23 2023-09-29 华为技术有限公司 Method, device and system for advertising processing capability of network device
CN113726650B (en) * 2021-07-19 2022-11-18 新华三信息安全技术有限公司 SBFD detection method and network equipment
CN113794632B (en) * 2021-08-31 2023-04-07 新华三信息安全技术有限公司 Network protection method and device
CN114448865B (en) * 2021-12-23 2024-01-02 东莞市李群自动化技术有限公司 Service message processing method, system, equipment and storage medium
CN115037677A (en) * 2022-04-02 2022-09-09 烽火通信科技股份有限公司 Method and device for protecting frr scene
WO2023197644A1 (en) * 2022-04-15 2023-10-19 华为技术有限公司 Cross-segmented network fault detection method, and communication system and related apparatus

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101635656B (en) * 2008-07-26 2013-06-05 华为技术有限公司 Fault detection method in layered ordered address packet network, system and equipment
WO2012106915A1 (en) * 2011-07-22 2012-08-16 华为技术有限公司 Failure notification method, detection apparatus, forwarding apparatus, system and data structure
CN103647710A (en) * 2013-11-01 2014-03-19 华为技术有限公司 Path configuration method and device
CN105337860B (en) * 2014-06-23 2018-10-30 华为技术有限公司 A kind of the determination method, apparatus and system of data packet transmission path
CN105515970B (en) * 2015-12-16 2019-09-03 北京华为数字技术有限公司 A kind of method and apparatus being used for transmission message
CN105704021B (en) * 2016-01-22 2019-04-12 中国人民解放军国防科学技术大学 A kind of heavy route method based on elastic label
CN107979499A (en) * 2018-01-26 2018-05-01 福州大学 Network multipoint fault restoration methods based on stateful datum plane

Also Published As

Publication number Publication date
CN110113259A (en) 2019-08-09

Similar Documents

Publication Publication Date Title
CN110113259B (en) Path state notification method, path switching method, forwarding equipment and system
JP7152533B2 (en) Method, apparatus, and system for handling transmission path failures
US8004967B2 (en) Ring network routing method and ring network node
US8908676B2 (en) Automatically detecting best paths from shadow route reflectors
CN104168193B (en) A kind of method and routing device of Virtual Router Redundancy Protocol fault detect
US7936667B2 (en) Building backup tunnels for fast reroute in communications networks
US7864666B2 (en) Communication control apparatus, method and program thereof
CN110730125B (en) Message forwarding method and device, dual-active system and communication equipment
CN110798403B (en) Communication method, communication device and communication system
CN108768796B (en) Link fault detection method and device
US20220166706A1 (en) Method and Apparatus for Processing Link State Information
CN110113260B (en) Forwarding table updating method and device
CA3104756C (en) Loop avoidance communications method, device, and system
US11818038B2 (en) Initiator-based data-plane validation for segment routed, multiprotocol label switched (MPLS) networks
CN102957573A (en) Path detection realizing method and node
CN113615132B (en) Fast flood Hong Tapu protection
CN111224870B (en) Fault repairing method, equipment and storage medium in SR-MPLS Anycast scene
CN111629386A (en) Communication method, system and equipment
CN110611620B (en) Link updating method and device
CN111385195B (en) Information processing method, device and storage medium
CN108600075B (en) Fault processing method and device
JP6490167B2 (en) COMMUNICATION DEVICE, COMMUNICATION METHOD, COMPUTER PROGRAM, AND COMMUNICATION SYSTEM
CN113037636A (en) Router link updating method, router and storage medium
CN113872843B (en) Route generation method, route processing method and device
CN111917637B (en) Data message sending method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant