IP network path restoration method and communication device

By obtaining IGP routing prefix information in the network for path restoration, the problem of high resource occupation, high cost and inability to realize real-time path restoration in the prior art is solved, and efficient and fast network path restoration is achieved.

CN119544512APending Publication Date: 2025-02-28HUAWEI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311137249.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-08-31
Publication Date
2025-02-28

AI Technical Summary

Technical Problem

The existing network path restoration method requires the collection of a large amount of routing forwarding information, resulting in high resource utilization, high cost and inability to realize real-time path restoration.

Method used

The control device obtains node information, link information and routing prefix information, and uses IGP routing prefix information to restore network paths to avoid collecting routing forwarding information.

Benefits of technology

It reduces the amount of information that control equipment needs to collect, reduces deployment costs, improves information collection efficiency, and realizes minute-level restoration of tens of millions of routes.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 00000000_0000_ABST
    Figure 00000000_0000_ABST
Patent Text Reader

Abstract

The invention provides an IP network path restoration method and a communication device, which are applied to the technical field of network communication. In the method, a control device acquires node information, link information and routing prefix information in a network. And obtaining an identifier and a destination IP address of a source node of the to-be-restored path. And the control device determines one or more pieces of target routing prefix information from the routing prefix information set according to the destination IP address and one or more IGP domain identifiers corresponding to the source node in the node information set. And the control device determines the routing prefix information according to one or more pieces of target routing prefix information, link information from a source node in the link information set to a node identified by a node identifier corresponding to a routing prefix in each piece of target routing prefix information, and an IGP domain identifier corresponding to the routing prefix in each piece of target routing prefix information in the node information set. And determining a to-be-restored path.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of network communications, and in particular to an Internet Protocol (IP) network path restoration method and a communication device. Background Art

[0002] The network digital map is a newly proposed network topology management map, which is used to digitize the network topology to improve network operation and maintenance efficiency and enhance user experience.

[0003] Network path restoration is an important function in the network digital map. For a given source and destination, the network management device can restore the real forwarding path in the physical network. The commonly used network path restoration method is that the network management device collects the routing table information of all devices in the network, and then queries the routing table based on the given source and destination information to determine the forwarding path from the source to the destination.

[0004] However, in most networks, the routing table of a single network device has many entries. Collecting the routing table of the devices in the entire network requires a lot of resources, so it is necessary to deploy many control devices to collect the information of the routing table, which is very costly. In addition, it takes a long time to collect the routing table of all devices and query the forwarding path according to the routing table, and it is impossible to restore the real-time network path. Summary of the invention

[0005] The embodiments of the present application provide an IP network path restoration method and a communication device, which help to achieve IP network path restoration faster and more efficiently.

[0006] In a first aspect, an IP network path restoration method is provided, which can be executed by a control device, or by a component of the control device, such as a processor, a chip, or a chip system of the control device, or by a logic module or software that can realize all or part of the functions of the control device. The method may include: the control device obtains a node information set, a link information set, and a routing prefix information set in the network, the node information in the node information set includes a node identifier and an internal gateway protocol IGP domain identifier corresponding to the node, the link information in the link information set includes a link identifier and a link cost, and the routing prefix information in the routing prefix information set includes a routing prefix, and a node identifier, an IGP domain identifier, and a metric value corresponding to the routing prefix. The control device obtains the identifier of the source node of the path to be restored and the destination Internet Protocol IP address. The control device determines one or more target routing prefix information from the routing prefix information set according to the destination IP address and one or more IGP domain identifiers corresponding to the source node in the node information set. The routing prefix in the one or more target routing prefix information meets the longest prefix matching rule with the destination IP address, and the IGP domain identifier corresponding to the routing prefix in each target routing prefix information is the same as one of the one or more IGP domain identifiers. The control device determines the path to be restored based on one or more target routing prefix information, link information between the source node in the link information set and the node identified by the node identifier corresponding to the routing prefix in each target routing prefix information, and the IGP domain identifier corresponding to the routing prefix in each target routing prefix information in the node information set.

[0007] Based on this solution, the control device can restore the network path based on the collected IGP route prefix information, without collecting the information of the route forwarding table. This greatly reduces the amount of information that the control device needs to collect, reduces the deployment cost of the solution, and improves the efficiency of information collection. In addition, since the route forwarding table is not used for path restoration, there is no need to traverse the full route table, which can greatly improve the path restoration rate. For example, it can achieve minute-level restoration of tens of millions of routes.

[0008] In combination with the first aspect above, as a possible implementation method, the IGP domain identifier corresponding to the source node in the node information set includes a first IGP domain identifier, one or more target routing prefix information includes at least one first-class target routing prefix information, and the IGP domain identifier corresponding to the routing prefix in the first-class target routing prefix information is the first IGP domain identifier. The control device determines the path to be restored based on one or more target routing prefix information, the link information between the source node and the node identified by the node identifier corresponding to the routing prefix in each target routing prefix information in the link information set, and the IGP domain identifier corresponding to the routing prefix in each target routing prefix information in the node information set, including: the control device determines at least one first path based on at least one first-class target routing prefix information, and each first path corresponds to a first-class target routing prefix information. The starting node of the first path is the source node, and the end node of the first path is the node identified by the node identifier in the first-class target routing prefix information corresponding to the first path. The IGP domain identifier corresponding to the node on the first path includes the first IGP domain identifier. The control device determines the target first path from at least one first path. In the case where there are multiple first paths, the sum of the cost of the target first path and the metric value in the first type target routing prefix information corresponding to the target first path is less than or equal to the sum of the cost of any first path other than the target first path among the multiple first paths and the metric value in the first type target routing prefix information corresponding to the any first path. The control device determines the path to be restored according to the target first path, the link information corresponding to the target first path in the link information set, and the IGP domain identifier corresponding to the node on the target first path in the node information set.

[0009] In combination with the first aspect above, as a possible implementation method, the IGP domain identifier corresponding to the source node in the node information set also includes a second IGP domain identifier, one or more target routing prefix information includes at least one second-class target routing prefix information, and the IGP domain identifier corresponding to the routing prefix in the second-class target routing prefix information is the second IGP domain identifier. The method also includes: the control device determines at least one second path according to at least one second-class target routing prefix information, and each second path corresponds to a second-class target routing prefix information. The starting node of the second path is the source node, and the end node of the second path is the node identified by the node identifier in the second-class target routing prefix information corresponding to the second path. The IGP domain identifier corresponding to the node on the second path includes the second IGP domain identifier. The control device determines the target second path from at least one second path. In the case where the number of second paths is multiple, the sum of the cost of the target second path and the metric value in the second-class target routing prefix information corresponding to the target second path is less than or equal to the sum of the cost of any second path other than the target second path among the multiple second paths and the metric value in the second-class target routing prefix information corresponding to the any second path. The control device determines the path to be restored based on the target first path, the link information corresponding to the target first path in the link information set, and the IGP domain identifier corresponding to the node on the target first path in the node information set, including: when the sum of the cost of the target first path and the metric value in the first type of target routing prefix information corresponding to the first path is less than or equal to the sum of the cost of the target second path and the metric value in the second target routing prefix information corresponding to the target second path, the control device determines the path to be restored based on the target first path, the link information corresponding to the target first path in the link information set, and the IGP domain identifier corresponding to the node on the target first path in the node information set.

[0010] In combination with the first aspect above, as a possible implementation method, the control device determines the path to be restored according to the target first path, the link information corresponding to the target first path in the link information set, and the IGP domain identifier corresponding to the node on the first path in the node information set, including: when the IGP domain identifier corresponding to the node other than the starting node on the target first path only includes the first IGP domain identifier, the control device determines the end node on the target first path as the destination node, and determines the target first path as the path to be restored. Alternatively, when the IGP domain identifier corresponding to the node other than the starting node and the end node on the target first path only includes the first IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target first path also includes the third IGP domain identifier, and the routing prefix information including the third IGP domain identifier in the routing prefix information set contains routing prefix information including the third IGP domain identifier and the node identifier of the end node on the target first path, the control device determines the end node of the target first path as the destination node, and determines the target first path as the path to be restored. Alternatively, when the IGP domain identifiers corresponding to the nodes other than the starting node and the end node on the target first path only include the first IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target first path also includes the third IGP domain identifier, and there is no routing prefix information including the third IGP domain identifier in the routing prefix information set that satisfies the longest routing prefix matching rule with the destination IP address, the control device determines that the end node of the target first path is the destination node, and determines that the target first path is the path to be restored. Alternatively, when the IGP domain identifiers corresponding to the nodes other than the starting node and the end node on the target first path only include the first IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target first path also includes the third IGP domain identifier, and there is routing prefix information including the third IGP domain identifier and the node identifier of the end node on the target first path in the routing prefix information set, the control device determines that the path to be restored includes the target first path and at least one third path connected end to end, and the end node on the target first path is the starting node of the first third path of at least one third path connected end to end. Among them, different third paths are located in different IGP domains, and the IGP domain identifier corresponding to the node between the starting node and the end node on each third path only includes one IGP domain identifier. The end node of each third path is determined by the routing prefix information determined from the routing prefix information set based on the IGP domain identifier corresponding to the starting node of each third path and the destination IP address, and each third path is determined based on the link information between the starting node of the third path and the end node of the third path, combined with the shortest path algorithm. The IGP domain identifier corresponding to the end node of the last third path only includes one IGP domain identifier.Alternatively, the end node of the last third path corresponds to the fourth IGP domain identifier, the fourth IGP domain identifier is different from the IGP domain identifier corresponding to the nodes other than the end node on the last third path, and the routing prefix information set contains routing prefix information including the fourth IGP domain identifier and the node identifier of the end node of the last third path. Alternatively, the routing prefix information set does not contain routing prefix information including the fourth IGP domain identifier that satisfies the longest routing prefix matching rule with the destination IP address.

[0011] In combination with the first aspect above, as a possible implementation method, the control device determines the path to be restored according to the target first path, the link information corresponding to the target first path in the link information set, and the IGP domain identifier corresponding to the node on the first path in the node information set, including: when the first intermediate node between the starting node and the end node on the target first path corresponds to multiple IGP domain identifiers, the control device determines the first sub-path in the target first path, the starting node of the first sub-path is the source node, and the end node of the first sub-path is the first intermediate node. The IGP domain identifiers corresponding to the nodes other than the source node and the first intermediate node on the first sub-path only include the first IGP domain identifier. The control device determines that the path to be restored includes the first sub-path and at least one third path connected end to end to each other, and the end node on the first sub-path is the starting node of the first third path in at least one third path connected end to end to each other. Wherein, different third paths are located in different IGP domains, and the IGP domain identifiers corresponding to the nodes between the starting node and the end node on each third path only include one IGP domain identifier. The end node of each third path is determined by the routing prefix information determined from the routing prefix information set according to the IGP domain identifier corresponding to the starting node of each third path and the destination IP address, and each third path is determined according to the link information between the starting node of the third path and the end node of the third path, combined with the shortest path algorithm. The IGP domain identifier corresponding to the end node of the last third path only includes one IGP domain identifier. Alternatively, the end node of the last third path corresponds to the fourth IGP domain identifier, and the fourth IGP domain identifier is different from the IGP domain identifier corresponding to the node other than the end node on the last third path, and the routing prefix information set contains routing prefix information including the fourth IGP domain identifier and the node identifier of the end node of the last third path. Alternatively, there is no routing prefix information in the routing prefix information set that includes the fourth IGP domain identifier and satisfies the longest routing prefix matching rule with the destination IP address.

[0012] In combination with the above-mentioned first aspect, as a possible implementation method, the method also includes: when the sum of the cost of the target second path and the metric value corresponding to the routing prefix in the first type of target routing prefix information corresponding to the end node on the target second path is less than or equal to the sum of the cost of the target first path and the metric value in the first type of target routing prefix information corresponding to the end node on the target first path, the control device determines the path to be restored based on the target second path and the IGP domain identifier corresponding to the node on the target second path in the node information set.

[0013] In combination with the first aspect above, as a possible implementation method, the control device determines the path to be restored according to the target second path, the link information corresponding to the target second path in the link information set, and the IGP domain identifier corresponding to the node on the second path in the node information set, including: when the IGP domain identifier corresponding to the node other than the starting node on the target second path only includes the second IGP domain identifier, the control device determines the end node on the target second path as the destination node, and determines the target second path as the path to be restored. Alternatively, when the IGP domain identifier corresponding to the node other than the starting node and the end node on the target second path only includes the second IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target second path also includes the third IGP domain identifier, and there is routing prefix information including the third IGP domain identifier and the node identifier of the end node on the target first path in the routing prefix information set, the control device determines the end node of the target second path as the destination node, and determines the target second path as the path to be restored. Alternatively, when the IGP domain identifiers corresponding to the nodes other than the starting node and the end node on the target second path only include the second IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target second path also includes the third IGP domain identifier, and there is no routing prefix information including the third IGP domain identifier in the routing prefix information set that satisfies the longest routing prefix matching rule with the destination IP address, the control device determines that the end node of the target second path is the destination node, and determines that the target second path is the path to be restored. Alternatively, when the IGP domain identifiers corresponding to the nodes other than the starting node and the end node on the target second path only include the second IGP domain identifier, and the IGP domain identifiers corresponding to the end node on the target second path also include the third IGP domain identifier, and the routing prefix information including the third IGP domain identifier in the routing prefix information set does not include the node identifier of the end node on the target second path, the control device determines that the path to be restored includes the target second path and at least one third path connected end to end to each other, and the end node on the target second path is the starting node of the first third path among the at least one third path connected end to end to each other. Among them, different third paths are located in different IGP domains, and the IGP domain identifier corresponding to the node between the starting node and the end node on each third path only includes one IGP domain identifier. The end node of each third path is determined by the routing prefix information determined from the routing prefix information set based on the IGP domain identifier corresponding to the starting node of each third path and the destination IP address, and each third path is determined based on the link information between the starting node of the third path and the end node of the third path, combined with the shortest path algorithm. The IGP domain identifier corresponding to the end node of the last third path only includes one IGP domain identifier.Alternatively, the end node of the last third path corresponds to the fourth IGP domain identifier, the fourth IGP domain identifier is different from the IGP domain identifier corresponding to the nodes other than the end node on the last third path, and the routing prefix information set contains routing prefix information including the fourth IGP domain identifier and the node identifier of the end node of the last third path. Alternatively, the routing prefix information set does not contain routing prefix information including the fourth IGP domain identifier that satisfies the longest routing prefix matching rule with the destination IP address.

[0014] In combination with the first aspect above, as a possible implementation method, the control device determines the path to be restored according to the target second path, the link information corresponding to the target second path in the link information set, and the IGP domain identifier corresponding to the node on the second path in the node information set, including: when the second intermediate node between the starting node and the end node on the target second path corresponds to multiple IGP domain identifiers, the control device determines the second sub-path in the target second path, the starting node of the second sub-path is the source node, and the end node of the second sub-path is the second intermediate node. The IGP domain identifiers corresponding to the nodes other than the source node and the second intermediate node on the second sub-path only include the second IGP domain identifier. The control device determines that the path to be restored includes the second sub-path and at least one third path connected end to end to each other, and the end node on the second sub-path is the starting node of the first third path in at least one third path connected end to end to each other. Wherein, different third paths are located in different IGP domains, and the IGP domain identifiers corresponding to the nodes between the starting node and the end node on each third path only include one IGP domain identifier. The end node of each third path is determined by the routing prefix information determined from the routing prefix information set according to the IGP domain identifier corresponding to the starting node of each third path and the destination IP address, and each third path is determined according to the link information between the starting node of the third path and the end node of the third path, combined with the shortest path algorithm. The IGP domain identifier corresponding to the end node of the last third path only includes one IGP domain identifier. Or, or, the end node of the last third path corresponds to the fourth IGP domain identifier, the fourth IGP domain identifier is different from the IGP domain identifier corresponding to the node other than the end node on the last third path, and the routing prefix information set contains routing prefix information including the fourth IGP domain identifier and the node identifier of the end node of the last third path. Or, there is no routing prefix information in the routing prefix information set that includes the fourth IGP domain identifier and satisfies the longest routing prefix matching rule with the destination IP address.

[0015] In a second aspect, a device is provided, comprising: a processor and a memory. The memory is used to store computer instructions, and when the device is running, the processor executes the computer instructions stored in the memory to enable the device to perform the IP network path restoration method as described in any one of the above-mentioned first aspects.

[0016] In conjunction with the above second aspect, in a possible implementation, the device further includes a communication interface. The communication interface is used for the device to communicate with other devices. Exemplarily, the communication interface can be a transceiver, an input / output interface, an interface circuit, an output circuit, an input circuit, a pin or a related circuit, etc.

[0017] In a third aspect, a computer-readable storage medium is provided, wherein instructions are stored in the computer-readable storage medium, and when the computer-readable storage medium is executed on the computer, the computer can execute the IP network path restoration method of any one of the above-mentioned first aspects.

[0018] In a fourth aspect, a computer program product comprising instructions is provided, which, when executed on a computer, enables the computer to execute any one of the IP network path restoration methods of the first aspect.

[0019] Among them, the technical effects brought about by any design method in the second to fourth aspects can refer to the technical effects brought about by different design methods in the first aspect, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] Figure 1 A schematic diagram of the structure of a communication network provided in an embodiment of the present application;

[0021] Figure 2 A schematic diagram of the structure of a communication system provided in an embodiment of the present application;

[0022] Figure 3 A flowchart of an IP network path restoration method provided in an embodiment of the present application;

[0023] Figure 4 A schematic diagram of the structure of a communication network provided in an embodiment of the present application;

[0024] Figure 5 A schematic diagram of the structure of a communication network provided in an embodiment of the present application;

[0025] Figure 6 A schematic diagram of the structure of a communication network provided in an embodiment of the present application;

[0026] Figure 7 A schematic diagram of the structure of a communication device provided in an embodiment of the present application;

[0027] Figure 8A schematic diagram of the structure of another communication device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0028] The interior gateway protocol (IGP) is a protocol for exchanging routing information between gateways (hosts or routers) within an autonomous system (AS). An AS can contain multiple IGP domains, and each device can obtain node information, link information, and routing prefix information in the IGP domain it joins. Each device can calculate the shortest path to other devices in the same IGP domain through the shortest path algorithm, and take the first hop of the shortest path as the next hop of the route.

[0029] IGP can be divided into two categories: 1. Distance-vector routing protocol. 2. Link state routing protocol. Distance-vector routing protocols can include routing information protocol (RIP), and link state routing protocols can include open shortest path first (OSPF) protocol and intermediate system to intermediate system (ISIS) protocol.

[0030] The border gateway protocol (BGP) is a protocol for exchanging routing information between different ASs. When two ASs need to exchange routing information, each AS must specify one or more nodes running BGP to represent the AS in exchanging routing information with other ASes. This node is usually a router. The routers between two ASs that use BGP to exchange information are also called border gateways or border routers.

[0031] Network digital map is a technology for digital and visual management of physical networks. Network digital map can restore the topology of the physical network and perform operation and maintenance management on this basis.

[0032] Figure 1The present invention is a structural diagram of a communication network, in which node A is connected to node B, node B is also connected to node C, node D and node E respectively, node C is also connected to node D, node E is also connected to node F, and node F is also connected to node G and node H respectively. Among them, node A, node B, node C and node D belong to IGP domain 1, and node F, node G and node H belong to IGP domain 2. Node E belongs to both IGP domain 1 and IGP domain 2, and node E is a node across IGP domains. The control device can be connected to node E in the network, and obtain node information, link information and routing information in IGP domain 1 and IGP domain 2 through node E. Then, a network digital map of the network can be generated to digitally manage the network.

[0033] Network path restoration is an important function in network digital maps, which can restore the real forwarding path for a given source and destination.

[0034] In one implementation, the control device can obtain the full routing information in the network. For a given source and destination, the control device can query the routing information hop by hop, and then perform routing splicing to restore the path from the source to the destination. However, the entries in the routing table of a single network device in most networks currently reach millions. Collecting the full routing of the entire network requires the deployment of a large number of control devices, which occupies a lot of communication resources and is very costly. In addition, it takes a long time to collect the routing tables of all devices and query the forwarding path based on the routing tables, and it is impossible to restore the real-time network path.

[0035] In another implementation, the control device can initiate a route tracing (tracert) process from the source to the destination, and detect the route from the source to the destination through the tracert message. However, some devices in the network will not respond to the tracert message, which will cause the final restored path to be inaccurate.

[0036] In view of the problems existing in the prior art, the present application provides an IP network path restoration method, which can calculate the path according to the network topology information and IGP routing prefix, and restore the path from the source end to the destination end. This method does not need to query the routing forwarding table, so that the amount of information that the control device needs to collect is greatly reduced, so that the network path restoration can be realized faster and more timely.

[0037] The technical solutions in the embodiments of the present application will be described below in conjunction with the drawings in the embodiments of the present application. Among them, in the description of the present application, unless otherwise specified, " / " indicates that the objects associated before and after are in an "or" relationship, for example, A / B can represent A or B; "and / or" in the present application is only a description of the association relationship of the associated objects, indicating that there can be three relationships, for example, A and / or B, which can represent: A exists alone, A and B exist at the same time, and B exists alone, where A and B can be singular or plural. And, in the description of the present application, unless otherwise specified, "multiple" refers to two or more than two. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single items or plural items. For example, at least one of a, b, or c can represent: a, b, c, ab, ac, bc, or abc, where a, b, c can be single or multiple. In addition, in order to facilitate the clear description of the technical solutions of the embodiments of the present application, in the embodiments of the present application, the words "first", "second" and the like are used to distinguish the same items or similar items with basically the same functions and effects. It can be understood by those skilled in the art that the words "first", "second" and the like do not limit the quantity and execution order, and the words "first", "second" and the like do not limit them to be necessarily different. At the same time, in the embodiments of the present application, the words "exemplary" or "for example" are used to indicate examples, illustrations or explanations. Any embodiment or design described as "exemplary" or "for example" in the embodiments of the present application should not be interpreted as being more preferred or more advantageous than other embodiments or design solutions. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a specific way for easy understanding. In addition, the network architecture and business scenarios described in the embodiments of the present application are intended to more clearly illustrate the technical solutions of the embodiments of the present application, and do not constitute a limitation on the technical solutions provided in the embodiments of the present application. It can be known to those of ordinary skill in the art that with the evolution of the network architecture and the emergence of new business scenarios, the technical solutions provided in the embodiments of the present application are also applicable to similar technical problems.

[0038] Before introducing the IP network path restoration method provided in the embodiment of the present application, the communication system / business scenario to which the message processing method of the present application is applied is first introduced.

[0039] Figure 2 A schematic diagram of the structure of a communication system provided in this application, such as Figure 2 As shown, the control device can establish a connection with the communication network, and the control device can collect IGP information and / or BGP information of the communication network, thereby realizing functions such as network topology restoration and path restoration.

[0040] As an implementation manner, the control device may establish an IGP connection or a BGP-LS connection with the communication network, and collect IGP routing information in the communication network through the IGP connection or the BGP-LS connection.

[0041] As an implementation manner, the control device may also establish a BGP connection with the communication network, and collect BGP routing information in the network through the BGP connection.

[0042] Optionally, Figure 2 Devices in the communication network can run protocols such as OSPF, ISIS or BGP.

[0043] The IP network path restoration method provided in this application can be applied to Figure 2 The communication system shown, the control device can be used to restore the network forwarding path from any source end to the destination end in the network according to the IP network path restoration method provided by this application. The specific implementation method is detailed in the method embodiment below, which will not be described in detail here.

[0044] Alternatively, if Figure 2 As shown, the control device may also be connected to a user device, and the user device may be used to indicate to the control device the source end and the destination end of the network forwarding path to be restored.

[0045] It should be understood that the network architecture and business scenarios described in the embodiments of the present application are intended to more clearly illustrate the technical solutions of the embodiments of the present application, and do not constitute a limitation on the technical solutions provided in the embodiments of the present application. Ordinary technicians in this field can know that with the evolution of network architecture and the emergence of new business scenarios, the technical solutions provided in the embodiments of the present application are also applicable to similar technical problems.

[0046] The following will be combined Figure 2 The communication system shown describes the IP network path restoration method provided by the embodiment of the present application. The actions, terms, etc. involved in the various embodiments of the present application can refer to each other without limitation. The message name or parameter name in the message in the embodiment of the present application is only an example, and other names can also be used in the specific implementation without limitation.

[0047] Figure 3 A flowchart of an IP network path restoration method provided in an embodiment of the present application is shown as follows: Figure 3 As shown, the method may include the following steps:

[0048] Step 301, the control device obtains a node information set, a link information set and a routing prefix information set in the network, the node information in the node information set includes a node identifier and an IGP domain identifier corresponding to the node, the link information in the link information set includes a link identifier and a link cost, and the routing prefix information in the routing prefix information set includes a routing prefix, and a node identifier, an IGP domain identifier and a metric value corresponding to the routing prefix.

[0049] For example, assuming that node A is in IGP domain 1, the node information corresponding to node A acquired by the control device can be expressed as “A1”, where A is the node identifier and 1 is the identifier of IGP domain 1.

[0050] For example, it is assumed that node A and node B are in IGP domain 1, node A and node B are IGP neighbors, and a link exists between node A and node B. Link information corresponding to the link between node A and node B acquired by the control device can be expressed as "AB1", where AB is an identifier of the link between node A and node B, and 1 is an identifier of IGP domain 1.

[0051] For example, assuming that node A is in IGP domain 1 and node A publishes the routing prefix 10.0.0.0 / 24 in IGP domain 1, the link information obtained by the control device can be expressed as A1_10.0.0.0 / 24_a, where A is the node identifier, 1 is the identifier of IGP domain 1, and a is the metric value corresponding to the routing prefix 10.0.0.0 / 24.

[0052] Optionally, the node information set may include node information of all nodes in the first network, and the link information set may include link information between all nodes in the first network. After acquiring the above information, the control device may restore the topology of the first network based on the node information set and the link information set.

[0053] Step 302: The control device obtains the identifier of the source node and the destination IP address of the path to be restored.

[0054] Optionally, the source node identifier and destination IP address of the path to be restored may be configured in the control device by a technician through a configuration tool. Alternatively, the source node identifier and destination IP address of the path to be restored may be sent by the user device to the control device.

[0055] Step 303: The control device determines one or more target routing prefix information from the routing prefix information set according to the destination IP address and one or more IGP domain identifiers corresponding to the source node in the node information set. The routing prefixes in the one or more target routing prefix information and the destination IP address meet the longest prefix matching rule, and the IGP domain identifier corresponding to the routing prefix in each target routing prefix information is the same as one of the one or more IGP domain identifiers.

[0056] Optionally, when the source node corresponds to an IGP domain identifier, one or more target routing prefix information corresponds to the same IGP domain identifier. In other words, when the source node is in only one IGP domain, the target routing prefix information matched by the destination IP address is the routing prefix information published by the node in the IGP domain to which the source node belongs.

[0057] Optionally, in the case where the source node corresponds to multiple IGP domain identifiers, one or more target routing prefix information corresponds to one or more IGP domain identifiers. In other words, in the case where the source node is only in multiple IGP domains, the target routing prefix information matched by the destination IP address can be the routing prefix information published by the nodes in the one or more IGP domains to which the source node belongs.

[0058] Step 304: The control device determines the path to be restored based on one or more target routing prefix information, link information between the source node in the link information set and the node identified by the node identifier corresponding to the routing prefix in each target routing prefix information, and the IGP domain identifier corresponding to the routing prefix in each target routing prefix information in the node information set.

[0059] As an implementation method, the IGP domain identifier corresponding to the source node in the node information set includes a first IGP domain identifier, the one or more target routing prefix information includes at least one first-class target routing prefix information, and the IGP domain identifier corresponding to the routing prefix in the first-class target routing prefix information is the first IGP domain identifier. In this case, the control device determines the path to be restored based on the one or more target routing prefix information, the link information between the source node in the link information set and the node identified by the node identifier corresponding to the routing prefix in each target routing prefix information, and the IGP domain identifier corresponding to the routing prefix in each target routing prefix information in the node information set, which may include:

[0060] S1. The control device determines at least one first path according to at least one first-class target routing prefix information, and each first path corresponds to a first-class target routing prefix information. The starting node of the first path is the source node, and the end node of the first path is the node identified by the node identifier in the first-class target routing prefix information corresponding to the first path. The IGP domain identifier corresponding to the node on the first path includes the first IGP domain identifier.

[0061] S2. The control device determines a target first path from at least one first path. The sum of the cost of the target first path and the metric value in the first type target routing prefix information corresponding to the first path is less than or equal to the sum of the cost of any first path other than the target first path in at least one first path and the metric value in the first type target routing prefix information corresponding to the any first path.

[0062] S3. The control device determines the path to be restored according to the target first path, the link information corresponding to the target first path in the link information set, and the IGP domain identifiers corresponding to the nodes on the target first path in the node information set.

[0063] As an implementation method, the IGP domain identifier corresponding to the source node in the node information set may also include a second IGP domain identifier, the one or more target routing prefix information includes at least one second-class target routing prefix information, and the IGP domain identifier corresponding to the routing prefix in the second-class target routing prefix information is the second IGP domain identifier. The above method may also include:

[0064] S4. The control device determines at least one second path according to at least one second-type target routing prefix information, and each second path corresponds to a second-type target routing prefix information. The starting node of the second path is the source node, and the end node of the second path is the node identified by the node identifier in the second-type target routing prefix information corresponding to the second path. The IGP domain identifier corresponding to the node on the second path includes the second IGP domain identifier.

[0065] S5. The control device determines a target second path from the at least one second path. The sum of the cost of the target second path and the metric value in the second type target route prefix information corresponding to the second path is less than or equal to the sum of the cost of any second path other than the target second path in the at least one second path and the metric value in the second type target route prefix information corresponding to the any second path.

[0066] Optionally, the control device may execute step S3 when the sum of the cost of the target first path and the metric value in the first type of target routing prefix information corresponding to the first path is less than or equal to the sum of the cost of the target second path and the metric value in the second target routing prefix information corresponding to the second path.

[0067] As an implementation method, step S3 may specifically include the following steps:

[0068] S31: When the IGP domain identifiers corresponding to the nodes other than the start node on the target first path include only the first IGP domain identifier, the control device determines the end node on the target first path as the destination node, and determines the target first path as the path to be restored.

[0069] S32. When the IGP domain identifiers corresponding to the nodes other than the starting node and the end node on the target first path include only the first IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target first path also includes the third IGP domain identifier, and the routing prefix information set contains routing prefix information including the third IGP domain identifier and the node identifier of the end node on the target first path, the control device determines that the end node of the target first path is the destination node, and determines that the target first path is the path to be restored.

[0070] S33. When the IGP domain identifiers corresponding to the nodes other than the starting node and the end node on the target first path include only the first IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target first path also includes the third IGP domain identifier, and there is no routing prefix information including the third IGP domain identifier in the routing prefix information set that satisfies the longest routing prefix matching rule with the destination IP address, the control device determines that the end node of the target first path is the destination node, and determines that the target first path is the path to be restored.

[0071] S34. When the IGP domain identifiers corresponding to the nodes other than the starting node and the end node on the target first path include only the first IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target first path also includes the third IGP domain identifier, and the routing prefix information set contains routing prefix information including the third IGP domain identifier and the node identifier of the end node on the target first path, the control device determines that the path to be restored includes the target first path and at least one third path connected end to end to each other, and the end node on the target first path is the starting node of the first third path of the at least one third path connected end to end to each other.

[0072] Among them, different third paths are located in different IGP domains, and the IGP domain identifiers corresponding to the nodes between the starting node and the end node on each third path only include one IGP domain identifier; the end node of each third path is determined by the routing prefix information determined from the routing prefix information set according to the IGP domain identifier corresponding to the starting node of each third path and the destination IP address, and each third path is determined according to the link information between the starting node of the third path and the end node of the third path, combined with the shortest path algorithm; the IGP domain identifier corresponding to the end node of the last third path only includes one IGP domain identifier; or, the end node of the last third path corresponds to the fourth IGP domain identifier, the fourth IGP domain identifier is different from the IGP domain identifiers corresponding to the nodes other than the end node on the last third path, and there is routing prefix information in the routing prefix information set that includes the fourth IGP domain identifier and the node identifier of the end node of the last third path; or, there is no routing prefix information in the routing prefix information set that includes the fourth IGP domain identifier and the destination IP address that satisfies the longest routing prefix matching rule.

[0073] S35. First, when the first intermediate node between the starting node and the end node on the target first path corresponds to multiple IGP domain identifiers, the control device determines the first sub-path in the target first path, the starting node of the first sub-path is the source node, and the end node of the first sub-path is the first intermediate node. The IGP domain identifiers corresponding to the nodes other than the source node and the first intermediate node on the first sub-path only include the first IGP domain identifier. Then, the control device determines that the path to be restored includes the first sub-path and at least one third path connected end to end to each other, and the end node on the first sub-path is the starting node of the first third path in at least one third path connected end to end to each other.

[0074] The third path can refer to the previous description and will not be repeated here.

[0075] As an implementation method, when the sum of the cost of the target second path and the metric value corresponding to the routing prefix in the first type of target routing prefix information corresponding to the end node on the target second path is less than or equal to the sum of the cost of the target first path and the metric value in the first type of target routing prefix information corresponding to the end node on the target first path, the above method may also include step S6, the control device determines the path to be restored based on the target second path and the IGP domain identifier corresponding to the node on the target second path in the node information set.

[0076] Optionally, step S6 may specifically include:

[0077] S61: When the IGP domain identifiers corresponding to the nodes other than the start node on the target second path include only the second IGP domain identifier, the control device determines the end node on the target second path as the destination node, and determines the target second path as the path to be restored.

[0078] S62: When the IGP domain identifiers corresponding to the nodes other than the start node and the end node on the target second path include only the second IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target second path also includes the third IGP domain identifier, and the routing prefix information set includes routing prefix information including the third IGP domain identifier and the node identifier of the end node on the target first path, the control device determines that the end node of the target second path is the destination node, and determines that the target second path is the path to be restored.

[0079] S63: When the IGP domain identifiers corresponding to the nodes other than the starting node and the end node on the target second path include only the second IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target second path also includes the third IGP domain identifier, and there is no routing prefix information including the third IGP domain identifier in the routing prefix information set that satisfies the longest routing prefix matching rule with the destination IP address, the control device determines that the end node of the target second path is the destination node, and determines that the target second path is the path to be restored.

[0080] S64. When the IGP domain identifiers corresponding to the nodes other than the starting node and the end node on the target second path include only the second IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target second path also includes the third IGP domain identifier, and the routing prefix information including the third IGP domain identifier in the routing prefix information set does not include the node identifier of the end node on the target second path, the control device determines that the path to be restored includes the target second path and at least one third path connected end to end to each other, and the end node on the target second path is the starting node of the first third path of the at least one third path connected end to end to each other.

[0081] Among them, different third paths are located in different IGP domains, and the IGP domain identifiers corresponding to the nodes between the starting node and the end node on each third path only include one IGP domain identifier; the end node of each third path is determined by the routing prefix information determined from the routing prefix information set according to the IGP domain identifier corresponding to the starting node of each third path and the destination IP address, and each third path is determined according to the link information between the starting node of the third path and the end node of the third path, combined with the shortest path algorithm; the IGP domain identifier corresponding to the end node of the last third path only includes one IGP domain identifier; or, or, the end node of the last third path corresponds to the fourth IGP domain identifier, the fourth IGP domain identifier is different from the IGP domain identifiers corresponding to the nodes other than the end node on the last third path, and there is routing prefix information in the routing prefix information set that includes the fourth IGP domain identifier and the node identifier of the end node of the last third path; or, there is no routing prefix information in the routing prefix information set that includes the fourth IGP domain identifier and the destination IP address that satisfies the longest routing prefix matching rule.

[0082] S65. First, when the second intermediate node between the starting node and the end node on the target second path corresponds to multiple IGP domain identifiers, the control device determines the second sub-path in the target second path, the starting node of the second sub-path is the source node, and the end node of the second sub-path is the second intermediate node. The IGP domain identifiers corresponding to the nodes other than the source node and the second intermediate node on the second sub-path only include the second IGP domain identifier. Afterwards, the control device determines that the path to be restored includes the second sub-path and at least one third path connected end to end to each other, and the end node on the second sub-path is the starting node of the first third path in at least one third path connected end to end to each other. Among them, the relevant content of the third path can refer to the above description, which will not be repeated here.

[0083] Based on the IP network path restoration method provided by the present application, the control device can restore the network path based on the collected IGP routing prefix information, without the need to collect routing forwarding table information, which greatly reduces the amount of information that the control device needs to collect, can reduce the deployment cost of the solution, and can improve the efficiency of information collection. In addition, since the routing forwarding table is not used for path restoration, there is no need to traverse the full routing table, which can greatly improve the path restoration rate. For example, it is possible to restore tens of millions of routes in minutes.

[0084] The IP network path restoration method provided by this application will be described in detail below in conjunction with a detailed network structure diagram.

[0085] Figure 4 A schematic diagram of the structure of a communication network is shown in FIG. Figure 4As shown, node A is connected to node B and node C respectively, and node B and node C are also connected to node D. Optionally, Figure 4 At least one node in the communication network shown can be connected to a control device ( Figure 4 (not shown) connection, the control device can be used to obtain information in the communication network.

[0086] For example, in Figure 4 In the communication network shown, nodes A, B, C, and D are all in IGP domain 1. Figure 4 The multiple node information obtained in the communication network shown may include: {A1, B1, C1, D1}, where A1 indicates that node A is in IGP domain 1, B1 indicates that node B is in IGP domain 1, C1 indicates that node C is in IGP domain 1, and D1 indicates that node D is in IGP domain 1.

[0087] For example, in Figure 4 In the communication network shown, the link cost between node A and node B is 4, the link cost between node A and node C is 2, the link cost between node B and node D is 5, and the link cost between node C and node D is 3. Based on this, the control device Figure 4 The multiple link information obtained in the communication network shown may include: {AB1:4, AC1:2, BD1:5, CD1:3}. AB1:4 indicates that link AB is in IGP domain 1, and the link cost is 4. AC1:2, BD1:5 and CD1:3 can refer to the explanation of AB1:4, which will not be repeated here.

[0088] Optionally, each node in the IGP domain may publish a routing prefix in the IGP domain in which it is located. The routing prefix is ​​used for addressing of network nodes. The routing prefix published by each node may be one or more. Figure 4 In the communication network shown, node A can publish the routing prefix: 10.0.0.0 / 24 in IGP domain 1, and the corresponding metric value is a. Node B can publish the routing prefix: 10.0.1.0 / 24 in IGP domain 1, and the corresponding metric value is b. Node C can publish the routing prefix: 10.0.2.0 / 24 in IGP domain 1, and the corresponding metric value is c. Node D can publish the routing prefix: 10.0.3.0 / 24 in IGP domain 1, and the corresponding metric value is d.

[0089] Based on the route prefix published above, the control device Figure 4The multiple routing prefix information obtained in the communication network shown may include: {A1_10.0.0.0 / 24_a, B1_10.0.1.0 / 24_b, C1_10.0.2.0 / 24_c, D1_10.0.3.0 / 24_d}. Among them, A1_10.0.0.0 / 24_a indicates that node A has published the routing prefix 10.0.0.0 / 24 in IGP domain 1, and the corresponding metric value is a. B1_10.0.1.0 / 24_b, C1_10.0.2.0 / 24_c, and D1_10.0.3.0 / 24_d can refer to the explanation of A1_10.0.0.0 / 24_a, which will not be repeated here.

[0090] With the above Figure 4 Taking the communication network and its configuration shown in the figure as an example, it is assumed that the source node of the network path to be restored obtained by the control device is node A, and the destination IP address is 10.0.3.1. The control device can restore the network path based on the node information, link information, and routing prefix information it collects. The restoration process may include the following steps:

[0091] 1. The control device starts calculating the route with node A as the starting point. The control device matches the longest route prefix in IGP domain 1 where node A is located based on the multiple route prefix information it obtains and the destination IP address "10.0.3.1".

[0092] The routing prefix information that successfully matches the destination IP address "10.0.3.1" in IGP domain 1 may be "D1_10.0.3.0 / 24_d". The routing prefix information "D1_10.0.3.0 / 24_d" corresponds to node D and IGP domain 1. This means that node A can address the destination IP address "10.0.3.1" through node D in IGP domain 1.

[0093] 2. The control device determines the shortest path for node A to address the destination IP address "10.0.3.1" in IGP domain 1.

[0094] Node A can address the destination IP address "10.0.3.1" through node D in IGP domain 1. The control device can calculate the shortest path from node A to node D in IGP domain 1 as: A→C→D based on the link information it obtains and the shortest path algorithm. This path is the shortest path for node A to address the destination IP address "10.0.3.1" in IGP domain 1.

[0095] 3. The control device detects whether the path A→C→D is the real forwarding path for node A to address the destination IP address "10.0.3.1".

[0096] Since node C is only in IGP domain 1, node C is a real forwarding node, and the path A→C→D is the real forwarding path for node A to address the destination IP address "10.0.3.1".

[0097] 4. Since node D is only in IGP domain 1, the control device can determine that the destination node corresponding to the destination IP address "10.0.3.1" is node D, and the path calculation is completed.

[0098] Therefore, the network path from source node A to destination IP address "10.0.3.1" restored by the control device is: A→C→D.

[0099] Figure 5 is a schematic diagram of the structure of another communication network, such as Figure 5 As shown, node A is connected to node B and node C respectively, node B and node C are also connected to node D, node D is also connected to node E and node F respectively, and node E is also connected to node F. Optionally, Figure 5 At least one node in the communication network shown can be connected to a control device ( Figure 5 (not shown) connection, the control device can be used to obtain information in the communication network.

[0100] For example, in Figure 5 In the communication network shown, nodes A, B, and C are in IGP domain 1, and nodes E and F are in IGP domain 2. Node D is in both IGP domain 1 and IGP domain 2, and is a routing device across IGP domains. Figure 5 The multiple node information obtained in the communication network shown may include: {A1, B1, C1, D1, D2, E2, F2}, where A1 indicates that node A is in IGP domain 1, B1 indicates that node B is in IGP domain 1, C1 indicates that node C is in IGP domain 1, D1 indicates that node D is in IGP domain 1, D2 indicates that node D is in IGP domain 2, E2 indicates that node E is in IGP domain 2, and F2 indicates that node F is in IGP domain 2.

[0101] For example, in Figure 5 In the communication network shown, the link cost between node A and node B is 4, the link cost between node A and node C is 2, the link cost between node B and node D is 5, the link cost between node C and node D is 3, the link cost between node D and node E is 3, the link cost between node D and node F is 3, and the link cost between node F and node E is 4. Based on this, the control device is Figure 4The multiple link information obtained in the communication network shown may be: {AB1:4, AC1:2, BD1:5, CD1:3, DE2:3, DF2:3, FE2:4}. AB1:4 indicates that link AB is in IGP domain 1, and the link cost is 4. AC1:2, BD1:5, CD1:3, DE2:3, DF2:3, and FE2:4 can refer to the explanation of AB1:4, which will not be repeated here.

[0102] Optionally, each node in the IGP domain may publish a routing prefix in the IGP domain in which it is located. The routing prefix is ​​used for addressing of network nodes. The routing prefix published by each node may be one or more. Figure 5 In the communication network shown, node A can publish the routing prefix: 10.0.0.0 / 24 in IGP domain 1, and the corresponding metric is a. Node B can publish the routing prefix: 10.0.1.0 / 24 in IGP domain 1, and the corresponding metric is b. Node C can publish the routing prefix: 10.0.2.0 / 24 in IGP domain 1, and the corresponding metric is c. Node D can publish the routing prefix: 10.0.3.0 / 24 in IGP domain 1 and IGP domain 2, and the corresponding metric is d. Node E can publish the routing prefix: 192.168.1.0 / 24 in IGP domain 2, and the corresponding metric is e. Node F can publish the routing prefix: 192.168.2.0 / 24 in IGP domain 2, and the corresponding metric is f.

[0103] Optionally, Figure 5The IGP domains 1 and 2 in the IGP domain run the same IGP protocol. Node D can also publish the routing prefixes it obtains from IGP domain 1 to IGP domain 2, and publish the routing prefixes it obtains from IGP domain 2 to IGP domain 1. For example, node D can publish the routing prefix 10.0.0.0 / 24 published by node A in IGP domain 1 in IGP domain 2. The metric value corresponding to the routing prefix 10.0.0.0 / 24 published by node D in IGP domain 2 is a`, which is determined based on the metric value a and the path cost between node D and node A. Node D can publish the routing prefix 10.0.1.0 / 24 published by node B in IGP domain 1 in IGP domain 2. The metric value corresponding to the routing prefix 10.0.1.0 / 24 published by node D in IGP domain 2 is b`, which is determined based on the metric value b and the path cost between node D and node B. Node D can publish the routing prefix 10.0.2.0 / 24 published by node C in IGP domain 1 in IGP domain 2. The metric value corresponding to the routing prefix 10.0.2.0 / 24 published by node D in IGP domain 2 is c`, which is determined based on the metric value c and the path cost between node D and node C. Node D can publish the routing prefix 192.168.1.0 / 24 published by node E in IGP domain 2 in IGP domain 1. The metric value corresponding to the routing prefix 192.168.1.0 / 24 published by node D in IGP domain 1 is e`, which is determined based on the metric value e and the path cost between node D and node E. Node D can publish the routing prefix 192.168.2.0 / 24 advertised by node F in IGP domain 2 in IGP domain 1. The metric value corresponding to the routing prefix 192.168.2.0 / 24 advertised by node D in IGP domain 1 is f`. f` is determined based on the metric value f and the path cost between node D and node F.

[0104] Based on the route prefix published above, the control device Figure 5The multiple routing prefix information obtained in the communication network shown may include: {A1_10.0.0.0 / 24_a, B1_10.0.1.0 / 24_b, C1_10.0.2.0 / 24_c, D1_10.0.3.0 / 24_d, D1_192.168.1.0 / 24_e`, D1_192.168.2.0 / 24_f`, D2_10.0.3.0 / 24_d, E2_192.168.1.0 / 24_e, F2_192.168.2.0 / 24_f, D2_10.0.0.0 / 24_a`, D2_10.0.1.0 / 24_b`, D2_10.0.2.0 / 24_c`}. A1_10.0.0.0 / 24_a indicates that node A advertises the routing prefix 10.0.0.0 / 24 in IGP domain 1, and the corresponding metric is a. B1_10.0.1.0 / 24_b, C1_10.0.2.0 / 24_c, D1_10.0.3.0 / 24_d, D1_192.168.1.0 / 24_e`, D1_192.168.2.0 / 24_f`, D2_10.0.3.0 / 24_d, E2_192.168.1.0 / 24_e, F2_192.168.2.0 / 24_f, D2_10.0.0.0 / 24_a`, D2_10.0.1.0 / 24_b`, and D2_10.0.2.0 / 24_c` can refer to the explanation of A1_10.0.0.0 / 24_a, which is not repeated here.

[0105] With the above Figure 5 Taking the communication network and its configuration shown in the figure as an example, it is assumed that the source node of the network path to be restored obtained by the control device is node A, and the destination IP address is 10.0.3.1. The control device can restore the network path based on the node information, link information, and routing prefix information it collects. The restoration process may include the following steps:

[0106] 1. The control device starts calculating the route with node A as the starting point. The control device matches the longest route prefix in IGP domain 1 where node A is located based on the multiple route prefix information it obtains and the destination IP address "10.0.3.1".

[0107] The destination IP address "10.0.3.1" can match the routing prefix information "D1_10.0.3.0 / 24_d" in IGP domain 1. The routing prefix information "D1_10.0.3.0 / 24_d" corresponds to node D and IGP domain 1. This means that node A can address the destination IP address "10.0.3.1" through node D in IGP domain 1.

[0108] 2. The control device determines the shortest path for node A to address the destination IP address "10.0.3.1" in IGP domain 1.

[0109] Node A can address the destination IP address "10.0.3.1" through node D in IGP domain 1. The control device calculates the shortest path from node A to node D in IGP domain 1 as A→C→D based on the link information it obtains and the shortest path algorithm. This path is the shortest path for node A to address the destination IP address "10.0.3.1" in IGP domain 1.

[0110] 3. The control device detects whether the path A→C→D is the real forwarding path for node A to address the destination IP address "10.0.3.1".

[0111] Since node C is only in IGP domain 1, node C is a real forwarding node, and the path A→C→D is the real forwarding path for node A to address the destination IP address "10.0.3.1".

[0112] 4. Compared with node A, node D has also joined the new IGP domain 2. Therefore, the control device determines that it is necessary to recalculate the route with node D as the starting node. The control device can perform the longest route prefix match in IGP domain 1 and IGP domain 2 where node D is located based on the multiple route prefix information and the destination IP address "10.0.3.1" it obtains.

[0113] The destination IP address "10.0.3.1" may match the routing prefix information "D1_10.0.3.0 / 24_d" in IGP domain 1, and may match the routing prefix information "D2_10.0.3.0 / 24_d" in IGP domain 2.

[0114] In an embodiment of the present application, after matching the routing prefix information, the control device can first mark the routing prefix information issued by the starting node of the route calculation in all the matched routing prefix information as the routing prefix information to be filtered. Afterwards, the control device can filter out all the routing prefix information that is the same as the IGP domain corresponding to the routing prefix information to be filtered in all the matched routing prefix information.

[0115] For example, the routing prefix information "D1_10.0.3.0 / 24_d" and "D2_10.0.3.0 / 24_d" matched by the destination IP address "10.0.3.1" are both routing prefix information published by the starting node D of this path calculation. Therefore, the control device can mark "D1_10.0.3.0 / 24_d" and "D2_10.0.3.0 / 24_d" as routing prefix information to be filtered. Afterwards, the control device filters out the routing prefix information corresponding to the same IGP domain (i.e., IGP domain 1 and IGP domain 2) as "D1_10.0.3.0 / 24_d" and "D2_10.0.3.0 / 24_d" from all routing prefix information matched by the destination IP address "10.0.3.1".

[0116] Based on this example, the control device can filter out "D1_10.0.3.0 / 24_d" and "D2_10.0.3.0 / 24_d". After filtering, there is no remaining routing prefix information. Therefore, the control device can determine that the destination node corresponding to the destination IP address "10.0.3.1" is node D, and the path calculation is completed.

[0117] Therefore, the network path from source node A to destination IP address "10.0.3.1" restored by the control device is: A→C→D.

[0118] Continue with the above Figure 5 Taking the communication network and its configuration shown in the figure as an example, it is assumed that the source node of the network path to be restored obtained by the control device is node A, and the destination IP address is 192.168.1.1. The control device can restore the network path based on the node information, link information and routing prefix information it collects. The restoration process may include the following steps:

[0119] 1. The control device starts to calculate the route starting from Node A. The control device matches the longest route prefix in IGP domain 1 where Node A is located based on the obtained multiple route prefix information and the destination IP address "192.168.1.1".

[0120] The routing prefix information matched to the destination IP address "192.168.1.1" in IGP domain 1 may be "D1_192.168.1.0 / 24_e`". "D1_192.168.1.0 / 24_e`" corresponds to node D and IGP domain 1, which means that node A can address the destination IP address "192.168.1.1" through node E in IGP domain 1.

[0121] 2. The control device determines the shortest path for node A to address the destination IP address "192.168.2.1" in IGP domain 1.

[0122] The control device calculates the shortest path from node A to node D in IGP domain 1 based on the acquired link information and the shortest path algorithm: A→C→D. This path is the shortest path for node A to address the destination IP address "192.168.1.1" in IGP domain 1.

[0123] 3. The control device detects whether the path A→C→D is the real forwarding path for node A to address the destination IP address "192.168.1.1".

[0124] Since node C is only in IGP domain 1, node C is a real forwarding node, and path A→C→D is a real forwarding path for node A to address the destination IP address "192.168.1.1".

[0125] 4. Since node D is in multiple IGP domains, the control device determines that it is necessary to recalculate the route with node D as the starting node. The control device performs the longest route prefix match in IGP domain 1 and IGP domain 2 where node D is located based on the multiple route prefix information it obtains and the destination IP address "192.168.1.1".

[0126] The routing prefix information matched by the destination IP address "192.168.1.1" may include "D1_192.168.1.0 / 24_e" and "E2_192.168.1.0 / 24_e".

[0127] "D1_192.168.1.0 / 24_e`" is the routing prefix information published by node D, and the control device can mark it as the routing prefix information to be filtered. In addition, the control device can filter out the routing prefix information corresponding to the same IGP domain (i.e., IGP domain 1) as "D1_192.168.1.0 / 24_e`" among all the matched routing prefix information.

[0128] Therefore, the control device can filter out "D1_192.168.1.0 / 24_e`" and obtain the remaining routing prefix information "E2_192.168.1.0 / 24_e". "E2_192.168.1.0 / 24_e" corresponds to node E and IGP domain 2, which means that after node A passes through path A→C→D, it still needs to pass through node E in IGP domain 2 to address the destination IP address "192.168.2.1".

[0129] 5. The control device calculates the shortest path from node D to node E in IGP domain 2 based on the acquired link information and the shortest path algorithm: D→E. This path is the shortest path for node A to address the destination IP address "192.168.1.1" in IGP domain 2.

[0130] 6. Since node E is only in IGP domain 2, the control device can determine that the destination node corresponding to the destination IP address "192.168.1.1" is node E, and the path calculation is completed.

[0131] 7. The control device concatenates the two calculated real forwarding paths A→C→D and D→E, and restores the network path from source node A to destination IP address "192.168.1.1" as: A→C→D→E.

[0132] Figure 6 is a schematic diagram of the structure of another communication network, such as Figure 6 As shown, node A is connected to node B and node C respectively, node B and node C are also connected to node D, node D is also connected to node E and node F respectively, and node E is also connected to node F. Optionally, Figure 6 At least one node in the communication network shown can be connected to a control device ( Figure 6 (not shown) connection, the control device is used to obtain information in the communication network.

[0133] For example, in Figure 6 In the communication network shown, node A is located in both IGP domain 1 and IGP domain 2, and node A is a cross-IGP domain routing device. Node B is located in IGP domain 1, and node C is located in IGP domain 2. Node D is located in both IGP domain 1 and IGP domain 2, and node D is a cross-IGP domain routing device. Node E is located in both IGP domain 1 and IGP domain 2, and node E is a cross-IGP domain routing device. Node F is located in IGP domain 2. Thus, the control device is Figure 6 The multiple node information obtained in the communication network shown may include: {A1, A2, B1, C2, D1, D2, E1, E2, F2}. Among them, A1 indicates that node A is in IGP domain 1, A2 indicates that node A is in IGP domain 2, B1 indicates that node B is in IGP domain 1, C2 indicates that node C is in IGP domain 2, D1 indicates that node D is in IGP domain 1, D2 indicates that node D is in IGP domain 2, E1 indicates that node E is in IGP domain 1, E2 indicates that node E is in IGP domain 2, and F2 indicates that node F is in IGP domain 2.

[0134] For example, in Figure 6 In the communication network shown, the link cost between node A and node B is 4, the link cost between node A and node C is 2, the link cost between node B and node D is 5, the link cost between node C and node D is 3, the link cost between node D and node E is 3, the link cost between node D and node F is 3, and the link cost between node F and node E is 4. Based on this, the control device is Figure 4The link information obtained in the communication network shown may include: {AB1:4, AC2:2, BD1:5, CD2:3, DE1:3, DF2:3, FE2:4}. AB1:4 indicates that link AB is in IGP domain 1, and the link cost is 4. AC2:2, BD1:5, CD2:3, DE1:3, DF2:3, and FE2:4 can refer to the explanation of AB1:4, which will not be repeated here.

[0135] Optionally, each node in the IGP domain may publish a routing prefix in the IGP domain in which it is located. The routing prefix is ​​used for addressing of network nodes. The routing prefix published by each node may be one or more. Figure 6 In the communication network shown, node A can publish the routing prefix: 10.0.0.0 / 24 in IGP domain 1 and IGP domain 2, and the corresponding metric is a. Node B can publish the routing prefix: 10.0.1.0 / 24 in IGP domain 1, and the corresponding metric is b. Node C can publish the routing prefix: 10.0.2.0 / 24 in IGP domain 2, and the corresponding metric is c. Node D can publish the routing prefix: 10.0.3.0 / 24 in IGP domain 1 and IGP domain 2, and the corresponding metric is d. Node E can publish the routing prefix: 192.168.1.0 / 24 in IGP domain 1 and IGP domain 2, and the corresponding metric is e. Node F can publish the routing prefix: 192.168.2.0 / 24 in IGP domain 2, and the corresponding metric is f.

[0136] Optionally, Figure 6 IGP domain 1 and IGP domain 2 in the communication network shown run different IGP protocols, for example, IGP domain 1 runs OSPF protocol, and IGP domain 2 runs ISIS protocol. In this case, the routing prefixes published in IGP domain 1 are not interoperable with the routing prefixes published in IGP domain 2, and nodes across IGP domains (such as node A, node D, and node E) will not publish the routing prefixes obtained in one domain to another domain. Thus, the control device Figure 6The routing prefix information obtained in the communication network shown may include: {A1_10.0.0.0 / 24_a, B1_10.0.1.0 / 24_b, D1_10.0.3.0 / 24_d, E1_192.168.1.0 / 24_e, A2_10.0.0.0 / 24_a, C2_10.0.2.0 / 24_c, D2_10.0.3.0 / 24_d, E2_192.168.1.0 / 24_e, F2_192.168.2.0 / 24_f}. Among them, A1_10.0.0.0 / 24_a means that node A has published the routing prefix 10.0.0.0 / 24 in IGP domain 1, and the corresponding metric value is a. For B1_10.0.1.0 / 24_b, D1_10.0.3.0 / 24_d, E1_192.168.1.0 / 24_e, A2_10.0.0.0 / 24_a, C2_10.0.2.0 / 24_c, D2_10.0.3.0 / 24_d, E2_192.168.1.0 / 24_e, and F2_192.168.2.0 / 24_f, refer to the explanation of A1_10.0.0.0 / 24_a and are not repeated here.

[0137] With the above Figure 6 Taking the communication network and its configuration shown in the figure as an example, it is assumed that the source node of the network path to be restored obtained by the control device is node A, and the destination IP address is 192.168.1.1. The control device can restore the network path based on the node information, link information and routing prefix information it collects. The restoration process may include the following steps:

[0138] 1. The control device starts to calculate the route starting from Node A. Based on the obtained multiple route prefix information and the destination IP address "192.168.1.1", the control device performs the longest route prefix match in IGP domain 1 and IGP domain 2 where Node A is located.

[0139] The routing prefix information matched to the destination IP address "192.168.1.1" in IGP domain 1 may be "E1_192.168.1.0 / 24_e". "E1_192.168.1.0 / 24_e" corresponds to node E and IGP domain 1. This means that node A can address the destination IP address "192.168.1.1" through node E in IGP domain 1.

[0140] The routing prefix information matched to the destination IP address "192.168.1.1" in IGP domain 2 may be "E2_192.168.1.0 / 24_e". "E2_192.168.1.0 / 24_e" corresponds to node E and IGP domain 2. This means that node A can address the destination IP address "192.168.1.1" through node E in IGP domain 2.

[0141] 2a. The control device determines the shortest path for node A to address the destination IP address "192.168.1.1" in IGP domain 1.

[0142] Node A can address the destination IP address "192.168.1.1" through node E in IGP domain 1. The control device calculates the shortest path from node A to node E in IGP domain 1 as: A→B→D→E based on the link information it obtains and the shortest path algorithm. This path is the shortest path for node A to address the destination IP address "192.168.1.1" in IGP domain 1.

[0143] The cost of node A for addressing the destination IP address "192.168.1.1" in IGP domain 1 is equal to the sum of the cost of the path A→B→D→E and the metric e, that is, 4+5+3+e=12+e.

[0144] 2b. The control device determines the shortest path for node A to address the destination IP address “192.168.1.1” in IGP domain 2.

[0145] Node A can address the destination IP address "192.168.1.1" through node E in IGP domain 2. The control device calculates the shortest path from node A to node E in IGP domain 2 as A→C→D→F→E based on the link information it obtains and the shortest path algorithm. This path is the shortest path for node A to address the destination IP address "192.168.1.1" in IGP domain 2.

[0146] The cost of node A for addressing the destination IP address "192.168.1.1" in IGP domain 2 is equal to the sum of the cost of the path A→C→D→F→E and the metric e, that is, 2+3+3+4+e=12+e.

[0147] 3. Since the cost of the shortest path for node A to address the destination IP address "192.168.1.1" in IGP domain 1 is 12+e, and the cost of the shortest path for node A to address the destination IP address "192.168.1.1" in IGP domain 2 is also 12+e, the two costs are the same. Therefore, the control device determines that the path A→B→D→E and the path A→C→D→F→E are equal-cost multi-path routing (ECMP) paths for node A to address the destination IP address 192.168.1.1, and the control device will retain both paths.

[0148] Optionally, if the costs of the path A→B→D→E and the path A→C→D→F→E are different, the control device retains the shortest path of the two paths.

[0149] 3a. The control device detects whether the path A→B→D→E is the real forwarding path for node A to address the destination IP address "192.168.1.1".

[0150] Since node B is only in IGP domain 1, node B is a real forwarding node, and path A→B→D is the real forwarding path for node A to address the destination IP address "192.168.1.1".

[0151] Since node D is in multiple IGP domains, the route between node D and node E needs to be recalculated. The control device can determine that the shortest path from node D to node E is D→E based on the link information and the shortest path algorithm. Therefore, the path D→E in the path A→B→D→E is also the real forwarding path for node A to address the destination IP address "192.168.1.1".

[0152] Therefore, the path A→B→D→E is the real forwarding path for node A to address the destination IP address "192.168.1.1".

[0153] 3b. The control device detects whether the path A→C→D→F→E is the real forwarding path for node A to address the destination IP address "192.168.1.1".

[0154] Since node C is only in IGP domain 2, node C is a real forwarding node, and path A→C is a real forwarding path for node A to address the destination IP address "192.168.1.1".

[0155] Since node D is in multiple IGP domains, D→F→E is not necessarily the real forwarding path. Combined with the shortest path from node D to node E calculated in step 3a as D→E, the control device can determine that the real forwarding path corresponding to the path A→C→D→F→E is A→C→D→E.

[0156] Therefore, the path A→C→D→E is the real forwarding path for node A to address the destination IP address "192.168.1.1".

[0157] 4. Since node E is in multiple IGP domains, the control device needs to recalculate the route with node E as the starting node. The control device can match the route prefix information in IGP domain 1 and IGP domain 2 where node E is located according to the acquired route prefix information.

[0158] Since no other routing prefix information except the routing prefix information published by node E is matched, the control device can determine that the destination node corresponding to the destination IP address "192.168.1.1" is node E, and the path calculation is completed.

[0159] Thus, the control device may determine that the network paths from node A to node E may include two: A→B→D→E and A→C→D→E.

[0160] Optionally, in the embodiment of the present application, the control device can restore the network path hop by hop. After the control device calculates the shortest path to the destination IP through the shortest path algorithm, the control device will recalculate the path with the next hop as the starting node, and so on, until the path is calculated to the destination node corresponding to the destination IP. Afterwards, the control device can splice the calculated hop-by-hop paths together to restore the network path from the source node to the destination node.

[0161] For example, Figure 4 Taking the communication network shown in the figure as an example, it is assumed that the source node of the network path to be restored obtained by the control device is node A, and the destination IP address is 10.0.3.1. The control device can restore the network path based on the node information, link information, and routing prefix information it collects. The restoration process may include the following steps:

[0162] 1. The control device starts calculating the route with node A as the starting point. The control device matches the longest route prefix in IGP domain 1 where node A is located based on the multiple route prefix information it obtains and the destination IP address "10.0.3.1".

[0163] The routing prefix information that successfully matches the destination IP address "10.0.3.1" in IGP domain 1 may be "D1_10.0.3.0 / 24_d". The routing prefix information "D1_10.0.3.0 / 24_d" corresponds to node D and IGP domain 1. This means that node A can address the destination IP address "10.0.3.1" through node D in IGP domain 1.

[0164] 2. The control device determines the shortest path for node A to address the destination IP address "10.0.3.1" in IGP domain 1.

[0165] Node A can address the destination IP address "10.0.3.1" through node D in IGP domain 1. The control device can calculate the shortest path from node A to node D in IGP domain 1 as: A→C→D based on the link information it obtains and the shortest path algorithm. This path is the shortest path for node A to address the destination IP address "10.0.3.1" in IGP domain 1.

[0166] 3. The controller recalculates the path with the next hop (i.e., node C) in the path A→C→D as the starting node. The control device performs the longest route prefix match in IGP domain 1 where node C is located based on the multiple route prefix information it obtains and the destination IP address "10.0.3.1".

[0167] The routing prefix information that successfully matches the destination IP address "10.0.3.1" in IGP domain 1 may be "D1_10.0.3.0 / 24_d". The routing prefix information "D1_10.0.3.0 / 24_d" corresponds to node D and IGP domain 1. This means that node C can address the destination IP address "10.0.3.1" through node D in IGP domain 1.

[0168] 4. The control device determines the shortest path for node C to address the destination IP address "10.0.3.1" in IGP domain 1.

[0169] The control device can calculate the shortest path from node C to node D in IGP domain 1 based on the acquired link information and the shortest path algorithm: C→D. This path is the shortest path for node C to address the destination IP address "10.0.3.1" in IGP domain 1.

[0170] 5. The controller recalculates the path with the next hop (i.e., node D) in the path C→D as the starting node. The control device performs the longest route prefix match in IGP domain 1 where node D is located based on the multiple route prefix information it obtains and the destination IP address "10.0.3.1".

[0171] The route prefix information that successfully matches the destination IP address "10.0.3.1" in IGP domain 1 may be "D1_10.0.3.0 / 24_d".

[0172] "D1_10.0.3.0 / 24_d" is the routing prefix information published by node D, and the control device can mark it as the routing prefix information to be filtered. In addition, the control device can filter out the routing prefix information corresponding to the same IGP domain (i.e., IGP domain 1) as "D1_10.0.3.0 / 24_d" among all the matched routing prefix information.

[0173] Therefore, the control device will filter out "D1_10.0.3.0 / 24_d". After filtering, there is no other routing prefix information. Therefore, the control device can determine that node D is the destination node corresponding to the destination IP address "10.0.3.1", and the path calculation is completed.

[0174] 6. The control device stitches together the previously calculated hop-by-hop paths and restores the network path for node A to address the destination IP address "10.0.3.1" as: A→C→D.

[0175] Based on this solution, this embodiment can restore the network path from the source node to the destination IP address by calculating the path hop by hop according to the IGP information.

[0176] It should be understood that the above Figures 4 to 6 The corresponding embodiment is an example of an IGP scenario. The routing prefixes mentioned above all refer to IGP routing prefixes and do not involve BGP routing. Optionally, if nodes in different ASs in the communication network establish a BGP connection, the control device can also obtain the BGP routing prefix in the communication network. The routing prefix information obtained by the control device may include IGP routing prefix information and BGP routing prefix information. Afterwards, the control device can calculate the route based on the BGP routing prefix information and the IGP routing prefix information.

[0177] by Figure 4 As an example, assume that node D establishes a BGP connection with nodes in other ASs. Figure 4 ), then node D can obtain the BGP routing prefixes published by other ASs, and node D can also forward the received BGP routing prefixes to node A, node B and node C.

[0178] For example, the BGP routing prefix information received by node D may be: {172.16.0.0 / 24: 192.168.1.0}, where 172.16.0.0 / 24 is the BGP routing prefix, 192.168.1.1 is the IP address of the next hop corresponding to the BGP routing prefix 172.16.0.0 / 24, and the next hop 192.168.1.1 may be the routing IP address of node D. Assuming that the source node of the network path to be restored obtained by the control device is node A, and the destination IP address is 172.16.0.1, the process of the control device performing network path restoration may include the following:

[0179] 1. The control device starts to calculate the route with Node A as the starting point. The control device matches the longest route prefix based on the multiple route prefix information it obtains and the destination IP address "172.16.0.1", and will match the BGP route prefix information "172.16.0.0 / 24:192.168.1.1". Therefore, the control device can determine that the next hop of the destination IP address "172.16.0.1" is "192.168.1.1".

[0180] 2. The control device continues to perform the longest routing prefix match based on the multiple routing prefix information it obtains and the next-hop IP address "192.168.1.1", and the matched routing prefix information may be "D1_10.0.3.0 / 24_d".

[0181] "D1_10.0.3.0 / 24_d" is the IGP route prefix advertised by node D. The subsequent steps are the same as above. Figure 4 The steps in the corresponding embodiments are the same and will not be repeated here.

[0182] Based on this solution, this embodiment can superimpose BGP routes on IGP routes to perform route calculation, so that a route can be calculated for a destination outside the current AS.

[0183] Optionally, the above-mentioned IP network path restoration method in the embodiment of the present application can be performed by a device, which can be the head node in the above-mentioned method embodiment, or a device including the above-mentioned head node, or a component that can be used for the head node. In order to realize the above-mentioned functions, the device includes a hardware structure and / or software module corresponding to each function. Those skilled in the art should easily realize that, in combination with the units and algorithm steps of each example described in the embodiments disclosed herein, the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is executed in the form of hardware or computer software driving hardware depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present application.

[0184] The embodiment of the present application can divide the functional modules of the device according to the above method embodiment. For example, each functional module can be divided according to each function, or two or more functions can be integrated into one processing module. The above integrated module can be implemented in the form of hardware or in the form of software functional modules. The division of modules in the embodiment of the present application is schematic and is only a logical function division. There may be other division methods in actual implementation.

[0185] Figure 7 A schematic diagram of the structure of a communication device is shown, the communication device 70 comprises a transceiver module 701 and a processing module 702. The transceiver module 701 may also be called a transceiver unit for implementing a transceiver function, for example, a transceiver circuit, a transceiver, a transceiver or a communication interface.

[0186] The transceiver module 701 is used to obtain a node information set, a link information set and a routing prefix information set in the network. The node information in the node information set includes a node identifier and an internal gateway protocol IGP domain identifier corresponding to the node, the link information in the link information set includes a link identifier and a link cost, and the routing prefix information in the routing prefix information set includes a routing prefix, and a node identifier, an IGP domain identifier and a metric value corresponding to the routing prefix. The transceiver module 701 is also used to obtain the identifier of the source node and the destination Internet Protocol IP address of the path to be restored. The processing module 702 is used to determine one or more target routing prefix information from the routing prefix information set according to the destination IP address and one or more IGP domain identifiers corresponding to the source node in the node information set. The routing prefix in one or more target routing prefix information meets the longest prefix matching rule with the destination IP address, and the IGP domain identifier corresponding to the routing prefix in each target routing prefix information is the same as one of the one or more IGP domain identifiers. The processing module 702 is also used to determine the path to be restored based on one or more target routing prefix information, link information between the source node in the link information set and the node identified by the node identifier corresponding to the routing prefix in each target routing prefix information, and the IGP domain identifier corresponding to the routing prefix in each target routing prefix information in the node information set.

[0187] All relevant contents of each step involved in the above method embodiment can be referred to the functional description of the corresponding functional module, which will not be repeated here. Since the communication device 70 provided in this embodiment can execute the above IP network path restoration method, the technical effects that can be obtained can refer to the above method embodiment, which will not be repeated here.

[0188] In this embodiment, the communication device 70 is presented in the form of dividing various functional modules in an integrated manner. The "module" here may refer to a specific ASIC, circuit, processor and memory that executes one or more software or firmware programs, integrated logic circuit, and / or other devices that can provide the above functions.

[0189] Alternatively, if Figure 7 As shown, the transceiver module 701 in the communication device 70 may include an IGP / BGP-LS route receiving module 7011 and a BGP route receiving module 7012. The IGP / BGP-LS route receiving module 7011 is used to receive IGP route information, and the BGP route receiving module 7012 is used to receive BGP route information.

[0190] Figure 8 A schematic diagram of the structure of another communication device provided in an embodiment of the present application, such as Figure 8 As shown, the communication device 80 includes one or more processors 801, a communication line 802, and at least one communication interface ( Figure 8 The communication interface 803 and a processor 801 are used as examples for illustration only. Optionally, a memory 804 may also be included.

[0191] The processor 801 may be a general-purpose central processing unit (CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits for controlling the execution of the program of the present application.

[0192] Communication line 802 may include a pathway for communication between different components.

[0193] The communication interface 803 may be a transceiver module for communicating with other devices or communication networks, such as Ethernet, RAN, wireless local area networks (WLAN), etc. For example, the transceiver module may be a device such as a transceiver or a transceiver. Optionally, the communication interface 803 may also be a transceiver circuit located in the processor 801 to implement signal input and signal output of the processor.

[0194] The memory 804 may be a device with a storage function. For example, it may be a read-only memory (ROM) or other types of static storage devices that can store static information and instructions, a random access memory (RAM) or other types of dynamic storage devices that can store information and instructions, or an electrically erasable programmable read-only memory (EEPROM), a compact disc read-only memory (CD-ROM) or other optical disc storage, optical disc storage (including compressed optical disc, laser disc, optical disc, digital versatile disc, Blu-ray disc, etc.), a magnetic disk storage medium or other magnetic storage device, or any other medium that can be used to carry or store the desired program code in the form of instructions or data structures and can be accessed by a computer, but is not limited thereto. The memory may exist independently and be connected to the processor via a communication line 802. The memory may also be integrated with the processor.

[0195] The memory 804 is used to store computer-executable instructions for executing the solution of the present application, and the execution is controlled by the processor 801. The processor 801 is used to execute the computer-executable instructions stored in the memory 804, thereby implementing the IP network path restoration method provided in the embodiment of the present application.

[0196] Alternatively, optionally, in an embodiment of the present application, the processor 801 may also execute processing-related functions in the IP network path restoration method provided in the following embodiment of the present application, and the communication interface 803 is responsible for communicating with other devices or communication networks, which is not specifically limited in the embodiment of the present application.

[0197] Optionally, the computer-executable instructions in the embodiments of the present application may also be referred to as application code, which is not specifically limited in the embodiments of the present application.

[0198] In a specific implementation, as an embodiment, the processor 801 may include one or more CPUs, such as Figure 8 CPU0 and CPU1 in.

[0199] In a specific implementation, as an embodiment, the device 80 may include multiple processors, such as Figure 8801 and processor 807 in the embodiment. Each of these processors may be a single-core processor or a multi-core processor. The processors here may include but are not limited to at least one of the following: a central processing unit (CPU), a microprocessor, a digital signal processor (DSP), a microcontroller unit (MCU), or an artificial intelligence processor and other types of computing devices running software, each of which may include one or more cores for executing software instructions to perform calculations or processing.

[0200] In a specific implementation, as an embodiment, the apparatus 80 may further include an output device 805 and an input device 806. The output device 805 communicates with the processor 801 and may display information in a variety of ways. For example, the output device 805 may be a liquid crystal display (LCD), a light emitting diode (LED) display device, a cathode ray tube (CRT) display device, or a projector. The input device 806 communicates with the processor 801 and may receive user input in a variety of ways. For example, the input device 806 may be a mouse, a keyboard, a touch screen device, or a sensor device.

[0201] The above-mentioned device 80 may also be sometimes referred to as a communication device, which may be a general device or a dedicated device. For example, the device 80 may be a network device such as a router, a switch, a gateway, or a terminal device, or a controller in a network, or a device having Figure 8 The embodiment of the present application does not limit the type of the device 80.

[0202] Figure 8 The processor 801 in the device 80 shown can call the computer execution instructions stored in the memory 804, so that the device 80 executes the IP network path restoration method in the above method embodiment.

[0203] Since the device 80 provided in this embodiment can execute the above-mentioned IP network path restoration method, the technical effects that can be obtained can refer to the above-mentioned method embodiment and will not be repeated here.

[0204] In various embodiments of the present application, the size of the serial numbers of the above-mentioned processes does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.

[0205] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0206] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0207] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0208] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0209] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.

[0210] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using a software program, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions may be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions may be transmitted from a website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (digital subscriber line, DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center. The computer-readable storage medium may be any available medium that a computer can access or may contain one or more servers, data centers and other data storage devices that can be integrated with the medium. The available medium may be a magnetic medium (eg, a floppy disk, a hard disk, a magnetic tape), an optical medium (eg, a digital versatile disc (DVD)), or a semiconductor medium (eg, a solid state disk (SSD)).

[0211] As used in this application, the terms "component", "module", "system", etc. are intended to refer to a computer-related entity, which can be hardware, firmware, a combination of hardware and software, software, or software in operation. For example, a component can be, but is not limited to: a process running on a processor, a processor, an object, an executable file, a thread in execution, a program, and / or a computer. As an example, an application running on a computing device and the computing device can both be components. One or more components can exist in a process and / or thread in execution, and a component can be located in a computer and / or distributed between two or more computers. In addition, these components can be executed from various computer-readable media with various data structures thereon. These components can communicate in a local and / or remote process manner, such as according to a signal with one or more data packets (for example, data from a component that interacts with another component in a local system, a distributed system, and / or interacts with other systems in a signal manner through a network such as the Internet).

[0212] The present application presents various aspects, embodiments, or features around a system that may include multiple devices, components, modules, etc. It should be understood and appreciated that each system may include additional devices, components, modules, etc., and / or may not include all of the devices, components, modules, etc. discussed in conjunction with the figures. In addition, combinations of these schemes may also be used.

[0213] In addition, in the embodiments of the present application, the word "exemplary" is used to indicate an example, illustration or description. Any embodiment or design described as "exemplary" in the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of the word "exemplary" is intended to present concepts in a concrete way.

[0214] In the embodiments of the present application, information, signal, message, and channel can sometimes be used interchangeably. It should be noted that when the distinction between them is not emphasized, the meanings they intend to express are consistent. "of", "corresponding, relevant" and "corresponding" can sometimes be used interchangeably. It should be noted that when the distinction between them is not emphasized, the meanings they intend to express are consistent. "System" and "network" can sometimes be used interchangeably. When the distinction between them is not emphasized, the meanings they intend to express are consistent. For example, "communication network" also refers to "communication system".

[0215] The network architecture and business scenarios described in the embodiments of the present application are intended to more clearly illustrate the technical solutions of the embodiments of the present application, and do not constitute a limitation on the technical solutions provided in the embodiments of the present application. A person of ordinary skill in the art can appreciate that with the evolution of the network architecture and the emergence of new business scenarios, the technical solutions provided in the embodiments of the present application are also applicable to similar technical problems.

[0216] 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 who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. A method for restoring an IP network path, characterized in that: The method comprises: The control device acquires a node information set, a link information set, and a routing prefix information set in the network, wherein the node information in the node information set includes a node identifier and an internal gateway protocol IGP domain identifier corresponding to the node, the link information in the link information set includes a link identifier and a link cost, and the routing prefix information in the routing prefix information set includes a routing prefix, and a node identifier, an IGP domain identifier, and a metric value corresponding to the routing prefix; The control device obtains the identifier of the source node and the destination Internet Protocol IP address of the path to be restored; The control device determines one or more target routing prefix information from the routing prefix information set according to the destination IP address and one or more IGP domain identifiers corresponding to the source node in the node information set; the routing prefixes in the one or more target routing prefix information and the destination IP address meet the longest prefix matching rule, and the IGP domain identifier corresponding to each routing prefix in the target routing prefix information is the same as one of the one or more IGP domain identifiers; The control device determines the path to be restored based on the one or more target routing prefix information, the link information between the source node in the link information set and the node identified by the node identifier corresponding to the routing prefix in each target routing prefix information in the node information set, and the IGP domain identifier corresponding to the routing prefix in each target routing prefix information in the node information set.

2. The method according to claim 1, characterized in that The IGP domain identifier corresponding to the source node in the node information set includes a first IGP domain identifier, the one or more target routing prefix information includes at least one first-type target routing prefix information, and the IGP domain identifier corresponding to the routing prefix in the first-type target routing prefix information is the first IGP domain identifier; The control device determines the path to be restored according to the one or more target routing prefix information, the link information between the source node in the link information set and the node identified by the node identifier corresponding to the routing prefix in each target routing prefix information, and the IGP domain identifier corresponding to the routing prefix in each target routing prefix information in the node information set, including: The control device determines at least one first path according to the at least one first-type target routing prefix information, each first path corresponds to one first-type target routing prefix information; the starting node of the first path is the source node, and the end node of the first path is the node identified by the node identifier in the first-type target routing prefix information corresponding to the first path; the IGP domain identifier corresponding to the node on the first path includes the first IGP domain identifier; The control device determines a target first path from the at least one first path; when there are multiple first paths, the sum of the cost of the target first path and the metric value in the first type of target routing prefix information corresponding to the target first path is less than or equal to the sum of the cost of any first path other than the target first path among the at least one first path and the metric value in the first type of target routing prefix information corresponding to the any first path; The control device determines the path to be restored according to the target first path, the link information corresponding to the target first path in the link information set, and the IGP domain identifiers corresponding to the nodes on the target first path in the node information set.

3. The method according to claim 2, characterized in that The IGP domain identifier corresponding to the source node in the node information set also includes a second IGP domain identifier, the one or more target routing prefix information includes at least one second-type target routing prefix information, and the IGP domain identifier corresponding to the routing prefix in the second-type target routing prefix information is the second IGP domain identifier; the method further includes: The control device determines at least one second path according to the at least one second-type target routing prefix information, each second path corresponds to one second-type target routing prefix information; the starting node of the second path is the source node, and the end node of the second path is the node identified by the node identifier in the second-type target routing prefix information corresponding to the second path; the IGP domain identifier corresponding to the node on the second path includes the second IGP domain identifier; The control device determines a target second path from the at least one second path; when there are multiple second paths, the sum of the cost of the target second path and the metric value in the second type target routing prefix information corresponding to the target second path is less than or equal to the sum of the cost of any second path other than the target second path among the multiple second paths and the metric value in the second type target routing prefix information corresponding to the any second path; The control device determines the path to be restored according to the target first path, the link information corresponding to the target first path in the link information set, and the IGP domain identifier corresponding to the node on the target first path in the node information set, including: When the sum of the cost of the target first path and the metric value in the first type of target routing prefix information corresponding to the first path is less than or equal to the sum of the cost of the target second path and the metric value in the second target routing prefix information corresponding to the target second path, the control device determines the path to be restored based on the target first path, the link information corresponding to the target first path in the link information set, and the IGP domain identifier corresponding to the node on the target first path in the node information set.

4. The method according to claim 2 or 3, characterized in that: The control device determines the path to be restored according to the target first path, the link information corresponding to the target first path in the link information set, and the IGP domain identifier corresponding to the node on the first path in the node information set, including: In a case where the IGP domain identifiers corresponding to the nodes other than the starting node on the target first path include only the first IGP domain identifier, the control device determines that the end node on the target first path is the destination node, and determines that the target first path is the path to be restored; Alternatively, in the case where the IGP domain identifiers corresponding to the nodes other than the start node and the end node on the target first path include only the first IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target first path also includes a third IGP domain identifier, and the routing prefix information set includes routing prefix information including the third IGP domain identifier and the node identifier of the end node on the target first path, the control device determines that the end node of the target first path is the destination node, and determines that the target first path is the path to be restored; Alternatively, when the IGP domain identifiers corresponding to the nodes other than the start node and the end node on the target first path only include the first IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target first path also includes a third IGP domain identifier, and there is no routing prefix information including the third IGP domain identifier in the routing prefix information set that satisfies the longest routing prefix matching rule with the destination IP address, the control device determines that the end node of the target first path is the destination node, and determines that the target first path is the path to be restored; Alternatively, in the case where the IGP domain identifiers corresponding to the nodes other than the starting node and the end node on the target first path only include the first IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target first path also includes a third IGP domain identifier, and the routing prefix information set includes routing prefix information including the third IGP domain identifier and the node identifier of the end node on the target first path, the control device determines that the path to be restored includes the target first path and at least one third path connected end to end to each other, and the end node on the target first path is the starting node of the first third path of the at least one third path connected end to end to each other; wherein different third paths are located in different IGP domains, and the IGP domain identifiers corresponding to the nodes between the starting node and the end node on each third path only include one IGP domain identifier; and each end node of the third path is determined according to each third path. The IGP domain identifier corresponding to the starting node of the path and the destination IP address are determined from the routing prefix information determined in the routing prefix information set, and each of the third paths is determined based on the link information between the starting node of the third path and the end node of the third path, combined with the shortest path algorithm; the IGP domain identifier corresponding to the end node of the last third path only includes one IGP domain identifier; or, the end node of the last third path corresponds to the fourth IGP domain identifier, and the fourth IGP domain identifier is different from the IGP domain identifier corresponding to the node other than the end node on the last third path, and the routing prefix information set includes the fourth IGP domain identifier and the node identifier of the end node of the last third path; or, the routing prefix information set does not include the routing prefix information including the fourth IGP domain identifier, and the destination IP address satisfies the longest routing prefix matching rule.

5. The method according to any one of claims 2 to 4, characterized in that: The control device determines the path to be restored according to the target first path, the link information corresponding to the target first path in the link information set, and the IGP domain identifier corresponding to the node on the first path in the node information set, including: In a case where a first intermediate node between a start node and an end node on the target first path corresponds to a plurality of IGP domain identifiers, the control device determines a first subpath in the target first path, the start node of the first subpath being the source node, and the end node of the first subpath being the first intermediate node; the IGP domain identifiers corresponding to nodes on the first subpath other than the source node and the first intermediate node only include the first IGP domain identifier; The control device determines that the path to be restored includes the first sub-path and at least one third path connected end to end to each other, and the end node on the first sub-path is the starting node of the first third path in the at least one third path connected end to end to each other; wherein different third paths are located in different IGP domains, and the IGP domain identifiers corresponding to the nodes between the starting node and the end node on each of the third paths only include one IGP domain identifier; the end node of each of the third paths is determined according to the routing prefix information determined from the routing prefix information set based on the IGP domain identifier corresponding to the starting node of each of the third paths and the destination IP address, and each of the third paths is determined according to the starting node and the end node of the third path. The link information between the end nodes of the third path is determined in combination with the shortest path algorithm; the IGP domain identifier corresponding to the last end node of the third path includes only one IGP domain identifier; or, the last end node of the third path corresponds to a fourth IGP domain identifier, and the fourth IGP domain identifier is different from the IGP domain identifier corresponding to the last node other than the end node on the third path, and the routing prefix information set includes the fourth IGP domain identifier and the node identifier of the last end node of the third path; or, the routing prefix information set does not include the routing prefix information including the fourth IGP domain identifier, and the routing prefix information satisfies the longest routing prefix matching rule with the destination IP address.

6. The method according to claim 3, characterized in that The method further comprises: When the sum of the cost of the target second path and the metric value corresponding to the routing prefix in the first type of target routing prefix information corresponding to the end node on the target second path is less than or equal to the sum of the cost of the target first path and the metric value in the first type of target routing prefix information corresponding to the end node on the target first path, the control device determines the path to be restored based on the target second path and the IGP domain identifier corresponding to the node on the target second path in the node information set.

7. The method according to claim 6, characterized in that The control device determines the path to be restored according to the target second path, the link information corresponding to the target second path in the link information set, and the IGP domain identifier corresponding to the node on the second path in the node information set, including: In a case where the IGP domain identifiers corresponding to the nodes other than the starting node on the target second path include only the second IGP domain identifier, the control device determines that the end node on the target second path is the destination node, and determines that the target second path is the path to be restored; Alternatively, in the case where the IGP domain identifiers corresponding to the nodes other than the start node and the end node on the target second path only include the second IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target second path also includes a third IGP domain identifier, and the routing prefix information set includes routing prefix information including the third IGP domain identifier and the node identifier of the end node on the target first path, the control device determines that the end node of the target second path is the destination node, and determines that the target second path is the path to be restored; Alternatively, when the IGP domain identifiers corresponding to the nodes other than the start node and the end node on the target second path only include the second IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target second path also includes a third IGP domain identifier, and there is no routing prefix information including the third IGP domain identifier in the routing prefix information set that satisfies the longest routing prefix matching rule with the destination IP address, the control device determines that the end node of the target second path is the destination node, and determines that the target second path is the path to be restored; Alternatively, in the case where the IGP domain identifiers corresponding to the nodes other than the starting node and the end node on the target second path only include the second IGP domain identifier, and the IGP domain identifier corresponding to the end node on the target second path also includes the third IGP domain identifier, and the routing prefix information including the third IGP domain identifier in the routing prefix information set does not include the node identifier of the end node on the target second path, the control device determines that the path to be restored includes the target second path and at least one third path connected end to end to each other, and the end node on the target second path is the starting node of the first third path of the at least one third path connected end to end to each other; wherein different third paths are located in different IGP domains, and the IGP domain identifiers corresponding to the nodes between the starting node and the end node on each third path only include one IGP domain identifier; and the end node of each third path is determined according to each third path. The IGP domain identifier corresponding to the starting node of the third path and the destination IP address are determined from the routing prefix information determined in the routing prefix information set, and each of the third paths is determined based on the link information between the starting node of the third path and the end node of the third path, combined with the shortest path algorithm; the IGP domain identifier corresponding to the end node of the last third path only includes one IGP domain identifier; or, or, the end node of the last third path corresponds to a fourth IGP domain identifier, and the fourth IGP domain identifier is different from the IGP domain identifier corresponding to the node other than the end node on the last third path, and there is routing prefix information including the fourth IGP domain identifier and the node identifier of the end node of the last third path in the routing prefix information set; or, there is no routing prefix information including the fourth IGP domain identifier in the routing prefix information set that satisfies the longest routing prefix matching rule with the destination IP address.

8. The method according to claim 6 or 7, characterized in that: The control device determines the path to be restored according to the target second path, the link information corresponding to the target second path in the link information set, and the IGP domain identifier corresponding to the node on the second path in the node information set, including: In a case where a second intermediate node between a start node and an end node on the target second path corresponds to a plurality of IGP domain identifiers, the control device determines a second subpath in the target second path, the start node of the second subpath being the source node, and the end node of the second subpath being the second intermediate node; the IGP domain identifiers corresponding to nodes on the second subpath other than the source node and the second intermediate node only include the second IGP domain identifier; The control device determines that the path to be restored includes the second sub-path and at least one third path connected end to end, and the end node on the second sub-path is the starting node of the first third path in the at least one third path connected end to end; wherein different third paths are located in different IGP domains, and the IGP domain identifier corresponding to the node between the starting node and the end node on each of the third paths only includes one IGP domain identifier; the end node of each of the third paths is determined by the routing prefix information determined from the routing prefix information set according to the IGP domain identifier corresponding to the starting node of each of the third paths and the destination IP address, and each of the third paths is determined according to the starting node and the end node of the third path. The link information between the end nodes of the third path is determined in combination with the shortest path algorithm; the IGP domain identifier corresponding to the last end node of the third path includes only one IGP domain identifier; or, or, the last end node of the third path corresponds to a fourth IGP domain identifier, and the fourth IGP domain identifier is different from the IGP domain identifier corresponding to the last node on the third path except the end node, and the routing prefix information set includes the fourth IGP domain identifier and the node identifier of the last end node of the third path; or, the routing prefix information set does not include the routing prefix information including the fourth IGP domain identifier, and the routing prefix information satisfies the longest routing prefix matching rule with the destination IP address.

9. A communication device, characterized in that: The communication device comprises: a processor and a memory; The memory is used to store computer program instructions. When the processor executes the computer program instructions, the communication device executes the method according to any one of claims 1 to 8.

10. A computer-readable storage medium, characterized in that: A computer program is stored thereon, and when the computer program is executed by a computer, the computer is caused to execute the method according to any one of claims 1 to 8.