Communication diagnosis recovery method

By adopting a communication diagnostic recovery method based on hierarchical routing tables in the communication system, the distributed routing tables are dynamically updated, and the performance loss and stability problems in the fault diagnosis and recovery of communication systems in the prior art are solved, thereby achieving low-latency and efficient communication diagnosis and recovery.

CN119696992APending Publication Date: 2025-03-25NAT UNIV OF DEFENSE TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411948886.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-27
Publication Date
2025-03-25

AI Technical Summary

Technical Problem

In the process of fault diagnosis and recovery of communication systems, the communication performance loss is large and the communication stability is weak, and the diagnosis and recovery process is low and the overhead is large.

Method used

The communication diagnostic recovery method based on the hierarchical routing table is adopted to update the distributed routing table by dynamically generating diagnostic messages or recovery messages to the upstream neighbors, thereby realizing communication diagnosis and recovery without user intervention and being transparent to the upper layer.

Benefits of technology

It realizes low communication diagnosis delay, small communication performance loss and high communication stability, which can effectively avoid faulty communication links, maximize available communication links, improve communication performance, and restore communication to pre-malfunction state and performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119696992A_ABST
    Figure CN119696992A_ABST
Patent Text Reader

Abstract

The communication diagnosis recovery method provided by the invention comprises the following steps: when a fault port exists, performing communication diagnosis; after the fault port is maintained, communication recovery is carried out; the scheme is a communication diagnosis recovery method provided based on a hierarchical routing table, and is a communication diagnosis recovery method capable of being used for a large-scale computing system, communication diagnosis and recovery are realized by dynamically generating a diagnosis message or a recovery message and reversely propagating the diagnosis message or the recovery message to an upstream neighbor to update a distributed routing table, user intervention is not needed, and the method is transparent to an upper layer; the method has the characteristics of low communication diagnosis delay, small communication performance loss and high communication stability; according to communication diagnosis, a fault communication link is effectively avoided by cancelling table items of a routing table where a fault port is located, stable communication is maintained, and meanwhile available communication links are maximized so as to improve communication performance; in the communication recovery, the failure table items are recovered layer by layer one by one by taking the fault port as a starting point, so that the communication is recovered to the communication state and performance before the fault.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of communications, and in particular to a communication diagnosis and recovery method. Background Art

[0002] Communication systems are important infrastructure for large-scale computing systems such as high-performance computers, intelligent computers, and data centers. With the rapid development of large-scale computing speed, the scale of communication systems continues to increase, and the cost, performance, and stability of ultra-large-scale communications are crucial. In recent years, the industry has adopted the Dragonfly topology, which is cost-effective, low-latency, and highly scalable. It does not require a top-level switch, and has a low number of hops and costs. However, the disadvantage is that it is difficult to adapt to complex traffic if the shortest path between any two points is small, and failures on any path may cause communication failures, seriously affecting system stability.

[0003] When a communication system failure occurs, the communication framework focuses on two aspects: system stability and minimum performance loss. Some related studies have adopted a connection protocol to implement end-to-end hardware retransmission, which tolerates a small amount of packet loss, but it is difficult for retransmitted messages to avoid the fault area, which may cause repeated retransmissions and performance loss. Some studies have proposed a nested multi-layer topology fault-tolerant routing algorithm. When retransmitting a fault, it searches the routing table and selects redundant links through intermediate agents to avoid the faulty link, but the algorithm has high computational complexity and poor fault tolerance. Another study has designed a related algorithm to switch to the emergency configuration state of the safe routing table when a fault occurs, and reconstruct to adapt to topology changes, but the algorithm has a large overhead and can only be used for specific topologies (such as Torus). It is also difficult to apply to communication systems with a scale of more than hundreds of nodes.

[0004] In view of this, providing a communication diagnosis recovery method that satisfies both low communication diagnosis delay and small communication performance loss is a technical problem that needs to be solved urgently by those skilled in the art. Summary of the invention

[0005] In order to solve the above technical problems, the purpose of the present invention is to provide a communication diagnosis and recovery method for large-scale computing systems based on a hierarchical routing table, which can automatically perform communication diagnosis and communication recovery when a fault occurs, without the need for user intervention in communication diagnosis operations and communication recovery operations and is transparent to the upper layer, and has the characteristics of low communication diagnosis delay, small communication performance loss and high communication stability.

[0006] The purpose of the present invention is to provide a communication diagnosis and recovery method; The technical solution provided by the present invention is as follows: A communication diagnosis and recovery method comprises the following steps: When there is a faulty port, perform communication diagnosis; After the faulty port is maintained, communication is restored.

[0007] Preferably, the communication diagnosis comprises the following steps: Traverse the local port routing table; The local port routing table is matched with the faulty port, and a corresponding diagnostic operation is performed according to the matching result.

[0008] Preferably, matching the local port routing table with the faulty port and performing a corresponding diagnostic operation according to the matching result includes: When the match satisfies the first diagnostic condition, a first diagnostic operation is performed; The first diagnostic condition is specifically: there is a table entry containing the valid state of the faulty port and there is a table entry not containing the valid state of the faulty port in the local port routing table; The first diagnostic operation specifically includes: setting the entry containing the faulty port to an invalid state.

[0009] Preferably, matching the local port routing table with the faulty port and performing corresponding operations according to the matching result includes: When the second diagnostic condition is met, the second diagnostic operation is performed; The second diagnostic condition is specifically: there is one and only one entry in the local port routing table that includes the valid state of the faulty port; The second diagnostic operation is specifically: setting the table entry containing the valid state of the faulty port to an invalid state, generating an upstream diagnostic message, and sending the upstream diagnostic message to an upper-level neighbor of the current layer.

[0010] Preferably, after performing the second diagnostic operation, the method further includes the following steps: The upper level neighbor matches the fault port address in the upstream diagnostic message with the corresponding routing table to obtain an associated table entry; Perform communication diagnosis according to the association table entry; The association table entry includes the fault port address.

[0011] Preferably, the communication recovery comprises the following steps: Traverse the local port routing table; The local port routing table is matched with the faulty port, and a corresponding recovery operation is performed according to the matching result.

[0012] Preferably, matching the local port routing table with the faulty port and performing a corresponding recovery operation according to the matching result includes: Matching satisfies the first recovery condition and executing the first recovery operation; The first recovery condition is specifically: all entries in the local port routing table are in a valid state; The first recovery operation specifically includes: restoring the table entry containing the faulty port to a valid state and generating a fault recovery message, and transmitting the fault recovery message to a neighbor at an upper level of the current layer.

[0013] Preferably, matching the local port routing table with the faulty port and performing a corresponding recovery operation according to the matching result includes: When the match satisfies the second recovery condition, the second recovery operation is performed; The second recovery condition is specifically: some entries of the local routing table are in an invalid state; The first recovery operation is specifically: after waiting for all entries in the local routing table to be in a valid state, the entry containing the faulty port is restored to a valid state and a fault recovery message is generated, and the fault recovery message is transmitted to the upper-level neighbor of the current layer.

[0014] Preferably, after performing the first recovery operation, the method further includes the following steps: The upper level neighbor matches the fault port address in the upstream fault recovery message with the corresponding routing table, and performs the corresponding upstream recovery operation according to the matching result; When the first upstream recovery condition is met, the first upstream recovery operation is performed; The first upstream recovery condition is specifically: the table entries of the routing table of the upper-level neighbor already include table entries in a valid state, and there is a table entry in a valid state including the faulty port; The first upstream recovery operation is specifically: restoring the entry of the faulty port contained in the routing table of the upper-level neighbor to a valid state; When the second upstream recovery condition is met, the second upstream recovery operation is performed; The second upstream recovery condition is specifically: there is one and only one entry in the routing table of the upper-level neighbor that includes the valid state of the faulty port; The second upstream recovery operation is specifically: restoring the entry of the faulty port contained in the routing table of the upper-level neighbor to a valid state, and performing communication recovery on the routing table of the upper-level neighbor.

[0015] Preferably, the fault diagnosis message and the fault recovery message are queued and executed in a message queue in a first-in-first-out manner; The fault diagnosis message and the fault recovery message are executed in series, and only one fault diagnosis message or one fault recovery message is processed in each working cycle.

[0016] A communication diagnosis and recovery method provided by the present invention comprises the following steps: when there is a faulty port, communication diagnosis is performed; after the faulty port is maintained, communication recovery is performed; this scheme is a communication diagnosis and recovery method proposed based on a hierarchical routing table, and is a communication diagnosis and recovery method that can be used for large-scale computing systems, and realizes communication diagnosis and recovery by dynamically generating a diagnosis message or a recovery message to reversely propagate and update a distributed routing table to an upstream neighbor, without user intervention and transparent to the upper layer, and has the characteristics of low communication diagnosis delay, small communication performance loss and high communication stability; communication diagnosis effectively avoids a faulty communication link by invalidating the routing table entry where the faulty port is located, maintains stable communication and maximizes the available communication link to improve communication performance; communication recovery takes the faulty port as the starting point, and restores the invalid table entries layer by layer, thereby restoring the communication to the communication state and performance before the fault. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0018] Figure 1 A flow chart of a communication diagnosis and recovery method according to an embodiment of the present invention; Figure 2 A flow chart of communication diagnosis in an embodiment of the present invention; Figure 3 The figure is a flow chart of communication recovery in an embodiment of the present invention. DETAILED DESCRIPTION

[0019] In order to enable those skilled in the art to better understand the technical solutions in this application, the technical solutions in the embodiments of this application will be clearly and completely described below. Obviously, the described embodiments are only part of the embodiments of this application, not all of them. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0020] The embodiments of the present invention are written in a progressive manner.

[0021] The embodiment of the present invention provides a communication diagnosis and recovery method, which mainly solves the technical problems in the prior art of large communication performance loss and weak communication stability during the communication system fault diagnosis and recovery process, as well as low efficiency and high overhead of the communication diagnosis and recovery process.

[0022] like Figure 1As shown, a communication diagnosis and recovery method comprises the following steps: S1. When there is a faulty port, perform communication diagnosis; S2. After the faulty port is maintained, communication is restored.

[0023] In step S1, communication diagnosis refers to setting the communication link including the faulty port to an invalid state to avoid communication passing through the faulty port, thereby maintaining communication stability.

[0024] In step S2, communication recovery refers to restoring the communication link set to an invalid state in the fault diagnosis of step S1 to the communication state and performance before the fault after the fault port is maintained.

[0025] like Figure 2 As shown, step S1 includes the following steps: A1. Traverse the local port routing table; A2. Match the local port routing table with the faulty port and perform corresponding diagnostic operations based on the matching result.

[0026] In step A1, the local port routing table may be a local input port routing table; the local port routing table includes: a port number, a port address, and a target address.

[0027] It should be noted that in steps A1 to A2, when the switch detects the existence of a local faulty port, each local port of the switch is traversed, all entries in the local port routing table are matched one by one with the entries of the faulty port, and corresponding diagnostic operations are performed according to the matching results; the matching results include: a first diagnostic condition and a second diagnostic condition; the diagnostic operations include: a first diagnostic operation and a second diagnostic operation.

[0028] Preferably, step A2 comprises: B1. When the first diagnostic condition is met, the first diagnostic operation is performed; The first diagnostic condition is specifically: there is a table entry containing the valid state of the faulty port and there is a table entry not containing the valid state of the faulty port in the local port routing table; The first diagnostic operation is specifically: setting the table entry containing the faulty port to an invalid state.

[0029] It should be noted that the valid state of an entry means that the entry does not have an invalid flag set, and the valid state of an entry means that the entry has an invalid flag set; In this embodiment, satisfying the first diagnostic condition indicates that there is at least one communication link that reaches the target address through other ports. In this case, the entry containing the faulty port is set to an invalid state, and there is no need to generate an upstream diagnostic message.

[0030] B2. When the second diagnostic condition is met, the second diagnostic operation is performed; The second diagnostic condition is specifically: there is one and only one entry in the local port routing table that includes the valid state of the faulty port; The second diagnostic operation is specifically: setting the table entry containing the valid state of the faulty port to an invalid state, generating an upstream diagnostic message, and sending the upstream diagnostic message to the upper-level neighbor of the current layer.

[0031] In this embodiment, satisfying the second diagnostic condition indicates that there does not exist any communication link that can reach the target address. At this time, the table entry containing the valid state of the faulty port is set to an invalid state, and an upstream diagnostic message is generated at the same time. The upstream diagnostic message is sent to the upper-level neighbor of the current level. The upstream neighbors are informed step by step through the upstream diagnostic message that communication with the target address is impossible; the upstream diagnostic message includes the faulty port number and the faulty port address.

[0032] Preferably, after step B2, the method further comprises the following steps: C1. The upper-level neighbor matches the fault port address in the upstream diagnostic message with the corresponding routing table to obtain the associated table entry; C2. Perform communication diagnosis based on the associated table entries; The association table entry includes the fault port address.

[0033] It should be noted that in step C1, the association table entry is obtained by matching the address of the faulty port with the switch router address of the upper-level neighbor to obtain a unique table entry containing the faulty address as the association table entry; the communication diagnosis based on the association table entry in step C2 specifically refers to the communication diagnosis of step S1 on the association table, wherein the traversal of the local port routing table in sub-step A1 of step S1 is replaced by traversal of the association table entry.

[0034] The specific steps of the communication diagnosis process in this scheme are as follows: after the faulty port is detected, each input port of the local routing table where the faulty port is located is traversed starting from the faulty port, all the table items of the port are traversed one by one, and the faulty port is matched with the local port routing table, specifically, the faulty port table items and the target address of the faulty port are matched with the table items of the local port routing table one by one. When it is matched that there is a table item containing the valid state of the faulty port and there is a table item that does not contain the valid state of the faulty port in the local port routing table (i.e., the first diagnostic condition), the table item containing the faulty port is set to an invalid state (i.e., the first diagnostic operation), and no fault diagnosis message is generated at this time; when it is matched that there is only one table item containing the valid state of the faulty port in the local port routing table When (i.e., the second diagnostic condition), the table entry containing the valid state of the faulty port is set to an invalid state, and an upstream diagnostic message is generated at the same time, and the upstream diagnostic message is sent to the upper-level neighbor of the current layer (i.e., the second diagnostic operation); when the upper-level neighbor receives the fault diagnosis message from the downstream, the upper-level neighbor matches the faulty port address in the upstream diagnostic message with the corresponding routing table to obtain the table entry including the faulty port address as the associated table entry; the associated table entry is fault diagnosed, that is, the associated table entry is matched with the faulty port, and the corresponding diagnostic operation is performed according to the matching result, so as to realize the communication diagnosis step by step, and the communication link containing the faulty port is changed to an invalid state; when all the links containing the faulty port are changed to an invalid state, the communication diagnosis is completed. This process can invalidate the path of the communication link containing the faulty port in the reverse transmission of the fault diagnosis message, and at the same time, it can also maximize the number of other valid paths.

[0035] like Figure 3 As shown, step S2 includes the following steps: D1. Traverse the local port routing table; D2. Match the local port routing table with the faulty port, and perform corresponding recovery operations according to the matching result.

[0036] Preferably, step D2 comprises: E1. Matching satisfies the first recovery condition and performing the first recovery operation; The first restoration condition is specifically: all entries in the local port routing table are in a valid state; The first recovery operation is specifically: restoring the entry containing the faulty port to a valid state and generating a fault recovery message, and transmitting the fault recovery message to the upper-level neighbor of the current layer.

[0037] E2. When the match satisfies the second recovery condition, the second recovery operation is performed; The second recovery condition is specifically: some entries in the local routing table are in an invalid state; The first recovery operation is specifically: after waiting for all entries in the local routing table to be in a valid state, the entry containing the faulty port is restored to a valid state and a fault recovery message is generated, and the fault recovery message is transmitted to the upper-level neighbor of the current layer.

[0038] It should be noted that communication recovery starts with restoring the local routing table containing the faulty port, and completes communication recovery step by step. When all entries in the local port routing table are in a valid state, a fault recovery message is generated and transmitted to the previous level neighbor of the current level; the matching result also includes the first recovery condition and the second recovery condition; the recovery operation includes the first recovery operation and the second recovery operation.

[0039] Preferably, after step E1, the following steps are also included: The upper-level neighbor matches the fault port address in the upstream fault recovery message with the corresponding routing table, and performs the corresponding upstream recovery operation according to the matching result; It should be noted that the matching result also includes a first upstream recovery condition and a second upstream recovery condition; the upstream recovery operation includes a first upstream recovery operation and a second upstream recovery operation.

[0040] F1. When the match meets the first upstream recovery condition, the first upstream recovery operation is performed; The first upstream recovery condition is specifically: the table entries of the routing table of the upper level neighbor already include table entries in a valid state, and there is a table entry in a valid state including the faulty port; The first upstream recovery operation is specifically: restoring the entry of the faulty port contained in the routing table of the upper level neighbor to a valid state; F2. When the second upstream recovery condition is met, the second upstream recovery operation is performed; The second upstream recovery condition is specifically: there is one and only one entry in the routing table of the upper-level neighbor that includes the valid state of the faulty port; The second upstream recovery operation is specifically: restoring the entry of the faulty port contained in the routing table of the upper-level neighbor to a valid state, and performing communication recovery on the routing table of the upper-level neighbor.

[0041] It should be noted that the communication recovery of the routing table of the upper-level neighbor in the second upstream recovery operation in step F2 specifically refers to: performing communication recovery of step S2 on the local routing table of the upper-level neighbor, that is, traversing the routing table of the upper-level neighbor for a second time, matching the faulty port with the routing table of the upper-level neighbor, and performing communication recovery operation according to the matching result, with the purpose of recursively determining again that all entries in the routing table of the upper-level neighbor are in a valid state; when all entries of the upper-level neighbor are in a valid state, generating a fault recovery message, and transmitting the fault recovery message to the upper-level neighbor of the current level.

[0042] The specific steps of the communication recovery process in this scheme are as follows: after the faulty port is maintained, starting from the faulty port, each input port of the local routing table where the faulty port is located is traversed, all the table items of the port are traversed one by one, and the table items of the faulty port are matched with the local port routing table. When all the table items matched to the local port routing table are in a valid state (i.e., the first recovery condition), the table items containing the faulty port are restored to a valid state and a fault recovery message is generated, and the fault recovery message is transmitted to the upper-level neighbor of the current level (i.e., the second recovery operation); when some table items matched to the local routing table are in an invalid state (i.e., the second recovery condition), after waiting for all the table items in the local routing table to be in a valid state, the table items containing the faulty port are restored to a valid state and a fault recovery message is generated, and the fault recovery message is transmitted to the upper-level neighbor of the current level (i.e., the second recovery operation); when the upper-level neighbor receives the fault recovery message from the downstream, the upper-level neighbor matches the corresponding routing table according to the faulty port address in the upstream fault recovery message. The corresponding upstream recovery operation is performed according to the matching result. When the table items in the routing table of the upper-level neighbor are matched to include table items in the valid state, and there are table items including the valid state of the faulty port (i.e., the first upstream recovery condition), the table items of the faulty port contained in the routing table of the upper-level neighbor are restored to the valid state (i.e., the first upstream recovery operation); when there is and only one table item in the routing table of the upper-level neighbor that includes the valid state of the faulty port (i.e., the second upstream recovery condition), the table item of the faulty port contained in the routing table of the upper-level neighbor is restored to the valid state, and the communication of the routing table of the upper-level neighbor is restored (i.e., the second upstream recovery operation). When all routing table items of all levels are in the valid state, the communication diagnosis is completed. In this process, the path of the communication link containing the faulty port can be restored in the reverse transmission of the fault recovery message until the communication is restored to the communication state and performance before the fault.

[0043] Preferably, the fault diagnosis message and the fault recovery message are queued and executed in a first-in-first-out manner in the message queue; Fault diagnosis messages and fault recovery messages are executed serially, and only one fault diagnosis message or fault recovery message is processed in each working cycle.

[0044] It should be noted that large-scale communication systems need to allow fault accumulation and regularly restore and maintain communication faults. When there are multiple fault events or multiple recovery events at the same time, this solution can achieve the same diagnostic or recovery effect for communication diagnosis operations and communication recovery operations performed in different sequences. The present invention adopts four principles in processing fault diagnosis messages or fault recovery messages: 1) Fault diagnosis messages and fault recovery messages are queued and executed in a first-in-first-out manner in the message queue; 2) The message queue is immediately cleared when a fault occurs and then a local fault diagnosis message is generated; 3) When a local fault port is detected, the fault diagnosis message and fault recovery message are discarded, and a local fault recovery message is generated immediately after the fault is maintained; 4) Fault diagnosis messages and fault recovery messages are executed serially, and only one fault diagnosis message or fault recovery message is processed in each working cycle.

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

[0046] In addition, all functional modules in the embodiments of the present invention may be integrated into one processor, or each module may be a separate device, or two or more modules may be integrated into one device; each functional module in the embodiments of the present invention may be implemented in the form of hardware or in the form of hardware plus software functional units.

[0047] A person of ordinary skill in the art can understand that all or part of the steps of implementing the above method embodiment can be completed by program instructions and related hardware. The aforementioned program instructions can be stored in a computer-readable storage medium. When the program instructions are executed, the steps of the above method embodiment are executed; and the aforementioned storage medium includes: a mobile storage device, a read-only memory (ROM), a magnetic disk or an optical disk, and other media that can store program codes.

[0048] It should be understood that the use of "system", "device", "unit" and / or "module" in this application is only a method for distinguishing different components, elements, parts, parts or assemblies at different levels. However, if other words can achieve the same purpose, the word can be replaced by other expressions.

[0049] As shown in this application and claims, unless the context clearly indicates an exception, the words "a", "an", "a kind" and / or "the" do not refer to the singular, but also include the plural. Generally speaking, the terms "include" and "comprise" only indicate the inclusion of clearly identified steps and elements, and these steps and elements do not constitute an exclusive list. The method or device may also include other steps or elements. The elements defined by the sentence "includes a..." do not exclude the existence of other identical elements in the process, method, commodity or device that includes the elements.

[0050] If a flow chart is used in the present application, the flow chart is used to illustrate the operations performed by the system according to the embodiment of the present application. It should be understood that the preceding or following operations are not necessarily performed accurately in order. On the contrary, each step can be processed in reverse order or simultaneously. At the same time, other operations can also be added to these processes, or a certain step or several steps of operations can be removed from these processes.

[0051] A method and system for preparing tobacco extract provided by the present invention are described in detail above. The above description of the disclosed embodiments enables professionals and technicians in the field to implement or use the present invention. The various modifications to these embodiments will be apparent to professionals and technicians in the field, and the general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to these embodiments shown herein, but will conform to the widest range consistent with the principles and novel features disclosed herein.

Claims

1. A communication diagnosis and recovery method, characterized in that: The steps include: When there is a faulty port, perform communication diagnosis; After the faulty port is maintained, communication is restored.

2. A communication diagnosis and recovery method according to claim 1, characterized in that: The communication diagnosis comprises the following steps: Traverse the local port routing table; The local port routing table is matched with the faulty port, and a corresponding diagnostic operation is performed according to the matching result.

3. A communication diagnosis and recovery method according to claim 2, characterized in that: The matching of the local port routing table with the faulty port and performing a corresponding diagnostic operation according to the matching result includes: When the match satisfies the first diagnostic condition, a first diagnostic operation is performed; The first diagnostic condition is specifically: there is a table entry containing the valid state of the faulty port and there is a table entry not containing the valid state of the faulty port in the local port routing table; The first diagnostic operation specifically includes: setting the entry containing the faulty port to an invalid state.

4. A communication diagnosis and recovery method according to claim 2, characterized in that: The matching of the local port routing table with the faulty port and performing corresponding operations according to the matching result includes: When the second diagnostic condition is met, the second diagnostic operation is performed; The second diagnostic condition is specifically: there is one and only one entry in the local port routing table that includes the valid state of the faulty port; The second diagnostic operation is specifically: setting the table entry containing the valid state of the faulty port to an invalid state, generating an upstream diagnostic message, and sending the upstream diagnostic message to an upper-level neighbor of the current layer.

5. A communication diagnosis and recovery method according to claim 4, characterized in that: After the second diagnostic operation is performed, the method further includes the following steps: The upper level neighbor matches the fault port address in the upstream diagnostic message with the corresponding routing table to obtain an associated table entry; Perform communication diagnosis according to the association table entry; The association table entry includes the fault port address.

6. A communication diagnosis and recovery method according to claim 5, characterized in that: The communication recovery comprises the following steps: Traverse the local port routing table; The local port routing table is matched with the faulty port, and a corresponding recovery operation is performed according to the matching result.

7. A communication diagnosis and recovery method according to claim 6, characterized in that: The matching of the local port routing table with the faulty port and performing a corresponding recovery operation according to the matching result includes: Matching satisfies the first recovery condition and executing the first recovery operation; The first recovery condition is specifically: all entries in the local port routing table are in a valid state; The first recovery operation specifically includes: restoring the entry containing the faulty port to a valid state and generating a fault recovery message, and transmitting the fault recovery message to a neighbor at an upper level of the current layer.

8. A communication diagnosis and recovery method according to claim 6, characterized in that: The matching of the local port routing table with the faulty port and performing a corresponding recovery operation according to the matching result includes: When the match satisfies the second recovery condition, the second recovery operation is performed; The second recovery condition is specifically: some entries of the local routing table are in an invalid state; The first recovery operation is specifically: after waiting for all entries in the local routing table to be in a valid state, the entry containing the faulty port is restored to a valid state and a fault recovery message is generated, and the fault recovery message is transmitted to the upper-level neighbor of the current layer.

9. A communication diagnosis and recovery method according to claim 7, characterized in that: After the first recovery operation is performed, the following steps are also included: The upper level neighbor matches the fault port address in the upstream fault recovery message with the corresponding routing table, and performs the corresponding upstream recovery operation according to the matching result; When the first upstream recovery condition is met, the first upstream recovery operation is performed; The first upstream recovery condition is specifically: the table entries of the routing table of the upper-level neighbor already include table entries in a valid state, and there is a table entry including the valid state of the faulty port; The first upstream recovery operation is specifically: restoring the entry of the faulty port contained in the routing table of the upper-level neighbor to a valid state; When the second upstream recovery condition is met, the second upstream recovery operation is performed; The second upstream recovery condition is specifically: there is one and only one entry in the routing table of the upper-level neighbor that includes the valid state of the faulty port; The second upstream recovery operation is specifically: restoring the entry of the faulty port contained in the routing table of the upper-level neighbor to a valid state, and performing communication recovery on the routing table of the upper-level neighbor.

10. A communication diagnosis and recovery method according to claims 7-9, characterized in that: The fault diagnosis message and the fault recovery message are queued and executed in a first-in-first-out manner in the message queue; The fault diagnosis message and the fault recovery message are executed in series, and only one fault diagnosis message or one fault recovery message is processed in each working cycle.