A method for protecting routing and network equipment
The method and network device address slow convergence in SRv6 networks by pre-calculating backup paths for FRR, ensuring rapid route protection and recovery in SRv6 networks with equal-cost links.
Patent Information
- Application Number
- CN202210588065.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-27
- Publication Date
- 2024-12-31
- Estimated Expiration
- 2042-05-27
AI Technical Summary
In SRv6-TE Policy tunnels, when the tail node fails, packet forwarding fails due to slow convergence of equal-cost links, preventing timely FRR (Fast Reroute) activation.
A method and network device that receive END.MSID from tail nodes, establish mapping relationships, perform FRR calculations, and store backup paths (END.M) in memory, enabling immediate FRR switching upon link disconnection, using timers to manage convergence and ensure rapid protection.
Enables rapid FRR link switching and protects routes by pre-calculating backup paths, reducing convergence time and ensuring reliable traffic recovery in SRv6 networks with equal-cost links.
Smart Images

Figure CN115037678B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of communication technology, and in particular to a method and network device for protecting routing. Background Art
[0002] SRv6 (Segment Routing IPv6, segment routing based on IPv6 forwarding plane), namely SR (Segment Routing) + IPv6, is a new generation of IP bearer protocol. It adopts the existing IPv6 forwarding technology and realizes network programmability through flexible IPv6 extension headers.
[0003] SRv6 simplifies network protocol types, has good scalability and programmability, can meet the diverse needs of more new businesses, provides high reliability, and has good application prospects in cloud businesses.
[0004] In an MPLS L3VPN over SRv6 network, when the public network tunnel is an SRv6-TE Policy tunnel, if the tail node of the SRv6-TE Policy fails, packet forwarding fails. Summary of the invention
[0005] The embodiments of the present disclosure provide a method for protecting routing and a network device, through which the routing protection can be achieved.
[0006] The present disclosure provides a method for protecting routing, the method comprising:
[0007] receiving a first END.MSID sent by the tail node through each equivalent link, and establishing a mapping relationship with each tail node according to the first END.MSID;
[0008] Perform FRR calculation according to the LOCATOR information of the tail node that sends the first END.M SID to obtain a calculation result;
[0009] When the equivalent link of the tail node monitored according to the mapping relationship is disconnected, the FRR link switching is performed according to the calculation result.
[0010] The receiving of the first END.MSID sent by the tail node through each equivalent link and establishing a mapping relationship between the first END.MSID and each tail node include:
[0011] Using the first END.M SID as an index, obtaining node information, LOCATOR information, and link information of each tail node that sends the first END.M SID;
[0012] A vector is constructed using the node information, LOCATOR information, and link information, and a mapping relationship between the first END.MSID and each tail node is established according to the vector.
[0013] The performing of FRR calculation according to the LOCATOR information of the tail node that sends the first END.M SID to obtain the calculation result includes:
[0014] Perform FRR calculation on the LOCATOR information to obtain a calculation result, wherein the calculation result includes that the next hop is END.M;
[0015] Save the END.M.
[0016] When the equivalent link of the tail node monitored according to the mapping relationship is disconnected, the FRR link switching is performed according to the calculation result, including: setting an FRR waiting time, wherein the FRR waiting time is started when the first equivalent link reaching the tail node is disconnected;
[0017] If the FRR waiting time has not exceeded and the number of disconnected links in the equivalent links reaching the tail node reaches a preset value, FRR link switching is performed according to the calculation result.
[0018] Wherein, before the FRR waiting time times out, the route corresponding to the LOCATOR of the tail node is not converged.
[0019] Through the above methods, FRR switching can be implemented on the tail node with equal-cost links to protect the route.
[0020] The embodiment of the present disclosure further provides a network device, the network device being connected to one or more tail nodes, the network device comprising:
[0021] A receiving module, configured to receive a first END.M SID sent by an end node through each equivalent link, and establish a mapping relationship with each end node according to the first END.M SID;
[0022] A calculation module, used to perform FRR calculation according to the LOCATOR information of the tail node that sends the first END.M SID, and obtain a calculation result;
[0023] The switching module is used to perform FRR link switching according to the calculation result when the equivalent link monitored to the tail node according to the mapping relationship is disconnected.
[0024] The receiving module is specifically used to obtain the node information, LOCATOR information, and link information of each tail node that sends the first END.MSID by taking the first END.MSID as an index;
[0025] A vector is constructed using the node information, LOCATOR information, and link information, and a mapping relationship between the first END.MSID and each tail node is established according to the vector.
[0026] The calculation module is specifically used to perform FRR calculation on the LOCATOR information to obtain a calculation result, wherein the calculation result includes that the next hop is END.M;
[0027] Save the END.M.
[0028] Wherein, the network device further includes: a timer, the timer is used to correspond to the FRR waiting time;
[0029] The switching module is specifically configured to perform FRR link switching according to the calculation result if the FRR waiting time has not exceeded and the number of disconnected links in the equivalent links reaching the tail node reaches a preset value.
[0030] Wherein, before the FRR waiting time times out, the route corresponding to the LOCATOR of the tail node is not converged. BRIEF DESCRIPTION OF THE DRAWINGS
[0031] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the specification and, together with the description, serve to explain the principles of the specification.
[0032] Figure 1 A schematic diagram of a network architecture provided for an embodiment of the present disclosure.
[0033] Figure 2 A flowchart of a method for protecting routing provided in an embodiment of the present disclosure. DETAILED DESCRIPTION
[0034] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The implementations described in the following exemplary embodiments do not represent all implementations consistent with this specification. Instead, they are merely examples of devices and methods consistent with some aspects of this specification as detailed in the appended claims.
[0035] The terms used in this specification are for the purpose of describing specific embodiments only and are not intended to limit this specification. The singular forms "a", "the" and "the" used in this specification and the appended claims are also intended to include plural forms unless the context clearly indicates otherwise. It should also be understood that the term "and / or" used herein refers to and includes any or all possible combinations of one or more associated listed items.
[0036] It should be understood that although the terms first, second, third, etc. may be used in this specification to describe various information, this information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other. For example, without departing from the scope of this specification, the first information may also be referred to as the second information, and similarly, the second information may also be referred to as the first information. Depending on the context, the word "if" as used herein may be interpreted as "at the time of" or "when" or "in response to determining".
[0037] FRR (Fast Reroute) aims to provide backup protection for important nodes or links when links or nodes in the network fail, implement fast rerouting, reduce the impact of link or node failure on traffic, and enable rapid recovery of traffic.
[0038] like Figure 1 As shown in the figure, PE4 and PE3 learn private network routes from CE2 at the same time and generate VPN routes locally. PE4 sends End.M SID to P1. At the same time, PE3 and PE4 also establish VPNv4 neighbors and learn each other's VPNv4 routes. After comparison, PE4 establishes a mapping table between SRv6 SID and VPN instance.
[0039] If a node failure occurs in PE3, PE4 performs FRR switching, and P1 senses that the next hop PE3 is unreachable, so it switches to the FRR path. P1 encapsulates the message with an IPv6 message header, whose destination address is End.M SID, and then forwards it to PE4.
[0040] PE 4 resolves the End.M SID, queries the Local SID table, and searches for the mirroring entry of END.M, thereby finding the VPN SID corresponding to PE4. Based on the remote SRv6 SID found, it queries the mapping table of the remote SRv6 SID and VPN instance to find the corresponding VPN instance. Then, PE 4 queries the routing table of the VPN instance and forwards the traffic to CE 2.
[0041] However, in the current situation, when there are equal-cost links between P1 and PE3, slow convergence will occur. Assuming that there are two links A and B between P1 and PE3, and the PE3 node fails, it is possible that link A and link B will go down one after another (that is, P1 cannot sense the failure of link A and link B at the same time). After P1 finds that link A is down, it will perform routing convergence because it has not received the message that link B is down, and cannot enter the FRR process, resulting in slow convergence.
[0042] In order to solve the problem that the existing equal-cost links cause the routing to converge slowly and the FRR process cannot be entered in time, the embodiment of the present disclosure provides a method for protecting routing, such as Figure 2 As shown, the method includes:
[0043] S201 receives a first END.MSID sent by an egress node through each equivalent link, and establishes a mapping relationship with each egress node according to the first END.MSID;
[0044] S202 performs FRR calculation according to the LOCATOR information of the tail node that sends the first END.MSID to obtain a calculation result;
[0045] S203: When the equivalent link of the tail node monitored according to the mapping relationship is disconnected, perform FRR link switching according to the calculation result.
[0046] In this embodiment, the method can be applied to a target node supporting the FRR function, which may be a head node or an intermediate node in the network. Specifically, the target node may be a routing device (such as a router, a switch), a transmission node, etc.
[0047] In this embodiment, the target node may receive the END.MSID sent by the tail node (it should be noted that the tail node may be the next hop or multiple next hop nodes relative to the target node, not just the tail node in the network).
[0048] In a large-scale network, a target node may receive END.M SIDs sent by multiple tail nodes, and the END.M SIDs sent by different tail nodes may be different. In this embodiment, the first END.M SID refers to the same END.M SID.
[0049] In this embodiment, the tail node can send the first END.MSID to the target node through the equivalent link, such as Figure 1 As shown, assuming that P1 is the target node, there are two equivalent links, link A and link B, between PE3 and P1.
[0050] P1 receives the first END.M SID sent by PE3 through link A and link B. At the same time, P1 receives the first END.M SID sent by PE4, where M represents the mapping address of the protection device. In this embodiment, PE4 and PE3 are each other's protection devices.
[0051] In step S201, after P1 receives the first END.M SID sent by each tail node, it records the first END.M SID received from those links, performs routing calculation and statistics, obtains a vector constructed by node information, LOCATOR information, and link information, and establishes a mapping relationship based on the vector. The mapping relationship is shown in the following example:
[0052] PE3-LOCATOR, END.M, Link A, Link B.
[0053] In step S202, after receiving the first END.M SID sent by PE3, the P1 device performs FRR calculation according to the LOCATOR information of PE3 to obtain the calculation result, and uses END.M (in this embodiment, the END.M is the mapping address of PE4, that is, the END.M here is the mapping address of the FRR protection device of PE3) as the backup next hop (that is, when the current link fails, the backup next hop is enabled).
[0054] Since PE3 has equivalent links to Link A and Link B, FRR cannot be enabled temporarily. Therefore, END.M can be saved in the memory. When FRR is enabled for PE3, END.M can be directly called from the memory, thereby avoiding FRR calculation after the link is disconnected and saving FRR link switching time.
[0055] In this embodiment, P1 may monitor the operation status of the equivalent link to the tail node according to the mapping relationship.
[0056] Meanwhile, a timer (ie, FRR waiting time) may be set in P1, and the timer may be started when P1 monitors that the first link among the equal-cost links is disconnected.
[0057] In one example, when P1 monitors that link A of PE3 is disconnected, a timer is started. If the timer times out and monitors that link B is disconnected, it means that PE3 and P1 communicate through link B and no FRR is required.
[0058] In another example, when P1 monitors that link A of PE3 is disconnected, the timer is started. Before the timer times out, link B is monitored to be disconnected. At this time, the routing table corresponding to LOCATOR can be assigned the FRR next hop END.M through software to implement FRR protection to PE3. It should be noted that this embodiment lists an example of implementing FRR. In other examples, there can be more than two equivalent links, and a preset value can be set. When P1 monitors that the number of equivalent link disconnections reaches the preset value, FRR protection can be executed.
[0059] It can be seen from the above content that in this embodiment, the target node can perform FRR calculation in advance and save the FRR next hop address in the memory. When the equivalent link is monitored to be disconnected and the preset conditions are met (the number of disconnections reaches the preset value, or all equivalent links are disconnected), the routing table corresponding to LOCATOR can be assigned the FRR next hop END.M through software (hardware) to achieve FRR protection to PE3.
[0060] In another embodiment, when P1 monitors that a certain equivalent link of PE3 is disconnected, the timer is started. Before the timer expires, the route corresponding to the LOCATOR of PE3 can be controlled not to be converged. Because the timer is generally not very long, if P1 performs route convergence calculation when it monitors that a certain equivalent link of PE3 is disconnected, and the disconnection of the equivalent link of PE3 is caused by a PE3 failure, it is very likely that after the convergence calculation is completed, other equivalent links between P1 and PE3 are also disconnected. At this time, the result of the above-mentioned route convergence calculation may be useless. Therefore, in order to save route convergence resources, before the timer expires, the route corresponding to the LOCATOR of PE3 can be controlled not to be converged.
[0061] In combination with the above-mentioned method embodiments, the embodiments of the present disclosure also provide a network device, which can be a routing device (such as a router, a switch), a transmission node, etc. The network device is connected to one or more tail nodes, and the network device includes: a receiving module, a computing module, and a switching module.
[0062] The receiving module is used to receive the first END.M SID sent by the tail node through each equivalent link, and establish a mapping relationship with each tail node according to the first END.M SID;
[0063] A calculation module, used to perform FRR calculation according to the LOCATOR information of the tail node that sends the first END.M SID, and obtain a calculation result;
[0064] The switching module is used to perform FRR link switching according to the calculation result when the equivalent link monitored to the tail node according to the mapping relationship is disconnected.
[0065] In this embodiment, the receiving module can be implemented by an interface board of the network device, and the computing module and the switching module can be implemented by modules such as the CPU and GPU of the network device.
[0066] In this embodiment, the receiving module is specifically used to obtain the node information, LOCATOR information, and link information of each tail node that sends the first END.M SID by taking the first END.M SID as an index;
[0067] A vector is constructed using the node information, LOCATOR information, and link information, and a mapping relationship between the first END.MSID and each tail node is established according to the vector.
[0068] The calculation module is specifically used to perform FRR calculation on the LOCATOR information to obtain a calculation result, wherein the calculation result includes that the next hop is END.M; and save the END.M.
[0069] When saving END.M, END.M may be saved in the RAM or ROM of the network device.
[0070] In another embodiment, the network device further includes a timer, which can be implemented by software or hardware, and the timer corresponds to the FRR waiting time.
[0071] The switching module is specifically configured to perform FRR link switching according to the calculation result if the FRR waiting time has not exceeded and the number of disconnected links in the equivalent links reaching the tail node reaches a preset value.
[0072] Before the FRR waiting time times out, the route corresponding to the LOCATOR of the tail node is not converged.
[0073] Since the effects and problems achieved and solved by the network device in this embodiment through the use of various modules are the same as those in the above method embodiment, they will not be described in detail here.
[0074] The above is a description of a specific embodiment of the specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims can be performed in an order different from that in the embodiments and still achieve the desired results. In addition, the processes depicted in the drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0075] Those skilled in the art will readily appreciate other embodiments of the specification after considering the specification and practicing the invention claimed herein. The specification is intended to cover any variations, uses or adaptations of the specification that follow the general principles of the specification and include common knowledge or customary techniques in the art that are not claimed in the specification. The specification and examples are to be considered exemplary only, and the true scope and spirit of the specification are indicated by the following claims.
[0076] It should be understood that the present description is not limited to the precise structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present description is limited only by the appended claims.
[0077] The above description is only a preferred embodiment of this specification and is not intended to limit this specification. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of this specification should be included in the scope of protection of this specification.
Claims
1. A method for protecting routing, characterized in that: The method comprises: receiving a first END.MSID sent by the tail node through each equivalent link, and establishing a mapping relationship with each tail node according to the first END.MSID; Perform FRR calculation according to the LOCATOR information of the tail node that sends the first END.M SID to obtain a calculation result; When the equivalent link of the tail node monitored according to the mapping relationship is disconnected, performing FRR link switching according to the calculation result; When the equivalent link of the tail node monitored according to the mapping relationship is disconnected, performing FRR link switching according to the calculation result includes: setting an FRR waiting time, wherein the FRR waiting time is started when the first equivalent link reaching the tail node is disconnected; If the FRR waiting time has not exceeded and the number of disconnected links in the equivalent links reaching the tail node reaches a preset value, FRR link switching is performed according to the calculation result.
2. The method according to claim 1, characterized in that The receiving the first END.M SID sent by the tail node through each equivalent link, and establishing a mapping relationship between the first END.M SID and each tail node, includes: Using the first END.M SID as an index, obtaining node information, LOCATOR information, and link information of each tail node that sends the first END.M SID; A vector is constructed using the node information, LOCATOR information, and link information, and a mapping relationship between the first END.MSID and each tail node is established according to the vector.
3. The method according to claim 1, characterized in that The performing FRR calculation according to the LOCATOR information of the tail node sending the first END.M SID to obtain the calculation result includes: Perform FRR calculation on the LOCATOR information to obtain a calculation result, wherein the calculation result includes that the next hop is END.M; Save the END.M.
4. The method according to claim 1, characterized in that: Before the FRR waiting time times out, the route corresponding to the LOCATOR of the tail node is not converged.
5. A network device, characterized in that: The network device is connected to one or more tail nodes, and the network device includes: A receiving module, configured to receive a first END.M SID sent by an end node through each equivalent link, and establish a mapping relationship with each end node according to the first END.M SID; A calculation module, used to perform FRR calculation according to the LOCATOR information of the tail node that sends the first END.M SID, and obtain a calculation result; A switching module, configured to perform FRR link switching according to the calculation result when an equivalent link monitored to the tail node according to the mapping relationship is disconnected; Wherein, the network device further includes: a timer, the timer is used to correspond to the FRR waiting time; The switching module is specifically configured to perform FRR link switching according to the calculation result if the FRR waiting time has not exceeded and the number of disconnected links in the equivalent links reaching the tail node reaches a preset value.
6. The network device according to claim 5, characterized in that: The receiving module is specifically used to obtain the node information, LOCATOR information, and link information of each tail node that sends the first END.M SID by taking the first END.M SID as an index; A vector is constructed using the node information, LOCATOR information, and link information, and a mapping relationship between the first END.MSID and each tail node is established according to the vector.
7. The network device according to claim 5, characterized in that: The calculation module is specifically used to perform FRR calculation on the LOCATOR information to obtain a calculation result, wherein the calculation result includes that the next hop is END.M; Save the END.M.
8. The network device according to claim 5, characterized in that: Before the FRR waiting time times out, the route corresponding to the LOCATOR of the tail node is not converged.
