Backup path generation method, apparatus, device, storage medium, and program product

By generating equivalent link groups and index tables, the FRR backup path generation method is optimized, solving the problem of insufficient backup path bandwidth and achieving more efficient network traffic forwarding and reduced congestion and packet loss.

CN118827525BActive Publication Date: 2026-01-16CHINA MOBILE COMM LTD RES INST +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410205093.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-02-23
Publication Date
2026-01-16
Estimated Expiration
2044-02-23

AI Technical Summary

Technical Problem

Insufficient bandwidth in the backup path provided by FRR leads to service congestion and packet loss. Existing technologies cannot effectively utilize the relevant links and bandwidth, resulting in traffic congestion and packet loss.

Method used

By generating equal-cost link groups and an equal-cost link group index table, multiple alternative paths are generated based on the fast rerouting algorithm. The alternative paths are then updated using the equal-cost link group index table to optimize bandwidth utilization.

Benefits of technology

Effectively utilize network links and bandwidth to reduce traffic congestion and packet loss caused by insufficient backup path bandwidth, thereby improving network transmission stability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118827525B_ABST
    Figure CN118827525B_ABST
Patent Text Reader

Abstract

The application discloses a backup path generation method and device, equipment, a storage medium and a program product. Wherein, the network includes a plurality of forwarding devices, the method is applied to the forwarding device, the method comprises: setting one or more constraint condition groups according to a preset target; generating an equivalent link group of the forwarding device in each local direction according to the constraint condition group; generating an equivalent link group index table according to the equivalent link group, and updating the equivalent link group index table according to the state of the equivalent link group; generating a backup path based on a fast rerouting algorithm; updating the backup path according to the equivalent link group index table.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of network transmission, and in particular to a backup path generation method and device, equipment, a storage medium and a program product. BACKGROUND

[0002] Route changes caused by link failure of a bearer network usually result in a large amount of data loss, which has a great impact on services. Therefore, under the premise of ensuring network performance stability, in order to shorten the failure time, a fast traffic protection mechanism can be provided by using a protocol such as FRR (Fast ReRoute). FRR is a network technology that aims to provide backup protection for important nodes or links in the network when the links or nodes fail, and to achieve fast rerouting, thereby reducing the impact on traffic when the links or nodes fail, and enabling traffic to be quickly recovered. However, the backup path provided by FRR has a bandwidth deficiency, which leads to service congestion and packet loss, which is one of the problems that needs to be solved in the field. SUMMARY

[0003] To solve the technical problems in the related art, the embodiments of the present application provide a backup path generation method and device, equipment, a storage medium and a program product.

[0004] To achieve the above-mentioned purposes, the technical solutions of the embodiments of the present application are as follows:

[0005] In a first aspect, the embodiments of the present application provide a backup path generation method for network transmission, wherein a network includes a plurality of forwarding devices, the method is applied to the forwarding devices, and the method includes:

[0006] setting one or more constraint condition groups according to a preset target;

[0007] generating an equivalent link group of the forwarding device in each local direction according to the constraint condition group;

[0008] generating an equivalent link group index table according to the equivalent link group, and updating the equivalent link group index table according to the state of the equivalent link group;

[0009] generating a backup path based on a fast reroute algorithm;

[0010] updating the backup path according to the equivalent link group index table.

[0011] In a second aspect, the embodiments of the present application provide a backup path generation device for network transmission, wherein a network includes a plurality of forwarding devices, the device is applied to the forwarding devices, and the device includes:

[0012] a setting unit configured to set one or more constraint condition groups according to a preset target;

[0013] The first generating unit is configured to generate, according to the constraint condition group, an equivalent link group of the forwarding device in each local direction;

[0014] The second generating unit is configured to generate an equivalent link group index table according to the equivalent link group, and update the equivalent link group index table according to the state of the equivalent link group;

[0015] The third generating unit is configured to generate a backup path based on a fast reroute algorithm;

[0016] The updating unit is configured to update the backup path according to the equivalent link group index table.

[0017] In a third aspect, an embodiment of the present application provides a forwarding device, comprising a processor and a memory for storing a computer program capable of running on the processor;

[0018] When the processor runs the computer program, the processor is configured to perform the steps of the method.

[0019] In a fourth aspect, an embodiment of the present application provides a computer readable storage medium, which stores a computer program, and the computer program is configured to perform the steps of the method when executed by a processor.

[0020] In a fifth aspect, an embodiment of the present application provides a computer program product, comprising a computer program, and the computer program is configured to perform the steps of the method when executed by a processor.

[0021] The backup path generation method, device, equipment, storage medium and program product provided by the embodiment of the present application can generate the equivalent link group of the forwarding device in each local direction based on the preset constraint condition group, and generate the equivalent link group index table, thereby generating multiple equivalent backup paths. In addition, the equivalent link group index table and the backup path are also updated. In this way, on the one hand, the related links and bandwidths can be used as much as possible, and on the other hand, the traffic congestion and packet loss caused by insufficient bandwidth of the backup path can be reduced. BRIEF DESCRIPTION OF DRAWINGS

[0022] Figure 1 A schematic diagram of backup path congestion in related art;

[0023] Figure 2 A flowchart of the backup path generation method for network transmission of an embodiment of the present application Figure 1 ;

[0024] Figure 3 A flowchart of the backup path generation method for network transmission of an embodiment of the present application Figure 2 ;

[0025] Figure 4A schematic diagram of a network for a forwarding device of an embodiment of the present application;

[0026] Figure 5 A flowchart of a method for generating a backup path for network transmission of an embodiment of the present application Figure 3

[0027] Figure 6 A structure diagram of an apparatus for generating a backup path for network transmission of an embodiment of the present application Figure 1

[0028] Figure 7 A structure diagram of an apparatus for generating a backup path for network transmission of an embodiment of the present application Figure 2

[0029] Figure 8 An entity structure block diagram of a forwarding device of an embodiment of the present application. DETAILED DESCRIPTION

[0030] The present application will be further described by examples in conjunction with the accompanying drawings.

[0031] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used in the description herein is for describing particular embodiments only and is not intended to be limiting of the application.

[0032] In order to reduce the situation of a large amount of data loss caused by route change when a bearer network link fails, prevent a great impact on services, a FRR mechanism can be used to achieve fast convergence. By using FRR technology, a backup route can be calculated in advance, and when a network failure occurs, traffic can be quickly switched to a backup path to achieve the purpose of fast convergence. However, the calculation of the backup route by FRR can only generate one backup route, that is, only one backup link can be used. As shown in Figure 1 When network traffic is large, the primary path (forwarding device-node 1-node 2) can improve the actual network bandwidth by using link bundling or high-speed ports and the like to carry related traffic. However, when the primary path fails, the backup path (forwarding device-node 3-node 2) generated by using fast reroute for forwarding can cause congestion and packet loss due to insufficient bandwidth of the backup link, and even affect the normal operation of other services running on the backup path. As shown in Figure 1 The cost of the primary path is 10, and the cost of the backup path is 20, so congestion occurs.

[0033] ​​​Based on this, the embodiments of the present application propose a data query method, in various embodiments of the present application, a generation method and device of fast re-routing are proposed, in the case of ECMP (Equal-Cost Multi-Path routing) existing in a backup path, the relevant link and bandwidth can be used as much as possible, and the traffic congestion and packet loss caused by insufficient bandwidth of the backup path calculated by the fast re-routing technology are optimized.

[0034] The embodiments of the present application provide a generation method of a backup path of network transmission, a network includes a plurality of forwarding devices, the method is applied to the forwarding device, as shown in Figure 2 The method comprises the following steps.

[0035] Step 101, setting one or more constraint condition groups according to a preset target.

[0036] Here, the preset target can be determined according to the demand of data transmission in the network, and the constraint condition in the constraint condition group is used to limit the transmission requirement of the backup path. The constraint condition group can be set to one or more, and when generating the backup path, the appropriate constraint condition group can be selected from the constraint condition group according to the actual capacity of the current forwarding device or the type of transmission data.

[0037] In an embodiment, each constraint condition group is for one or more specific processes of an IGP routing protocol, and is set according to actual business requirements. Different processes can set the same or different constraint condition groups.

[0038] In some embodiments, the constraint condition group comprises one or more of the following: delay requirement, link bandwidth requirement, packet loss rate requirement, configuration requirement; or the constraint condition group is empty.

[0039] For a certain routing protocol, one or more constraint condition groups can be generated. When there is no special requirement, the constraint condition group can be empty. Exemplarily, the plurality of constraint condition groups include a constraint condition group that limits only one parameter such as delay requirement or link bandwidth requirement, also include a constraint condition group that limits the above multiple parameters, and also include a constraint condition group without any limit, that is, the constraint condition group is empty.

[0040] It can be understood that when the empty constraint condition group is selected to be used, there is actually no constraint condition for the generated backup path.

[0041] Step 102, generating an equal link group of the forwarding device in each local direction according to the constraint condition group.

[0042] The forwarding device can be connected with a plurality of other forwarding devices or terminal devices and perform data transceiving, that is, each forwarding device can include a plurality of different directions. The direction refers to Bureau Direction, which is the direction of signaling, such as signaling to a certain office (each office corresponds to a DPC (Destination Point Code, Destination Point Code)), which can be referred to as the direction of the office.

[0043] The equivalent link group refers to the cost of transmission, that is, the link cost is the same. The link cost is related to parameters such as bandwidth. The forwarding device can have a plurality of equivalent link groups in each direction, and can select a backup path in the equivalent link group according to the process requirement when forwarding traffic. The backup path obtained in this way can be more than one, so that the bandwidth can be effectively utilized, and traffic congestion and packet loss caused by insufficient bandwidth of the backup path can be reduced.

[0044] Specifically, in some embodiments, in step 102, the equivalent link groups of the forwarding device in each direction are generated according to the constraint condition groups, including:

[0045] According to the target process of the equivalent link group to be generated, a target constraint condition group is selected from one or more constraint condition groups; and the equivalent link groups of the forwarding device in each direction are generated according to the target constraint condition group.

[0046] Since the different constraint condition groups are for different processes, when generating the equivalent link groups, a target constraint condition group needs to be selected according to the process, that is, the target process of the equivalent link group to be generated, that is, the constraint condition group that meets the process requirement.

[0047] In some embodiments, the equivalent link groups of the forwarding device in each direction are generated according to the target constraint condition group, including: determining all next-hop direction of the forwarding device; and generating an equivalent link group for each next-hop direction according to the target constraint condition group.

[0048] It can be understood that generating an equivalent link group for each next-hop direction can generate one or more backup paths for each next-hop direction. In this way, when forwarding traffic, a plurality of backup paths can be selected for the next hop for forwarding, thereby reducing the occurrence of congestion.

[0049] In the embodiments of the present disclosure, the equivalent link groups generated above need to meet the following target conditions:

[0050] First, the number of links in the equivalent link group is less than or equal to a preset number threshold;

[0051] Here, the quantity threshold is the maximum number of links set for a certain local direction corresponding to a process in the equivalent link group. The maximum number of links corresponding to different local directions can be the same or different. In actual application, it can be set according to actual needs.

[0052] Second, the links in the equivalent link group meet the principle of minimum transmission cost equivalence;

[0053] That is, the link costs in the equivalent link group are equivalent and are the minimum, which can reduce the generation of unnecessary links and effectively save link costs, and will not cause excessive transmission cost because of selecting a backup path.

[0054] Third, the interface state of the link in the equivalent link group is in an available state; that is, the interface state is “UP”.

[0055] Fourth, the IGP (Interior Gateway Protocol) neighbor of the interface in each link in the equivalent link group is successfully established and in a normal state;

[0056] In addition, if the forwarding device is an MPLS (Multi-Protocol Label Switching) enabled device, in addition to the above four points, it also needs to meet:

[0057] Fifth, the MPLS neighbor of the interface in each link in the equivalent link group is successfully established and in a normal state.

[0058] If the forwarding device is an SRv6 (Segment Routing over IPv6) enabled device, in addition to the above four points, it also needs to meet:

[0059] Sixth, the SRv6 neighbor of the interface in each link in the equivalent link group is successfully established and in a normal state and the SID (Segment Identification) is normally allocated.

[0060] In some embodiments, the above generating an equivalent link group for each next hop local direction according to the target constraint condition group comprises:

[0061] Determining all physical interfaces of each next hop local direction;

[0062] For each physical interface, sequentially determining a logical interface or a logical sub-interface that meets the target condition to obtain an interface set;

[0063] Determining the minimum value of the link transmission cost of each interface in the interface set;

[0064] If the number of links in the current equivalent link group is less than or equal to the number threshold, it is determined whether the link transmission overhead of a next interface in the subset of interfaces is equal to the minimum value;

[0065] If the link transmission overhead of the interface is equal to the minimum value, it is determined whether the interface meets the target constraint condition;

[0066] If the interface meets the target constraint condition, the link corresponding to the interface is added to the equivalent link group;

[0067] If the number of links in the current equivalent link group is greater than the number threshold, the determination of whether the link transmission overhead of a next interface in the set of interfaces is equal to the minimum value is stopped.

[0068] Here, all neighbors of the device can be discovered through the LLDP (Link Layer Discovery Protocol), and the direction of all neighbors of the device can be determined through the names of the neighbors.

[0069] The physical interfaces reaching the direction of all next hops are found, all physical interfaces of each next hop direction can be found through the LLDP protocol. Then the relevant physical interfaces of the physical interfaces can be determined one by one, as well as the bundled interfaces formed by the physical interfaces, and it is determined whether the logical interfaces or logical sub-interfaces of each physical interface can be added to the equivalent link group. Then it is determined whether the link overhead of each interface meets the equivalent minimum principle, whether it meets the target constraint condition, and whether the equivalent link group has reached the maximum, so as to determine whether the corresponding interface is added to the equivalent link group.

[0070] In step 103, an equivalent link group index table is generated according to the equivalent link group, and the equivalent link group index table is updated according to the state of the equivalent link group.

[0071] It can be understood that the state of each interface in the equivalent link group may change at any time, for example, the interface state changes from available to unavailable (state "UP" to state "DOWN"), the interface state is abnormal, the link quality deteriorates, or other configuration changes occur, etc. All of these will cause the interface to no longer meet the requirements of the equivalent link group, and thus need to be deleted from the equivalent link group. Therefore, the equivalent link group index table can be used to realize the state update of the equivalent link group, such as adding and deleting, so as to facilitate the generation of backup paths that meet the transmission conditions.

[0072] It should be noted that the updating of the equivalent link group index table can be real-time, for example, when the interface state in the equivalent link group is updated, the equivalent link group index table is updated synchronously. It can also be based on a certain frequency to periodically detect whether the interface state in the equivalent link group changes, and update the equivalent link group index table based on the changed interface state.

[0073] In some embodiments, in the step 103, the equivalent link group index table is generated according to the equivalent link group, and the equivalent link group index table is updated according to the state of the equivalent link group, comprising:

[0074] determining the interface index of each interface in the equivalent link group and the state value of each interface;

[0075] updating the state value of each interface according to the state of each interface;

[0076] updating the equivalent link group index table according to the state value of each interface.

[0077] That is, whether each interface meets the requirements of the equivalent link group can be determined by the state value of each interface, and the equivalent link group index table is updated. The state value of each interface is updated according to the state, so that the interface index in the equivalent link group can be updated in time. Exemplarily, the updating mode can include deleting the interface that does not meet the requirements of the equivalent link group or adding a new interface that meets the requirements in the equivalent link group index table, or the equivalent link group index table can contain the state value item of the interface, and updating the equivalent link group index table can update the state value item in the corresponding index table according to the state value of the interface.

[0078] Here, the state value of the interface can be different numerical values representing different states of the interface. For example, if the interface is in a normal available state, the state value of the interface can be 1; if the interface is in an unavailable state, the state value of the interface can be 0. In addition, if the interface has other states, other numerical values can also be used to represent the state value.

[0079] In some embodiments, the updating of the equivalent link group index table according to the state value of each interface comprises: if the state value of the current interface is a first numerical value indicating that the interface is available, determining the state value of the next interface;

[0080] if the state value of the current interface is a second numerical value indicating that the interface is unavailable, deleting the current interface from the equivalent link group index table;

[0081] if the state value of the current interface is a numerical value other than the first numerical value and the second numerical value, determining whether the current interface meets the constraint condition group;

[0082] if the current interface does not meet the constraint condition group, deleting the current interface from the equivalent link group index table;

[0083] If the current interface meets the constraint condition set, the state value of the next interface is determined.

[0084] Here, the state value of each interface in the equivalent link group can be determined in turn in a polling manner, and the equivalent link group index table is updated accordingly according to the state value.

[0085] The first value is a state value indicating that the interface is available. Exemplarily, the value can be 1. If the state value of the currently determined interface is the first value, it means that the interface meets the requirements of the equivalent link group and is an available interface. Therefore, at this time, there is no need to update the information of the interface, and the state value of the next interface is determined.

[0086] If the state value of the currently determined interface is the second value, exemplarily, the value is 0, the current interface is not available, that is, it does not meet the requirements of the equivalent link group, and needs to be deleted from the equivalent link group. Therefore, at this time, the current interface in the equivalent link group index table can be deleted.

[0087] When the state value of the current interface is other values, it means that the state of the interface has changed from the available state, but it is not completely unavailable. At this time, it is necessary to determine whether the interface meets the requirements of the equivalent link group, so it is necessary to re-determine whether the current interface meets the constraint condition set. If it meets, it means that the interface can still be used as an interface in the equivalent link group, at this time, there is no need to update, and the next interface is determined. If the interface does not meet the constraint condition set, it means that the interface cannot continue to be used as an interface in the equivalent link group, and therefore needs to be deleted.

[0088] In some embodiments, the other values include a third value for indicating that the configuration of the interface is changed, and a fourth value for indicating that the quality of the link corresponding to the interface is deteriorated.

[0089] Exemplarily, the third value can be 2, and the fourth value can be 3. In addition, the above-mentioned state values can also be represented by two-bit binary numbers, for example, the first value is 01, the second value is 00, the third value is 10, and the fourth value is 11. The values here can also be other values, which are not limited by the embodiments of the present application.

[0090] In some embodiments, the above-mentioned updating the state value of each interface according to the state of each interface includes: if the state of the interface or the interface protocol in the equivalent link group index table changes, adjusting the state value of the interface to the second value;

[0091] If the configuration of the interface in the equivalent link group index table is changed, the state value of the interface is adjusted to the third value;

[0092] If the link quality of the interface in the equivalent link group index table deteriorates, the state value of the interface is adjusted to the fourth value.

[0093] Here, a way of updating the interface state value is provided, that is, if the interface state changes or the interface protocol changes, it means that the interface is no longer applicable to the current process, so the state of the interface can be directly adjusted to the second value described above, indicating that the interface is unavailable, so that the device can delete the interface from the equivalent link group and the equivalent link group index table.

[0094] In addition, for the case of interface configuration change or interface link quality deterioration, whether the interface can still be used as an interface in the equivalent link group needs to be further confirmed, so it is updated to the third value and the fourth value respectively, so as to further determine whether it meets the constraint condition group subsequently.

[0095] Step 104, generating a backup path based on a fast reroute algorithm.

[0096] Here, the fast reroute algorithm (FRR, Fast Reroute) is a network fault recovery technology designed to provide fast and transparent path switching to reduce network interruption time and packet loss. When a link or node in the network fails, fast reroute can quickly switch traffic from the failed path to the backup path to ensure network connectivity and reliability.

[0097] Through the fast reroute algorithm, a backup path can be pre-calculated and maintained in the network, and when the main path fails, the traffic can be immediately switched to the backup path. The backup path can be a completely different path or a partially overlapping path with the main path. The calculation and maintenance of the backup path can be done through various routing protocols and algorithms.

[0098] Here, the backup path generated by the fast reroute algorithm described above can be any backup path generated by a conventional algorithm, and then further updated to a path in the equivalent link group through subsequent steps.

[0099] In some embodiments, the step 104 of generating a backup path based on a fast reroute algorithm includes:

[0100] If the network transmission protocol is IGP, the backup path of the route in the IGP process is generated based on the IGP fast reroute algorithm;

[0101] If the network transmission protocol is MPLS, the backup path of the route in the MPLS process is generated based on the remote loop free alternate fast reroute (RLFA FRR) algorithm;

[0102] If the network transmission protocol is SRv6, a backup path of the SRv6 process route is generated based on a Ti-LFA FRR (Topology Independent Loop Free Alternate Fast Reroute).

[0103] In addition, if the network transmission protocol is another protocol, a corresponding backup path can also be generated by using a fast reroute algorithm matched with the other protocol.

[0104] Step 105: updating the backup path according to the equivalent link group index table.

[0105] Here, updating the backup path is for updating the equivalent links in the equivalent link group index table to the backup path on the one hand, so that the backup path is expanded; on the other hand, it is for synchronously updating the backup path when the equivalent link group index table is updated, so that the backup path is in a usable state.

[0106] Since the above-mentioned equivalent link index table is updated based on the interface state, the generated backup path also needs to be updated according to the equivalent link table, so that the backup path is maintained in a usable state, preventing the backup path from being unavailable due to the change of the interface state.

[0107] In some embodiments, in step 105, updating the backup path according to the equivalent link group index table includes:

[0108] If the out-interface in the backup path belongs to the interface indicated by the interface index in the equivalent link group index table, the index value of the out-interface in the backup path is updated to the corresponding index value in the equivalent link group index table, so that the out-interface is all available interfaces in the equivalent link group index table.

[0109] Load balancing of the equivalent route is performed on all available interfaces in the equivalent link group index table.

[0110] If the equivalent link group index table is updated, the index value of the out-interface in the backup path is updated.

[0111] The backup path generated in step 104 can be generated by using a conventional fast reroute algorithm, and then it is judged by the interface index in the equivalent link group index table whether the out-interface in the backup path has equivalent other interfaces. If the out-interface in the backup path belongs to the interface maintained in the equivalent link group index table, it means that the interface has equivalent interfaces, and therefore the out-interface in the backup path can be replaced by all equivalent interfaces in the equivalent link group index table, so that the backup path is expanded to contain multiple equivalent paths.

[0112] It can be understood that the index value of the out interface of the backup path is replaced by the corresponding index value in the equivalent link group index table, so as to realize the replacement of the interface.

[0113] Then, the load balancing of each interface is performed, so as to effectively utilize the bandwidth and reduce the occurrence of congestion when the traffic is forwarded.

[0114] In addition, when the equivalent link group index table is updated, the backup path can be updated correspondingly, so that the backup path is maintained in an available state.

[0115] In some embodiments, as shown in Figure 3 The method further includes:

[0116] Step 201, setting a timer with a timing duration of a first duration; wherein the timer starts timing after the equivalent link group index table is generated;

[0117] Step 202, when the timer timing ends, generating the equivalent link groups of each local direction of the forwarding device according to the constraint condition group again;

[0118] Step 203, if the number of available interfaces in the equivalent link group index table is less than a preset number threshold, modifying the timing duration of the timer to a second duration; wherein the second duration is less than the first duration.

[0119] Here, the duration of the timer can be understood as the validity period of the generated equivalent link group index table and the equivalent link group. When the timer timing ends, the equivalent link group index table is invalid, and the equivalent link group needs to be generated again, and the corresponding equivalent link group index table needs to be generated again.

[0120] Since the states or configurations of the interfaces in the equivalent link group may change at any time, when an equivalent link group is generated for a period of time, there will be many interfaces that need to be updated, resulting in more complex updating of the equivalent link group and the equivalent link group index table. Therefore, the validity period of the equivalent link group and the equivalent link group index table can be set by timing, so as to facilitate the maintenance of the equivalent link group and the equivalent link group index table.

[0121] For the case where the number of equivalent links in the equivalent link group reaches a set number threshold, the timing duration can be set to a first duration. However, if the number of equivalent links does not reach the number threshold, it means that the number of interfaces in the equivalent link group is smaller, and the situation that most of the interfaces need to be updated will be faster. Therefore, in this case, the timing duration can be set to a second duration which is less than the first duration. Specifically, the second duration can be set according to the number of links in the equivalent link group, for example, the second duration is set in proportion to the ratio of the number threshold to the first duration.

[0122] The present application will be described below in conjunction with application examples.

[0123] The present application provides a method for generating backup paths for fast reroute of an IGP protocol (including ISIS (Intermediate System to Intermediate System) or OSPF (Open Shortest Path First) protocol).

[0124] The method is used for data forwarding and a bearer network supporting an Ethernet IGP protocol. The network includes a plurality of forwarding devices, i.e., traffic forwarder devices, and the forwarder applied in the forwarding devices can be located at any position in the network, as shown in Figure 4 .

[0125] The forwarding devices in the network have the capability of forwarding data packets by enabling IGP protocol transceiving and obtaining network topology in a region for path calculation. When the forwarding devices are configured to enable fast reroute, the forwarding devices have the capability of generating a plurality of equivalent backup paths and out-ports according to constraint conditions when performing backup path calculation and selection.

[0126] Specifically, as shown in Figure 5 , the method provided by the present application includes the following steps:

[0127] Step 1: Setting constraint condition group: according to actual business requirements, a constraint condition group is set for a specific process of an IGP routing protocol (ISIS or OSPF), and the constraint conditions contained in the constraint condition group can be delay requirements, link bandwidth requirements, link quality conditions such as packet loss rate, specific configuration requirements or other conditions, etc. The constraint condition group can contain a single constraint condition or a combination of the above constraint conditions. The device can generate one or more constraint condition groups for a certain routing protocol. When there is no special requirement, the constraint condition group can be empty.

[0128] Step 2: Generating equivalent link group: according to actual requirements, an equivalent link group is generated for each local direction of a certain routing protocol process X in the constraint condition group selected in step 1 manually or automatically by the forwarding device, and the number of links in the equivalent link group is not more than a set value N. In addition to meeting the constraint condition group related conditions in step 1, the links in the equivalent link group of a certain local direction of a certain IGP protocol process X should also meet the following conditions: ① meeting the equivalent link requirement (belonging to the same local direction link and having the same protocol cost and being the smallest) ② link interface state UP and IGP neighbor establishment success, normal state.

[0129] In addition, it should be noted that:

[0130] First, for MPLS-enabled devices, this step can also generate MPLS protocol equivalent link groups based on MPLS protocol synchronization. In addition to the requirements related to step 2, MPLS protocol (including LDP, RSVP, etc. Protocol) neighbor establishment success and normal state are required.

[0131] Second, for SRv6-enabled devices, this step can generate SRv6 equivalent link groups based on SRv6 protocol synchronization. In addition to the requirements related to step 2, it is necessary to determine that the SRv6-related address family neighbor is established successfully, the function is normal, and the SRv6 SID is normally distributed.

[0132] In the above step 2, the method of dynamically generating equivalent link groups according to IGP protocol process includes:

[0133] 1. Find all next-hop local orientations N1, N2... Nm of the device. One possible method is to discover all neighbors of the device through the LLDP protocol (Link Layer Discovery Protocol), and determine the local orientation of all neighbors of the device through the name of the neighbor.

[0134] 2. For each local orientation Ni, automatically generate an equivalent link group according to the selected constraint conditions. The specific method is as follows:

[0135] 3. Find all physical interfaces P1, P2... Pn to the local orientation Ni. One possible way is to find all physical interfaces with the next-hop local orientation Ni through the LLDP protocol, and determine whether the relevant physical interface, logical interface (including a bundled interface composed of physical interfaces), or logical sub-interface can join the equivalent link group. The specific determination method is as follows:

[0136] 4. Find the subset PX1, PX2... PXc of interfaces or sub-interfaces in P1, P2... Pn that enable the corresponding IGP process X and have successfully established neighbors (for MPLS networks, additional MPLS-related protocol enablement and establishment success should be determined; for SRv6 networks, additional SRv6-related capability status normal should be determined).

[0137] 5. Find the minimum IGP cost value Cn of all interface links in PX1, PX2... PXc

[0138] 6. Determine whether the number of links in the current equivalent link group is not greater than N. If it is not greater than N, continue to explore the joinable interfaces.

[0139] 7. Perform constraint condition judgment on PX1, PX2... PXc in order. Determine whether the IGP cost of PXj interface is equal to Cn. If it is equal, proceed to the subsequent judgment.

[0140] 8. Determine whether the corresponding link meets the constraint condition of step 1;

[0141] 9. If it meets the above condition, add the interface PXj to the equivalent link group, otherwise do not add PXj to the equivalent link group;

[0142] 10. Continue to determine other interfaces until the verification of all candidate interfaces is completed or the number of links in the equivalent link group reaches the maximum number of links N;

[0143] Step 3: Generate equivalent link group index table: After generating the equivalent link group, an equivalent link group index table should be generated, which contains the indexes of each equivalent link port in the group and the corresponding interface state value (0, 1, 2, 3). The interface state value of the interface state UP and IGP protocol state UP and normal (for MPLS network, additional MPLS related protocol enablement and successful establishment should be judged; for SRv6 network, additional SRv6 related capability state normal should be judged) is 1, the interface state value of the interface state Down or protocol exception is 0, 2 and 3 are reserved. When the interface state in the index table changes, the interface state changes from UP to Down, the index table should be updated immediately, and the corresponding interface state value should be adjusted from 1 to 0; when the interface recovers from Down to UP, the interface state value should be updated from 0 to 1.

[0144] In addition: when step 2 uses the dynamic equivalent link group generation method, this step corresponds to the dynamic update algorithm of the equivalent link group index table:

[0145] 1. Set the timer to T, start the timer T when the equivalent link group index table is generated, when the timer counts to 0, re-run the dynamic link group generation algorithm in step 2, and reset the timer time to T after the calculation is completed;

[0146] 2. When running, for each port P1, P2...Pn, if the port index is already in the index table and the interface state value is 1, do not perform constraint condition judgment on the port, and keep it in the index table, if the interface state value is not 1, re-perform constraint condition judgment, and delete the related interface from the index table for the interface that does not meet the constraint condition;

[0147] 3. If the interface or IGP protocol in the index table changes state (for MPLS network, additional MPLS related protocol state change should be judged; for SRv6 network, additional SRv6 related protocol state normal should be judged), if it changes from UP to Down, adjust the related port state value to 0, delete the port from the index table, and clear the timer T to 0, and re-run the dynamic link group generation algorithm in step 2;

[0148] 4、If the interface in the index table changes, the corresponding interface state value is adjusted to 2;

[0149] 5、If the interface in the index table has link quality degradation, such as increased latency, increased packet loss rate, reduced bandwidth, etc., the interface state value is adjusted to 3;

[0150] 6、If the number of ports with a state value of 1 in the index table is less than the minimum threshold Nmin of the equivalent link group, the timer counting time T is reduced to Tmin, and when the number of ports with a state value of 1 in the index table is greater than or equal to Nmin, the timer counting time is restored to T.

[0151] Step 4: Run the basic IGP fast reroute algorithm: when the device starts the IGP fast reroute function, the basic fast reroute algorithm is normally run to calculate the backup path for the route in the IGP process X. In addition, for the network with MPLS enabled, the method can also be based on the RLFA FRR (Remote Loop Free Alternate Fast Reroute) algorithm, and for the network with SRv6 enabled, the method can also be based on the Ti-LFA FRR (Topology Independent Loop Free Alternate) algorithm.

[0152] Step 5: Generate backup path: for the backup path generated in step 4, if the backup path egress interface index hits the interface index in the equivalent link group index table generated in step 3, the backup path index of the corresponding route is updated to the index value of the corresponding equivalent link group index table, so that the egress interface is all the interfaces with a state value of 1 in the equivalent link group index table, and load balancing of equivalent routes is performed in each egress interface.

[0153] Step 6: Update the backup path: when the equivalent link group index table generated in step 3 changes, the corresponding backup path egress interface of the route should be updated accordingly.

[0154] To achieve the above functions, the embodiment of the present application also provides a backup path generation device for network transmission. As shown in the structure Figure 6 , it includes a first processor 61, a first communication interface 62, a clock module 63 and a first memory 64. The first processor 61, the first communication interface 62, the clock module 63 and the first memory 64 are connected through a bus.

[0155] The first processor 61 is used to run relevant algorithms to calculate and generate basic routes and fast rerouting results, and to generate, update, and perform calculations on equal-cost link groups and equal-cost link group index tables based on the aforementioned algorithms. The clock module 63 is used for timing operations of the corresponding timers. The first memory 64 is used to store program code and related calculation results. Its receiving unit 641 can be used to receive processing results from other modules, its sending unit 642 can be used to send stored parameters, and its processing unit 643 can be used for basic data processing. The memory 64 may also contain an operating system 644, through which the first processor 61 can call the code in the first memory 64.

[0156] To implement the alternative path generation method for network transmission in the embodiments of this application, the embodiments of this application also provide an alternative path generation device for network transmission. Figure 7 This is a schematic diagram of the composition of the alternative path generation device according to an embodiment of this application. Figure 1 ,like Figure 7 As shown, the device is applied to the forwarding device, and the device includes:

[0157] Setting unit 71 is used to set one or more constraint condition groups according to preset targets;

[0158] The first generation unit 72 is used to generate an equivalent link group for the forwarding device in each local direction according to the constraint condition group;

[0159] The second generation unit 73 is used to generate an equal-cost link group index table according to the equal-cost link group, and update the equal-cost link group index table according to the status of the equal-cost link group.

[0160] The third generation unit 74 is used to generate alternative paths based on the fast rerouting algorithm;

[0161] The update unit 75 is used to update the backup path according to the equivalent link group index table.

[0162] In some embodiments, the first generation unit 72 includes:

[0163] The first selection subunit is used to select a target constraint group from one or more constraint groups based on the target process of the equivalent link group to be generated.

[0164] The first generation subunit is configured to generate an equivalent link group for the forwarding device in each local exchange direction based on the target constraint condition set, such that the equivalent link group satisfies the following target conditions:

[0165] The number of links in the equivalent link group is less than or equal to a preset number threshold.

[0166] The links in the equivalent link group satisfy the principle of equivalent and minimum transmission overhead;

[0167] The interface state of the link in the equivalent link group is an available state;

[0168] The IGP neighbor of the interface in each link in the equivalent link group is successfully established and in a normal state;

[0169] If the forwarding device is an MPLS-enabled device, the MPLS neighbor of the interface in each link in the equivalent link group is successfully established and in a normal state;

[0170] If the forwarding device is an SRv6-enabled device, the SRv6 neighbor of the interface in each link in the equivalent link group is successfully established, in a normal state, and a normal SID is allocated.

[0171] In some embodiments, the first generating subunit comprises:

[0172] A first determining subunit configured to determine all next-hop local directions of the forwarding device;

[0173] A second generating subunit configured to generate, according to the target constraint condition group, an equivalent link group for each next-hop local direction.

[0174] In some embodiments, the second generating subunit is specifically configured to:

[0175] Determine all physical interfaces of each next-hop local direction;

[0176] For each physical interface, sequentially determine a logical interface or a logical sub-interface satisfying the target condition to obtain an interface set;

[0177] Determine the minimum value of the link transmission overhead of each interface in the interface set;

[0178] If the number of links of the current equivalent link group is less than or equal to the number threshold, determine whether the link transmission overhead of the next interface in the interface subset is equal to the minimum value;

[0179] If the link transmission overhead of the interface is equal to the minimum value, determine whether the interface satisfies the target constraint condition;

[0180] If the interface satisfies the target constraint condition, add the link corresponding to the interface to the equivalent link group;

[0181] If the number of links of the current equivalent link group is greater than the number threshold, stop determining whether the link transmission overhead of the next interface in the interface set is equal to the minimum value.

[0182] In some embodiments, the second generating unit 73 comprises:

[0183] a second determining sub-unit, configured to determine an interface index of each interface in the equivalent link group and a state value of the each interface;

[0184] a first updating sub-unit, configured to update the state value of the each interface according to a state of the each interface;

[0185] a second updating sub-unit, configured to update the equivalent link group index table according to the state value of the each interface.

[0186] In some embodiments, the second updating sub-unit is specifically configured to:

[0187] if the state value of the current interface is a first numerical value indicating that the interface is available, determine a state value of a next interface;

[0188] if the state value of the current interface is a second numerical value indicating that the interface is unavailable, delete the current interface from the equivalent link group index table;

[0189] if the state value of the current interface is a numerical value other than the first numerical value and the second numerical value, determine whether the current interface satisfies the constraint condition group;

[0190] if the current interface does not satisfy the constraint condition group, delete the current interface from the equivalent link group index table;

[0191] if the current interface satisfies the constraint condition group, continue to determine the state value of the next interface.

[0192] In some embodiments, the numerical value other than the first numerical value and the second numerical value comprises a third numerical value indicating that the interface is configured to change and a fourth numerical value indicating that a link quality corresponding to the interface deteriorates;

[0193] the first updating sub-unit is specifically configured to:

[0194] if a state of an interface or an interface protocol in the equivalent link group index table changes, adjust the state value of the interface to the second numerical value;

[0195] if the interface in the equivalent link group index table is configured to change, adjust the state value of the interface to the third numerical value;

[0196] if the interface in the equivalent link group index table deteriorates in link quality, adjust the state value of the interface to the fourth numerical value.

[0197] In some embodiments, the apparatus further comprises:

[0198] The setting unit is configured to set a timer with a first time length; wherein the timer starts timing after the generation of the equivalent link group index table is completed;

[0199] The fourth generating unit is configured to regenerate the equivalent link group of the forwarding device in each local direction according to the constraint condition group when the timer timing ends.

[0200] The modifying unit is configured to modify the timing time length of the timer to a second time length if the number of available interfaces in the equivalent link group index table is less than a preset number threshold; wherein the second time length is less than the first time length.

[0201] In some embodiments, the constraint condition group comprises one or more of the following: a delay requirement, a link bandwidth requirement, a packet loss rate requirement, a configuration requirement.

[0202] Or

[0203] The constraint condition group is empty.

[0204] In some embodiments, the third generating unit 74 is specifically configured to:

[0205] If the network transmission protocol is IGP, generate a backup path of the route in the IGP process based on an IGP fast reroute algorithm;

[0206] If the network transmission protocol is MPLS, generate a backup path of the route in the MPLS process based on an RLFA fast reroute algorithm;

[0207] If the network transmission protocol is SRv6, generate a backup path of the route in the SRv6 process based on a Ti-LFA fast reroute algorithm.

[0208] In some embodiments, the updating unit 75 is specifically configured to:

[0209] If the out interface in the backup path belongs to the interface indicated by the interface index in the equivalent link group index table, update the index value of the out interface in the backup path to the corresponding index value in the equivalent link group index table, so that the out interface is all available interfaces in the equivalent link group index table.

[0210] Perform load balancing of equivalent routes for all available interfaces in the equivalent link group index table.

[0211] If the equivalent link group index table is updated, update the index value of the out interface in the backup path accordingly.

[0212] In actual application, the setting unit 71, the first generating unit 72, the second generating unit 73, the third generating unit 74 and the updating unit 75 can be implemented by a processor in the backup path generating device.

[0213] It should be noted that the backup path generating device provided in the above embodiments is only used as an example to illustrate the division of the above program modules, and in actual application, the above processing can be completed by different program modules according to needs, that is, the internal structure of the device is divided into different program modules to complete all or part of the above-described processing. In addition, the data query device and the first backup path generating method provided in the above embodiments belong to the same concept, and the specific implementation process is described in detail in the first backup path generating method, which will not be repeated here.

[0214] Based on the hardware implementation of the above program modules, and in order to implement the backup path generating method of the embodiments of the present application, the embodiments of the present application further provide a forwarding device, Figure 8 The hardware composition structure of the forwarding device of the embodiments of the present application is shown in FIG. 8, which includes: Figure 8

[0215] The second communication interface 81 can interact with other devices (such as other forwarding devices) and forward data;

[0216] The second processor 82 is connected with the second communication interface 81 to realize information interaction and data forwarding with other devices (such as other forwarding devices), and is further used to run a computer program to execute the backup path generating method provided above, and the computer program is stored on the second memory 83.

[0217] Specifically, the second processor 82 is configured to perform the following steps: setting one or more constraint condition groups according to a preset target; generating an equivalent link group of the forwarding device in each local direction according to the constraint condition group; generating an equivalent link group index table according to the equivalent link group, and updating the equivalent link group index table according to the state of the equivalent link group; generating a backup path based on a fast reroute algorithm; and updating the backup path according to the equivalent link group index table. The second processor 82 can also perform each step of each method in any of the above embodiments. In addition, after the backup path generating method generates the backup path, the second communication interface 81 of the forwarding device can be used to forward data on the backup path.

[0218] It should be noted that the specific processing process of the second communication interface 81 and the second processor 82 can be understood with reference to the above backup path generating method.

[0219] ​Of course, in a practical application, the various components in the forwarding device 80 are coupled together by a bus system 84. As will be appreciated, the bus system 84 is used to facilitate communication among the various components. The bus system 84 is illustrated as including a data bus to facilitate the transfer of computer program instructions and data between the components. The bus system 84 can also include a power bus, a control bus, and a state signal bus, although these are not shown for clarity. For purposes of illustration, the bus system 84 is shown in the example of FIG. 1 as including a data bus for the transfer of data, a control bus for the transfer of control signals, and a state bus for the transfer of status signals. Figure 8

[0220] The second memory 83 in the embodiments of the present application is used to store various types of data to support the operation of the forwarding device 80. Examples of such data include any computer programs used to operate on the forwarding device 80.

[0221] The backup path generation method disclosed in the embodiments of the present application can be applied to or implemented by the second processor 82. The second processor 82 can be an integrated circuit chip with signal processing capability. In the implementation, the steps of the backup path generation method can be completed by the integrated logic circuit of hardware or the instructions in the form of software in the second processor 82. The second processor 82 can be a general-purpose processor, a digital signal processor (DSP), or other programmable logic device, discrete gate or transistor logic device, discrete hardware component, etc. The second processor 82 can implement or execute the backup path generation method, steps, and logic block diagram disclosed in the embodiments of the present application. The general-purpose processor can be a microprocessor or any conventional processor, etc. In combination with the steps of the backup path generation method disclosed in the embodiments of the present application, the execution can be directly completed by a hardware decoding processor or by a combination of hardware and software modules in the decoding processor. The software module can be located in a storage medium, which is located in the second memory 83. The second processor 82 reads the information in the second memory 83 and combines the hardware to complete the steps of the aforementioned backup path generation method.

[0222] ​In the example embodiment, the forwarding device 80 can be implemented by one or more Application Specific Integrated Circuits (ASICs), DSPs, Programmable Logic Devices (PLDs), Complex Programmable Logic Devices (CPLDs), Field-Programmable Gate Arrays (FPGAs), general-purpose processors, controllers, microcontrollers (MCUs), microprocessors (Microprocessors), or other electronic elements for executing the aforementioned standby path generation method.

[0223] It can be understood that the memory of the embodiments of the present application can be a volatile memory or a non-volatile memory, and can also include both volatile and non-volatile memories. Among them, the non-volatile memory can be a read-only memory (ROM, Read Only Memory), a programmable read-only memory (PROM, Programmable Read-Only Memory), an erasable programmable read-only memory (EPROM, Erasable Programmable Read-Only Memory), an electrically erasable programmable read-only memory (EEPROM, Electrically Erasable Programmable Read-Only Memory), a ferromagnetic random access memory (FRAM, ferromagnetic random access memory), a flash memory (Flash Memory), a magnetic surface memory, an optical disc, or a compact disc read-only memory (CD-ROM, Compact Disc Read-Only Memory); the magnetic surface memory can be a disk memory or a tape memory. The volatile memory can be a random access memory (RAM, Random Access Memory) used as an external cache. By way of example but not limitation, many forms of RAM can be used, such as static random access memory (SRAM, Static Random Access Memory), synchronous static random access memory (SSRAM, Synchronous Static Random Access Memory), dynamic random access memory (DRAM, Dynamic Random Access Memory), synchronous dynamic random access memory (SDRAM, Synchronous Dynamic Random Access Memory), double data rate synchronous dynamic random access memory (DDR SDRAM, Double Data Rate Synchronous Dynamic Random Access Memory), enhanced synchronous dynamic random access memory (ESDRAM, Enhanced Synchronous Dynamic Random Access Memory), synchronous link dynamic random access memory (SLDRAM, SyncLink Dynamic Random Access Memory), direct memory bus random access memory (DRRAM, Direct Rambus Random Access Memory).The memory described in the embodiments of the present application is intended to include, but not limited to, these and any other suitable types of memory.

[0224] In the example embodiments, the embodiments of the present application also provide a storage medium, i.e. a computer storage medium, specifically a computer readable storage medium, such as the first memory 64 or the second memory 83 storing a computer program, which can be executed by the second processor 82 in the forwarding device 80 or the first processor 61 of the backup path generation apparatus. The above computer program can be used to complete the steps of the backup path generation method described in the embodiments of the present application. The computer readable storage medium can be FRAM, ROM, PROM, EPROM, EEPROM, Flash Memory, magnetic surface memory, optical disc, CD-ROM, etc.

[0225] In the example embodiments, the embodiments of the present application also provide a computer program product, which includes a computer program, and when the computer program is executed by a processor (such as the first processor 61 or the second processor 82), the steps of the backup path generation method described in the embodiments of the present application are implemented.

[0226] It should be noted that "first", "second", "third", etc. are used to distinguish similar objects, and do not necessarily mean a specific order or sequence.

[0227] In addition, the technical solutions described in the embodiments of the present application can be combined arbitrarily without conflict.

[0228] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art can easily think of changes or replacements within the technical scope disclosed in the present application, which should be covered within the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.

Claims

1. A method for generating a backup path of a network transmission, characterized by, The network comprises a plurality of forwarding devices, and the method is applied to the forwarding devices, and the method comprises: setting one or more constraint condition groups according to a preset target; generating an equivalent link group in each local direction of the forwarding device according to the constraint condition group; generating an equivalent link group index table according to the equivalent link group, and updating the equivalent link group index table according to the state of the equivalent link group; generating a backup path based on a fast reroute algorithm; updating the backup path according to the equivalent link group index table; wherein the updating the backup path according to the equivalent link group index table comprises: if an out interface in the backup path belongs to an interface indicated by an interface index in the equivalent link group index table, updating an index value of the out interface in the backup path to a corresponding index value in the equivalent link group index table, so that the out interface is all available interfaces in the equivalent link group index table; performing load balancing of the equivalent routing for all available interfaces in the equivalent link group index table; if the equivalent link group index table is updated, updating the index value of the out interface in the backup path correspondingly.

2. The method of claim 1, wherein, The generating the equivalent link group in each local direction of the forwarding device according to the constraint condition group comprises: selecting a target constraint condition group from one or more constraint condition groups according to a target process of the equivalent link group to be generated; generating the equivalent link group in each local direction of the forwarding device according to the target constraint condition group, so that the equivalent link group meets the following target conditions: the number of links in the equivalent link group is less than or equal to a preset number threshold; the links in the equivalent link group meet the principle of equivalent and minimum transmission cost; the interface state in the links in the equivalent link group is an available state; the internal gateway protocol (IGP) neighbor of the interface in each link in the equivalent link group is successfully established and in a normal state; if the forwarding device is a multi-protocol label switching (MPLS) enabled device, the MPLS neighbor of the interface in each link in the equivalent link group is successfully established and in a normal state; if the forwarding device is a segment routing version 6 (SRv6) enabled device, the SRv6 neighbor of the interface in each link in the equivalent link group is successfully established, in a normal state, and a segment identifier (SID) is normally distributed.

3. The method of claim 2, wherein, The generating the equivalent link group in each local direction of the forwarding device according to the target constraint condition group comprises: determining all next hop local directions of the forwarding device; generating an equivalent link group for each next hop local direction according to the target constraint condition group.

4. The method of claim 3, wherein, The generating an equivalent link group for each next hop local direction according to the target constraint condition group comprises: determining all physical interfaces of each next hop local direction; for each physical interface, sequentially determining a logical interface or a logical sub-interface that meets the target condition to obtain an interface set; determining the minimum value of link transmission cost of each interface in the interface set; if the number of links in the current equivalent link group is less than or equal to the number threshold, determining whether a link transmission overhead of a next interface in the subset of interfaces is equal to the minimum value; if the link transmission overhead of the interface is equal to the minimum value, judging whether the interface satisfies the target constraint condition; if the interface satisfies the target constraint condition, adding a link corresponding to the interface to the equivalent link group; if the number of links in the current equivalent link group is greater than the number threshold, stopping judging whether a link transmission overhead of a next interface in the set of interfaces is equal to the minimum value.

5. The method of claim 1, wherein, the generating an equivalent link group index table according to the equivalent link group and updating the equivalent link group index table according to a state of the equivalent link group comprises: determining an interface index of each interface in the equivalent link group and a state value of the each interface; updating the state value of the each interface according to the state of the each interface; updating the equivalent link group index table according to the state value of the each interface.

6. The method of claim 5, wherein, the updating the equivalent link group index table according to the state value of the each interface comprises: if the state value of a current interface is a first numerical value indicating that an interface is available, determining a state value of a next interface; if the state value of the current interface is a second numerical value indicating that an interface is unavailable, deleting the current interface from the equivalent link group index table; if the state value of the current interface is a numerical value other than the first numerical value and the second numerical value, determining whether the current interface satisfies the constraint condition group; if the current interface does not satisfy the constraint condition group, deleting the current interface from the equivalent link group index table; if the current interface satisfies the constraint condition group, continuing to determine the state value of the next interface.

7. The method of claim 6, wherein, the numerical value other than the first numerical value and the second numerical value comprises a third numerical value indicating that an interface configuration is changed and a fourth numerical value indicating that a link quality corresponding to the interface is degraded; the updating the state value of the each interface according to the state of the each interface comprises: if a state of an interface or an interface protocol in the equivalent link group index table changes, adjusting the state value of the interface to the second numerical value; if the interface in the equivalent link group index table is changed in configuration, adjusting the state value of the interface to the third numerical value; if the interface in the equivalent link group index table is degraded in link quality, adjusting the state value of the interface to the fourth numerical value.

8. The method of claim 1, wherein, the method further comprises: setting a timer with a timing duration of a first duration; wherein the timer starts timing after the equivalent link group index table is generated; at the end of the timing of the timer, generating an equivalent link group of the forwarding device in each local direction again according to the constraint condition group; if a number of available interfaces in the equivalent link group index table is less than a preset number threshold, modifying the timing duration of the timer to a second duration; wherein the second duration is less than the first duration.

9. The method of claim 1, wherein, the constraint condition group comprises one or more of a delay requirement, a link bandwidth requirement, a packet loss rate requirement, and a configuration requirement; or the constraint condition group is empty.

10. The method of claim 1, wherein, the generating a backup path based on the fast reroute algorithm comprises: If the network transmission protocol is IGP, a backup path of a route in an IGP process is generated based on an IGP fast reroute algorithm; If the network transmission protocol is MPLS, a backup path of a route in an MPLS process is generated based on a remote loop-free alternate path (RLFA) fast reroute algorithm; If the network transmission protocol is SRv6, a backup path of a route in an SRv6 process is generated based on a topology-independent loop-free alternate path (Ti-LFA) fast reroute algorithm.

11. A network transmission backup path generating apparatus characterized by comprising: A network includes a plurality of forwarding devices, and the device is applied to the forwarding device, and the device includes: A setting unit configured to set one or more constraint condition groups according to a preset target; A first generating unit configured to generate an equivalent link group of the forwarding device in each local direction according to the constraint condition groups; A second generating unit configured to generate an equivalent link group index table according to the equivalent link groups, and update the equivalent link group index table according to a state of the equivalent link groups; A third generating unit configured to generate a backup path based on a fast reroute algorithm; An updating unit configured to update the backup path according to the equivalent link group index table; The updating unit is specifically configured to: If an out interface in the backup path belongs to an interface indicated by an interface index in the equivalent link group index table, update an index value of the out interface in the backup path to a corresponding index value in the equivalent link group index table, so that the out interface is all available interfaces in the equivalent link group index table; Perform load balancing of equivalent routes for all available interfaces in the equivalent link group index table; If the equivalent link group index table is updated, update the index value of the out interface in the backup path.

12. A forwarding device, characterized in that, It includes: A processor and a memory for storing a computer program capable of running on the processor; When the processor runs the computer program, the processor executes the steps of the method of any one of claims 1 to 10.

13. A computer readable storage medium having stored thereon a computer program, characterized in that, The computer program is executed by the processor to implement the steps of the method of any one of claims 1 to 10.

14. A computer program product comprising a computer program, characterized in that, The computer program is executed by the processor to implement the steps of the method of any one of claims 1 to 10. The computer program is executed by the processor to implement the steps of the method of any one of claims 1 to 10.

Citation Information

Patent Citations

  • Method for realizing rapid path switching and apparatus thereof

    CN102201964A

  • Method and device for determining path

    CN116684347A