Inter-ring backup method and device of DRP ring network
By receiving announcement messages in the DRP ring network and electing the primary and backup ports in the connectivity domain, the problems of long recovery time and asymmetric backup in the DRP ring network are solved, and fast recovery and symmetric backup are realized, which is suitable for controlling recovery time and symmetry. Highly demanding application scenarios.
Patent Information
- Application Number
- CN202411057165.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-02
- Publication Date
- 2024-10-11
AI Technical Summary
The existing DRP ring network takes a long time to recover after a network abnormality, and the backup between rings is asymmetric, making it difficult to meet the rapid recovery and symmetry requirements of industrial control and other fields.
By receiving the announcement message from the opposite end of the ring network, the network status is determined, the primary backup port is elected in each connectivity domain, and the secondary backup port is set to the blocking state to realize the backup of the inter-ring link, reduce the network recovery time, and ensure multiple Symmetrical configuration between rings.
It achieves rapid recovery after network abnormalities, reduces recovery time, supports normal communication when the ring network is broken into multiple segments, and meets symmetry requirements. It is suitable for application scenarios that require high network recovery time and symmetry.
Smart Images

Figure CN118764337A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of Ethernet communication technology, and in particular to a method and device for inter-ring backup of a DRP ring network. Background Art
[0002] Ethernet redundancy technologies commonly use the Spanning Tree Protocol (STP), Rapid Spanning Tree Protocol (RSTP), or Multiple Spanning Tree Protocol (MSTP). However, these communication protocols typically have a network recovery time of several seconds to tens of seconds after a network anomaly.
[0003] To meet the rapid recovery requirements after network anomalies in industrial control, automated communications, and other fields, high-performance ring networks, particularly Distributed Ring Protection (DRP), are often used. However, the inter-ring redundancy recovery time in DRP ring networks is typically only in seconds, creating a performance bottleneck for practical applications. Furthermore, because existing DRP ring networks can only configure inter-ring redundancy on a single ring, the two rings are asymmetrical, making them difficult to apply in applications requiring high network symmetry. Summary of the Invention
[0004] In view of the above problems in the prior art, the present application provides a DRP ring network inter-ring backup method and device, which can not only reduce the network recovery time after a network anomaly, but also realize symmetrical backup of backup information on two rings, thereby expanding the scope of application.
[0005] To achieve the above-mentioned purpose, the first aspect of the present application provides a DRP ring network inter-ring backup method, comprising: receiving a declaration message sent by the opposite ring network, the declaration message including the opposite ring network identification information; determining the network status of the opposite ring network and the local ring network according to the opposite ring network identification information and the local ring network identification information, the network status including the Active state or the Inactive state, and setting the backup port corresponding to the ring network with the Inactive state to the forwarding state; dividing the backup port corresponding to the ring network with the Active state into a connectivity domain according to the opposite ring network identification information, wherein each connectivity domain includes a backup port with the same opposite ring network identification information; electing a master backup port in each connectivity domain, and setting the elected master backup port to the forwarding state, and setting the backup port that has not been elected in each connectivity domain as a slave backup port, and setting the slave backup port to the blocking state.
[0006] From the above, the sending cycle of the declaration message is generally about 10ms, that is, a declaration message is sent every 10ms or so, and the process of network status generally takes 30-50ms, and the division of the connectivity domain and the election of the primary and backup ports generally also take 30-50ms. Therefore, when a fault occurs in the network topology, based on the method of the present application, the switching time of the entire execution process can be controlled within 100ms. Compared with the switching time of other protocols in the prior art, such as the process based on the STP protocol, the required switching time reaches the second level. The present application greatly reduces the network recovery time. In addition, the election mechanism of the present application is extended from the ring to the connectivity domain, supporting the backup of the links between the rings, so that when the ring network is broken into multiple segments, the normal communication of the network can still be guaranteed. Based on the solution of the present application, the entire ring network is made into a symmetrical structure by dividing the connectivity domain of the backup port, so that it is also symmetrically backed up in configuration, so that the configurations between multiple ring networks can be kept consistent, meeting the application scenarios with high network symmetry requirements.
[0007] As an implementation manner of the first aspect, the ring network identifier includes a ring network ID and a root switch ID.
[0008] As an implementation method of the first aspect, determining the network status of the opposite ring network and the local ring network based on the opposite ring network identification information and the local ring network identification information includes: comparing the ring network ID of the opposite ring network with the ring network ID of the local ring network, and determining the network status of the ring network based on the comparison result of the ring network IDs; when the ring network ID of the opposite ring network is the same as the ring network ID of the local ring network, comparing the root switch ID of the opposite ring network with the root switch ID of the local ring network, and determining the network status of the ring network based on the comparison result of the root switch IDs.
[0009] As described above, by setting the comparison priority between the ring network ID and the root switch ID, the number of network switching times can be reduced in some specific fault scenarios.
[0010] As an implementation method of the first aspect, the backup ports corresponding to the ring network with the network status as Active are divided into connectivity domains according to the opposite ring network identification information, including: in the ring network with the network status as Active, the backup ports with the same root switch ID are classified into the same connectivity domain.
[0011] As described above, the election mechanism of the present application is extended from the ring to the connected domain, supporting the backup of the inter-ring links, thereby ensuring normal network communication when the ring network is broken into multiple segments.
[0012] As an implementation method of the first aspect, it also includes: when a link within the local ring network and / or the opposite ring network fails but does not cause a change in the divided connectivity domain, the network status of the local ring network and the opposite ring network and the status of the backup port corresponding to each end ring network remain unchanged.
[0013] As an implementation method of the first aspect, it also includes: when a link between the local ring network and the opposite ring network for connecting the primary and backup ports fails and causes the divided connectivity domain to change, the connectivity domain is re-divided according to the opposite ring network identification information, and the primary and backup ports are re-elected and the status of each backup port is set within the new connectivity domain.
[0014] As an implementation method of the first aspect, it also includes: when a link within the local ring network and / or the opposite ring network fails and causes the divided connectivity domain to change, the connectivity domain is re-divided according to the opposite ring network identification information, and the primary and backup ports are re-elected and the status of each backup port is set within the new connectivity domain.
[0015] From the above, under the above-mentioned various fault conditions, the method of the present application can ensure the normal operation of the ring network.
[0016] As an implementation of the first aspect, the method further includes: when a topology change is detected within the DRP ring network but does not result in a status change of the backup port, sending a table clearing notification to a device within the DRP ring network to notify the device to clear and update the forwarding table; when a topology change is detected outside the DRP ring network and results in a status change of the backup port, sending a table clearing notification to the device within the DRP ring network and the opposite ring network device of the DRP ring network to notify the device to clear and update the forwarding table.
[0017] From the above, when the network topology changes, the correctness of the forwarding path can be ensured by sending a clear table notification.
[0018] A second aspect of the present application provides a backup method for train networking, comprising: dividing the switching equipment of each carriage into two independent DRP ring networks; the DRP ring network is used to execute any of the methods described in the first aspect above.
[0019] The beneficial effects of this aspect can also be found in the description of the beneficial effects of each part of the first aspect above.
[0020] The third aspect of the present application provides an inter-ring backup device for a DRP ring network, comprising: a receiving module for receiving a declaration message sent by a peer ring network, the declaration message including the peer ring network identification information; a determining module for determining the network status of the peer ring network and the local ring network based on the peer ring network identification information and the local ring network identification information, the network status including the Active state or the Inactive state, and setting the backup port corresponding to the ring network with the Inactive state to the forwarding state; a dividing module for dividing the backup port corresponding to the ring network with the Active state into connectivity domains based on the peer ring network identification information, wherein each connectivity domain includes a backup port with the same peer ring network identification information; an election module for electing a master backup port in each connectivity domain, setting the elected master backup port to the forwarding state, setting the backup port that has not been elected in each connectivity domain as a slave backup port, and setting the slave backup port to the blocking state.
[0021] The beneficial effects of this aspect can also be found in the description of the beneficial effects of each part of the first aspect above.
[0022] A fourth aspect of the present application provides a computing device, comprising: at least one processor; and at least one memory, connected to the processor and storing program instructions, wherein when the program instructions are executed by the at least one processor, the at least one processor executes the inter-ring backup method for a DRP ring network according to any one of the first aspects.
[0023] The beneficial effects of this aspect can also be found in the description of the beneficial effects of each part of the first aspect above.
[0024] A sixth aspect of the present application provides a computer-readable storage medium having program instructions stored thereon. When the program instructions are executed by a computer, the computer executes the inter-ring backup method for a DRP ring network according to any one of the first aspects.
[0025] The beneficial effects of this aspect can also be found in the description of the beneficial effects of each part of the first aspect above. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] The following further illustrates the various technical features of the present application and the relationships between them with reference to the accompanying drawings. The accompanying drawings are exemplary, and some technical features are not shown in actual proportion. In addition, some drawings may omit technical features that are commonly used in the technical field to which the present application belongs and are not essential for understanding and implementing the present application, or additional technical features that are not essential for understanding and implementing the present application may be shown. In other words, the combination of the various technical features shown in the accompanying drawings is not intended to limit the present application. In addition, throughout the present application, the same figure numbers refer to the same content. The specific description of the drawings is as follows:
[0027] Figure 1 A schematic diagram of the network topology of a DRP ring network provided in an embodiment of the present application;
[0028] Figure 2 A flowchart of a DRP ring network inter-ring backup method provided in an embodiment of the present application;
[0029] Figure 3 A schematic diagram of the network topology structure when encountering the first type of failure provided in an embodiment of the present application;
[0030] Figure 4 A schematic diagram of a network topology structure when encountering the second type of failure provided in an embodiment of the present application;
[0031] Figure 5 A schematic diagram of a network topology structure when encountering the third type of failure provided in an embodiment of the present application;
[0032] Figure 6 A schematic diagram of a network topology structure when encountering the fourth type of fault provided in an embodiment of the present application;
[0033] Figure 7 A schematic diagram of the network topology of a train network provided in an embodiment of the present application;
[0034] Figure 8 A schematic diagram of the structure of an inter-ring backup device of a DRP ring network provided in an embodiment of the present application;
[0035] Figure 9 A schematic diagram of the structure of a computing device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0036] The technical solution provided by this application is further described below with reference to the accompanying drawings and examples. It should be understood that the system structure and business scenarios provided in the examples of this application are mainly for illustrating possible implementation methods of the technical solution of this application and should not be interpreted as the sole limitation of the technical solution of this application. It is known to those skilled in the art that with the evolution of the system structure and the emergence of new business scenarios, the technical solution provided by this application is also applicable to similar technical problems.
[0037] It should be understood that the embodiments of the present application provide an inter-ring backup solution for a DRP ring network. Because these technical solutions solve the same or similar problems, some repetitions may not be repeated in the following specific embodiments. However, these specific embodiments should be considered as cross-references and can be combined with each other.
[0038] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the art in the art of this application. In the event of any inconsistency, the meaning described in this specification or the meaning derived from the contents recorded in this specification shall prevail. In addition, the terms used herein are only for the purpose of describing the embodiments of the present application and are not intended to limit this application.
[0039] Before further explaining the specific embodiments of the present application in detail, the nouns and terms involved in the embodiments of the present application, as well as their corresponding uses, effects, and functions in the present application, are explained. The nouns and terms involved in the embodiments of the present application are subject to the following interpretations:
[0040] Root switch: refers to the top switch in the spanning tree structure and the logical center.
[0041] First, the application scenario of the inter-ring backup solution of the DRP ring network provided by the embodiment of the present application is introduced.
[0042] The inter-ring backup solution for the DRP ring network provided herein provides high network reliability and rapid fault recovery capabilities, making it particularly suitable for application scenarios requiring high redundancy and low-latency recovery. For example, in the field of industrial automation control, specifically in the manufacturing industry, especially in automated production lines, network delays or failures can cause production halts and even significant economic losses. The inter-ring backup solution for the DRP ring network provided herein can achieve rapid recovery after failures, ensuring real-time transmission of signals and data, thereby maintaining continuity in the production process and improving production efficiency. Another example is that it can also be applied in the fields of urban rail transit or intelligent transportation, specifically in urban rail transit such as subways and light rail. Signal control and communication transmission rely on highly reliable network structures, and network failures can affect the safety of train scheduling and operation. The inter-ring backup solution for the DRP ring network provided herein can ensure that even if a failure occurs within a network segment, the entire system can still operate uninterrupted. Another example is that it can also be applied in data centers. The solution provided herein provides redundant paths and rapid switching capabilities in the event of network hardware failures, ensuring data loss and reliable service, thereby improving business continuity. For another example, it can also be applied to the field of smart grids. Smart grids rely on the collection and analysis of real-time data to optimize energy distribution. Any network interruption may affect energy management and distribution efficiency, and even cause safety accidents. The solution provided in this application provides a stable communication foundation for smart grids, improving the reliability and security of the system.
[0043] It should be understood that the above application scenarios are exemplary descriptions and are not intended to limit the scope of this application.
[0044] The following is a detailed description of a DRP ring network inter-ring backup method provided by the application embodiment with reference to the accompanying drawings. Figure 1 The network topology shown is taken as an example to illustrate the specific implementation process of the inter-ring backup method of the DRP ring network.
[0045] like Figure 1 As shown, the network topology in this example includes DRP ring network T and DRP ring network D. Links L1, L2, and L3 are the three links connecting ring network T and ring network D. The ports connected at both ends of each link are configured as backup ports for their respective ring networks. That is, Port_T1, Port_T2, and Port_T3 are the three backup ports of ring network T, and Port_D1, Port_D2, and Port_D3 are the three backup ports of ring network D. Based on this network topology connection relationship, it can be seen that ring network T and ring network D are each other's peer networks. That is, if ring network T is the local network, then ring network D is its peer network; if ring network D is the local network, then ring network T is its peer network.
[0046] like Figure 2 As shown, the DRP ring network inter-ring backup method includes steps S110-S140:
[0047] S110: Receive a declaration message sent by the opposite ring network, where the declaration message includes identification information of the opposite ring network.
[0048] In this embodiment, ring network T receives a declaration message regarding the network identification information of ring network D from its peer network, ring network D, via backup ports Port_T1, Port_T2, and Port_T3. Similarly, ring network D receives a declaration message regarding the network identification information of its peer network, ring network T, via backup ports Port_D1, Port_D2, and Port_D3. These declaration messages are sent periodically according to a preset period.
[0049] In this embodiment, the ring network identifier includes the ID of each ring network and the ID of the root switch in each ring network. The ID of each ring network is manually configured. In this embodiment, the ID of ring network T is configured as RingT_MAC_T, and the ID of ring network D is configured as RingD_MAC_D. The ID of the root switch in each ring network is generally the MAC address of the corresponding switch. Due to the uniqueness of the root switch, its corresponding MAC address is also unique.
[0050] S120: Determine the network status of the opposite ring network and the local ring network according to the opposite ring network identification information and the local ring network identification information, wherein the network status includes an Active state or an Inactive state, and set the backup port corresponding to the ring network with the Inactive state to a forwarding state.
[0051] In this step, the network status of the opposite ring network and the local ring network is determined using the identification information of the opposite ring network and the identification information of the local ring network. Specifically, the ring network ID of the opposite ring network is compared with the ring network ID of the local ring network, and the network status of the ring network is determined based on the comparison result of the ring network IDs. If the ring network IDs of the opposite ring network and the local ring network do not compare to each other (i.e., they are the same), the root switch IDs of the two ends are then compared, and the network status of the ring network is determined based on the comparison result of the root switch IDs.
[0052] As an implementation method, the identification information of the local ring network and the opposite ring network is compared in order, and the end with the larger value is selected as the Active state (active state), while the end with the smaller value is set to the Inactive state (inactive state). Specifically: First, the size of the local ring network ID and the opposite ring network ID are compared, and the end with the larger ring network ID value is selected as the Active state, while the end with the smaller ring network ID value is set to the Inactive state. If the ring network ID values of the two networks do not compare to determine the size (i.e., the sizes are the same), then the sizes of the Root switch IDs in the two networks are compared. Due to the uniqueness of the Root switch ID, the size can be compared to determine the size. The ring network on the side with the larger Root switch ID value is selected as the Active state, while the other side is set to the Inactive state. In this embodiment, all backup ports in the ring network determined to be in the Inactive state should be set to the forwarding state.
[0053] As another implementation, the ring end with the smaller ID value can be elected as Active, and the ring end with the larger ID value can be set to Inactive. If the ring IDs of the two networks do not compare to determine the same value (i.e., they are the same), the Root switch IDs of the two networks are then compared. Due to the uniqueness of the Root switch ID, the comparison guarantees a correct value. The ring end with the smaller Root switch ID value is elected as Active, and the other end is set to Inactive.
[0054] In this embodiment, the ID of ring network T is RingT_MAC_T, and the ID of ring network D is RingD_MAC_D. Since the two ring network IDs are different, their sizes can be directly compared. Here, we assume that the ID of ring network T is greater than that of ring network D (i.e., RingT_MAC_T > RingD_MAC_D). After receiving the announcement message from ring network D, ring network T compares its own ring ID with that of ring network D. Similarly, after receiving the announcement message from ring network T, ring network D compares its own ring ID with that of ring network T. The comparison results on both ends indicate that the ID of ring network T is greater. Therefore, the backup ports Port_T1, Port_T2, and Port_T3 in the ring network corresponding to ring network T are set to the Active state, while the backup ports Port_D1, Port_D2, and Port_D3 in the ring network corresponding to ring network D are set to the Inactive state. At the same time, the backup ports Port_D1, Port_D2, and Port_D3 are set to the Forwarding state.
[0055] In this embodiment, if the IDs of ring network T and ring network D fail to compare, the root switch IDs of the two networks are compared. The root switch in a ring network is the only device elected through network election, so the MAC address of the root switch is unique. For example, the root switch ID in ring network T is Root_MAC_T, and the root switch ID in ring network D is Root_MAC_D. By comparing these root switch IDs, the active and inactive networks can be selected if the ring IDs cannot be compared. It should be understood that the root switch ID is also carried in the announcement message.
[0056] S130: Divide the backup ports corresponding to the ring network in the Active state into connected domains according to the peer ring network identification information, wherein each connected domain includes a backup port with the same peer ring network identification information.
[0057] The ring network identification information in this embodiment includes the ring network ID and the Root switch ID. Since the ring network ID is manually configured, and the Root switch ID is the only switch elected within the ring, the MAC address of this switch never changes. Therefore, connectivity domains in this embodiment can be divided based on the Root switch ID. That is, backup ports with the same peer Root switch ID are grouped into the same connectivity domain.
[0058] In the example of this embodiment, the backup ports Port_T1, Port_T2, and Port_T3 in the ring network corresponding to the ring network T are in the Active state. Therefore, connectivity domains are divided among the backup ports Port_T1, Port_T2, and Port_T3 in the Active state. Since the Root switch ID of the opposite ring network D received by Port_T1, Port_T2, and Port_T3 is Root_MAC_D, that is, Port_T1, Port_T2, and Port_T3 are backup ports with the same identification information of the opposite ring network, Port_T1, Port_T2, and Port_T3 belong to the same connectivity domain.
[0059] S140: Electing a primary backup port in each connectivity domain, setting the elected primary backup port to a forwarding state, and setting the unelected backup port in each connectivity domain as a secondary backup port, and setting the secondary backup port to a blocking state.
[0060] In this embodiment, backup ports in the same connectivity domain can communicate with the same ring network (the same ring network identifier indicates that it is the same ring network). When there are multiple backup ports in the connectivity domain, only one of these backup ports can be set to forward state (forward), and the others can be set to block state (block). Otherwise, data communication with the same ring network can be carried out via two or more backup ports. This state will cause data transmission confusion, so this situation needs to be avoided; and the backup ports in different connectivity domains communicate with different ring networks. Therefore, it is necessary to divide the connectivity domains and elect the primary and backup ports in each connectivity domain.
[0061] Specifically, backup ports within a ring network are elected among backup ports within the same connectivity domain. A master port, or primary backup port, is elected within a connectivity domain, and the remaining ports within the domain are slave ports. The master port is set to forwarding mode, while the slave ports are set to blocking mode.
[0062] In this embodiment, an election is performed among backup ports Port_T1, Port_T2, and Port_T3 within the same connectivity domain. For example, Port_T1 is elected as the Master and is set to the Forwarding state. Port_T2 and Port_T3 are elected as Slaves and are set to the Blocking state. Ring network D is elected to the Inactive state in step S120, and its backup ports Port_D1, Port_D2, and Port_D3 are set to the Forwarding state in step S120.
[0063] Based on the status settings of the above backup ports, when the network is normal, ring network T and ring network D communicate through link L1 between Port_T1 and Port_D1. Since Port_T2 and Port_T3 are in the blocked state, links L2 and L3 are logically blocked.
[0064] Next, we will introduce the network switching, port election, and status setting processes when encountering different faults.
[0065] The first type of failure is when a link failure occurs within the local and / or remote networks, but does not change the connected domain. Due to the ID priority rules of the ring network configuration and the redundant design of DRP, the status of each network (Active / Inactive) and the Master election results usually remain unchanged.
[0066] For example: Figure 3 As shown, link LD_1, connecting Port_D1 and Port_D2 within ring network D, is disconnected, and link LT_3, connecting Port_T2 and Port_T3 within ring network T, is disconnected. Clearly, this means that a link in each ring network has been disconnected, transforming the ring network into a chain network at both ends. At this point, the entire network can still communicate normally. Although the transition from a ring network to a chain network may cause the elected root switch to change, the ID priority rule set in this solution requires comparing ring IDs first. Therefore, in network D, the network ID remains RingD_MAC_D, and in network T, the network ID remains RingD_MAC_T. Therefore, even if the network breaks from a ring to a chain, RingD_MAC_T still exceeds RingD_MAC_D. Therefore, network T remains in the Active state, while network D remains in the Inactive state. Similarly, the ports Port_T1, Port_T2, and Port_T3 in the Active state still belong to the same connectivity domain (even if the Root switch elected in network D changes, the Root switch ID received by each port remains the same). Therefore, if the ports in the connectivity domain do not change, the Master and Slave elections will not change either.
[0067] As an implementation method, in this fault type, when a topology change is detected in each ring network but does not cause a change in the status of the backup port (Master, Salve, Inactive), it is necessary to send a table clearing notification to the devices in each ring to notify the relevant devices to clear and update the forwarding table, thereby ensuring the correct forwarding path.
[0068] This shows that in this fault situation, the reliability of network communication can still be guaranteed without network switching.
[0069] The second type of fault described below occurs when the link between the primary and backup ports on the local and remote ring networks fails. That is, the primary and backup ports enter the linkdown state. At this time, the network status (Active / Inactive) at each end remains unchanged. Because the primary and backup ports are linkdown, it is necessary to re-elect a master from the secondary and backup ports within the connected domain and change the status of the related backup ports.
[0070] For example: Figure 4 As shown, the link LD_1 connecting Port_D1 and Port_D2 in the ring network D is disconnected, and the link LT_3 connecting Port_T2 and Port_T3 in the ring network T is disconnected. Figure 3 After the link L1 between ring networks D and T, which connects Port_D1 and Port_T1, fails again, Port_D1 and Port_T1 on both ends of link L1 enter the linkdown state. At this point, the networks at both ends can still communicate normally. Similarly, by comparing the ring ID, RingD_MAC_T of ring network T is still greater, so the status of network T remains Active, and the status of network D remains Inactive. Since Port_T1 is in the linkdown state, the ring network identification information of the opposite network D does not change. Therefore, Port_T2 and Port_T3 belong to the same connectivity domain. In the new connectivity domain, Port_T2 and Port_T3 re-elect a master. If Port_T2 is elected as the master, Port_T2 is set to the forwarding state, while Port_T3 remains the slave, so Port_T2 is blocked.
[0071] As an implementation method, in this fault type, when the inter-ring link (i.e., the link outside the ring network) detects a topology change that leads to a backup port status change (Master, Salve, Inactive), it is necessary to send a clearing notification to the devices in each ring and the opposite ring network to ensure the correct forwarding path.
[0072] Network D and network T can communicate through the link L2 connecting Port_D2 and Port_T2, thereby ensuring normal communication of the networks.
[0073] The third type of failure introduced next is when a link failure occurs within the local and / or opposite network, causing the divided connectivity domain to change. At this time, it is necessary to divide the connectivity domain based on the opposite ring network identification information, and re-elect the primary and backup ports and re-set the status of each backup port within the new connectivity domain.
[0074] For example: Figure 5 As shown, the link LD_1 connecting Port_D1 and Port_D2 in the ring network D is disconnected, and the link LT_3 connecting Port_T2 and Port_T3 in the ring network T is disconnected. Figure 3 After the state is reached, the link LD_2 between Port_D5 and Port_D6 in the ring network D is disconnected again, causing the ring network T to be broken into a single chain network and the ring network D to be broken into two chain networks DL and DR, and both chains are in the ring open state. Based on this fault, if Figure 5It can be seen that network DL has a backup port Port_D1, and network DR has two backup ports Port_D2 and Port_D3. Through these three backup ports, a message announcing the local ring network identification information can be sent to the remote network T. After receiving the announcement message, network T performs a comparison and judgment. Since networks DL and DR are formed by the disconnection of ring network D, the network ID of network DL and network DR is still RingD_MAC_D (unchanged). Therefore, the comparison result is still RingD_MAC_T>RingD_MAC_D, so network T is in the Active state, while network DL and network DR are in the Inactive state. The connectivity domains of the backup ports in the active network are divided: Among the backup ports Port_T1, Port_T2, and Port_T3 on network T, Port_T1 receives its elected root switch ID (Root_MAC_D-L) from network DL, while Port_T2 and Port_T3 receive their elected root switch IDs (Root_MAC_D-R) from network DR. Because Root_MAC_D-L is the address of the root switch elected within network DL, and Root_MAC_D-R is the address of the root switch elected within network DR, the two addresses are different. Therefore, Port_T1 is divided into an independent connectivity domain, while Port_T2 and Port_T3 are divided into another independent connectivity domain. Then, the primary and backup ports are re-elected within their respective connectivity domains. Since Port_T1's corresponding connectivity domain has only one backup port, Port_T1 becomes the primary and backup port within that connectivity domain, and Port_T1 is set to the forwarding state. In the connectivity domain corresponding to Port_T2 and Port_T3, for example, if the elected primary backup port is Port_T2, Port_T2 is set to the forwarding state, and if the elected secondary backup port is Port_T3, Port_T3 is set to the blocking state.
[0075] Based on this switching, network DL and network T can communicate through link L1 between Port_D1 and Port_T1, and network DR and network T can communicate through link L2 between Port_D2 and Port_T2, thereby ensuring normal communication of the networks.
[0076] exist Figure 5 In the example, the ring network D is broken into two chain networks, and the ring network T is broken into one chain network. In order to fully illustrate the third fault situation mentioned above, Figure 6 As shown, the ring network D and the ring network T are both broken into two chain networks, that is, Figure 5On the basis of this, the link LT_4 connecting Port_T4 and Port_T5 in the ring network T also fails. At this time, the ring network T is broken into two chain networks TL and TR, and the ring network D is broken into chain networks DL and DR, and each chain is in the ring open state.
[0077] like Figure 6 Network DL has one backup port, Port_D1; network DR has two backup ports, Port_D2 and Port_D3; network TL has two backup ports, Port_T1 and Port_T2; and network TR has one backup port, Port_T3. After the network status changes, these four networks re-elect their respective root switches and send messages announcing their local ring network identifiers to their respective peer networks. Upon receiving these messages, the peer networks perform a new comparison. Since networks DL and DR were formed by disconnecting ring D, the network IDs of networks DL and DR remain unchanged, RingD_MAC_D. Since networks TL and TR were formed by disconnecting ring T, the network IDs of networks TL and TR remain unchanged, RingD_MAC_T. Therefore, the comparison result is still RingD_MAC_T > RingD_MAC_D, placing networks TL and TR in the Active state and networks DL and DR in the Inactive state. The backup ports, Port_D1, Port_D2, and Port_D3, in the Inactive network are set to the Forwarding state. Backup ports Port_D1 and Port_D2 in network TL receive different IDs of the root switch in the peer network (Port_D1 receives the ID of the root switch elected in the peer network DL, Root_MAC_D-L; Port_D2 receives the ID of the root switch elected in the peer network DR, Root_MAC_D-R). Therefore, they belong to different connectivity domains. Within each connectivity domain, there is only one backup port. Therefore, Port_D1 and Port_D2 are each the primary and backup ports within their own connectivity domain, and both are in the forwarding state. Network TR has only one backup port, Port_T3, and therefore, Port_T3 is also the primary and backup port within its own connectivity domain, and is also in the forwarding state.
[0078] As an implementation method, in this fault type, when the inter-ring link (i.e., the link outside the ring network) detects a topology change that leads to a backup port status change (Master, Salve, Inactive), it is necessary to send a clearing notification to the devices in each ring and the opposite ring network to ensure the correct forwarding path.
[0079] Based on this switching, the six backup ports Port_T1, Port_T2, Port_T3, Port_D1, Port_D2, and Port_D3 in the example network are all in the forwarding state, and the four chain networks TL, TR, DL, and DR are all connected, thus ensuring normal communication in the network.
[0080] In this embodiment, the process of electing whether the network state is Active or Inactive is generally several times the sending interval, and the sending interval is generally about 10ms. Therefore, the process of electing the network state takes about 30-50ms, and the backup port division of the connectivity domain and the Master election and status setting are generally several times the sending interval. Therefore, the Master election and status setting process also takes about 30-50ms. In summary, the entire switching process can be controlled within 100ms, greatly reducing the network recovery time. In addition, the election mechanism of the present application is extended from the ring to the connectivity domain, supports the backup of the inter-ring links, and also supports the scenario where the ring network is broken into multiple segments. Furthermore, based on the solution of the present application, the configurations between multiple ring networks can be kept consistent, meeting the application scenarios with high network symmetry requirements.
[0081] Another embodiment of the present application provides a train network backup method. The method first divides the switching equipment in each carriage into two independent DRP ring networks, and then these two independent DRP ring networks adopt the backup method of the above embodiment. Specifically:
[0082] like Figure 7 The figure shows a common network in train networking, generally called a ladder network. Specifically: a train is usually composed of multiple carriages, each of which is equipped with network equipment (such as switches). These switches are connected by physical links to form a communication network between carriages. A ladder network is a common configuration method, in which the network connection between carriages allows data to flow between carriages, thereby supporting the data communication needs of the entire train. In this example, carriage A, carriage B, carriage C, and carriage D are connected together to form the communication network within the train. In order to improve the redundancy of the system, each carriage is connected to the adjacent carriages through two links.
[0083] In this embodiment, the switches in the carriage are divided into Figure 7The upper and lower sections shown are each configured as an independent DRP ring network. The upper switches in all train cars are DRP Ring 1, and the lower switches are DRP Ring 2. The two rings are disconnected at the front and rear of the train, maintaining an open ring state. This configuration provides two independent data transmission paths, increasing network redundancy. A backup port is provided between Ring 1 and Ring 2, and the backup ports of the two rings are connected via a link. Therefore, when the network structure changes (such as a link disconnection), the backup ports automatically conduct a new round of elections to determine which port serves as the master and which ports as the slave. This dynamic election ensures that even if part of the network is disconnected, connectivity remains between all devices in the entire system, maintaining normal operation and maximizing the utilization of all available network resources. Furthermore, when the train composition changes (i.e., cars are added or removed), this DRP ring structure and backup port configuration allow the network to automatically adapt to the new composition, eliminating the need for manual network reconfiguration. This significantly simplifies operation, reduces the possibility of human configuration errors, and reduces maintenance costs.
[0084] Another embodiment of the present application provides an inter-ring backup device 80 of a DRP ring network. It should be understood that Figure 8 This is only an exemplary structural diagram of an inter-ring backup device of a DRP ring network, and this application does not limit the division of functional modules in the inter-ring backup device of the DRP ring network. Figure 8 As shown, the device 80 can be logically divided into multiple modules, each module can have different functions, and the functions of each module can be implemented by a processor in a computing device reading and executing instructions in a memory. Exemplarily, the device 80 includes a receiving module 810, a determining module 820, a dividing module 830, and an electing module 840. In one implementation, the inter-ring backup device 80 of the DRP ring network is used to perform Figure 2 The content shown.
[0085] Specifically: The receiving module 810 is used to receive a declaration message sent by the opposite ring network, wherein the declaration message includes the identification information of the opposite ring network. The determining module 820 is used to determine the network status of the opposite ring network and the local ring network based on the identification information of the opposite ring network and the identification information of the local ring network, wherein the network status includes the Active state or the Inactive state, and set the backup port corresponding to the ring network with the Inactive state to the forwarding state. The dividing module 830 is used to divide the backup ports corresponding to the ring network with the Active state into connectivity domains based on the identification information of the opposite ring network, wherein each connectivity domain includes backup ports with the same identification information of the opposite ring network. The electing module 840 is used to elect a primary backup port in each connectivity domain, set the elected primary backup port to the forwarding state, set the unselected backup ports in each connectivity domain as slave backup ports, and set the slave backup ports to the blocking state.
[0086] The specific implementation of each functional module in this embodiment can be found in the introduction of the above embodiment, and will not be described in detail in this embodiment.
[0087] Figure 9 This is a schematic structural diagram of a computing device 900 provided in an embodiment of the present application. The computing device can execute the various optional embodiments of the above-mentioned DRP ring network inter-ring backup method. The computing device can be a terminal, or a chip or chip system inside the terminal. Figure 9 As shown, the computing device 900 includes: a processor 910 , a memory 920 , and a communication interface 930 .
[0088] It should be understood that Figure 9 The communication interface 930 in the computing device 900 shown can be used to communicate with other devices, and specifically may include one or more transceiver circuits or interface circuits.
[0089] The processor 910 may be connected to a memory 920. The memory 920 may be used to store the program code and data. Therefore, the memory 920 may be a storage unit within the processor 910, an external storage unit independent of the processor 910, or a component including both a storage unit within the processor 910 and an external storage unit independent of the processor 910.
[0090] Optionally, the computing device 900 may further include a bus. The memory 920 and the communication interface 930 may be connected to the processor 910 via a bus. The bus may be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 9 A line without an arrow is used to represent the bus, but this does not mean that there is only one bus or one type of bus.
[0091] It should be understood that in the embodiment of the present application, the processor 910 can adopt a central processing unit (CPU). The processor can also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc. Alternatively, the processor 910 adopts one or more integrated circuits to execute relevant programs to implement the technical solutions provided in the embodiments of the present application.
[0092] The memory 920 may include a read-only memory and a random access memory, and provides instructions and data to the processor 910. A portion of the processor 910 may also include a non-volatile random access memory. For example, the processor 910 may also store information about the device type.
[0093] When the computing device 900 is running, the processor 910 executes the computer-executable instructions in the memory 920 to perform any operation step of the above method and any optional embodiment thereof.
[0094] It should be understood that the computing device 900 according to the embodiment of the present application can correspond to the corresponding subject in executing the method according to each embodiment of the present application, and the above-mentioned and other operations and / or functions of each module in the computing device 900 are respectively for implementing the corresponding processes of each method of the present embodiment. For the sake of brevity, they will not be repeated here.
[0095] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0096] Those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0097] In the several embodiments provided in this application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of the units is merely a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0098] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.
[0099] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0100] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.
[0101] An embodiment of the present application also provides a computer-readable storage medium having a computer program stored thereon. When the program is executed by a processor, the program is used to execute the above method, which includes at least one of the solutions described in the above embodiments.
[0102] The computer storage medium of the embodiment of the present application can adopt any combination of one or more computer-readable media.Computer-readable media can be computer-readable signal media or computer-readable storage media.Computer-readable storage media can be, for example, but not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices or components, or any combination thereof.More specific examples (non-exhaustive list) of computer-readable storage media include: electrical connection with one or more wires, portable computer disks, hard disks, random access memories (RAM), read-only memories (ROM), erasable programmable read-only memories (EPROM or flash memory), optical fibers, portable compact disk read-only memories (CD-ROMs), optical storage devices, magnetic storage devices, or any suitable combination thereof.In this document, computer-readable storage media can be any tangible medium containing or storing a program, which can be used by an instruction execution system, device or device or used in combination with it.
[0103] A computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, which carries computer-readable program code. Such propagated data signals may take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium that can transmit, propagate, or transport a program for use by or in conjunction with an instruction execution system, apparatus, or device.
[0104] Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
[0105] The computer program code for performing the operations of the present application can be written in one or more programming languages, or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, C++, and conventional procedural programming languages such as "C" or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer can be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computer (e.g., through the Internet using an Internet service provider).
[0106] In addition, the words "first, second, third, etc." or module A, module B, module C and other similar terms in the specification and claims are only used to distinguish similar objects and do not represent a specific ordering of the objects. It can be understood that the specific order or sequence can be interchanged where permitted so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein.
[0107] In the above description, the numbers representing the steps, such as S110, S120, etc., do not necessarily mean that the steps must be executed in this manner. If permitted, the order of the steps can be interchanged or they can be executed simultaneously.
[0108] The term "comprising" as used in the specification and claims should not be construed as limiting to what is listed thereafter; it does not exclude other elements or steps. Thus, it should be interpreted as specifying the presence of the features, integers, steps, or components mentioned, but not excluding the presence or addition of one or more other features, integers, steps, or components, or groups thereof. Thus, the expression "a device comprising means A and B" should not be limited to a device consisting solely of components A and B.
[0109] References in this specification to "one embodiment" or "an embodiment" mean that a particular feature, structure, or characteristic described in connection with the embodiment is included in at least one embodiment of the present application. Therefore, the phrases "in one embodiment" or "in an embodiment" appearing throughout this specification do not necessarily refer to the same embodiment, but may refer to the same embodiment. Furthermore, in one or more embodiments, the particular features, structures, or characteristics can be combined in any suitable manner, as would be apparent to one of ordinary skill in the art from this disclosure.
[0110] Note that the above are only preferred embodiments of the present application and the technical principles employed. Those skilled in the art will understand that the present application is not limited to the specific embodiments described herein, and that various obvious changes, readjustments, and substitutions can be made by those skilled in the art without departing from the scope of protection of the present application. Therefore, although the present application has been described in more detail through the above embodiments, the present application is not limited to the above embodiments and may include many other equivalent embodiments without departing from the scope of protection of the present application, all of which fall within the scope of protection of the present application.
Claims
1. A DRP ring network inter-ring backup method, characterized in that: include: Receiving a declaration message sent by a peer ring network, wherein the declaration message includes identification information of the peer ring network; Determine the network status of the opposite ring network and the local ring network according to the opposite ring network identification information and the local ring network identification information, wherein the network status includes an active state or an inactive state, and set the backup port corresponding to the ring network with the inactive network status to a forwarding state; According to the peer ring network identification information, the backup ports corresponding to the ring network in the active network state are divided into connected domains, wherein each connected domain includes a backup port having the same peer ring network identification information; The primary and backup ports are elected in each connected domain, and the elected primary and backup ports are set to a forwarding state. The backup ports that are not elected in each connected domain are used as secondary and backup ports, and the secondary and backup ports are set to a blocking state.
2. The method according to claim 1, characterized in that The ring network identifier includes a ring network ID and a root switch ID.
3. The method according to claim 2, characterized in that The determining the network status of the opposite end ring network and the local end ring network according to the opposite end ring network identification information and the local end ring network identification information includes: Comparing the ring network ID of the opposite ring network with the ring network ID of the local ring network, and determining the network status of the ring network based on the comparison result of the ring network IDs; When the ring network ID of the opposite ring network is the same as the ring network ID of the local ring network, the root switch ID of the opposite ring network is compared with the root switch ID of the local ring network, and the network status of the ring network is determined based on the comparison result of the root switch ID.
4. The method according to claim 2, characterized in that: The dividing of the connection domains of the backup ports corresponding to the ring network in the active network state according to the peer ring network identification information includes: In the ring network in which the network state is active, backup ports with the same root switch ID are grouped into the same connectivity domain.
5. The method according to claim 1, characterized in that Also includes: When a link in the local ring network and / or the opposite ring network fails but does not cause a change in the divided connectivity domain, the network status of the local ring network and the opposite ring network and the status of the backup ports corresponding to each ring network remain unchanged.
6. The method according to claim 1, characterized in that Also includes: When a link between the local ring network and the opposite ring network for connecting the primary and backup ports fails and causes the divided connectivity domain to change, the connectivity domain is re-divided according to the identification information of the opposite ring network, and the primary and backup ports are re-elected and the status of each backup port is set in the new connectivity domain.
7. The method according to claim 1, characterized in that Also includes: When a link failure occurs in the local ring network and / or the opposite ring network and causes a change in the divided connectivity domain, the connectivity domain is re-divided according to the opposite ring network identification information, and the primary and backup ports are re-elected and the status of each backup port is re-set in the new connectivity domain.
8. The method according to claim 1, characterized in that Also includes: When a topology change is detected in the DRP ring network but does not cause a status change of the backup port, a table clearing notification is sent to a device in the DRP ring network to notify the device to clear and update the forwarding table; When a topology change is detected outside the DRP ring network and causes a status change of the backup port, a table clearing notification is sent to the device in the DRP ring network and the opposite end ring network device of the DRP ring network to notify the device to clear and update the forwarding table.
9. A train networking backup method, characterized in that: include: Divide the switching equipment in each carriage into two independent DRP ring networks; The DRP ring network is used to execute the method according to any one of claims 1 to 8.
10. An inter-ring backup device of a DRP ring network, characterized in that: include: A receiving module, used for receiving a declaration message sent by a peer ring network, wherein the declaration message includes identification information of the peer ring network; A determination module, used to determine the network status of the opposite ring network and the local ring network according to the opposite ring network identification information and the local ring network identification information, wherein the network status includes an active state or an inactive state, and set the backup port corresponding to the ring network with the inactive network status to a forwarding state; A division module, used for dividing the backup ports corresponding to the ring network in the active state into connected domains according to the peer ring network identification information, wherein each connected domain includes a backup port having the same peer ring network identification information; The election module is used to elect the primary and backup ports in each connected domain, and set the elected primary and backup ports to the forwarding state, and use the unselected backup ports in each connected domain as slave backup ports, and set the slave backup ports to the blocking state.
Citation Information
Cited By
Switching method of ERPS looped network, switching equipment and storage medium
CN120915629A
