Method, device, equipment and system for forwarding message, chip and storage medium

By perceiving the abnormal link in the communication network, determining the new forwarding path and forwarding messages, the problem that the abnormal link affects the forwarding of messages is solved, and the reliability and success rate of forwarding are improved.

CN119865455APending Publication Date: 2025-04-22HUAWEI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311376037.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-10-20
Publication Date
2025-04-22

AI Technical Summary

Technical Problem

In a communication network, when there is an abnormal link, how to effectively forward packets to ensure the reliability and success rate of forwarding?

Method used

When the first node perceives the abnormal link, a new forwarding path from the first node to the second node is determined, and the packet is forwarded according to the new forwarding path, the impact of the abnormal link is avoided.

Benefits of technology

Improve the reliability and success rate of packet forwarding, ensure that packets can be delivered normally, and avoid forwarding failures caused by abnormal links.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119865455A_ABST
    Figure CN119865455A_ABST
Patent Text Reader

Abstract

The invention discloses a message forwarding method, device, equipment and system, a chip and a storage medium, and belongs to the technical field of communication. The abnormal area comprises N nodes, an abnormal link exists among the N nodes, a first node in the N nodes determines a second node located on a first forwarding path of the message in the N nodes after acquiring the message, and determines a second forwarding path from the first node to the second node under the condition of sensing the abnormal link, and forwarding the message according to the second forwarding path. Wherein the first node is the first node in the nodes overlapped with the N nodes on the first forwarding path of the message, and the second node is the node used for leaving the abnormal area in the nodes overlapped with the N nodes on the first forwarding path, or the second node is the last node in the nodes overlapped with the N nodes on the first forwarding path. The second forwarding path is not interfered by an abnormal link, so that the reliability of forwarding the message according to the second forwarding path is relatively high.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of communication technology, and in particular to a method, device, equipment, system, chip and storage medium for forwarding messages. Background Art

[0002] A communication network includes multiple nodes, and there are links between different nodes. Since links may become abnormal for various reasons and become abnormal links, how to forward messages in the presence of abnormal links has become an urgent problem to be solved. Summary of the invention

[0003] The present application provides a method, device, equipment, system, chip and storage medium for forwarding a message, so as to realize the forwarding of the message in the case of an abnormal link. The technical solution provided by the present application includes the following aspects.

[0004] In the first aspect, a method for forwarding a message is provided. For an abnormal area where there are N nodes, there is an abnormal link between the N nodes. The first node used to execute the method for forwarding the message is one of the N nodes, and the first node can perceive the abnormal link. Based on this, in the method, the first node obtains the message, and the first node is the first node among the nodes that overlap with the N nodes on the first forwarding path of the message. Afterwards, the first node determines the second node among the N nodes that is located on the first forwarding path, and the second node is a node used to leave the abnormal area among the nodes that overlap with the N nodes on the first forwarding path, or the second node is the last node among the nodes that overlap with the N nodes on the first forwarding path. Then, the first node determines the second forwarding path from the first node to the second node when perceiving the abnormal link, and forwards the message according to the second forwarding path.

[0005] The first forwarding path is the original forwarding path of the message, the second forwarding path is the new forwarding path of the message, and the original forwarding path and the new forwarding path include at least the same first node and second node. Since the first node determines a new forwarding path from the first node to the second node when sensing an abnormal link in the abnormal area, the new forwarding path can be prevented from being affected by the abnormal link, so that the reliability of forwarding the message to the second node according to the new forwarding path is higher.

[0006] Furthermore, since the second node is a node that already exists on the original forwarding path, the second node has the ability to process the message and can process the message normally and reasonably. For example, if the processing of the message includes receiving the message, the second node can receive the message normally, thereby improving the success rate of forwarding the message. For another example, if the processing of the message includes forwarding the message, the second node can forward the message along a reasonable path, thereby avoiding forwarding the message along a path with a loop, thereby improving the efficiency of forwarding the message.

[0007] In a possible implementation manner, the first forwarding path is used to forward the message when no abnormal link exists.

[0008] Among them, the absence of an abnormal link may mean the absence of any abnormal link, or it may mean that there is no abnormal link for determining the abnormal area where the first node is located but there are other abnormal links. In other words, when there is a current abnormal link in the abnormal area, the first forwarding path may be affected by the current abnormal link and is not suitable for forwarding messages. In this case, the second forwarding path is used instead of the first forwarding path, which further ensures the reliability and success rate of forwarding messages.

[0009] In a possible implementation, forwarding the message according to the second forwarding path includes: if the second forwarding path is different from the first forwarding path, the first node encapsulates the node information of each node on the second forwarding path into the message to obtain an updated message; and the first node sends the updated message.

[0010] Since the node information of each node on the second forwarding path is encapsulated into the message, the obtained updated message can be sent to the second node strictly according to the second forwarding path. That is to say, the forwarded message includes the update message (that is, the node information of each node is encapsulated into the message) and the sent updated message, thereby avoiding interference of the message due to unexpected situations during forwarding, and ensuring the reliability of the forwarded message.

[0011] In a possible implementation, forwarding the message according to the second forwarding path includes: if the second forwarding path is different from the first forwarding path, the first node encapsulates the node information of the second node into the message to obtain an updated message; and the first node sends the updated message.

[0012] In this way, the node information of all nodes on the second forwarding path does not need to be encapsulated into the message. Instead, the node information of the second node can be encapsulated into the message and then the updated message can be sent. The forwarding message also includes the update message (that is, the node information of the second node is encapsulated into the message) and the updated message. Therefore, the encapsulation pressure can be reduced, the encapsulation efficiency can be improved, and the efficiency of forwarding messages can be improved.

[0013] In a possible implementation, before the first node obtains the message, the method also includes: the first node senses the abnormal link and determines M nodes based on the abnormal link; the first node obtains capability information of the M nodes, where the capability information is used to indicate whether the capability of supporting the abnormal area is available; if it is determined based on the capability information that at least some of the M nodes have the capability of supporting the abnormal area, the first node determines the abnormal area based on the first node and at least some of the nodes.

[0014] Among them, the first node and the M nodes are nodes that should be used to form an abnormal area, but in some cases, such as when the capabilities of different nodes are different due to batch updates of nodes, only some of the M nodes may have the ability to support abnormal areas, and the remaining nodes do not have the ability to support abnormal areas. Even in these cases, the present application can determine the abnormal area, making the method provided by the present application more applicable.

[0015] In a possible implementation, the first node obtains capability information of M nodes, including: for any one of the M nodes, the first node receives a routing publication message sent by any one of the M nodes; the first node obtains the capability information of any one of the nodes according to the capability field in the routing publication message.

[0016] In this implementation, different nodes exchange their own capability information respectively, so that each node can perceive the capability information of all nodes, thereby determining whether each node has the capability to support the abnormal area.

[0017] In a possible implementation, the first node obtains the capability information of M nodes, including: the first node receives a notification message sent by the controller; the first node obtains the capability information of the M nodes according to the capability field in the notification message.

[0018] In this implementation, the controller uniformly collects and sends the capability information of all nodes, so that each node can perceive the capability information of all nodes, thereby determining whether each node has the capability to support the abnormal area.

[0019] In one possible implementation, the method also includes: if the neighbor node of the first node in the abnormal area is unreachable, the first node sends abnormal information of the neighbor node to other nodes outside the first node, and the abnormal information is used by other nodes to confirm that the neighbor node is unreachable and delete the route published by the neighbor node as the source node.

[0020] Among them, the other nodes may be nodes outside the abnormal area. That is to say, when there is an unreachable node in the abnormal area, even the nodes outside the abnormal area can promptly learn about the unreachable node and delete the route published with the unreachable node as the source node accordingly, so as to avoid using the route published with the unreachable node as the source node when subsequently generating a message forwarding path, thereby avoiding including the unreachable node on the subsequently generated message forwarding path.

[0021] In a possible implementation, if there are multiple ordered nodes for leaving the abnormal area among the nodes overlapping with the N nodes on the first forwarding path, the second node is the first node or the last node among the multiple ordered nodes.

[0022] If the message is forwarded according to the first forwarding path, the message may enter and leave the abnormal area multiple times, which is also called a multiple-input multiple-output scenario. The present application provides an optional second node for the multiple-input multiple-output scenario, making the method of forwarding messages more applicable and flexible.

[0023] In one possible implementation, the first node determines a second forwarding path from the first node to the second node when sensing an abnormal link, including: the first node generates a first shortest-path tree (SPT) based on N nodes and the abnormal link; the first node updates the first SPT based on the second SPT to obtain an updated result, and the second SPT is generated in the absence of the abnormal link; the first node determines the second forwarding path from the first node to the second node based on the updated result.

[0024] Compared to jointly generating an SPT based on nodes inside and outside the abnormal area and the links between these nodes, the present application generates the first SPT based only on N nodes in the abnormal area and the links between the N nodes, which can reduce the computational complexity and save computational overhead. After the first SPT is generated, the first SPT is updated according to the previous second SPT, that is, the association relationship between different nodes in the second SPT is selectively migrated to the first SPT to obtain an updated result, so as to accurately determine the second forwarding path from the first node to the second node.

[0025] In one possible implementation, the first node updates the first SPT according to the second SPT to obtain an updated result, including: the first node uses the parent node of the node outside the abnormal area in the second SPT as the parent node of the node outside the abnormal area in the first SPT, and uses the parent nodes of N nodes outside the abnormal area in the second SPT as the parent nodes of N nodes in the first SPT to obtain a transition result; if there are nodes with multiple parent nodes in the transition result, the first node determines the cost values ​​of the multiple parent nodes, updates the transition result according to the cost values, and obtains an updated result, and the cost value of any parent node is used to indicate the cost of reaching the node from the first node through any parent node.

[0026] In this implementation, a node in the transition result may have multiple parent nodes, so the parent nodes are screened according to the cost value of the parent nodes, so that the update result is more concise than the transition result, and the efficiency of determining the second forwarding path according to the update result is higher. For example, when screening the parent nodes, the parent node with a non-maximum cost value can be selected from multiple parent nodes to ensure that the determined second forwarding path is a forwarding path with a lower cost.

[0027] In a possible implementation, the first node updates the first SPT according to the second SPT to obtain an update result, including: the first node uses the parent node of the node outside the abnormal area in the second SPT as the parent node of the node outside the abnormal area in the first SPT to obtain an update result.

[0028] Among them, even if the node in the abnormal area has a parent node outside the abnormal area in the second SPT, the first node may not use such a parent node as the parent node of the node in the abnormal area in the first SPT, so that the node in the abnormal area in the update result only has a parent node in the abnormal area, and does not have a parent node outside the abnormal area, thereby ensuring that the second forwarding path determined by the first node does not include nodes outside the abnormal area, but only includes nodes in the abnormal area. Since the nodes in the abnormal area can all perceive the abnormal link, the reliability of the second forwarding path is guaranteed, and then the reliability of forwarding messages according to the second forwarding path is guaranteed.

[0029] In a second aspect, a device for forwarding a message is provided, the device comprising:

[0030] A forwarding module, used to perform forwarding-related operations in the first aspect or any possible implementation manner of the first aspect;

[0031] A processing module is used to perform other operations other than the forwarding-related operations in the first aspect or any possible implementation manner of the first aspect.

[0032] In one possible implementation, a processing module is used to obtain a message, wherein the first node is the first node among the nodes that overlap with N nodes on a first forwarding path of the message; the processing module is also used to determine a second node among the N nodes that is located on the first forwarding path, wherein the second node is a node that overlaps with the N nodes on the first forwarding path and is used to leave the abnormal area, or the second node is the last node among the nodes that overlap with the N nodes on the first forwarding path; the processing module is also used to determine a second forwarding path from the first node to the second node when an abnormal link is sensed; and the forwarding module is used to forward the message according to the second forwarding path.

[0033] In a possible implementation manner, the first forwarding path is used to forward the message when no abnormal link exists.

[0034] In a possible implementation, the forwarding module is configured to encapsulate node information of each node on the second forwarding path into a message to obtain an updated message if the second forwarding path is different from the first forwarding path; and send the updated message.

[0035] In a possible implementation, the forwarding module is configured to encapsulate the node information of the second node into a message to obtain an updated message if the second forwarding path is different from the first forwarding path; and send the updated message.

[0036] In one possible implementation, the processing module is also used to sense abnormal links and determine M nodes based on the abnormal links; obtain capability information of the M nodes, where the capability information is used to indicate whether the nodes have the capability to support the abnormal area; if it is determined based on the capability information that at least some of the M nodes have the capability to support the abnormal area, determine the abnormal area based on the first node and at least some of the nodes.

[0037] In a possible implementation, the processing module is used to receive a route publishing message sent by any one of the M nodes; and obtain capability information of any one of the nodes according to a capability field in the route publishing message.

[0038] In a possible implementation, the processing module is configured to receive a notification message sent by a controller; and obtain capability information of M nodes according to a capability field in the notification message.

[0039] In one possible implementation, the forwarding module is also used to send abnormal information of the neighbor node to other nodes outside the first node if the neighbor node of the first node in the abnormal area is unreachable. The abnormal information is used by other nodes to confirm that the neighbor node is unreachable and delete the route published by the neighbor node as the source node.

[0040] In a possible implementation, if there are multiple ordered nodes for leaving the abnormal area among the nodes overlapping with the N nodes on the first forwarding path, the second node is the first node or the last node among the multiple ordered nodes.

[0041] In one possible implementation, a processing module is used to generate a first SPT based on N nodes and an abnormal link; update the first SPT based on a second SPT to obtain an update result, and the second SPT is generated in the absence of an abnormal link; and determine a second forwarding path from the first node to the second node based on the update result.

[0042] In one possible implementation, a processing module is used to use the parent node of the node outside the abnormal area in the second SPT as the parent node of the node outside the abnormal area in the first SPT, and use the parent nodes of N nodes outside the abnormal area in the second SPT as the parent nodes of N nodes in the first SPT to obtain a transition result; if there are nodes with multiple parent nodes in the transition result, determine the cost values ​​of the multiple parent nodes, update the transition result according to the cost values, and obtain an updated result, and the cost value of any parent node is used to indicate the cost of reaching the node from the first node through any parent node.

[0043] In a possible implementation, the processing module is used to use the parent node of the node outside the abnormal area in the second SPT as the parent node of the node outside the abnormal area in the first SPT to obtain an update result.

[0044] In a third aspect, a device for forwarding messages is provided, the device comprising a memory and a processor; at least one computer instruction is stored in the memory, and the at least one computer instruction is loaded and executed by the processor, so that the device for forwarding messages implements the method for forwarding messages provided by the first aspect or any possible implementation method of the first aspect.

[0045] Optionally, there are one or more processors and one or more memories.

[0046] Optionally, the memory may be integrated with the processor, or the memory may be provided separately from the processor.

[0047] In a fourth aspect, a computer-readable storage medium is provided, in which at least one computer instruction is stored, and the at least one computer instruction is loaded and executed by a processor to enable a computer to implement the method for forwarding messages provided by the first aspect or any possible implementation method of the first aspect.

[0048] In a fifth aspect, a computer program or a computer program product is provided, and the computer program or the computer program product includes: computer instructions, when the computer instructions are executed by a computer, the computer executes the method for forwarding messages provided by the first aspect or any possible implementation of the first aspect.

[0049] In a sixth aspect, a chip is provided, comprising a processor for calling and executing instructions stored in a memory from the memory, so that a computer equipped with the chip executes the method for forwarding messages provided in the first aspect or any possible implementation of the first aspect.

[0050] In the seventh aspect, another chip is provided, including: an input interface, an output interface, a processor and a memory, wherein the input interface, the output interface, the processor and the memory are connected via an internal connection path, and the processor is used to execute the code in the memory. When the code is executed, a computer equipped with the chip executes the method for forwarding messages provided in the first aspect or any possible implementation of the first aspect.

[0051] In an eighth aspect, a system for forwarding messages is provided, wherein N nodes in the system form an abnormal area, an abnormal link exists between the N nodes, and a first node among the N nodes is used to execute the method for forwarding messages provided by the first aspect or any possible implementation of the first aspect. In the present application, the first node may be any one of the N nodes. The system may also include other nodes outside the N nodes, which are not used to form an abnormal area and are nodes outside the abnormal area.

[0052] It should be understood that the technical effects achieved by the technical solutions provided by the second to eighth aspects of the present application and the corresponding possible implementation methods can be referred to the above description of the technical effects achieved by the technical solutions provided by the first aspect and the corresponding possible implementation methods, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS

[0053] Figure 1 A schematic diagram of an abnormal area provided in an embodiment of the present application;

[0054] Figure 2 A schematic diagram of another abnormal area provided in an embodiment of the present application;

[0055] Figure 3 A schematic diagram of another abnormal area provided in an embodiment of the present application;

[0056] Figure 4 A schematic diagram of another abnormal area provided in an embodiment of the present application;

[0057] Figure 5 A schematic diagram of determining an abnormal area provided in an embodiment of the present application;

[0058] Figure 6 Another schematic diagram for determining an abnormal area provided in an embodiment of the present application;

[0059] Figure 7 A schematic diagram of another method for determining an abnormal area provided in an embodiment of the present application;

[0060] Figure 8 A flowchart of a method for forwarding a message provided in an embodiment of the present application;

[0061] Fig. 9 A schematic diagram of a first forwarding path provided in an embodiment of the present application;

[0062] Fig.10 A schematic diagram of another first forwarding path provided in an embodiment of the present application;

[0063] Fig.11 A schematic diagram of another first forwarding path provided in an embodiment of the present application;

[0064] Fig.12 A schematic diagram of another first forwarding path provided in an embodiment of the present application;

[0065] Fig.13 A schematic diagram of centralized learning capability information provided by an embodiment of the present application;

[0066] Fig.14 A schematic diagram of distributed learning capability information provided in an embodiment of the present application;

[0067] Fig.15 A schematic diagram showing that all nodes in an abnormal area provided in an embodiment of the present application have the ability to support the abnormal area;

[0068] Fig.16 A schematic diagram of an embodiment of the present application providing that some nodes in an abnormal area have the ability to support an area;

[0069] Fig.17 A schematic diagram of another abnormal area provided in an embodiment of the present application;

[0070] Fig.18 A schematic diagram of routing convergence provided in an embodiment of the present application;

[0071] Fig.19 A schematic diagram of an unreachable node provided in an embodiment of the present application;

[0072] Fig. 20 A flowchart for confirming that a node is unreachable provided in an embodiment of the present application;

[0073] Fig.21 A schematic diagram of the structure of a device for forwarding messages provided in an embodiment of the present application;

[0074] Fig. 22 A schematic diagram of the structure of a device for forwarding messages provided in an embodiment of the present application. DETAILED DESCRIPTION

[0075] The terms used in the implementation section of this application are only used to explain the specific embodiments of this application and are not intended to limit this application.

[0076] With the development of communication technology, the scale of communication networks is getting larger and larger, and the number of nodes in communication networks is increasing. In order to facilitate the management of these nodes, the communication network can be divided into different domains to reduce the mutual influence between different domains. If a link in a domain is abnormal, it is not easy to affect the links in other domains. For example, the autonomous system (AS) is one of the domains, also known as the AS domain or the interior gateway protocol (IGP) domain. In the AS domain, the number of nodes is about 1 to 5000.

[0077] However, when there are abnormal links in the domain, it is necessary to flood the abnormal links so that all nodes in the domain can perceive the abnormal links and all nodes complete routing convergence based on the abnormal links. In some scenarios, the abnormal links in the domain may be updated frequently, so the domain needs to frequently flood the abnormal links, and all nodes in the domain frequently perceive the abnormal links and complete routing convergence, which results in high flooding pressure and routing convergence pressure. For example, when the nodes in the domain are used for satellite communications, due to the high dynamics and high abnormality rate of satellites, frequent updates of abnormal links may occur.

[0078] In this regard, an embodiment of the present application proposes an abnormal area. When an abnormal link is generated in a domain (including but not limited to the above-mentioned AS domain or other types of domains), the abnormal area located in the domain is determined based on the abnormal link. The number of nodes in the abnormal area is less than the number of nodes in the domain, that is, the abnormal area only includes some nodes in the domain. Among them, the nodes in the abnormal area will perceive the abnormal link and complete routing convergence based on the abnormal link, while the nodes outside the abnormal area do not need to perceive the abnormal link and complete routing convergence based on the abnormal link. As a result, the number of nodes that need to perform routing convergence in the domain is reduced, and the flooding pressure and routing convergence pressure in the domain are reduced. Next, the process of determining the abnormal area based on the abnormal link is described.

[0079] In the initial state, there are no abnormal links in the domain, the domain has an initial basic topology, and each node in the domain can perceive the initial basic topology. As the nodes in the domain continue to run, the links in the domain may become abnormal for various reasons and become abnormal links. For example, the link itself fails, making the link an abnormal link (also called a faulty link). For another example, the link itself does not fail, but the link is interrupted manually or by an upper node, making the link an abnormal link. For example, when the link needs to be repaired or debugged, or when it is predicted in advance that the link may be abnormal, the link interruption can be controlled. When all abnormal links in the domain are faulty links, the abnormal area can also be called a fault domain.

[0080] After a link becomes abnormal, the nodes at both ends of the abnormal link can detect the existence of the abnormal link, and at least one of the nodes at both ends of the abnormal link will add the abnormal link to its own abnormal link set (the abnormal link set is an empty set in the initial state), and the at least one node determines which nodes in the domain are included in the abnormal area according to the initial basic topology and the abnormal link set. For example, see Figure 1 ,right Figure 1 By superimposing the initial basic topology shown in (1) and the abnormal links included in the abnormal link set, it is possible to determine Figure 1 The abnormal region shown in (2) includes nodes shown by bold lines.

[0081] Exemplarily, in the process of determining which nodes in the domain are included in the abnormal area, one of the nodes at both ends of the abnormal link is used as the starting point, and the other node of the nodes at both ends of the abnormal link is used as the end point. The initial basic topology is combined to traverse and determine whether there is a reference path from the starting point to the end point. If there is no reference path from the starting point to the end point (case 1), it means that there is no reachable path between the starting point and the end point, then the determination of the abnormal area can be abandoned, and all nodes in the domain are aware of the abnormal link (i.e., flooding) and complete routing convergence according to the scheme provided by the relevant technology. If there is only one reference path from the starting point to the end point (case 2), the nodes on the reference path are taken as nodes included in the abnormal area. If there are X (X is greater than or equal to 2) reference paths (case 3), Y reference paths can be selected from the X reference paths according to the link selection principle (Y is greater than or equal to 1, and Y is less than or equal to X), and the nodes on the Y reference paths are taken as nodes included in the abnormal area. Optionally, when Y is greater than or equal to 2, there are disjoint reference paths among the Y reference paths, and the intermediate nodes on the disjoint reference paths (i.e., all nodes on the reference paths except the starting point and the end point) are completely different. In some cases, any two reference paths among the Y reference paths do not intersect.

[0082] In an embodiment of the present application, a traversal may be performed in combination with the initial basic topology to try to determine a reference path from the starting point to the end point. The reference path may be the path with the least number of hops among all paths from the starting point to the end point, that is, the path with the least number of nodes. Alternatively, the reference path may be the path with the least cost among all paths from the starting point to the end point. The cost of a path is equal to the sum of the costs of all links included in the path. The cost of a link may be calculated based on the bandwidth and other characteristics of the link. If such a reference path cannot be determined, proceed to case 1 above. If such a reference path can be determined, continue to assume that the intermediate nodes on this reference path are unreachable, and traverse again in combination with the initial basic topology to try to determine another reference path from the starting point to the end point. If such another reference path cannot be determined, proceed to case 2 above. If such another reference path can be determined, proceed to case 3 above.

[0083] By the methods described in the above paragraphs, at least one of the nodes at both ends of the abnormal link can determine which nodes in the domain are included in the abnormal area, and the abnormal area formed by the determined nodes can provide at least one reachable path for the nodes at both ends of the abnormal link (i.e., the starting point to the end point). For example, see Figure 2 , there is a ring subnetwork in the Internet protocol (IP) radio access network (RAN). When an abnormality occurs in a link in the ring subnetwork, the ring subnetwork constitutes an abnormal area. For another example, see Figure 3 , there are multiple square-shaped sub-networks in the backbone network. When a link in a square-shaped sub-network is abnormal, the square-shaped sub-network and other square-shaped sub-networks together constitute an abnormal area. For another example, Figure 4 As shown, the metropolitan area network includes optical line terminals (OLT), customer premise equipment (CPE), switches, cloud provider edge (PE) nodes, edge leaf nodes, core routers (CR), autonomous system border routers (ASBR), cloud servers, access leaf nodes and spine nodes. When an abnormality occurs in the link between an access leaf node and a spine node, the access leaf node, the spine node and another spine node together constitute an abnormal area.

[0084] Then, for at least one of the nodes at both ends of the abnormal link, the abnormal link can be notified to other nodes except itself in the nodes included in the abnormal area. For example, the abnormal link can be notified to other nodes in a non-repeated diffusion mode, that is, the at least one node notifies the abnormal link to its own neighbor nodes in other nodes, and the neighbor nodes of the at least one node continue to notify the abnormal link to its own neighbor nodes (excluding the at least one node, avoiding repeated notification) in the abnormal area, so that the abnormal link is diffused in the abnormal area until the nodes in the abnormal area all perceive the abnormal link. Thus, even if there is one or some nodes in other nodes that do not belong to the nodes at both ends of the abnormal link, this or these nodes can also perceive the abnormal link. After receiving the notification, other nodes also add the abnormal link of the notification to their own abnormal link set (that is, each node in the abnormal area maintains its own abnormal link set respectively), realizing the synchronization of the abnormal link set between different nodes in the abnormal area. Other nodes also determine which nodes in the domain are included in the abnormal area according to the initial basic topology and the abnormal link set in the manner described above.

[0085] Since different nodes perceive the same initial basic topology and the same abnormal links (i.e., the abnormal links included in the abnormal link sets maintained by each node are the same), and determine which nodes in the domain are included in the abnormal area based on the initial basic topology and the abnormal link set in the same way, the results obtained when different nodes determine which nodes in the domain are included in the abnormal area are the same, or in other words, the abnormal areas determined by different nodes are the same.

[0086] At this point, the determination of the abnormal area in the domain is achieved. Of course, each node in the abnormal area also needs to perform routing convergence according to the nodes and abnormal link sets included in the abnormal area. Among them, the implementation method of routing convergence will be described in the method embodiment below, and will not be repeated here.

[0087] Combination Figure 5 , the process of determining abnormal areas is illustrated with examples.

[0088] like Figure 5 As shown in (1), in the initial state, there is no abnormal link in the domain, and the abnormal link sets of each node (P0 to P11) in the domain are all empty sets. Afterwards, the link between P2 and P8 becomes abnormal and becomes abnormal link P8-P2. P8 detects the abnormal link P8-P2 and adds the abnormal link P8-P2 to the abnormal link set of P8. Then, the abnormal link set of P8 includes {P8-P2}.

[0089] like Figure 5As shown in (2), P8 determines that the abnormal area includes P0, P1, P2, P3, P4, P8, P9 and P10 according to the initial basic topology and the abnormal link P8-P2 included in the abnormal link set, and P8 sets the state of P8 to in, indicating that P8 is located in the abnormal area.

[0090] like Figure 5 As shown in (3), the neighbor nodes of P8 include P0, P2 and P9. According to ①, P8 notifies P0 and P9 of the abnormal link P8-P2, but does not notify P2 of the abnormal link P8-P2, because the link between P2 and P8 is the abnormal link. In addition, according to ②, P0 notifies P1 of the abnormal link, and P9 notifies P10 of the abnormal link. According to ③, P1 notifies P2 of the abnormal link, and P10 notifies P4 of the abnormal link. According to ④, P2 notifies P3 of the abnormal link, and P4 notifies P3 of the abnormal link. For each node among P0, P1, P2, P3, P4, P9 and P10, after receiving the abnormal link P8-P2 notified, the abnormal link is added to its own abnormal link set, and the abnormal area is determined according to the initial basic topology and the abnormal link P8-P2 included in the abnormal link set (the abnormal area is the same as the abnormal area determined by P8), and its own state is set to in, indicating that it is located in the abnormal area.

[0091] In addition, if Figure 5 As shown in (4), the nodes in the abnormal area also perform routing convergence. For example, before routing convergence, the forwarding path from P1 to P11 may be P1 to P2 to P8 to P9 to P10 to P11 (including the abnormal link P8-P2), and after routing convergence, the forwarding path from P1 to P11 may be P1 to P0 to P8 to P9 to P10 to P11 (excluding the abnormal link P8-P2).

[0092] Exemplarily, the node in the abnormal area also records: its own neighboring nodes, abnormal links notified by itself to its own neighboring nodes, and abnormal links notified by its own neighboring nodes to itself. See Table 1 below.

[0093] Table 1

[0094]

[0095]

[0096] After the abnormal area (hereinafter referred to as the original abnormal area, for the convenience of distinguishing different abnormal areas) has been determined based on the abnormal link (hereinafter referred to as the original abnormal link, for the convenience of distinguishing different abnormal links), a new abnormal link may be generated on the basis of the original abnormal area for various reasons, or the original abnormal link may return to normal. Both of these situations belong to the link abnormality in the original abnormal area being updated. When the link abnormality in the original abnormal area is updated, the original abnormal area needs to be updated accordingly to obtain a new abnormal area.

[0097] In the case where a new abnormal link is generated on the basis of the original abnormal area, the nodes at both ends of the new abnormal link perceive the existence of the new abnormal link through detection, and at least one of the nodes at both ends of the new abnormal link adds the new abnormal link to its own abnormal link set including the original abnormal link. After that, the at least one node determines which nodes in the domain are included in the new abnormal area according to the initial basic topology and the abnormal link set (the new abnormal link has been added, thus including the original abnormal link and the new abnormal link). The determination method is the same as the determination method used when determining the nodes included in the original abnormal area above, and will not be repeated here. Among them, the new abnormal area may include the same nodes as the original abnormal area, or the new abnormal area includes more nodes than the original abnormal area. Nodes that are not included in the original abnormal area but included in the new abnormal area are referred to as newly added nodes below.

[0098] At least one of the nodes at both ends of the new abnormal link notifies the new abnormal link and the original abnormal link to the newly added node (also called full diffusion). After receiving the notification, the newly added node adds the new abnormal link and the original abnormal link to its own abnormal link set, which is an empty set, and then determines the nodes included in the new abnormal area according to the initial basic topology and the abnormal link set. At least one of the nodes at both ends of the new abnormal link also notifies the new abnormal link to other nodes other than itself in the nodes included in the original abnormal area (also called incremental diffusion). After receiving the notification, the other nodes add the new abnormal link to their own abnormal link set including the original abnormal link, and then determine the nodes included in the new abnormal area according to the initial basic topology and the abnormal link set. Among them, for the at least one node, the nodes in the abnormal link set that are not an empty set are the nodes included in the original abnormal area, because the abnormal link set of the nodes included in the original abnormal area includes the original abnormal link, and is not an empty set.

[0099] Exemplarily, whether it is full diffusion or incremental diffusion, non-repetitive diffusion can be used. The non-repetitive diffusion method has been described above and will not be repeated here. Through full diffusion and incremental expansion, the nodes in the new abnormal area can all perceive the new abnormal link and the original abnormal link, and the synchronization of the abnormal link set is realized again. The abnormal link sets maintained by different nodes in the new abnormal area include the same abnormal links, and the new abnormal areas determined by different nodes are also the same.

[0100] In addition, the nodes in the new abnormal area will also perform routing convergence. After all nodes in the new abnormal area complete routing convergence, they will be updated from the original abnormal area to the new abnormal area.

[0101] Combination Figure 6 , the process of updating the original abnormal area to the new abnormal area is explained.

[0102] like Figure 6 As shown in (1) in the above Figure 5 Based on the original abnormal area including the original abnormal link P8-P2 as shown in (4), a new abnormal link P4-P6 is generated. P4 in the original abnormal area detects the new abnormal link P4-P6 and adds the abnormal link P4-P6 to the abnormal link set of P4. Then, the abnormal link set of P4 is updated from the previous {P8-P2} to {P8-P2, P4-P6}.

[0103] like Figure 6 As shown in (2), P4 determines that the new abnormal area includes P0 to P6, P8 to P11 according to the initial basic topology and the abnormal link set of P4, including the original abnormal link P8-P2 and the new abnormal link P4-P6. The state of P4 remains in, indicating that P4 is still in the abnormal area.

[0104] like Figure 6As shown in (3), P4's neighbor nodes include P3, P6 and P10. P4 notifies P3 and P10 of the new abnormal link P4-P6, but not P6, because the link between P4 and P6 is the new abnormal link. In addition, P3 notifies P2 of the new abnormal link, P2 notifies P1 of the new abnormal link, P1 notifies P0 of the abnormal link, P0 notifies P8 of the new abnormal link, P10 notifies P9 of the new abnormal link, and P9 notifies P8 of the new abnormal link. These belong to incremental diffusion. After P0 to P3 and P8 to P10 receive the notified new abnormal link, they will add the new abnormal link to the abnormal link set that originally includes the original abnormal link, and determine the new abnormal area (the same as the new abnormal area determined by P4) based on the initial basic topology and the new abnormal link and the original abnormal link included in the abnormal link set. In addition, P3 also notifies P5 of the new abnormal link and the original abnormal link, P10 also notifies P11 of the new abnormal link and the original abnormal link, and P11 and P5 also respectively notify P6 of the new abnormal link and the original abnormal link, which belong to full diffusion. After receiving the notified new abnormal link and the original abnormal link, P5, P6 and P11 will add the new abnormal link and the original abnormal link to the abnormal link set which was originally an empty set, and determine the new abnormal area (the same as the new abnormal area determined by P4) according to the initial basic topology and the new abnormal link and the original abnormal link included in the abnormal link set, and set their own status to in.

[0105] In addition, if Figure 6 As shown in (4), the nodes in the new abnormal area also perform routing convergence.

[0106] Exemplarily, the node in the new abnormal area also records: its neighbor nodes, abnormal links notified by itself to its neighbor nodes, and abnormal links notified by its neighbor nodes to itself. See Table 2 below, where the abnormal links in brackets are the abnormal links newly added to the abnormal link set.

[0107] Table 2

[0108]

[0109]

[0110] When the original abnormal link in the original abnormal area returns to normal and becomes a normal link, the nodes at both ends of the normal link perceive the existence of the normal link through detection, and at least one of the nodes at both ends of the normal link deletes the original abnormal link from its own abnormal link set including the original abnormal link, so that its own abnormal link set is restored to an empty set. Afterwards, the at least one node determines the nodes included in the new abnormal area according to the initial basic topology and the abnormal link set. Since the abnormal link set is an empty set, it is determined that the new abnormal area does not include any nodes, that is, there is no longer an abnormal area in the domain. The at least one node notifies the normal link to other nodes (i.e., nodes in the non-empty set of the abnormal link set) included in the original abnormal area, for example, notifying the normal link in a non-repeated diffusion manner until all other nodes perceive the normal link. After receiving the notification, the other nodes also delete the original abnormal link from their own abnormal link set, thereby realizing the synchronization of the abnormal link set between different nodes in the original abnormal area, and then determine that the new abnormal area does not include any nodes in the domain according to the initial basic topology and the abnormal link set.

[0111] It should be understood that the above text uses the update of the link anomaly in the original abnormal area as an example for explanation. In addition, the link anomaly in the new abnormal area may also be updated, such as generating an updated abnormal link based on the new abnormal area, or a new abnormal link in the new abnormal area or the original abnormal link returning to normal. The method for updating the new abnormal area can refer to the method for updating the original abnormal area above, which will not be repeated here. In a multi-abnormal scenario where the link anomaly is updated multiple times or frequently, a node may repeatedly enter and exit the abnormal area, that is, become a node in the abnormal area and become a node outside the abnormal area alternately, until it becomes stable and the node is fixed to belong to the node in the abnormal area or fixed to belong to the node outside the abnormal area for a period of time. In this multi-abnormal scenario, each time the link anomaly is updated, the relevant nodes will synchronize the abnormal link set according to the above instructions.

[0112] Combination Figure 7 , the process of restoring the new abnormal link in the new abnormal area to normal is explained.

[0113] like Figure 7 As shown in (1), Figure 6 Based on (4), the abnormal link P4-P6 returns to normal. After P6 detects that the abnormal link P4-P6 returns to normal, it deletes the normal link P4-P6 from the abnormal link set of P6. Then the abnormal link set of P6 is updated from {P8-P2, P4-P6} to {P8-P2}. P6 determines the abnormal area based on the initial basic topology and the abnormal link set and updates it to Figure 7The area shown in (2) includes P0, P1, P2, P3, P4, P8, P9 and P10, and P6 sets the state of P6 to out, indicating that P6 is no longer located in the abnormal area.

[0114] P6 notifies P5 and P11 that P4-P6 has returned to normal. P5 and P11 delete P4-P6 from their own abnormal link sets and re-determine Figure 7 The abnormal area shown in (3) in (the same as the abnormal area determined by P6) is set, and its own state is set to out, indicating that it is no longer in the abnormal area.

[0115] In addition, P5 and P11 will continue to notify other nodes such as P3 that P4-P6 have returned to normal, such as Figure 7 As shown in (2), other nodes will also redetermine the abnormal area (the same as the abnormal area determined by P6) after receiving the notification and complete the routing convergence.

[0116] Exemplarily, the node in the abnormal area also records: its neighbor nodes, abnormal links notified by itself to its neighbor nodes, and abnormal links notified by its neighbor nodes to itself. See Table 3 below, where the normal links in brackets in Table 3 are links that need to be deleted (or revoked) from the abnormal link set.

[0117] Table 3

[0118]

[0119] It should be understood that in addition to the abnormality of the links within the domain, the nodes within the domain may also be abnormal and become abnormal nodes. In this regard, it can be considered that the links between the abnormal node and each of its neighboring nodes are abnormal links, and they can be processed according to the above processing method for abnormal links. For example, Figure 7 As shown, if node P8 is an abnormal node, the following links can be considered to be abnormal links: the link between node P8 and neighbor node P0, the link between node P8 and neighbor node P2, and the link between node P8 and neighbor node P9. Of course, when the abnormal link or normal link is diffused in the presence of an abnormal node, the abnormal node itself may be difficult to expand the abnormal link, so the abnormal link can be diffused by the neighbor node of the abnormal node, because the neighbor node of the abnormal node belongs to one of the nodes at both ends of the abnormal link, and according to the above description, at least one of the nodes at both ends of the abnormal link can diffuse the abnormal link. Similarly, after the abnormal node returns to normal and becomes a normal node, it can be considered that the links between the normal node and each of the neighbor nodes of the normal node are restored from abnormal links to normal links.

[0120] It should also be understood that in the determination process and update process of the abnormal area described above, different nodes maintain their own abnormal link set, which is temporary and does not directly cause the initial basic topology in the domain to change. Exemplarily, the embodiment of the present application can detect that an abnormal link is in an abnormal state for more than a certain time, and it is considered that the abnormal link has a permanent abnormality, so that the nodes at both ends of the abnormal link of the permanent abnormality notify that the abnormal link is restored to normal, so that the abnormal link is deleted from the abnormal link set of each node in the abnormal area. On this basis, the abnormal link of the permanent abnormality is synchronized to the initial basic topology, so that the initial basic topology changes, and the domain converges to obtain an updated basic topology. Thus, in the determination process and update process of the subsequent abnormal area, the initial basic topology in the initial state is no longer used, but the updated basic topology is used. Wherein, different basic topologies correspond to different link state databases (link state database, LSDB) and SPT.

[0121] Based on the abnormal area described above, an embodiment of the present application provides a method for forwarding a message, which is applied to a first node, where the first node is one of the N nodes included in the abnormal area, and there are abnormal links between the N nodes. For example, the first node includes but is not limited to a router or other device with routing capabilities. Figure 8 As shown, the method includes the following steps 801 to 804.

[0122] Step 801: A first node obtains a message, where the first node is the first node among the nodes that overlap with N nodes on a first forwarding path of the message.

[0123] The first node may be any one of the N nodes included in the abnormal area. Figure 1 In (2), the N nodes included in the abnormal region are nodes indicated by bold lines, and the first node is any node among the nodes indicated by bold lines. Figure 2 and Figure 3 In , the N nodes included in the abnormal area are the nodes in the dotted box, and the first node is any node in the dotted box. Figure 4 In the example, the N nodes included in the abnormal area are an access leaf node and two spine nodes. The first node can be the access leaf node or any one of the two spine nodes. Figures 1 to 4 The abnormal areas in the illustrated scenario illustrate the first node, but the first node in the embodiment of the present application is not limited to these examples. Figures 1 to 4In the scenario shown, there may be other abnormal areas, and the first node may be any node in the other abnormal areas. Figures 1 to 4 Any node in the abnormal area in other scenarios except

[0124] In an embodiment of the present application, the first node obtaining a message may include two situations. In situation a, the first node in the abnormal area generates a message, and the first node is the source node of the message. In situation b, the node outside the abnormal area generates a message, the node outside the abnormal area is the source node of the message, the node outside the abnormal area sends a message to the first node in the abnormal area, the first node receives the message, so that the message enters the abnormal area, and the first node is the entry node for the message to enter the abnormal area. Exemplarily, when the first node is the entry node for the message to enter the abnormal area, the first node is an edge node in the abnormal area. The embodiment of the present application can ensure that the edge nodes of the abnormal area are reachable nodes in a certain way when generating the abnormal area, so that the first node can normally receive the message sent by the node outside the abnormal area.

[0125] The message acquired by the first node has a first forwarding path, and the first forwarding path includes at least two nodes in order, and there is a point that overlaps with the N nodes included in the abnormal area among the at least two nodes on the first forwarding path. The first node is the first node among the nodes that overlap with the N nodes included in the abnormal area on the first forwarding path. In an exemplary embodiment, the first forwarding path is used to forward the message in the absence of an abnormal link. As mentioned above, there is an abnormal link between the N nodes included in the abnormal area where the first node is located, and the abnormal area where the first node is located is determined according to the abnormal link. For ease of explanation, the abnormal link used to determine the abnormal area where the first node is located is referred to as the current abnormal link. Then, the absence of an abnormal link means that there is no current abnormal link, that is, the first forwarding path is used to forward the message in the absence of a current abnormal link. Exemplarily, the absence of a current abnormal link can mean that there is no abnormal link (such as the initial state above), or it can mean that there are other abnormal links different from the current abnormal link. In the embodiment of the present application, it can be considered that the first forwarding path is the original forwarding path of the message before the current abnormal link is generated.

[0126] For the above situation a, after generating the message, the first node can determine the first forwarding path of the message according to the link abnormality before the current abnormal link, that is, there is no abnormal link or there are other abnormal links different from the current abnormal link. Fig. 9(The current abnormal link is S23 to S33), S33 in the abnormal area generates a message, the source node of the message is S33, the destination node is S31, and the first forwarding path of the message is S33 to S32 to S31. The nodes on the first forwarding path that overlap with the N nodes included in the abnormal area are S33, S32 and S31, and the first node among them is S33. Then the first node is S33 used to generate the message. For another example, refer to Fig.10 (The current abnormal link is the same as Fig. 9 ), S33 in the abnormal area generates a message, the source node of the message is S33, the destination node is S52, and the first forwarding path of the message is S33 to S32 to S42. Then the nodes on the first forwarding path that overlap with the N nodes included in the abnormal area are S33, S32 and S42, among which the first node is S33, then the first node is S33 used to generate the message.

[0127] For the above situation b, after receiving the message, if the message carries the first forwarding path, the first node can read the first forwarding path carried by the message, or if the message does not carry the first forwarding path, the first node can also determine the first forwarding path of the message as in situation a. For example, see Fig.11 (The current abnormal link is S23 to S33), the node S13 outside the abnormal area generates a message, the source node of the message is S13, the destination node is S31, the first forwarding path of the message is S23 to S33 to S32 to S31, then the nodes on the first forwarding path that overlap with the N nodes included in the abnormal area are S23, S33, S32 and S31, the first node of which is S23, then the first node is S23 for receiving the message, that is, the entry node for the message to enter the abnormal area. For another example, see Fig.12 (The current abnormal link is the same as Fig.11 ), the node S13 outside the abnormal area generates a message, the source node S13 of the message, the destination node S52, the first forwarding path of the message is S23 to S33 to S32 to S42, then the nodes on the first forwarding path that overlap with the N nodes included in the abnormal area are S23, S33, S32 and S42, the first node of which is S23, then the first node is S23 for receiving the message, that is, the entry node for the message to enter the abnormal area.

[0128] In an exemplary embodiment, before the first node obtains the message, the method further includes the following steps 8011 to 8013.

[0129] Step 8011: The first node senses an abnormal link and determines M nodes based on the abnormal link.

[0130] The abnormal link perceived by the first node is the current abnormal link mentioned above. According to the above description, when the first node is a node at both ends of the abnormal link, the first node can perceive the abnormal link through detection. When the first node is not a node at both ends of the abnormal link, the first node can receive notifications from the nodes at both ends of the abnormal link, thereby perceiving the abnormal link. After the first node perceives the abnormal link, a plurality of nodes used to constitute an abnormal area are determined based on the abnormal link, and the plurality of nodes include the first node and other nodes except the first node, and the other nodes are M nodes. The manner in which the first node determines a plurality of nodes used to constitute an abnormal area based on the abnormal link can be found in the above description and will not be repeated here.

[0131] Step 8012: The first node obtains capability information of M nodes, where the capability information is used to indicate whether the node has the capability to support the abnormal area.

[0132] The first node can perceive its own capability information, and on this basis, the first node also obtains the capability information of M nodes, so that the first node can know the capability information of each node in the multiple nodes used to constitute the abnormal area, so as to determine the abnormal area including N nodes according to the capability information of each node. Among them, the capability information of a node is used to indicate whether the node has the capability to support the abnormal area. Exemplarily, the capability to support the abnormal area may include: the capability to perceive abnormal links, the capability to determine the nodes included in the abnormal area according to the abnormal links to determine the abnormal area, the capability to perform routing convergence in the abnormal area, and the capability to update the abnormal area.

[0133] In some embodiments, the first node obtains the capability information of M nodes through centralized learning. For example, the first node obtains the capability information of M nodes, including: the first node receives a notification message sent by the controller, and the first node obtains the capability information of M nodes according to the capability field in the notification message. Among them, the notification message sent by the controller to the first node includes a capability field, and the capability field carries at least the capability information of M nodes, so that the first node can obtain the capability information of M nodes according to the capability field in the notification message. Exemplarily, the embodiment of the present application forms a notification message by extending the border gateway protocol (BGP) by adding a capability field to the BGP message. For example, the BGP message that can add the capability field includes but is not limited to the BGP-link state (link state, LS) message or other types of BGP messages, etc., and the embodiment of the present application does not limit this.

[0134] The controller is a centralized controller, and all nodes in the domain report their own capability information to the controller. The controller can collect the capability information of all nodes in the domain (for example, send capability information collection instructions to all nodes in the domain, and each node reports its own capability information to the controller respectively), and then send the capability information of one or some nodes that the node needs to perceive to a certain node in the domain in combination with actual needs. For example, for the first node, the capability field in the notification message can carry the capability information of all nodes in the domain (including the capability information of the first node itself), and the first node obtains the capability information of M nodes from the capability information of all nodes in the domain. For another example, for the first node, the capability field in the notification message can carry the capability information of nodes other than the first node in the domain (excluding the capability information of the first node itself), and the first node obtains the capability information of M nodes from the capability information of nodes other than the first node in the domain. For another example, the first node requests the controller to obtain the capability information of M nodes, and the controller obtains the capability information of M nodes from the capability information of all nodes in the domain, and the capability field in the notification message only carries the capability information of M nodes.

[0135] For example, see Fig.13 Assuming that the first node is node B, and the M nodes are node F, node C, and node H, node B can send a request to the controller and receive a notification message sent by the controller according to the request. The capability field in the notification message carries the capability information of node F, node C, and node H.

[0136] In other embodiments, the first node obtains the capability information of M nodes through distributed learning. For example, the first node obtains the capability information of M nodes, including: for any one of the M nodes, the first node receives a route publishing message sent by any one of the M nodes, and the first node obtains the capability information of any one of the nodes according to the capability field in the route publishing message. Among them, the capability field in the route publishing message sent by any one of the M nodes to the first node carries the capability information of the node, so that the first node can obtain the capability information of the node according to the capability field in the route publishing message sent by the node. Of course, the route publishing message of the node is not only sent to the first node, but can be sent to all nodes in the domain except the node itself. Similarly, the first node can also carry its own capability information in the capability field, generate a route publishing message of the first node, and send the route publishing message of the first node to all nodes in the domain except itself. In this way, each node in the domain can perceive the capability information of all nodes in the domain. For example, see Fig.14 , Fig.14 The diagram shows the interaction of messages between different nodes to obtain capability information of M nodes through distributed learning.

[0137] It should be understood that the above is a distributed learning process based on the routing publishing process, and the embodiments of the present application can also complete the distributed learning process at other times. For example, distributed learning can be performed based on the basic topology announcement process, and the basic topology announcement process involves the announcement of the link state. Then each node in the domain can add a capability field in the link state announcement message to carry the node's own capability information. For another example, distributed learning can be performed based on the neighbor establishment process. Then each node in the domain can add a capability field in the neighbor establishment message (such as a BGP open (open) message) to carry the node's own capability information.

[0138] Exemplarily, the embodiment of the present application can extend the BGP protocol to increase the capability field in the BGP message, and the extension method is described above, which will not be described in detail here. Alternatively, the embodiment of the present application can also extend the IGP protocol (including but not limited to the IS-IS protocol, the open shortest path first (open shortest path first, OSPF) protocol, etc.) to increase the capability field in the IGP message to form the above-mentioned route publishing message, link state notification message or neighbor establishment message. For example, the IGP message that can increase the capability field includes but is not limited to IGP-segment routing (segment routing, SR) message or other types of IGP messages.

[0139] Regardless of the implementation method, the first node can obtain the capability information of each node among the multiple nodes (including the first node and M nodes) used to constitute the abnormal area, so as to determine the abnormal area including N nodes according to the capability information of each node.

[0140] For example, if multiple nodes used to constitute an abnormal area all have the ability to support the abnormal area, the abnormal area is determined based on these multiple nodes. The first node can notify its neighboring nodes of the current abnormal link. Since the first node and its neighboring nodes all have the ability to support the abnormal area, the first node and its neighboring nodes establish a neighbor relationship in the abnormal area. Among them, after the first node notifies its neighboring nodes of the current abnormal link, the neighboring node can enable the ability to support the abnormal area, thereby determining multiple nodes used to constitute the abnormal area in the same way (the same as the multiple nodes determined by the first node), and the neighboring node also notifies its neighboring nodes of the current abnormal link to achieve the diffusion of the current abnormal link, determine the abnormal area, and subsequently complete routing convergence in the abnormal area. In other words, when the nodes at both ends of a link have the ability to support the abnormal area, one of the nodes at both ends of the link can notify the other node of the current abnormal link, achieve the diffusion of the current abnormal link, and establish a neighbor relationship in the abnormal area. If any of the nodes at both ends of the link does not have the ability to support the abnormal area, the neighbor relationship in the abnormal area cannot be established.

[0141] For example, see Fig.15 , the link between node B and node C is an abnormal link, and node B and node C can respectively sense the abnormal link and respectively determine that the multiple nodes used to constitute the abnormal area include node B, node C, node F and node H. Taking the first node as node C as an example, node C can determine that these four nodes are capable of supporting the abnormal area, and node C notifies node F and node H of the abnormal link between node B and node C, so that node F and node H also determine the same abnormal area according to the notified abnormal link, and subsequently the four nodes each complete routing convergence.

[0142] For another example, if some of the multiple nodes used to constitute the abnormal area have the ability to support the abnormal area, and the other nodes do not have the ability to support the abnormal area, for example, the first node itself has the ability to support the abnormal area, but according to the capability information of the M nodes, it is determined that some of the M nodes have the ability to support the abnormal area, and the other nodes do not have the ability to support the abnormal area, then the first node can give up determining the abnormal area, and according to the solution provided by the relevant technology, all nodes in the domain can perceive the abnormal link and complete routing convergence, or the first node can also adopt the following step 8013.

[0143] Step 8013: If it is determined according to the capability information that at least some of the M nodes have the capability to support the abnormal area, the first node determines the abnormal area according to the first node and at least some of the nodes.

[0144] In some embodiments, the first node ignores at least some nodes that do not have the ability to support the abnormal area in the process of determining the abnormal area, and determines the abnormal area based on the first node and at least some nodes among the M nodes that have the ability to support the abnormal area, so that the determined abnormal area only includes the first node and at least some nodes among the M nodes that have the ability to support the abnormal area, and subsequently each node in the abnormal area completes routing convergence.

[0145] In other embodiments, the first node does not ignore the nodes that do not have the ability to support the abnormal area in the process of determining the abnormal area, but adopts a compatible manner so that the determined abnormal area includes both the first node and at least some of the M nodes that have the ability to support the abnormal area, and another part of the M nodes that do not have the ability to support the abnormal area. However, only the nodes that have the ability to support the abnormal area will perform the diffusion of the current abnormal link and route convergence, while the nodes that do not have the ability to support the abnormal area, although in the abnormal area, will not perceive the current abnormal link and will not perform route convergence.

[0146] The first node may notify its neighboring nodes of the current abnormal link. If its neighboring nodes have the ability to support abnormal areas, the neighboring nodes may implement the diffusion of the current abnormal link and determine the abnormal area in the manner described in step 8012, and subsequently complete the routing convergence in the abnormal area. Alternatively, if the first node's neighboring nodes do not have the ability to support abnormal areas, the first node cannot establish a neighbor relationship with its neighboring nodes in the abnormal area. After the first node notifies its neighboring nodes of the current abnormal link, the neighboring nodes are also unable to enable the ability to support abnormal areas. Therefore, the neighboring nodes will only transparently transmit the received current abnormal link as a message of unknown attributes, and will not participate in the routing convergence in the abnormal area subsequently.

[0147] For example, see Fig.16 , Fig.16 exist Fig.15On the basis of , an abnormal link between node H and node C is added, and the multiple nodes used to constitute the abnormal area include node B, node C, node F, node H and node K. Node K does not have the ability to support abnormal areas, and the other four nodes have the ability to indicate abnormal areas. Still taking the first node as node C as an example, node C notifies node F and node K of the abnormal link between node H and node C, and node H notifies node B and node K of the abnormal link between node H and node C. Since node B and node F both have the ability to support abnormal areas, they can determine the same abnormal area after receiving the notification, and subsequently nodes B, node C, node F and node H will all perform routing convergence. However, since node K does not have the ability to support abnormal areas, node K will transparently transmit the received abnormal link as a message of unknown attributes, and will not participate in the routing convergence in the abnormal area subsequently.

[0148] Step 802: The first node determines a second node among the N nodes that is located on the first forwarding path, where the second node is a node used to leave the abnormal area among the nodes that overlap with the N nodes on the first forwarding path, or the second node is the last node among the nodes that overlap with the N nodes on the first forwarding path.

[0149] Among them, the method for determining the first forwarding path has been explained in step 802 and will not be repeated here. There are two situations for the second node located on the first forwarding path. In situation c, the node outside the abnormal area is the destination node of the message. Since the first node has obtained the message in step 801 and the message is already located in the abnormal area, when the node outside the abnormal area is the destination node of the message, the message needs to leave the abnormal area, then the second node is the node used to leave the abnormal area among the nodes that overlap with the N nodes on the first forwarding path. In situation d, the node in the abnormal area is the destination node of the message. Since the first node has obtained the message in step 801 and the message is already located in the abnormal area, then the second node is the last node among the nodes that overlap with the N nodes on the first forwarding path.

[0150] For case c, see Fig.10 , since the first forwarding path of the message is S33 to S32 to S42, the nodes on the first forwarding path that overlap with the N nodes included in the abnormal area are S33, S32 and S42, among which the node for leaving the abnormal area is S42, so the second node is S42. Fig.12 Since the first forwarding path of the message is S23 to S33 to S32 to S42, the nodes on the first forwarding path that overlap with the N nodes included in the abnormal area are S23, S33, S32 and S42, among which the node used to leave the abnormal area is S42, and thus the second node is S42.

[0151] For case d, see Fig. 9 , since the first forwarding path of the message is S33 to S32 to S31, the nodes on the first forwarding path that overlap with the N nodes included in the abnormal area are S33, S32 and S31, of which the last node is S31, and the second node is S31. Fig.11 Since the first forwarding path of the message is S23 to S33 to S32 to S31, the nodes on the first forwarding path that overlap with the N nodes included in the abnormal area are S23, S33, S32 and S31, the last node of which is S31, and the second node is S31.

[0152] It can be seen that Fig. 9 A scenario combining scenario a and scenario d is shown, in which both the source node and the destination node of the message are nodes in the abnormal area. Fig.10 A scenario combining case a and case c is shown. In this scenario, the source node of the message is a node in the abnormal area, and the destination node is a node outside the abnormal area. Fig.11 A scenario combining scenario b and scenario d is shown. In this scenario, the source node of the message is a node outside the abnormal area, and the destination node is a node within the abnormal area. Fig.12 A scenario combining scenario b and scenario c is shown, in which both the source node and the destination node of the message are nodes outside the abnormal area.

[0153] In some implementations, among the nodes that overlap with the N nodes on the first forwarding path, there is only one node (i.e., the second node) for leaving the abnormal area, and the second node is also the last node among the nodes that overlap with the N nodes on the first forwarding path. Fig.10 and Fig.12 In some other embodiments, among the nodes overlapping with the N nodes on the first forwarding path, there are multiple ordered nodes for leaving the abnormal area. For example, see Fig.17, the first forwarding path is S23 to S22 to S21 to S31 to S32, S22 is the first node for leaving the abnormal area, and S32 is the second node for leaving the abnormal area. Exemplarily, if there are multiple ordered nodes for leaving the abnormal area among the nodes that overlap with N nodes on the first forwarding path, the second node is the first node or the last node among the multiple ordered nodes. Of course, the second node can also be an intermediate node among the multiple ordered nodes, and the implementation of this application does not limit this. Among them, if the second node is the first node among the multiple ordered nodes, the second node is not the last node among the nodes that overlap with N nodes on the first forwarding path. If the second node is the last node among the multiple ordered nodes, the second node is also the last node among the nodes that overlap with N nodes on the first forwarding path. It can be seen that for the second node, situation c and situation d are not mutually exclusive situations. In some cases, the second node can meet both situation c and situation d.

[0154] Step 803: The first node determines a second forwarding path from the first node to the second node when sensing an abnormal link.

[0155] Through the above steps 801 and 802, the first node has obtained the message and determined the second node, so the first node can determine the second forwarding path from the first node to the second node when sensing the current abnormal link. As mentioned above, in the embodiment of the present application, the first forwarding path can be considered as the original forwarding path of the message before the current abnormal link is generated, and correspondingly, the second forwarding path can be considered as the new forwarding path of the message after the current abnormal link has been generated.

[0156] In an exemplary embodiment, the first node determines a second forwarding path from the first node to the second node when sensing an abnormal link, including the following steps 8031 ​​to 8033.

[0157] Step 8031: The first node generates a first SPT according to N nodes and abnormal links.

[0158] When the first node generates the first SPT based on the N nodes and the current abnormal link, it can use the first node itself as the root node and use the shortest path first (SPF) algorithm to traverse the N nodes in the abnormal area, the current abnormal link, and the non-abnormal links between the N nodes to obtain the first SPT. The algorithm complexity is N·log2N. Fig.17In the scenario shown in FIG. 1 , the nodes in the abnormal area include S22, S23, S24, S32, S33 and S34 (the value of N is 6), and the current abnormal link is S23 to S33. The first SPT generated based on the 6 nodes and abnormal links in the abnormal area can be seen in FIG. Fig.18 in (1).

[0159] Assuming that there are a total of Q nodes in the domain, and Q is greater than N, if the SPF algorithm is used to traverse all nodes in the domain and the links between all nodes, the algorithm complexity is Q·log2Q, which is larger than the algorithm complexity N·log2N of the embodiment of the present application. Therefore, the embodiment of the present application adopts this method to reduce the algorithm complexity and improve the efficiency of determining the second forwarding path.

[0160] Step 8032: The first node updates the first SPT according to the second SPT to obtain an update result. The second SPT is generated in the absence of an abnormal link.

[0161] The second SPT is generated when there is no current abnormal link. For the description of the absence of the current abnormal link, please refer to step 801 above, which will not be repeated here. The first node updates the first SPT according to the second SPT to selectively migrate the parent-child relationship between different nodes in the second SPT to the first SPT, thereby obtaining an updated result. The second SPT can be referred to as Fig.18 In (2), the nodes in the abnormal area can be marked in the second SPT (the bold marks are for example only).

[0162] In implementation mode 1, the first node updates the first SPT according to the second SPT to obtain an updated result, including: the first node uses the parent node of the node outside the abnormal area in the second SPT as the parent node of the node outside the abnormal area in the first SPT, and uses the parent nodes of N nodes outside the abnormal area in the second SPT as the parent nodes of N nodes in the first SPT to obtain a transition result. If there are nodes with multiple parent nodes in the transition result, the first node determines the cost values ​​of the multiple parent nodes, updates the transition result according to the cost values, and obtains an updated result. The cost value of any parent node is used to indicate the cost of reaching the node from the first node through any parent node.

[0163] The transition results can be found in Fig.18 In (3), compare Fig.18 (1) and Fig.18From (3), it can be seen that for nodes outside the abnormal area, no matter whether the parent node of a node outside the abnormal area in the second SPT includes only nodes outside the abnormal area, only nodes within the abnormal area, or nodes inside and outside the abnormal area, the parent node of the node outside the abnormal area in the second SPT is directly used as the parent node of the node outside the abnormal area in the first SPT. As for the situation where the parent node of the node within the abnormal area is also the node within the abnormal area, it has been reflected in the first SPT. Therefore, for the nodes within the abnormal area, it is only necessary to use the parent node of the node within the abnormal area outside the abnormal area in the second SPT as the parent node of the node within the abnormal area in the first SPT, or to add the parent-child relationship between the node within the abnormal area and the node outside the abnormal area on the basis of the first SPT. For example, continue to refer to Fig.18 In (3), for S32 in the abnormal area, the parent node of S32 outside the abnormal area in the second SPT is S31, so a path with S31 as the parent node and S32 as the child node is added to the first SPT. Thus, a transition result can be obtained.

[0164] After obtaining the transition result, there may be nodes with multiple parent nodes in the transition result, so the parent nodes can be screened. For example, the cost value of each parent node among the multiple parent nodes is determined, and the cost value of a parent node is equal to the cost of the first node (i.e., the root node) passing through the parent node to reach the node. Exemplarily, the embodiment of the present application can delete the parent node with a non-minimum cost value and only retain the parent node with the minimum cost value.

[0165] For example, the update results can be found in Fig.18 In (4), S32 has parent nodes S31 and S22, and the cost value of parent node S31 includes the sum of the cost values ​​of the links from S23 to S22, S22 to S21, S21 to S31, and S31 to S32, while the cost value of parent node S22 includes the sum of the cost values ​​of the links from S23 to S22 and S22 to S32. If the cost value of parent node S31 is less than the cost value of parent node S32, parent node S31 is retained and the path from S22 to S32 in the transition result is deleted. Similarly, the path from S53 to S54 and the path from S43 to S44 can be deleted.

[0166] In implementation mode 2, the first node updates the first SPT according to the second SPT to obtain an update result, including: the first node uses the parent node of the node outside the abnormal area in the second SPT as the parent node of the node outside the abnormal area in the first SPT to obtain an update result.

[0167] In implementation mode 2, the parent-child relationship between the nodes in the abnormal area and the nodes outside the abnormal area is no longer added on the basis of the first SPT, but only the parent-child relationship between the nodes outside the abnormal area is added on the basis of the first SPT. For example, the update result can be seen in Fig.18 In (5), for S32 in the abnormal area, although the parent node of S32 outside the abnormal area in the second SPT is S31, a path with S31 as the parent node and S32 as the child node is not added in the first SPT. Thus, an updated result can be obtained.

[0168] Step 8033: The first node determines a second forwarding path from the first node to the second node according to the update result.

[0169] Wherein, the first node can obtain a routing table according to the update result, such as directly generating a routing table according to the update result, or refreshing an original routing table (such as a routing table directly generated according to the second SPT tree) according to the update result to obtain a refreshed routing table. Thus, the first node can determine a second forwarding path from the first node to the second node according to the obtained routing table. Exemplarily, the first node can also generate a forwarding table according to the routing table, and the first node can determine the second forwarding path from the first node to the second node according to the obtained routing table and the forwarding table. The embodiment of the present application does not limit the manner in which the first node determines the second forwarding path according to the update result.

[0170] It should be understood that after obtaining the routing table and forwarding table, routing convergence is completed. The embodiment of the present application does not limit the timing of routing convergence. For example, the first node can complete routing convergence and obtain the routing table and forwarding table after determining the abnormal area. Then, after obtaining the message to be forwarded and determining the second node, the second forwarding path can be obtained by directly querying the routing table and forwarding table.

[0171] In the embodiment of the present application, if the update result is determined according to the above-mentioned implementation mode 1, there may be nodes outside the abnormal area on the second forwarding path determined according to the update result, because when the transition result is obtained in implementation mode 1, the parent-child relationship between the nodes in the abnormal area and the nodes outside the abnormal area is added on the basis of the first SPT, so that the nodes in the abnormal area may have a parent node outside the abnormal area. If the update result is determined according to the above-mentioned implementation mode 2, there will be no nodes outside the abnormal area on the second forwarding path determined according to the update result, because when the update result is obtained in implementation mode 2, the parent-child relationship between the nodes in the abnormal area and the nodes outside the abnormal area is not added on the basis of the first SPT, so the nodes in the abnormal area may only have a parent node in the abnormal area.

[0172] Step 804: The first node forwards the message according to the second forwarding path.

[0173] The second forwarding path determined by the first node may be the same as the first forwarding path, or may be different from the first forwarding path. If the second forwarding path is the same as the first forwarding path, it means that the first forwarding path will not be affected by the current abnormal link. If the second forwarding path is different from the first forwarding path, it means that the first forwarding path will be affected by the current abnormal link. In an embodiment of the present application, the second node on the second forwarding path can be marked so that when the message needs to pass through the second node, the first node can forward the message in an appropriate manner.

[0174] Exemplarily, nodes other than the first node and the second node on the second forwarding path are used as intermediate nodes of the second forwarding path, and nodes other than the first node and the second node on the first forwarding path are used as intermediate nodes of the first forwarding path. If the intermediate nodes of the second forwarding path are consistent with the intermediate nodes of the first forwarding path, for example, the nodes included in the intermediate nodes and the order in which the nodes are located in the intermediate nodes are consistent, then it means that the second forwarding path is the same as the first forwarding path; if the intermediate nodes of the second forwarding path are inconsistent with the intermediate nodes of the first forwarding path, for example, at least one of the nodes included in the intermediate nodes and the order in which the nodes are located in the intermediate nodes is inconsistent, then it means that the second forwarding path is different from the first forwarding path.

[0175] In some embodiments, regardless of whether the second forwarding path is the same as the first forwarding path, the first node adopts a specified method to forward the message according to the second forwarding path. Under this embodiment, the first node does not need to determine whether the second forwarding path is the same as the first forwarding path. After determining the second forwarding path, it can directly adopt a specified method to forward the message according to the second forwarding path. For example, the specified method can be strict path forwarding, then the first node encapsulates the node information of each node on the second forwarding path into the message (including but not limited to encapsulation by means of a label stack), obtains and sends the updated message. For another example, the specified method can be a loose path, then the first node only encapsulates the node information of the second node on the second forwarding path into the message, obtains and sends the updated message.

[0176] In other embodiments, when the second forwarding path is the same as the first forwarding path, and when the second forwarding path is different from the first forwarding path, the first node forwards the message in different ways according to the second forwarding path. For example, when the second forwarding path is the same as the first forwarding path, the first node does not need to encapsulate, that is, it does not adopt a strict path or a loose path, and directly forwards the message in a hop-by-hop forwarding manner. For another example, when the second forwarding path is different from the first forwarding path, the first node encapsulates, adopts a strict path or a loose path, and forwards the message in the second forwarding path.

[0177] It can be seen that when a strict path method is adopted, forwarding a message according to the second forwarding path includes: if the second forwarding path is different from the first forwarding path, the first node encapsulates the node information of each node on the second forwarding path into the message to obtain an updated message, and the first node sends the updated message. When a loose path method is adopted, forwarding a message according to the second forwarding path includes: if the second forwarding path is different from the first forwarding path, the first node encapsulates the node information of the second node into the message to obtain an updated message, and the first node sends the updated message. It can be seen that the first node forwarding a message according to the second forwarding path includes: encapsulating the node information of the nodes on the second forwarding path into the message to obtain an updated message, and sending the updated message.

[0178] Exemplarily, when the second forwarding path is different from the first forwarding path, the first node can also select from the strict path and the loose path according to the actual situation. For example, after the first node enters a stable state, that is, after the link abnormality has not been updated within a certain period of time (for example, 5 seconds, 10 seconds, not limited here), the loose path method is adopted, and when it has not entered a stable state, the strict path method is adopted, thereby reducing the packaging pressure after the first node enters a stable state.

[0179] It should be understood that after the message arrives at the second node, if the second node is the destination node of the message, the second node does not need to forward the message. If the second node is not the destination node of the message, the second node can directly forward the message in a hop-by-hop forwarding manner. Since the embodiment of the present application makes the first node and the second node on the first forwarding path and the second forwarding path the same, even if the second node directly forwards the message in a hop-by-hop forwarding manner, no loop will be caused.

[0180] Of course, in addition to the case where the second forwarding path is the same as the first forwarding path described above, in some other cases, the hop-by-hop forwarding method can also be used. For example, when the destination node of the message is a node outside the abnormal area, and all nodes in the abnormal area can specify the same second node for the message after confirming the destination node of the message, so that the message leaves the abnormal area from a specified second node, the hop-by-hop forwarding method can also be used.

[0181] In an exemplary embodiment, the method provided by the embodiment of the present application also includes: if the neighbor node of the first node in the abnormal area is unreachable, the first node sends abnormal information of the neighbor node to other nodes outside the first node, and the abnormal information is used by other nodes to confirm that the neighbor node is unreachable and delete the route published by the neighbor node as the source node.

[0182] Among them, the neighboring nodes of the first node in the abnormal area are unreachable. There may be two situations. One is that the neighboring node itself is abnormal, and the other is that the neighboring node itself is not abnormal, but all the direct links of the neighboring node are abnormal, such as Fig.19 This situation is shown. Since all direct links of G are abnormal, G is an unreachable node.

[0183] In case of abnormality of the neighbor node itself, the first node sends abnormal information of the neighbor node to other nodes outside the first node, that is, all nodes in the domain except the first node (not limited to the abnormal area), and the abnormal information indicates that the neighbor node itself is abnormal. When other nodes receive this abnormal information, they can determine that the neighbor information of the first node is unreachable, and delete the routes published with the neighbor node as the source node, including but not limited to overlay routes and underlay routes. Exemplarily, after deletion, other nodes can also update the routes.

[0184] In the case where all direct links of the neighboring node are abnormal, the abnormal information sent by the first node to the above-mentioned other nodes indicates that the direct link between the first node and the neighboring node is unreachable. Other nodes need to collect enough abnormal information about the neighboring node before determining that the neighboring node is unreachable, thereby deleting the route published with the neighboring node as the source node, and can also update the route.

[0185] For example, see Fig. 20 , after the first node F detects that the four links FG, CG, KG and HG are all abnormal, it confirms that G is unreachable, and thus sends abnormal information to other nodes, indicating that FG is an abnormal link. Similarly, C will send abnormal information to other nodes after confirming that G is unreachable, indicating that CG is an abnormal link. K will send abnormal information to other nodes after confirming that G is unreachable, indicating that KG is an abnormal link. H will send abnormal information to other nodes after confirming that G is unreachable, indicating that HG is an abnormal link. Other nodes include E. When E only receives abnormal information indicating that FG is an abnormal link, it cannot determine that G is unreachable for the time being, and therefore does not delete it. When E receives four pieces of abnormal information sent by F, C, K and H, E can determine that FG, CG, KG and HG are all abnormal links, and therefore E can determine that G is unreachable, then E deletes the route published with G as the source node, and can adaptively update the route.

[0186] In summary, after the first node in the abnormal area obtains the message to be forwarded, it determines the second node that the message needs to reach according to the first forwarding path of the message and the abnormal area, and determines the second forwarding path from the first node to the second node when sensing the abnormal link in the abnormal area, and the first forwarding path and the second forwarding path at least include the same first node and second node. After forwarding the message to the second node according to the second forwarding path, since the second node is a node that already exists on the first forwarding path, the availability of the second node is guaranteed when the first forwarding path is determined, and the second node can normally receive and process the message, thereby ensuring the reliability of message forwarding when the abnormal area is involved in the message forwarding process. In addition, when the first forwarding path is determined, the loop problem is often avoided, so when the second node processes the message including forwarding the message, a loop problem will not be formed.

[0187] The above describes the method for forwarding a message provided by the embodiment of the present application. Corresponding to the above method, the embodiment of the present application also provides a device for forwarding a message. The device can be applied to a first node. The device is used to Fig.21 The modules shown above perform the Figure 8 The method of forwarding messages is shown in FIG. Fig.21 As shown, the device for forwarding messages provided in the embodiment of the present application includes the following modules.

[0188] exist Fig.21 When the device shown is applied to the first node, the forwarding module 2101 is used to execute Figure 8 The forwarding-related operations performed by the first node in the method for forwarding a message shown in FIG. 21; a processing module 2102 for performing Figure 8 The method for forwarding a message shown includes other operations other than the forwarding-related operations performed by the first node. The first node is one of N nodes included in the abnormal area, and an abnormal link exists between the N nodes.

[0189] In an exemplary embodiment, the processing module 2102 is used to obtain a message, and the first node is the first node among the nodes that overlap with N nodes on the first forwarding path of the message; the processing module 2102 is also used to determine a second node among the N nodes that is located on the first forwarding path, and the second node is a node that overlaps with the N nodes on the first forwarding path and is used to leave the abnormal area, or the second node is the last node among the nodes that overlap with the N nodes on the first forwarding path; the processing module 2102 is also used to determine a second forwarding path from the first node to the second node when an abnormal link is perceived; the forwarding module 2101 is used to forward the message according to the second forwarding path.

[0190] In an exemplary embodiment, the first forwarding path is used to forward the message when no abnormal link exists.

[0191] In some implementations, the forwarding module 2101 is configured to encapsulate node information of each node on the second forwarding path into a message to obtain an updated message if the second forwarding path is different from the first forwarding path; and send the updated message.

[0192] In some other implementations, the forwarding module 2101 is used to encapsulate the node information of the second node into a message to obtain an updated message if the second forwarding path is different from the first forwarding path; and send the updated message.

[0193] In an exemplary embodiment, the processing module 2102 is also used to sense abnormal links and determine M nodes based on the abnormal links; obtain capability information of the M nodes, where the capability information is used to indicate whether they have the ability to support abnormal areas; if it is determined based on the capability information that at least some of the M nodes have the ability to support abnormal areas, determine the abnormal area based on the first node and at least some of the nodes.

[0194] In some implementations, the processing module 2102 is used to receive a route publishing message sent by any one of the M nodes; and obtain capability information of any one of the nodes according to a capability field in the route publishing message.

[0195] In some other implementations, the processing module 2102 is used to receive a notification message sent by the controller; and obtain capability information of the M nodes according to a capability field in the notification message.

[0196] In an exemplary embodiment, the forwarding module 2101 is also used to send abnormal information of the neighbor node to other nodes outside the first node if the neighbor node of the first node in the abnormal area is unreachable. The abnormal information is used by other nodes to confirm that the neighbor node is unreachable and delete the route published by the neighbor node as the source node.

[0197] In an exemplary embodiment, if there are multiple ordered nodes for leaving the abnormal area among the nodes overlapping with the N nodes on the first forwarding path, the second node is the first node or the last node among the multiple ordered nodes.

[0198] In an exemplary embodiment, the processing module 2102 is used to generate a first SPT based on N nodes and abnormal links; update the first SPT based on the second SPT to obtain an updated result, and the second SPT is generated in the absence of an abnormal link; and determine a second forwarding path from the first node to the second node based on the updated result.

[0199] In an exemplary embodiment, the processing module 2102 is used to use the parent node of the node outside the abnormal area in the second SPT as the parent node of the node outside the abnormal area in the first SPT, and use the parent nodes of N nodes outside the abnormal area in the second SPT as the parent nodes of N nodes in the first SPT to obtain a transition result; if there are nodes with multiple parent nodes in the transition result, determine the cost values ​​of the multiple parent nodes, update the transition result according to the cost values, and obtain an updated result, and the cost value of any parent node is used to indicate the cost of reaching the node from the first node through any parent node.

[0200] In an exemplary embodiment, the processing module 2102 is used to use the parent node of the node outside the abnormal area in the second SPT as the parent node of the node outside the abnormal area in the first SPT to obtain an update result.

[0201] It should be understood that the above Fig.21 The device shown in the figure has the following beneficial effects when realizing its function: Figure 8 The methods for forwarding messages shown have the same beneficial effects. Fig.21 When the device shown implements its functions, only the division of the above-mentioned functional modules is used as an example. In actual applications, the above-mentioned functions can be assigned to different functional modules as needed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. In addition, the device and method embodiments provided in the above embodiments belong to the same concept, and their specific implementation process is detailed in the method embodiment, which will not be repeated here.

[0202] See also Fig. 22 , Fig. 22 A schematic structural diagram of an exemplary message forwarding device 2200 of the present application is shown. The message forwarding device 2200 includes at least one processor 2201, a memory 2203, and at least one network interface 2204.

[0203] Processor 2201 is, for example, a general-purpose central processing unit (CPU), a digital signal processor (DSP), a network processor (NP), a graphics processing unit (GPU), a neural-network processing units (NPU), a data processing unit (DPU), a microprocessor or one or more integrated circuits or application-specific integrated circuits (ASICs) for implementing the solution of the present application, a programmable logic device (PLD), other general-purpose processors or other programmable logic devices, discrete gates, transistor logic devices, discrete hardware components or any combination thereof. PLD is, for example, a complex programmable logic device (CPLD), a field-programmable gate array (FPGA), a generic array logic (GAL) or any combination thereof. A general-purpose processor may be a microprocessor or any conventional processor, etc. It is worth noting that the processor may be a processor supporting an advanced RISC machines (ARM) architecture. It can implement or execute various logic blocks, modules and circuits described in conjunction with the disclosure of this application. The processor can also be a combination that implements computing functions, such as a combination of one or more microprocessors, a combination of DSP and microprocessor, and so on.

[0204] Optionally, the device 2200 for forwarding messages further includes a bus 2202. The bus 2202 is used to transmit information between components of the device 2200 for forwarding messages. The bus 2202 may be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus. The bus 2202 may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Fig. 22 The fact that only one line is used in the diagram does not mean that there is only one bus or only one type of bus.

[0205] The memory 2203 is, for example, a volatile memory or a nonvolatile memory, or may include both volatile and nonvolatile memories. Among them, the nonvolatile memory may be a read-only memory (ROM), a programmable ROM (PROM), an erasable programmable ROM (EPROM), an electrically erasable programmable ROM (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), which is used as an external cache.

[0206] By way of example but not limitation, many forms of ROM and RAM are available. For example, ROM is a compact disc read-only memory (CD-ROM). RAM includes, but is not limited to, static RAM (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM) and direct rambus RAM (DR RAM).

[0207] The memory 2203 may also be other types of storage devices that can store static information and instructions. Or it may be other types of dynamic storage devices that can store information and instructions. Or it may be other optical disk storage, optical disk storage (including compressed optical disk, laser disk, optical disk, digital versatile disk, blue-ray disk, etc.), 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 the computer, but is not limited to this. The memory 2203, for example, exists independently and is connected to the processor 2201 via the bus 2202. The memory 2203 may also be integrated with the processor 2201.

[0208] The network interface 2204 uses any transceiver-like device to communicate with other devices or communication networks, and the communication network can be Ethernet, radio access network (RAN) or wireless local area network (WLAN), etc. The network interface 2204 may include a wired network interface and may also include a wireless network interface. Specifically, the network interface 2204 may be an Ethernet interface, such as a fast Ethernet (FE) interface, a gigabit Ethernet (GE) interface, an asynchronous transfer mode (ATM) interface, a WLAN interface, a cellular network interface or a combination thereof. The Ethernet interface may be an optical interface, an electrical interface or a combination thereof. In some embodiments of the present application, the network interface 2204 may be used for the device 2200 that forwards messages to communicate with other devices.

[0209] In a specific implementation, as some embodiments, the processor 2201 may include one or more CPUs, such as Fig. 22 0 and CPU1 shown in FIG. Each of these processors may be a single-core processor or a multi-core processor. A processor herein may refer to one or more devices, circuits, and / or processing cores for processing data (e.g., computer program instructions).

[0210] In a specific implementation, as some implementation methods, the device 2200 for forwarding a message may include multiple processors, such as Fig. 22 2201 and processor 2205 shown in FIG. Each of these processors may be a single-core processor or a multi-core processor. A processor herein may refer to one or more devices, circuits, and / or processing cores for processing data (such as computer program instructions).

[0211] In some implementations, the memory 2203 is used to store program instructions 2210 for executing the solution of the present application, and the processor 2201 can execute the program instructions 2210 stored in the memory 2203. That is, the device 2200 for forwarding messages can implement the method provided in the method embodiment through the processor 2201 and the program instructions 2210 in the memory 2203, that is, Figure 8 The method shown. The program instruction 2210 may include one or more software modules. Optionally, the processor 2201 itself may also store program instructions for executing the solution of the present application.

[0212] In a specific implementation process, the device 2200 of the present application for forwarding a message may correspond to a first node for executing the above method, and the processor 2201 in the device 2200 for forwarding a message reads the instruction in the memory 2203, so that Fig. 22 The device 2200 for forwarding messages shown can execute all or part of the steps in the method embodiment.

[0213] The device 2200 for forwarding messages may also correspond to the above Fig.21 The device shown, Fig.21 Each functional module in the device shown is implemented using software of the device 2200 for forwarding messages. In other words, Fig.21 The functional modules included in the apparatus shown are generated after the processor 2201 of the device 2200 for forwarding messages reads the program instructions 2210 stored in the memory 2203 .

[0214] in, Figure 8 Each step of the method shown is completed by an integrated logic circuit of hardware or software instructions in the processor of the device 2200 that forwards the message. The steps of the method embodiment disclosed in the present application can be directly embodied as being executed by a hardware processor, or can be executed by a combination of hardware and software modules in the processor. The software module can be located in a mature storage medium in the art such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory, and the processor reads the information in the memory, and completes the steps of the above method embodiment in combination with its hardware. To avoid repetition, it is not described in detail here.

[0215] In an exemplary embodiment, the present application provides a computer-readable storage medium, in which at least one computer instruction is stored, and the at least one computer instruction is loaded and executed by a processor to enable a computer to implement Figure 8 The method of forwarding messages shown in FIG.

[0216] Exemplarily, an embodiment of the present application provides a computer program or a computer program product, the computer program or the computer program product comprising: computer instructions, when the computer instructions are executed by a computer, the computer executes Figure 8 The method of forwarding messages shown in FIG.

[0217] In an exemplary embodiment, the present application provides a chip, including a processor, for calling and executing instructions stored in a memory, so that a computer equipped with the chip executes Figure 8 The method of forwarding messages shown in FIG.

[0218] Exemplarily, the embodiment of the present application also provides another chip, including: an input interface, an output interface, a processor and a memory, wherein the input interface, the output interface, the processor and the memory are connected through an internal connection path, and the processor is used to execute the code in the memory. When the code is executed, the computer equipped with the chip executes Figure 8 The method of forwarding messages shown in FIG.

[0219] Exemplarily, the embodiment of the present application further provides a system for forwarding messages, wherein N nodes in the system form an abnormal area, an abnormal link exists between the N nodes, and a first node among the N nodes is used to execute Figure 8 The method for forwarding messages shown in the figure. It should be understood that the system may include not only N nodes, but also other nodes in addition to the N nodes. Compared with the nodes used to form the abnormal area and belong to the abnormal area, the other nodes are not used to form the abnormal area and belong to the nodes outside the abnormal area.

[0220] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented by software, 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 present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can 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 can be transmitted from a website site, computer, server or data center to another website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line) or wireless (e.g., infrared, wireless, microwave, etc.) mode. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrated. The available medium can be a magnetic medium (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid state disk), etc.

[0221] In this application, the terms "first", "second", etc. are used to distinguish between identical or similar items with substantially the same effects and functions. It should be understood that there is no logical or temporal dependency between "first", "second", and "nth", nor is there a limitation on the quantity and execution order. It should also be understood that although the following description uses the terms first, second, etc. to describe various elements, these elements should not be limited by the terms. These terms are only used to distinguish one element from another.

[0222] It should also be understood that in the various embodiments of the present application, the size of the serial number of each process 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.

[0223] The term "at least one" in this application means one or more, and the term "multiple" in this application means two or more, for example, multiple nodes means two or more nodes. The terms "system" and "network" are often used interchangeably herein.

[0224] It should be understood that the terms used in the description of the various examples herein are only for describing specific examples and are not intended to be limiting. As used in the description of the various examples and the appended claims, the singular forms "a", "an", and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise.

[0225] It should also be understood that the term "and / or" used herein refers to and encompasses any and all possible combinations of one or more of the associated listed items. The term "and / or" is a description of the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this application generally indicates that the associated objects before and after are in an "or" relationship.

[0226] It should also be understood that the terms "if" and "if" may be interpreted to mean "when" or "upon" or "in response to determining" or "in response to detecting." Similarly, the phrases "if it is determined that ..." or "if [a stated condition or event] is detected" may be interpreted to mean "upon determining that ..." or "in response to determining that ..." or "upon detecting [a stated condition or event]" or "in response to detecting [a stated condition or event]," depending on the context.

[0227] The above description is only an embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the principles of the present application shall be included in the protection scope of the present application.

Claims

1. A method for forwarding a message, characterized in that: The method is applied to a first node, the first node is one of N nodes included in an abnormal area, and an abnormal link exists between the N nodes. The method includes: The first node acquires a message, where the first node is a first node among nodes that overlap with the N nodes on a first forwarding path of the message; The first node determines a second node located on the first forwarding path among the N nodes, where the second node is a node used to leave the abnormal area among the nodes that coincide with the N nodes on the first forwarding path, or the second node is the last node among the nodes that coincide with the N nodes on the first forwarding path; The first node determines a second forwarding path from the first node to the second node when sensing the abnormal link, and forwards the message according to the second forwarding path.

2. The method according to claim 1, characterized in that: The first forwarding path is used to forward the message when the abnormal link does not exist.

3. The method according to claim 1 or 2, characterized in that: The forwarding the message according to the second forwarding path includes: If the second forwarding path is different from the first forwarding path, the first node encapsulates the node information of each node on the second forwarding path into the message to obtain an updated message; The first node sends the updated message.

4. The method according to claim 1 or 2, characterized in that: The forwarding the message according to the second forwarding path includes: If the second forwarding path is different from the first forwarding path, the first node encapsulates the node information of the second node into the message to obtain an updated message; The first node sends the updated message.

5. The method according to any one of claims 1 to 4, characterized in that: Before the first node obtains the message, the method further includes: The first node senses the abnormal link and determines M nodes according to the abnormal link; The first node acquires capability information of the M nodes, where the capability information is used to indicate whether the node has the capability to support an abnormal area; If it is determined according to the capability information that at least some of the M nodes have the capability to support the abnormal area, the first node determines the abnormal area according to the first node and the at least some of the nodes.

6. The method according to claim 5, characterized in that The first node acquires the capability information of the M nodes, including: For any one of the M nodes, the first node receives a routing advertisement message sent by the any one of the M nodes; The first node obtains the capability information of the any one node according to the capability field in the routing publication message.

7. The method according to claim 5, characterized in that The first node acquires the capability information of the M nodes, including: The first node receives a notification message sent by the controller; The first node obtains the capability information of the M nodes according to the capability field in the notification message.

8. The method according to any one of claims 1 to 7, characterized in that: The method further comprises: If the neighbor node of the first node in the abnormal area is unreachable, the first node sends abnormal information of the neighbor node to other nodes other than the first node, and the abnormal information is used by the other nodes to confirm that the neighbor node is unreachable and delete the route published by the neighbor node as the source node.

9. The method according to any one of claims 1 to 8, characterized in that: If there are multiple ordered nodes for leaving the abnormal area among the nodes overlapping with the N nodes on the first forwarding path, the second node is the first node or the last node among the multiple ordered nodes.

10. The method according to any one of claims 1 to 9, characterized in that: The first node determines a second forwarding path from the first node to the second node when sensing the abnormal link, including: The first node generates a first shortest path tree SPT according to the N nodes and the abnormal link; The first node updates the first SPT according to the second SPT to obtain an update result, wherein the second SPT is generated when the abnormal link does not exist; The first node determines a second forwarding path from the first node to the second node according to the update result.

11. The method according to claim 10, characterized in that The first node updates the first SPT according to the second SPT to obtain an update result, including: The first node uses the parent node of the node outside the abnormal area in the second SPT as the parent node of the node outside the abnormal area in the first SPT, and uses the parent nodes of the N nodes outside the abnormal area in the second SPT as the parent nodes of the N nodes in the first SPT, to obtain a transition result; If there is a node with multiple parent nodes in the transition result, the first node determines the cost values ​​of the multiple parent nodes, updates the transition result according to the cost values, and obtains the updated result. The cost value of any parent node is used to indicate the cost of reaching the node from the first node through any parent node.

12. The method according to claim 10, characterized in that The first node updates the first SPT according to the second SPT to obtain an update result, including: The first node uses the parent node of the node outside the abnormal area in the second SPT as the parent node of the node outside the abnormal area in the first SPT to obtain the update result.

13. A device for forwarding a message, characterized in that: The device comprises: A forwarding module, used to perform forwarding-related operations in the method for forwarding a message according to any one of claims 1 to 12; A processing module, used to perform other operations other than forwarding-related operations in the method for forwarding a message described in any one of claims 1-12.

14. A device for forwarding a message, characterized in that: The device includes a memory and a processor; the memory stores at least one computer instruction, and the at least one computer instruction is loaded and executed by the processor, so that the device for forwarding messages implements the method for forwarding messages described in any one of claims 1-12.

15. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores at least one computer instruction, and the at least one computer instruction is loaded and executed by a processor so that a computer implements the method for forwarding a message described in any one of claims 1-12.

16. A chip, characterized in that: The chip includes a processor, and the processor is used to call and execute instructions stored in the memory from the memory, so that a computer equipped with the chip implements the method for forwarding a message as described in any one of claims 1-12.

17. A chip, characterized in that: The chip includes an input interface, an output interface, a processor and a memory. The input interface, the output interface, the processor and the memory are connected via an internal connection path. The processor is used to execute the code in the memory. When the code is executed, a computer equipped with the chip implements the method for forwarding messages described in any one of claims 1-12.

18. A system for forwarding messages, characterized in that: N nodes in the system form an abnormal area, an abnormal link exists between the N nodes, and a first node among the N nodes is used to implement the method for forwarding a message described in any one of claims 1-12.

19. A computer program product, characterized in that The computer program product includes computer instructions, and the computer instructions are executed by a processor to enable a computer to implement the method for forwarding a message as described in any one of claims 1 to 12.