Method, device and storage medium for configuring an ethernet ring network

CN122969924APending Publication Date: 2026-10-23HUAWEI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510473899.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-15
Publication Date
2026-10-23

Smart Images

  • Figure CN122969924A_ABST
    Figure CN122969924A_ABST
Patent Text Reader

Abstract

The application discloses a method, device and storage medium for configuring an Ethernet ring network, and belongs to the field of communication. The method comprises the following steps: a management device acquires a network topology of a local area network; a first spanning tree and a link set are acquired based on the network topology, the first spanning tree comprises a first node, a plurality of second nodes and a path between each second node and the first node, the path between each second node and the first node is a shortest path between each second node and the first node in the network topology, and the link set comprises links in the network topology except for links in the first spanning tree; a plurality of nodes are determined based on the first spanning tree and the link set, and a ring topology formed by the plurality of nodes does not contain a sub-ring topology; and configuration information of the Ethernet ring network is sent to the plurality of nodes, and the configuration information is used for configuring the plurality of nodes to form the Ethernet ring network. The application can realize rapid deployment of the Ethernet ring network.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of communications, and in particular to a method, apparatus and storage medium for configuring an Ethernet ring network. Background Technology

[0002] An Ethernet ring network is a ring topology consisting of multiple nodes. For each node, it is connected to its two neighboring nodes through a port, and any two nodes can communicate directly or indirectly.

[0003] Ethernet ring networks offer advantages such as high availability, fault tolerance, and rapid fault recovery. Deploying Ethernet ring networks in local area networks (LANs) like enterprise campus networks can ensure reliable service transmission. Therefore, how to quickly deploy Ethernet ring networks within LANs is a pressing issue that needs to be addressed. Summary of the Invention

[0004] This application provides a method, apparatus, and storage medium for configuring an Ethernet ring network to achieve rapid deployment of the Ethernet ring network. The technical solution is as follows:

[0005] Firstly, this application provides a method for configuring an Ethernet ring network. The method is applied to a management device of a local area network (LAN). The LAN further includes a first node and multiple second nodes. The first node is either an egress device of the LAN or communicates with an egress device. In the method, the management device obtains the network topology of the LAN, where adjacent nodes are connected by links. Based on the network topology, the management device obtains a first spanning tree and a set of links. The first spanning tree includes the first node, multiple second nodes, and paths from each second node to the first node. Each path from a second node to the first node is the shortest path from each second node to the first node in the network topology. The set of links includes all links in the network topology except those in the first spanning tree. Based on the first spanning tree and the set of links, the management device determines multiple nodes, including the first node and at least two second nodes, or at least three second nodes. The ring topology formed by the multiple nodes does not contain sub-ring topologies. The management device sends Ethernet ring network configuration information to the multiple nodes. This configuration information is used to configure the multiple nodes to form an Ethernet ring network.

[0006] The management device automatically acquires the local area network (LAN) topology and, based on this topology, obtains the first spanning tree and link set. Based on the first spanning tree and link set, it identifies multiple nodes, forming a ring topology that does not contain sub-ring topologies. It then sends Ethernet ring network configuration information to these nodes, which then form the Ethernet ring network based on this configuration information. In this way, the management device can automatically obtain the network topology, automatically determine the ring topology, and automatically configure the Ethernet ring network based on this ring topology, without manual intervention. It automatically collects network topologies and divides them into ring networks, thus enabling automatic and rapid deployment of the Ethernet ring network.

[0007] In one possible implementation, a link is selected from the set of links as the target link. The target link is the link between two adjacent nodes in the network topology, and the first spanning tree includes these two nodes. The two nodes in the first spanning tree are connected using the target link to obtain the second spanning tree. A minimum ring topology including the target link is determined in the second spanning tree, and multiple nodes are nodes in this minimum ring topology. In this way, ring networks can be automatically divided according to the minimum spanning tree.

[0008] In another possible implementation, for each of the plurality of nodes, the Ethernet ring network configuration information sent to the node includes one or more of the following: Ethernet ring network identification information, Ethernet ring network control VLAN identification information, Ethernet ring network service VLAN identification information, Ethernet ring network protection instance, Ethernet ring network master / slave type, or the role of the target port in the node, where the target port is a port in the node belonging to the ring topology. In this way, by sending configuration information to each node, the multiple nodes in the ring topology are automatically configured into an Ethernet ring network.

[0009] In another possible implementation, multiple nodes are nodes with Ethernet ring network protection capabilities, thus ensuring that multiple nodes are successfully configured into an Ethernet ring network.

[0010] In another possible implementation, the local area network (LAN) is a corporate campus network.

[0011] Secondly, this application provides an apparatus for configuring an Ethernet ring network. The apparatus is located in a local area network (LAN), which further includes a first node and multiple second nodes. The first node is either an egress device of the LAN or communicates with the egress device. The apparatus includes:

[0012] The processing unit is used to obtain the network topology of the local area network, in which adjacent nodes are connected by links.

[0013] The processing unit is also used to obtain a first spanning tree and a link set based on the network topology. The first spanning tree includes a first node, multiple second nodes, and a path from each second node to the first node. The path from each second node to the first node is the shortest path from each second node to the first node in the network topology. The link set includes links in the network topology other than the links in the first spanning tree.

[0014] The processing unit is also configured to determine multiple nodes based on the first spanning tree and the link set, wherein the multiple nodes include a first node and at least two second nodes, or the multiple nodes include at least three second nodes, and the ring topology formed by the multiple nodes does not contain a sub-ring topology;

[0015] The sending unit is used to send configuration information of the Ethernet ring network to multiple nodes. The configuration information is used to configure multiple nodes to form an Ethernet ring network.

[0016] The processing unit automatically acquires the local area network (LAN) topology and, based on this topology, obtains the first spanning tree and link set. The processing unit then determines multiple nodes based on the first spanning tree and link set; the ring topology formed by these nodes does not contain sub-ring topologies. The sending unit sends Ethernet ring network configuration information to these multiple nodes, and the nodes form the Ethernet ring network based on this configuration information. In this way, the processing and sending units can automatically obtain the network topology, automatically determine the ring topology, and automatically configure the Ethernet ring network based on this ring topology, without manual intervention. It automatically collects the network topology and divides it into ring networks, thus enabling automatic and rapid deployment of the Ethernet ring network.

[0017] In one possible implementation, the processing unit is used for:

[0018] Select a link from the set of links as the target link. The target link is the link between two adjacent nodes in the network topology. The first spanning tree consists of two nodes.

[0019] Connect the two nodes in the first spanning tree using the target link to obtain the second spanning tree;

[0020] In the second spanning tree, a minimum ring topology including the target link is determined, where multiple nodes are nodes on the minimum ring topology. This allows for automatic ring network partitioning based on the minimum spanning tree.

[0021] In another possible implementation, for each of the plurality of nodes, the Ethernet ring network configuration information sent to the node includes one or more of the following: Ethernet ring network identification information, Ethernet ring network control VLAN identification information, Ethernet ring network service VLAN identification information, Ethernet ring network protection instance, Ethernet ring network master / slave type, or the role of the target port in the node, where the target port is a port in the node belonging to the ring topology. In this way, by sending the Ethernet ring network configuration information to each node, the multiple nodes in the ring topology are automatically configured into an Ethernet ring network based on the configuration information.

[0022] In another possible implementation, multiple nodes are nodes with Ethernet ring network protection capabilities, thus ensuring that multiple nodes are successfully configured into an Ethernet ring network.

[0023] In another possible implementation, the local area network (LAN) is a corporate campus network.

[0024] Thirdly, this application provides a device for configuring an Ethernet ring network, the device including a processor, a memory and a communication interface, the processor being used to execute program instructions in the memory to implement the method provided in the first aspect or any possible implementation of the first aspect, and the communication interface being used to communicate with network devices in an optical communication network.

[0025] Fourthly, this application provides a computer-readable storage medium storing at least one program instruction that is read by a processor to cause a control device to perform the method provided by the first aspect or any possible implementation thereof.

[0026] Fifthly, this application provides a computer program product including program instructions stored in a computer-readable storage medium. A processor of a control device reads the program instructions from the computer-readable storage medium and executes the program instructions, causing the control device to perform the method provided in the first aspect or any possible implementation thereof. Attached Figure Description

[0027] Figure 1 This is a schematic diagram of a local area network structure provided in an embodiment of this application;

[0028] Figure 2 This is a schematic diagram of another local area network structure provided in an embodiment of this application;

[0029] Figure 3 This is a flowchart of a method for configuring an Ethernet ring network provided in an embodiment of this application;

[0030] Figure 4This is a flowchart of a method for discovering neighboring nodes provided in an embodiment of this application;

[0031] Figure 5 This is a schematic diagram of a first spanning tree structure provided in an embodiment of this application;

[0032] Figure 6 This is a flowchart of another method for configuring an Ethernet ring network provided in an embodiment of this application;

[0033] Figure 7 This is a schematic diagram of a second spanning tree structure provided in an embodiment of this application;

[0034] Figure 8 This is a schematic diagram of another second spanning tree structure provided in an embodiment of this application;

[0035] Figure 9 This is a schematic diagram of a device structure for configuring an Ethernet ring network according to an embodiment of this application;

[0036] Figure 10 This is a schematic diagram of a device structure provided in an embodiment of this application. Detailed Implementation

[0037] See Figure 1 This application provides a local area network 100, which includes a management device 101, a first node 102 and a plurality of second nodes 103. The management device 101 can communicate with the first node 102 and the management device 101 can communicate with each of the second nodes 103.

[0038] In some embodiments, see Figure 1 The first node 102 can be the egress device of the local area network 100. The egress device is a device in the local area network 100, and the local area network 100 communicates with the Internet through the egress device.

[0039] In some embodiments, see Figure 2 The first node 101 is a node in the local area network 100 that communicates with the exit device. The exit device is not a device in the local area network 100. The local area network 100 is connected to the exit device to enable communication with the Internet.

[0040] The local area network 100 communicates with the Internet through an egress device. Each network element in the local area network 100 can communicate with the egress device, and each network element includes a management device 101, a first node 102, and multiple second nodes 103. That is, the management device 101 in the local area network 100 can communicate with the egress device, the first node 102 in the local area network 100 can communicate with the egress device, and each second node 103 in the local area network 100 communicates with the egress device.

[0041] For example, see Figure 1 or Figure 2 The multiple second nodes 103 include second node A, second node B, second node C, second node D and second node E. The management device 101 can communicate with the first node, second node A, second node B, second node C, second node D and second node E.

[0042] See Figure 1 The export device and the first node 101 are the same device. The export device can communicate with the management device 101, as well as with the second nodes A, B, C, D, and E. Alternatively,

[0043] See Figure 2 The export device is a different device from the first node 101. The export device can communicate with the management device 101, the first node 101, and the second nodes A, B, C, D and E.

[0044] In some embodiments, the management device 101, the first node 102, and the plurality of second nodes 103 may be network element devices in the local area network 100, and the egress device of the local area network 100 may be an egress gateway, etc.

[0045] In some embodiments, the local area network 100 may be an enterprise campus network, etc.

[0046] See Figure 1 or Figure 2 The network topology of the local area network 100 may include one or more ring topologies. For each ring topology, the ring topology is a closed-loop topology structure composed of multiple nodes, the multiple nodes including a first node 101 and at least two second nodes 103, or the multiple nodes including at least three second nodes 103.

[0047] For example, Figure 1 or Figure 2 The network topology shown can be such that the first node 102, the second node A, the second node D, and the second node C can form a ring topology, meaning that the nodes forming this ring topology include the first node 102, the second node A, the second node D, and the second node C. Also, the second node A, the second node B, and the second node D can form a ring topology, meaning that the nodes forming this ring topology include the second node A, the second node B, and the second node D.

[0048] For each ring topology, management device 101 can configure Ethernet ring network configuration information on each device in the ring topology, thus forming an Ethernet ring network. Ethernet ring networks offer advantages such as high availability, fault tolerance, and rapid fault recovery. By automatically and quickly deploying the Ethernet ring network in the local area network 100, the reliability of service transmission can be guaranteed.

[0049] Optionally, the configuration information for the Ethernet ring network can be Ethernet ring protection switching (ERPS) information or media redundancy protocol (MRP) information, etc. The configuration information can also be other information, which will not be listed here.

[0050] See Figure 3 This application provides a method 300 for configuring an Ethernet ring network, which can be applied to... Figure 1 or Figure 2 The method 300 is implemented on the management device 101 of the local area network 100 shown. The method 300 includes the following process.

[0051] Step 301: The management device collects device information from each node in the local area network.

[0052] Management devices can be higher-level network elements within a local area network (LAN). Administrators can configure a specific network element within the LAN as a management device.

[0053] Optionally, the administrator can configure a network element device in the local area network to use the site administrator (webmaster) function, so that the role of the network element device becomes a management device. The webmaster function is used to collect device information of each node in the local area network.

[0054] Optionally, the administrator can display a web page on the terminal device. The web page includes the identification information of each network element device in the local area network. The administrator can select the identification information of a certain network element device. The terminal device obtains the identification information of the network element device selected by the administrator. Based on the identification information of the network element device, the webmaster function is used on the network element device to change the role of the network element device to a management device, which is used to collect device information of each node in the local area network.

[0055] See Figure 4 The management device can send discovery messages to each node in the local area network (LAN), where each node includes a first node and multiple second nodes. Optionally, the management device can broadcast discovery messages to each node in the LAN, which are used to collect device information from the nodes.

[0056] For the first node in the local area network, upon receiving the discovery message, the first node obtains its device information and sends a first discovery response message to the management device. This first discovery response message includes the first node's device information. The management device receives the first discovery response message, retrieves the first node's device information from it, and saves the device information.

[0057] Optionally, after receiving the discovery message, the first node randomly selects a time within the first time period and sends a first discovery response message to the management device at the selected time. The start time of the first time period is the time when the first node receives the discovery message, and the duration of the first time period is a duration threshold.

[0058] Optionally, the device information of the first node includes one or more of the following: the device model, electronic serial number (ESN), address information, device capability or name information, etc. The address information of the first node may include the Internet Protocol (IP) and / or Media Access Control (MAC) of the first node.

[0059] For each second node in the local area network, the second node receives the discovery message, obtains its device information, and sends a second discovery response message to the management device. The second discovery response message includes the device information of the second node. The management device receives the second discovery response message, obtains the device information of the second node from the second discovery response message, and saves the device information of the second node.

[0060] Optionally, after receiving the discovery message, the second node may randomly select a time within the second time period and send a second discovery response message to the management device at the selected time. The start time of the second time period is the time when the second node receives the discovery message, and the duration of the second time period is a duration threshold.

[0061] Optionally, the device information of the second node includes one or more of the following: the device model, ESN, address information, device capabilities or name information of the second node, etc., and the address information of the second node may include the IP and / or MAC of the second node.

[0062] The duration threshold can be 5 seconds, 10 seconds, 15 seconds, or 20 seconds, etc. For each node in the local area network (the first node or the second node), after receiving the discovery message, the node sends a discovery response message (the first discovery response message or the second discovery response message) to the management device at a random time within a time period (the first time period or the second time period). This can avoid every node in the local area network sending discovery response messages at the same time, which would cause congestion and network storms in the local area network.

[0063] After receiving the discovery response messages sent by each node in the local area network, the management device manages each node in the local area network individually or in batches.

[0064] Step 302: The management device obtains the network topology of the local area network based on the device information of each node in the local area network. In this network topology, two adjacent nodes in the local area network are connected by a link.

[0065] This link can be a physical link, such as a fiber optic cable or a coaxial cable.

[0066] See Figure 4 In step 302, the management device can send a subscription request to each node based on the device information of each node. For each node, the subscription request sent to that node is used to request that node to collect information about its neighboring nodes.

[0067] For the first node in the local area network, the first node receives a subscription request from the management device, obtains its neighbor node information based on the subscription request, and sends a first subscription response to the management device. The first subscription response includes the neighbor node information of the first node, which may include identification information of the neighbor nodes. The management device receives the first subscription response, obtains the neighbor node information from it, and draws a map of the first node and its neighbor nodes based on this information. A connection is established between the first node and its neighbor nodes to represent the link between them.

[0068] For each second node in the local area network, the second node receives a subscription request from the management device, obtains its neighbor node information based on the subscription request, and sends a second subscription response to the management device. The second subscription response includes the neighbor node information of the second node, which may include identification information of the neighbor nodes. The management device receives the second subscription response, obtains the neighbor node information from the second subscription response, and draws a map of the second node and its neighbor nodes based on this information. A connection is established between the second node and its neighbor nodes to represent the link between them.

[0069] The network topology of a local area network includes each node and the links between adjacent nodes (represented by lines).

[0070] Step 303: The management device obtains a first spanning tree and a link set based on the network topology. The first spanning tree includes a first node, multiple second nodes, and the path between each second node and the first node. The path between each second node and the first node is the shortest path from each second node to the first node in the network topology. The link set includes the links in the network topology other than the links in the first spanning tree.

[0071] For example, suppose the network topology of the local area network obtained by the management device is as follows: Figure 1 As shown, the network topology includes a first node, a second node A, a second node B, a second node C, a second node D, and a second node E. The network topology also includes links between adjacent nodes, namely the link between the first node and the second node A, the link between the first node and the second node C, the link between the second node A and the second node B, the link between the second node A and the second node D, the link between the second node C and the second node D, the link between the second node B and the second node D, and the link between the second node D and the second node E.

[0072] See Figure 5 ,based on Figure 1The network topology shown is used to obtain the first spanning tree, which includes the first node, the second node A, the second node B, the second node C, the second node D, and the second node E. In the first spanning tree, the path between the first node and the second node A is the shortest path between the first node and the second node A in the network topology, including the link between the first node and the second node A; the path between the first node and the second node C is the shortest path between the first node and the second node C in the network topology, including the link between the first node and the second node C; the path between the first node and the second node B is the shortest path between the first node and the second node B in the network topology, including the link between the first node and the second node A and the link between the second node A and the second node B; the path between the first node and the second node D is the shortest path between the first node and the second node D in the network topology, including the link between the first node and the second node C and the link between the second node C and the second node D; the path between the first node and the second node E is the shortest path between the first node and the second node E in the network topology, including the link between the first node and the second node C, the link between the second node C and the second node D, and the link between the second node D and the second node E.

[0073] based on Figure 1 The network topology shown obtains a set of links, which includes... Figure 1 In the network topology shown, except Figure 5 The links in the first spanning tree shown are those other than the links in the second node A and the second node D. That is, the set of links includes the links between the second node A and the second node D and the links between the second node B and the second node D.

[0074] Step 304: The management device determines multiple nodes based on the first spanning tree and the link set. The multiple nodes include a first node and at least two second nodes, or the multiple nodes include at least three second nodes. The ring topology formed by the multiple nodes does not contain sub-ring topologies.

[0075] See Figure 6 The management device can send a capability query request to each node based on the device information of each node. For each node, upon receiving the capability query request, it sends a capability query response to the management device. This response includes indication information indicating that the node has Ethernet ring network protection capabilities. Optionally, the Ethernet ring network protection capability can be ERPS capabilities, etc.

[0076] In step 304, the management device divides the network topology of the local area network based on the first spanning tree and the link set to obtain at least one ring topology. Each ring topology includes multiple nodes, all of which have Ethernet ring network protection capabilities, and each ring topology does not include sub-ring topologies.

[0077] Optionally, in step 304, the network topology of the local area network can be divided into ring topologies through the following process.

[0078] 3041: Select a link from the set of links as the target link. The target link is the link between two adjacent nodes in the network topology. The first spanning tree includes two such nodes.

[0079] In 3041, a link can be selected as the target link from the link set in descending order of its hierarchical level. In the local network topology, the closer a link is to the first node, the higher its hierarchical level.

[0080] For example, see Figure 1 or Figure 2 In the network topology shown, the link between second node A and second node D is closer to the first node than the link between second node B and second node D, and the link between second node A and second node D has a higher hierarchical level than the link between second node B and second node D. Therefore, the link between second node A and second node D is selected as the target link from the link set.

[0081] 3042: Connect two nodes in the first spanning tree using the target link to obtain the second spanning tree.

[0082] For example, see Figure 7 The target link is the link between the second node A and the second node D. The target link is used for connection. Figure 5 The second node A and the second node D in the first spanning tree shown are obtained as follows: Figure 7 The second spanning tree is shown.

[0083] 3043: Determine the minimum ring topology that includes the target link in the second spanning tree, where the plurality of nodes are nodes on the minimum ring topology.

[0084] Alternatively, the so-called minimum ring topology refers to the ring topology that includes the target link with the fewest number of nodes.

[0085] For example, in Figure 7 The second spanning tree shown determines a minimum ring topology that includes the target link (the link between the second node A and the second node D), which includes the first node, the second node A, the second node D, and the second node C.

[0086] For links not selected in the link set, the management device can select one of the unselected links as the target link and repeat operations 3042 to 3043 above to obtain other ring topologies. Therefore, after selecting each link in the link set, at least one ring topology can be obtained.

[0087] For example, continue selecting the link between second node B and second node D from the link set as the target link. Use the target link to connect. Figure 7 The second node B and the second node D in the second spanning tree shown are obtained as follows: Figure 8 The second spanning tree is shown. Figure 8 The second spanning tree shown determines the minimum ring topology that includes the target link (the link between the second node B and the second node D), which includes the second node A, the second node B, and the second node D.

[0088] Step 305: The management device sends Ethernet ring network configuration information to multiple nodes in the ring topology. This configuration information is used to configure the multiple nodes to form an Ethernet ring network.

[0089] For each of the multiple nodes in the ring topology, the Ethernet ring network configuration information sent to that node includes one or more of the following: Ethernet ring network identification information, Ethernet ring network control virtual local area network (VLAN) identification information, Ethernet ring network service VLAN identification information, Ethernet ring network protection instance, Ethernet ring network master / slave type, or the role of the target port in the node, where the target port is the port in the node that belongs to the ring topology.

[0090] For each node in this ring topology, there are two ports that belong to the ring topology. In the ring topology, these two ports are connected to the two neighboring nodes of this node. The role of these two ports may be ordinary ports, or one of the two ports may be an ordinary port and the other port may be the master node (RPLowner), or one of the two ports may be an ordinary port and the other port may be a neighbor node (RPLneighhoor).

[0091] If a port of a node has the role of RPLowner, that port will be set as a blocked port to prevent the Ethernet ring network from forming a loop. If a port of a node has the role of RPLneighbor, then there is a blocked port with the role of RPLowner on a neighboring node, and there is a link between that port of the node and the blocked port of the neighboring node.

[0092] If a ring topology shares a common link with another ring topology, it means that the Ethernet ring network corresponding to the first ring topology shares a common link with the Ethernet ring network corresponding to the other ring topology. The master-slave type of the Ethernet ring network may be master, indicating that the Ethernet ring network is the master Ethernet ring network, and the master-slave type of the other Ethernet ring network may be slave, indicating that the other Ethernet ring network is the slave Ethernet ring network. Alternatively, the master-slave type of the Ethernet ring network may be slave, indicating that the Ethernet ring network is the slave Ethernet ring network, and the master-slave type of the other Ethernet ring network may be master, indicating that the other Ethernet ring network is the master Ethernet ring network. The configuration information sent to the nodes may include the master-slave type of the Ethernet ring.

[0093] Optionally, each Ethernet ring network has different identification information, each Ethernet ring network has different identification information for its control VLAN, and each Ethernet ring network has different identification information for its service VLAN.

[0094] For each node, it can receive configuration information from the management device and configure itself based on this information. For example, it can configure the Ethernet ring network identifier based on the Ethernet ring network identifier information; configure the control VLAN identifier based on the control VLAN identifier included in the configuration information; configure the service VLAN identifier based on the service VLAN identifier included in the configuration information; configure the protection instance based on the protection instance included in the configuration information; configure the Ethernet ring network type based on the master / slave type; and / or configure the target port of the node based on the role of the target port. Specifically, if the target port of the node has the role of RPLowner, then the target port is configured as a blocking port.

[0095] For example, see Figure 8 Two ring topologies were determined: Ring Topology 1 and Ring Topology 2. Ring Topology 1 includes a first node, a second node A, a second node D, and a second node C. Ring Topology 2 includes a second node A, a second node B, and a second node D. Ring Topology 1 is the topology of Ethernet Ring Network 1, and Ring Topology 2 is the topology of Ethernet Ring Network 2. Ethernet Ring Network 1 and Ethernet Ring Network 2 share a common link: the link between the second nodes A and D. Ethernet Ring Network 1 is the master Ethernet Ring Network, and Ethernet Ring Network 2 is the slave Ethernet Ring Network.

[0096] The management device can send configuration information 1 to the first node, configuration information A1 to the second node A, configuration information D1 to the second node D, and configuration information C to the second node C. Configuration information 1, configuration information A1, configuration information D1, and configuration information C all include the Ethernet ring network identifier "ring1", the Ethernet ring network control VLAN identifier "IDcv1", the Ethernet ring network service VLAN identifier "IDs1", the Ethernet ring network protection instance f1, and the Ethernet ring network master-slave type. The Ethernet ring network master-slave type is a master Ethernet ring network.

[0097] Configuration information 1 also includes the roles of port 1 and port 2 on the first node. Both port 1 and port 2 are ordinary ports. Port 1 is connected to port a1 of the second node A, and port 2 is connected to port c1 of the second node C. Therefore, the first node receives configuration information 1 and configures the Ethernet ring network 1 with the identifier "ring1", the control VLAN identifier "IDcv1", the service VLAN identifier "IDs1", the protection instance "f1", the master-slave type "master Ethernet ring network", and the roles of port 1 and port 2 as ordinary ports.

[0098] Configuration information A1 also includes the roles of port a1 and port a2 on the second node A. Port a1 is a normal port, and port a2 is an RPLowner. Port a2 is connected to port d1 on the second node D. Therefore, the second node A receives configuration information A1 and configures the Ethernet ring network 1 as follows: the identification information is "ring1", the identification information of the control VLAN of the Ethernet ring network 1 is "IDcv1", the identification information of the service VLAN of the Ethernet ring network 1 is "IDs1", the protection instance of the Ethernet ring network 1 is f1, the master-slave type of the Ethernet ring network 1 is master Ethernet ring network, the role of port a1 is a normal port, and the role of port a2 is a blocking port.

[0099] Configuration information D1 also includes the roles of port d1 and port d2 on the second node D. Port d1 is designated as an RPLneighbor, and port d2 is designated as a regular port. Port d2 is connected to port c2 on the second node C. Therefore, the second node D receives configuration information D1 and configures the Ethernet ring network 1 as follows: the identifier is "ring1", the control VLAN identifier is "IDcv1", the service VLAN identifier is "IDs1", the protection instance is f1, the master-slave type is master Ethernet ring network, port d1 is designated as an RPLneighbor, and port d2 is designated as a regular port.

[0100] Configuration information C also includes the roles of port c1 and port c2 on the second node C. Both ports c1 and c2 are ordinary ports. Therefore, the second node C receives configuration information C and configures Ethernet ring network 1 as follows: the identifier is "ring1", the control VLAN identifier is "IDcv1", the service VLAN identifier is "IDs1", the protection instance is f1, the master-slave type is master Ethernet ring network, and both ports c1 and c2 are ordinary ports. This results in Ethernet ring network 1, which includes the first node, second node A, second node B, and second node C.

[0101] The management device can send configuration information A2 to second node A, configuration information B to second node B, and configuration information D2 to second node D. Configuration information A2, B, and D2 all include the Ethernet ring network identifier "ring2", the Ethernet ring network control VLAN identifier "IDcv2", the Ethernet ring network service VLAN identifier "IDs2", the Ethernet ring network protection instance f2, and the Ethernet ring network master-slave type. The Ethernet ring network master-slave type is slave Ethernet ring network.

[0102] Configuration information A2 also includes the roles of ports a3 and a4 on the second node A. Both ports a3 and a4 are ordinary ports. Port a3 is connected to port b1 on the second node B, and port a4 is connected to port d3 on the second node D. Therefore, upon receiving configuration information A2, the second node configures the Ethernet ring network 2 as follows: the identifier is "ring2", the identifier of the control VLAN is "IDcv2", the identifier of the service VLAN is "IDs2", the protection instance is f2, the master-slave type is slave Ethernet ring network, and both ports a3 and a4 are ordinary ports.

[0103] Configuration information B also includes the roles of port b1 and port b2 on the second node B. Port b1 is a normal port, and port b2 is an RPLowner. Port b2 is connected to port d4 on the second node D. Therefore, the second node B receives configuration information B and configures the Ethernet ring network 2 as follows: the identification information is "ring2", the identification information of the control VLAN of the Ethernet ring network 2 is "IDcv2", the identification information of the service VLAN of the Ethernet ring network 2 is "IDs2", the protection instance of the Ethernet ring network 2 is f2, the master-slave type of the Ethernet ring network 2 is slave Ethernet ring network, the role of port b1 is a normal port, and the role of port b2 is a blocking port.

[0104] Configuration information D2 also includes the roles of port d4 and port d3 on the second node D. Port d4 is designated as an RPLneighbor, and port d3 is designated as a regular port. Port d4 is connected to port b2 on the second node B. Therefore, the second node D receives configuration information D2 and configures the Ethernet ring network 2 as follows: the identifier is "ring2", the control VLAN identifier is "IDcv2", the service VLAN identifier is "IDs2", the protection instance is f2, the master-slave type is set to slave Ethernet ring network, port d4 is designated as an RPLneighbor, and port d3 is designated as a regular port. This results in Ethernet ring network 2, which includes the second node A, the second node B, and the second node D.

[0105] Blocking ports are used to disrupt the ring links of an Ethernet ring network. When configuring blocking ports, the load balancing of the Ethernet ring network is taken into account when selecting ports, and the selected ports are configured as blocking ports.

[0106] For example, see Figure 8 In Ethernet ring network 1, port a2 on the second node A is configured as a blocking port. This ensures that for any node in Ethernet ring network 1, when sending data to the Internet, the data travels a shorter path within Ethernet ring network 1, resulting in a more balanced load on Ethernet ring network 1. Similarly, see... Figure 8 In Ethernet ring network 2, port b2 on the second node B is configured as a blocking port. This means that for any node in Ethernet ring network 2, when that node sends data to the Internet, the data transmission path in Ethernet ring network 2 is shorter, resulting in a more balanced load on Ethernet ring network 2.

[0107] In this embodiment, the management device acquires the network topology of the local area network (LAN). Based on the network topology, it acquires a first spanning tree and a set of links. Based on the first spanning tree and the set of links, it determines multiple nodes, and the ring topology formed by these nodes does not contain sub-ring topologies. It sends Ethernet ring network configuration information to these multiple nodes, and the multiple nodes form an Ethernet ring network based on the configuration information. In this way, the management device can automatically obtain the network topology, automatically determine the ring topology, and automatically configure the Ethernet ring network based on the ring topology, thereby enabling automatic and rapid deployment of the Ethernet ring network. This eliminates the need for manual intervention, automatically collecting the network topology and dividing the network into rings according to the minimum spanning tree. For ring-shaped networks, the ring network configuration is automatically distributed, eliminating the need for manual configuration. This avoids the problems of error-prone manual configuration and time-consuming debugging.

[0108] See Figure 9This application provides a device 900 for configuring an Ethernet ring network. The device 900 is located in a local area network (LAN). The LAN further includes a first node and multiple second nodes. The first node is either an egress device of the LAN or communicates with the egress device. The device 900 includes:

[0109] Processing unit 901 is used to obtain the network topology of the local area network, in which adjacent nodes are connected by links;

[0110] The processing unit 901 is also used to obtain a first spanning tree and a link set based on the network topology. The first spanning tree includes a first node, multiple second nodes, and a path from each second node to the first node. The path from each second node to the first node is the shortest path from each second node to the first node in the network topology. The link set includes links in the network topology other than the links in the first spanning tree.

[0111] The processing unit 901 is further configured to determine multiple nodes based on the first spanning tree and the link set, wherein the multiple nodes include a first node and at least two second nodes, or the multiple nodes include at least three second nodes, and the ring topology formed by the multiple nodes does not contain a sub-ring topology.

[0112] The sending unit 902 is used to send configuration information of the Ethernet ring network to multiple nodes. This configuration information is used to configure the multiple nodes to form an Ethernet ring network.

[0113] Optionally, for details of how processing unit 901 obtains the network topology of the local area network, please refer to [link to relevant documentation]. Figure 3 The details of step 302 in method 300 shown will not be explained in detail here.

[0114] Optionally, for details of the implementation process of processing unit 901 obtaining the first spanning tree and link set based on network topology, please refer to [link to relevant documentation]. Figure 3 The details of step 303 in method 300 shown will not be explained in detail here.

[0115] Optionally, for details on how processing unit 901 determines multiple nodes based on the first spanning tree and the link set, please refer to [link to relevant documentation]. Figure 3 The details of step 304 in method 300 shown will not be explained in detail here.

[0116] Optionally, for details on how the sending unit 902 sends the Ethernet ring network configuration information to multiple nodes, please refer to [link to relevant documentation]. Figure 3 The details of step 305 of method 300 shown will not be explained in detail here.

[0117] Optionally, the processing unit 901 is used for:

[0118] Select a link from the set of links as the target link. The target link is the link between two adjacent nodes in the network topology. The first spanning tree consists of two nodes.

[0119] Connect two nodes in the first spanning tree using the target link to obtain the second spanning tree;

[0120] In the second spanning tree, a minimum ring topology including the target link is determined, where multiple nodes are nodes in the minimum ring topology. This allows for automatic ring network partitioning based on the minimum spanning tree.

[0121] Optionally, for details on how processing unit 901 selects a link from the link set as the target link, see [link to implementation details]. Figure 3 The details of step 3041 in method 300 shown will not be explained in detail here.

[0122] Optionally, the processing unit 901 uses the target link to connect two nodes in the first spanning tree to obtain the second spanning tree. For a detailed implementation process, see [link to relevant documentation]. Figure 3 The details of step 3042 in method 300 shown will not be explained in detail here.

[0123] Optionally, for details of the implementation process of processing unit 901 determining the minimum ring topology including the target link in the second spanning tree, see [link to relevant documentation]. Figure 3 The details of step 3043 in method 300 shown will not be explained in detail here.

[0124] Optionally, for each of the plurality of nodes, the Ethernet ring network configuration information sent to the node includes one or more of the following: Ethernet ring network identification information, Ethernet ring network control virtual local area network (VLAN) identification information, Ethernet ring network service VLAN identification information, Ethernet ring network protection instance, Ethernet ring network master / slave type, or the role of the target port in the node, wherein the target port is a port in the node that belongs to the ring topology.

[0125] Optionally, multiple nodes are nodes with Ethernet ring network protection capabilities, thus ensuring that multiple nodes are successfully configured into an Ethernet ring network.

[0126] Optionally, the local area network (LAN) can be a corporate campus network.

[0127] In this embodiment, the processing unit automatically obtains the network topology of the local area network (LAN) and, based on the network topology, obtains a first spanning tree and a set of links. The processing unit then determines multiple nodes based on the first spanning tree and the set of links. The ring topology formed by these multiple nodes does not contain sub-ring topologies. The sending unit sends Ethernet ring network configuration information to the multiple nodes, and the multiple nodes form an Ethernet ring network based on the configuration information. In this way, the processing unit and the sending unit can automatically obtain the network topology, automatically determine the ring topology, and automatically configure the Ethernet ring network based on the ring topology, without manual intervention. This automatically collects the network topology and divides it into ring networks, thereby enabling automatic and rapid deployment of the Ethernet ring network.

[0128] See Figure 10 This application provides a schematic diagram of a device 1000. The device 1000 can be any of the optical network management systems provided in the above embodiments. The device 1000 includes at least one processor 1001, internal connections 1002, a memory 1003, and at least one communication interface 1004.

[0129] The device 1000 is a hardware-structured device.

[0130] In some embodiments, the device 1000 can be used to implement Figure 9 The functional modules in the device 900. For example, those skilled in the art will conceive of them. Figure 9 The processing unit 901 and the transmitting unit 902 in the illustrated device 900 can be implemented by at least one processor 1001. The device 1000 can also be used to implement the function of configuring an Ethernet ring network in any of the above embodiments.

[0131] The processor 1001 described above is, for example, a general-purpose central processing unit (CPU), a digital signal processor (DSP), a network processor (NP), a graphics processing unit (GPU), a neural network processing unit (NPU), a data processing unit (DPU), a microprocessor, or one or more integrated circuits for implementing the solutions of this application. For example, processor 1001 includes an application-specific integrated circuit (ASIC), a programmable logic device (PLD), or other programmable logic devices, transistor logic devices, hardware components, or any combination thereof. A PLD is, for example, a complex programmable logic device (CPLD), a field-programmable gate array (FPGA), a generic array logic (GAL), or any combination thereof. It can implement or execute the various logic blocks, modules, and circuits described in conjunction with the disclosure of the embodiments of this application. The processor can also be a combination of functions that perform computing, such as a combination of one or more microprocessors, a combination of a DSP and a microprocessor, etc.

[0132] The aforementioned internal connection 1002 may include a pathway for transmitting information between the aforementioned components. The internal connection 1002 may be a single board or a bus, etc. The bus may be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The bus can be divided into address bus, data bus, control bus, etc. For ease of representation, Figure 10 The bus is represented by a single thick line, but this does not mean that there is only one bus or one type of bus.

[0133] At least one communication interface 1004 described above uses any transceiver-like device for communicating with other devices or communication networks, such as Ethernet, wireless access networks, or wireless local area networks (WLANs). Communication interface 1004 may include wired communication interfaces and wireless communication interfaces. Specifically, communication interface 1004 may be an Ethernet interface, a Fast Ethernet (FE) interface, a Gigabit Ethernet (GE) interface, an Asynchronous Transfer Mode (ATM) interface, a WLAN interface, a cellular network communication interface, or a combination thereof. The Ethernet interface may be an optical interface, an electrical interface, or a combination thereof. In this embodiment, communication interface 1004 can be used by the device 1000 to communicate with other devices.

[0134] The aforementioned memory 1003 may be a read-only memory (ROM) or other type of static storage device capable of storing static information and instructions, random access memory (RAM) or other type of dynamic storage device capable of storing information and instructions, or electrically erasable programmable read-only memory (EEPROM), compact disc read-only memory (CD-ROM) or other optical disc storage, optical disc storage (including compressed optical discs, laser discs, optical discs, digital universal optical discs, Blu-ray discs, etc.), magnetic disk storage media or other magnetic storage devices, or any other medium capable of carrying or storing desired program code in the form of instructions or data structures and accessible by a computer, but not limited thereto. The memory may exist independently and be connected to the processor via a bus. The memory 1003 may also be integrated with the processor 1001.

[0135] In a specific implementation, as one example, the processor 1001 may include one or more CPUs, for example... Figure 10 CPU0 and CPU1 are mentioned. Each of these CPUs can be a single-core processor or a multi-core processor. Here, a processor can refer to one or more devices, circuits, and / or processing cores used to process data (such as computer program instructions).

[0136] In a specific implementation, as one example, the device 1000 may include multiple processors, for example... Figure 10Processors 1001 and 1007 are mentioned. Each of these processors can be a single-core (single-CPU) processor or a multi-core (multi-CPU) processor. A processor here can refer to one or more devices, circuits, and / or processing cores used to process data (e.g., computer program instructions).

[0137] This application also provides a computer program product including program instructions stored in a computer-readable storage medium. A processor of a management device reads the program instructions from the computer-readable storage medium and executes the program instructions, causing the management device to perform... Figure 3 The process shown is part of the workflow.

[0138] Those skilled in the art will recognize that the method steps and units described in the embodiments disclosed in this application can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the steps and components of each embodiment have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art 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.

[0139] In the embodiments provided in this application, it should be understood that the disclosed system architecture, apparatus, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative. For instance, the division of modules is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple modules or components may be combined or integrated into another system, or some features may be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed may be indirect coupling or communication connection through some interfaces, devices, or modules, or may be electrical, mechanical, or other forms of connection.

[0140] The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical modules; that is, they may be located in one place or distributed across multiple network modules. Some or all of the modules can be selected to achieve the purpose of the embodiments of this application, depending on actual needs.

[0141] Furthermore, the modules in the various embodiments of this application can be integrated into one processing module, or each module can exist physically separately, or two or more modules can be integrated into one module. The integrated modules described above can be implemented in hardware or in software.

[0142] If the integrated module is implemented as a software functional module and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, ROM, RAM, magnetic disks, or optical disks.

[0143] In this application, the terms "first" and "second," etc., are used to distinguish identical or similar items that have substantially the same function and purpose. It should be understood that there is no logical or temporal dependency between "first" and "second," nor does it limit the quantity or order of execution. It should also be understood that although the following description uses the terms "first" and "second," etc., to describe various elements, these elements should not be limited by the terms. These terms are merely used to distinguish one element from another. For example, without departing from the scope of various examples, first location information can be referred to as second location information, and similarly, second location information can be referred to as first location information. Both first and second location information can be location information, and in some cases, they can be separate and distinct location information.

[0144] The above description is merely an optional embodiment of this application and is not intended to limit this application. Any modifications, equivalent substitutions, improvements, etc., made within the principles of this application should be included within the protection scope of this application.

Claims

1. A method for configuring an Ethernet ring network, characterized in that, The method is applied to a management device of a local area network (LAN), wherein the LAN further includes a first node and multiple second nodes, the first node being an egress device of the LAN or the first node communicating with the egress device, and the method includes: The management device acquires the network topology of the local area network, where adjacent nodes in the network topology are connected by links. The management device obtains a first spanning tree and a link set based on the network topology. The first spanning tree includes the first node, the plurality of second nodes, and the path between each second node and the first node. The path between each second node and the first node is the shortest path from each second node to the first node in the network topology. The link set includes links in the network topology other than the links in the first spanning tree. The management device determines multiple nodes based on the first spanning tree and the link set. The multiple nodes include the first node and at least two second nodes, or the multiple nodes include at least three second nodes. The ring topology formed by the multiple nodes does not contain sub-ring topologies. The management device sends Ethernet ring network configuration information to the plurality of nodes, the configuration information being used to configure the plurality of nodes to form the Ethernet ring network.

2. The method as described in claim 1, characterized in that, The management device determines multiple nodes based on the first spanning tree and the link set, including: Select one link from the set of links as the target link. The target link is the link between two adjacent nodes in the network topology. The first spanning tree includes the two nodes. The two nodes in the first spanning tree are connected using the target link to obtain the second spanning tree; In the second spanning tree, a minimum ring topology including the target link is determined, wherein the plurality of nodes are nodes on the minimum ring topology.

3. The method as described in claim 1 or 2, characterized in that, For each of the plurality of nodes, the configuration information of the Ethernet ring network sent to the node includes one or more of the following: the identification information of the Ethernet ring network, the identification information of the control virtual local area network (VLAN) of the Ethernet ring network, the identification information of the service VLAN of the Ethernet ring network, the protection instance of the Ethernet ring network, the master-slave type of the Ethernet ring network, or the role of the target port in the node, wherein the target port is a port in the node that belongs to the ring topology.

4. The method according to any one of claims 1-3, characterized in that, The aforementioned nodes are nodes with Ethernet ring network protection capabilities.

5. The method according to any one of claims 1-4, characterized in that, The local area network mentioned is the enterprise campus network.

6. A device for configuring an Ethernet ring network, characterized in that, The device is located in a local area network (LAN), which further includes a first node and multiple second nodes. The first node is either an egress device of the LAN or communicates with the egress device. The device includes: The processing unit is used to obtain the network topology of the local area network, wherein adjacent nodes in the network topology are connected by links; The processing unit is further configured to obtain a first spanning tree and a link set based on the network topology. The first spanning tree includes the first node, the plurality of second nodes, and the path between each second node and the first node. The path between each second node and the first node is the shortest path from each second node to the first node in the network topology. The link set includes links in the network topology other than the links in the first spanning tree. The processing unit is further configured to determine multiple nodes based on the first spanning tree and the link set, wherein the multiple nodes include the first node and at least two second nodes, or the multiple nodes include at least three second nodes, and the ring topology formed by the multiple nodes does not contain sub-ring topologies; The sending unit is used to send configuration information of the Ethernet ring network to the plurality of nodes, the configuration information being used to configure the plurality of nodes to form an Ethernet ring network.

7. The apparatus as claimed in claim 6, characterized in that, The processing unit is used for: Select one link from the set of links as the target link. The target link is the link between two adjacent nodes in the network topology. The first spanning tree includes the two nodes. The two nodes in the first spanning tree are connected using the target link to obtain the second spanning tree; In the second spanning tree, a minimum ring topology including the target link is determined, wherein the plurality of nodes are nodes on the minimum ring topology.

8. A device for configuring an Ethernet ring network, characterized in that, The device includes a processor and a memory; The processor is configured to execute program instructions in the memory to perform the method as described in any one of claims 1 to 5.

9. A computer-readable storage medium having a computer program or instructions stored thereon, characterized in that, When the computer program or instructions are executed by the processor, they implement the method as described in any one of claims 1-5.

10. A computer program product having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the method as described in any one of claims 1-5.