Message transmission method, device and system
By introducing virtual port binding VPLS and VPWS instances into the EVPN network, the problem of MAC address learning pressure of PE devices is solved and the forwarding performance is improved.
Patent Information
- Application Number
- CN202011566677.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-12-25
- Publication Date
- 2025-08-08
- Estimated Expiration
- 2040-12-25
AI Technical Summary
In EVPN networks, PE devices need to learn a large number of MAC addresses, resulting in a degradation of forwarding performance. The prior art cannot effectively reduce the pressure of MAC address learning.
By introducing a virtual port in the VPLS network device, VPWS instances are instructed to bind VPLS and VPWS, packet forwarding is realized, and the need for PE devices to learn MAC addresses is reduced.
It reduces the pressure on PE devices to learn MAC addresses, simplifies MAC table entries, and improves the message forwarding performance of network systems.
Smart Images

Figure CN114760243B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of network technology, and in particular to a message transmission method, device and system. Background Art
[0002] In traditional Layer 2 virtual private networks (L2VPNs), different provider edge (PE) devices can be connected via virtual leased line pseudo wires (VLL PWs). PEs forward packets over these inter-PE VLL PWs, reducing the burden on PEs to learn media access control (MAC) addresses.
[0003] Traditional L2VPN networks, due to the characteristics of VLL PWs, can reduce the burden on PE devices in the network to learn MAC addresses. However, with technological advancements, various telecom services are evolving towards Ethernet virtual private network (EVPN) solutions. Because EVPN signaling does not support VLL PWs, PE devices in current EVPN networks need to learn MAC addresses to forward packets. This results in increased MAC address learning pressure on PE devices, resulting in complex MAC table entries in PE devices, which can easily affect PE forwarding performance. Summary of the Invention
[0004] This application provides a message transmission method, device, and system that can reduce the pressure on network devices to learn MAC addresses, simplify the MAC table entries of network devices, and help ensure the message forwarding performance of the network system including the network device. The technical solution of this application is as follows:
[0005] In a first aspect, a message transmission method is provided. The method is applied to a system including a first network device and a second network device, wherein the first network device is a device in a virtual private lan service (VPLS) network, and the second network device is a device in a virtual private wire service (VPWS) network. The method includes: the first network device determines, based on a destination address carried in a received first message, a virtual port corresponding to the destination address in a VPLS instance of the first network device, wherein the virtual port is used to indicate a first VPWS instance in the first network device; and the first network device sends the first message to a second VPWS instance in the second network device based on the virtual port, wherein the second VPWS instance in the second network device and the first VPWS instance in the first network device are VPWS instances used to carry the same service.
[0006] The technical solution provided by this application is that the virtual port in the VPLS instance of a first network device indicates the first VPWS instance in the first network device, and the first VPWS instance in the first network device and the second VPWS instance in the second network device are used to carry the same service. After the first network device determines the virtual port corresponding to the destination address in the VPLS instance of the first network device based on the destination address carried in the received first message, it sends the first message to the second VPWS instance in the second network device based on the virtual port, and the second network device can forward the first message through the second VPWS instance. As a result, the first VPWS instance in the first network device can be used as a port member of the VPLS instance in the first network device. In this way, the first VPWS instance is bound to the VPLS instance to achieve the connection between VPLS and VPWS in the first network device, so that when the message reaches the second network device, the second network device can use the VPWS forwarding mechanism to forward the message. Therefore, the second network device does not need to learn MAC addresses, which helps reduce the pressure on the second network device to learn MAC addresses, simplifies the MAC table entries of the second network device, and ensures the message forwarding performance of the entire network system.
[0007] Optionally, the first network device sends a first message to a second VPWS instance in a second network device based on the virtual port, including: the first network device determines a routing table of the first VPWS instance based on the virtual port; and the first network device determines, based on the routing table of the first VPWS instance, to send the first message to the second VPWS instance in the second network device. For example, the first network device determines an egress port for the first message in the first VPWS instance based on the routing table of the first VPWS instance, and sends the first message to the second network device via the egress port of the first message in the first VPWS instance, thereby instructing the second network device to determine the second VPWS instance on the second network device for forwarding the first message. For example, the routing table of the first VPWS instance can be used to record a correspondence between a port identifier and association indication information, where the port identifier indicates a port in the first VPWS instance corresponding to the corresponding association indication information, and the association indication information instructs a remote device of the first network device (e.g., the second network device) to determine a VPWS instance (e.g., the second VPWS instance) corresponding to the first VPWS instance. For example, the association indication information may be an identifier of a virtual private network (VPN) service carried in the VPWS instance in the remote device. For example, in a multi-protocol label switching (MPLS) network, the association indication information may be a VPN service label. In a segment routing internet protocol version 6 (SRv6) network, the association indication information may be a segment identifier (SID) of the VPN service.
[0008] The technical solution provided in the present application enables the first network device to determine the egress port of the first message in the first VPWS instance based on the routing and forwarding table of the first VPWS instance by determining the routing and forwarding table of the first VPWS instance, thereby enabling the second network device to directly forward the user's first message based on the VPWS mechanism without maintaining the user's MAC address.
[0009] Optionally, the system further includes a third network device, which is a device in the VPWS network, and the method includes: the first network device determines the virtual port based on the destination address carried in the received second message; the first network device sends the second message to the third VPWS instance in the third network device based on the virtual port, wherein the third VPWS instance in the third network device and the first VPWS instance in the first network device are VPWS instances for carrying the same service. For example, the first network device can send the second message to the third VPWS instance in the third network device based on the virtual port corresponding to the destination address carried in the second message based on a load sharing strategy or a primary-backup protection strategy. In this way, load balancing of the network devices in the message transmission system or forwarding protection of the message can be achieved, for example, the loss of the second message due to the inability to forward the message due to a failure of the second network device can be avoided.
[0010] The technical solution provided by the present application is that the first network device determines the virtual port corresponding to the destination address in the VPLS instance of the first network device based on the destination address carried in the received second message, and sends the second message to the third VPWS instance in the third network device based on the virtual port corresponding to the destination address. This can achieve load sharing or active-standby protection between the third network device and the aforementioned second network device, ensure load balancing of network devices in the message transmission system, or ensure forwarding protection of messages, for example, reducing the packet loss rate of the message transmission system.
[0011] Optionally, the first network device sends the second message to the third VPWS instance in the third network device based on the virtual port, including: the first network device determines that a primary forwarding path between the first network device and the device indicated by the destination address for carrying the service has failed, wherein the second network device is located on the primary forwarding path; and the first network device sends the second message to the third VPWS instance in the third network device based on the primary forwarding path failure and the virtual port, wherein the third network device is located on a backup forwarding path between the first network device and the device indicated by the destination address for carrying the service. The primary forwarding path failure may be a failure of at least one network device on the primary forwarding path, or a failure of a port of at least one network device on the primary forwarding path, such as a failure of the second network device.
[0012] The technical solution provided in the present application is that after a first network device determines that a primary forwarding path for carrying services between the first network device and a destination device (i.e., the device indicated by the destination address) has failed, upon receiving a second message sent to the destination device, the first network device sends the second message to a third VPWS instance in a third network device located on a backup forwarding path between the first network device and the destination device based on the virtual port corresponding to the destination address carried in the second message. That is, the first network device sends the second message to the destination device through the backup forwarding path, thereby avoiding the loss of the second message due to the failure of the primary forwarding path and helping to reduce the packet loss rate of the message transmission system.
[0013] Optionally, the virtual port points to at least two VPWS instances of at least two network devices for carrying the service, and the at least two network devices including the VPWS instance are located on at least two forwarding paths between the first network device and the device indicated by the destination address, and the at least two forwarding paths are load sharing paths for each other, or the at least two forwarding paths include a primary forwarding path and a backup forwarding path.
[0014] The technical solution provided by the present application is that a first VPWS instance in a first network device is used to carry a service, and a virtual port corresponding to a destination address carried in a first message points to at least two VPWS instances in at least two network devices used to carry the service, so that at least two forwarding paths can exist between the first network device and the destination device (that is, the device indicated by the destination address). The at least two forwarding paths can perform load balancing or primary-backup protection for messages sent by the first network device to the destination device. For example, when the primary forwarding path in the at least two forwarding paths fails, the first network device can send messages to the destination device through the backup forwarding path, which helps to reduce the packet loss rate of the message transmission system.
[0015] Optionally, the VPLS instance includes a port of the virtual port type, that is, the VPLS instance includes a virtual port. The virtual port in the VPLS instance indicates a VPWS instance in the first network device. The VPLS instance may include one or more virtual ports, and the multiple virtual ports may indicate different VPWS instances in the first network device. If the VPLS instance includes multiple virtual ports, the multiple virtual ports may be isolated from each other so that the VPWS instances indicated by the multiple virtual ports are isolated from each other, thereby preventing user devices connected to the VPWS instances indicated by the multiple virtual ports from accessing each other.
[0016] Optionally, the VPLS instance further includes at least one of an access circuit (AC) type port and an Ethernet virtual private network peer (EVPN Peer) type port. The AC type port may be referred to as an AC port, and the EVPN Peer type port may be referred to as an EVPN Peer port. In the first network device, the AC port may be used for communication between the first network device and a broadband access device, such as a broadband remote access server (BRAS), and the EVPN Peer port may be used for communication between the first network device and a remote network device, such as a remote PE device.
[0017] Optionally, the first network device determines the virtual port corresponding to the destination address in the VPLS instance of the first network device based on the destination address carried in the received first message, including: the first network device determines the virtual port corresponding to the destination address based on the port corresponding to the destination address in the routing forwarding table of the VPLS instance of the first network device as a virtual port.
[0018] Optionally, the first network device determines the virtual port corresponding to the destination address based on that the port corresponding to the destination address in the routing forwarding table of the VPLS instance of the first network device is a virtual port, including: the first network device determines the virtual port based on the destination address and the port identifier in the routing forwarding table of the VPLS instance, wherein the port identifier is used to indicate the virtual port corresponding to the destination address in the VPLS instance and the type of the virtual port; or, the first network device determines the virtual port based on the destination address, port identifier and port type in the routing forwarding table of the VPLS instance, wherein the port identifier indicates the port corresponding to the destination address in the VPLS instance, and the port type indicates that the type of the port is a virtual port type.
[0019] The technical solution provided by the present application is that the port identifier can be used to indicate the port and the type of the port, or the port identifier can be used only to indicate the port. In the case where the port identifier can be used to indicate both the port and the type of the port, the routing and forwarding table of the VPLS instance of the first network device can record the correspondence between the address and the port identifier. In the case where the port identifier is only used to indicate the port, the routing and forwarding table of the VPLS instance of the first network device can record the correspondence between the address, the port identifier and the port type. Regardless of the indication method, the first network device can determine the port type based on the routing and forwarding table of the VPLS instance, which helps to improve the accuracy of the first network device in determining the virtual port corresponding to the destination address carried by the first message based on the routing and forwarding table of the VPLS instance.
[0020] Optionally, before the first network device determines, in the VPLS instance of the first network device, the virtual port corresponding to the destination address carried in the received first message, the method further includes: the first network device receives a third message sent by the second network device through the first VPWS instance in the first network device; the first network device generates a forwarding entry in the routing and forwarding table of the VPLS instance based on the source address carried in the third message and the first VPWS instance, wherein the destination address in the forwarding entry is the source address carried in the third message, and the port identifier in the forwarding entry is used to indicate the virtual port, and the virtual port is used to indicate the first VPWS instance in the first network device. For example, the first network device determines, in the VPLS instance of the first network device, the virtual port corresponding to the first VPWS instance, and generates a forwarding entry in the routing and forwarding table of the VPLS instance based on the source address carried in the third message and the port identifier of the virtual port corresponding to the first VPWS instance.
[0021] The technical solution provided by the present application is that a first network device receives a third message sent by a second network device through a first VPWS instance in the first network device, and generates a forwarding entry in a routing and forwarding table of a VPLS instance of the first network device based on a source address carried in the third message and the first VPWS instance. This allows the first network device to determine, in the VPLS instance, a virtual port corresponding to a destination address carried in the first message and the first VPWS instance indicated by the virtual port based on the routing and forwarding table of the VPLS instance when sending a first message to the second network device.
[0022] Optionally, the method also includes: the first network device receives the fourth message; the first network device broadcasts the fourth message through multiple ports of the VPLS instance based on the absence of a port corresponding to the destination address carried in the fourth message in the VPLS instance of the first network device, and the multiple ports include the virtual port.
[0023] The technical solution provided by the present application is that when there is no port corresponding to the target address carried by the fourth message in the VPLS instance of the first network device, the first network device broadcasts the fourth message through multiple ports of the VPLS instance. Therefore, the message transmission solution provided by the present application can be applied to the message broadcast scenario.
[0024] In a second aspect, a message transmission system is provided, the system comprising a first network device and a second network device, the first network device being a device in a VPLS network, the second network device being a device in a VPWS network,
[0025] The first network device is configured to determine, in the VPLS instance of the first network device, a virtual port corresponding to the destination address carried in the received first message, and send the first message to the second VPWS instance in the second network device according to the virtual port, wherein the virtual port is used to indicate the first VPWS instance in the first network device, and the second VPWS instance in the second network device and the first VPWS instance in the first network device are VPWS instances for carrying the same service;
[0026] The second network device is configured to forward the first message through a second VPWS instance in the second network device.
[0027] Optionally, the first network device is specifically configured to: determine a routing table of the first VPWS instance according to the virtual port; and determine to send the first message to a second VPWS instance in the second network device according to the routing table of the first VPWS instance.
[0028] Optionally, the system further includes a third network device, which is a device in the VPWS network.
[0029] The first network device is further configured to determine the virtual port according to the destination address carried in the received second message, and send the second message to a third VPWS instance in the third network device according to the virtual port, where the third VPWS instance in the third network device and the first VPWS instance in the first network device are VPWS instances used to carry the same service;
[0030] The third network device is configured to forward the second message through a third VPWS instance in the third network device.
[0031] Optionally, the first network device is specifically used to: determine that a primary forwarding path between the first network device and the device indicated by the destination address for carrying the service has failed, and based on the primary forwarding path failure and the virtual port, send the second message to the third VPWS instance in the third network device, wherein the second network device is located on the primary forwarding path, and the third network device is located on the backup forwarding path between the first network device and the device indicated by the destination address for carrying the service.
[0032] Optionally, the virtual port points to at least two VPWS instances of at least two network devices for carrying the service, and the at least two network devices including the VPWS instance are located on at least two forwarding paths between the first network device and the device indicated by the destination address, and the at least two forwarding paths are load sharing paths for each other, or the at least two forwarding paths include a primary forwarding path and a backup forwarding path.
[0033] Optionally, the VPLS instance includes one or more virtual ports, and the multiple virtual ports indicate different VPLS instances in the first network device.
[0034] Optionally, the VPLS instance includes a port of a virtual port type.
[0035] Optionally, the VPLS instance further includes at least one of an AC type port and an EVPN Peer type port.
[0036] Optionally, the first network device is specifically configured to determine the virtual port corresponding to the destination address according to a routing forwarding table of a VPLS instance of the first network device that the port corresponding to the destination address is a virtual port.
[0037] Optionally, the first network device is specifically used to: determine the virtual port based on the destination address and port identifier in the routing and forwarding table of the VPLS instance, wherein the port identifier is used to indicate the virtual port corresponding to the destination address in the VPLS instance and the type of the virtual port; or determine the virtual port based on the destination address, port identifier and port type in the routing and forwarding table of the VPLS instance, wherein the port identifier indicates the port corresponding to the destination address in the VPLS instance, and the port type indicates that the type of the port is a virtual port type.
[0038] Optionally, the second network device is further configured to send a third message to the first network device;
[0039] The first network device is further configured to receive, through the first VPWS instance in the first network device, the third message sent by the second network device, and generate a forwarding entry in the routing forwarding table of the VPLS instance based on the source address carried in the third message and the first VPWS instance, wherein the destination address in the forwarding entry is the source address carried in the third message, and the port identifier in the forwarding entry is used to indicate the virtual port, and the virtual port is used to indicate the first VPWS instance in the first network device.
[0040] Optionally, the first network device is also used to receive a fourth message, and based on the fact that there is no port corresponding to the destination address carried in the fourth message in the VPLS instance of the first network device, broadcast the fourth message through multiple ports of the VPLS instance, and the multiple ports include the virtual port.
[0041] Optionally, the first network device, the second network device and the third network device are all PE devices.
[0042] The technical effects of the second aspect and its various optional implementations can refer to the technical effects of the above-mentioned first aspect and its various optional implementations, and will not be elaborated here.
[0043] In a third aspect, a first network device is provided. The first network device is located in a message transmission system. The system further includes a second network device. The first network device is a device in a VPLS network. The second network device is a device in a VPWS network. The first network device includes:
[0044] a determination module, configured to determine, in the VPLS instance of the first network device, a virtual port corresponding to the destination address according to the destination address carried in the received first message, wherein the virtual port is used to indicate the first VPWS instance in the first network device;
[0045] The sending module is configured to send the first message to the second VPWS instance in the second network device according to the virtual port, wherein the second VPWS instance in the second network device and the first VPWS instance in the first network device are VPWS instances for carrying the same service.
[0046] Optionally, the sending module is specifically configured to: determine a routing table of the first VPWS instance according to the virtual port; and determine to send the first message to the second VPWS instance in the second network device according to the routing table of the first VPWS instance.
[0047] Optionally, the system further includes a third network device, which is a device in the VPWS network.
[0048] The determining module is further configured to determine the virtual port according to the destination address carried in the received second message;
[0049] The sending module is further configured to send the second message to a third VPWS instance in the third network device according to the virtual port, wherein the third VPWS instance in the third network device and the first VPWS instance in the first network device are VPWS instances for carrying the same service.
[0050] Optionally, the determining module is further configured to determine that a primary forwarding path between the first network device and the device indicated by the destination address for carrying the service is faulty, wherein the second network device is located on the primary forwarding path;
[0051] The sending module is specifically configured to send the second message to the third VPWS instance in the third network device according to the primary forwarding path failure and the virtual port, wherein the third network device is located on the backup forwarding path for carrying the service between the first network device and the device indicated by the destination address.
[0052] Optionally, the virtual port points to at least two VPWS instances of at least two network devices for carrying the service, and the at least two network devices including the VPWS instance are located on at least two forwarding paths between the first network device and the device indicated by the destination address, and the at least two forwarding paths are load sharing paths for each other, or the at least two forwarding paths include a primary forwarding path and a backup forwarding path.
[0053] Optionally, the VPLS instance includes a port of the virtual port type.
[0054] Optionally, the VPLS instance further includes at least one of an AC-type port and an EVPN Peer-type port.
[0055] Optionally, the determining module is specifically configured to determine the virtual port corresponding to the destination address based on the port corresponding to the destination address in the routing forwarding table of the VPLS instance of the first network device being the virtual port.
[0056] Optionally, the determining module is specifically configured to:
[0057] Determine the virtual port according to the destination address and the port identifier in the routing table of the VPLS instance, wherein the port identifier is used to indicate the virtual port corresponding to the destination address in the VPLS instance and the type of the virtual port; or
[0058] The virtual port is determined according to the destination address, port identifier and port type in the routing table of the VPLS instance, wherein the port identifier indicates the port corresponding to the destination address in the VPLS instance, and the port type indicates that the type of the port is a virtual port type.
[0059] Optionally, the first network device further includes:
[0060] a receiving module configured to receive, through the first VPWS instance in the first network device, a third message sent by the second network device before the determining module determines, in the VPLS instance of the first network device, a virtual port corresponding to the destination address based on the destination address carried in the received first message;
[0061] The processing module is configured to generate a forwarding entry in the routing forwarding table of the VPLS instance based on the source address carried in the third message and the first VPWS instance, wherein the destination address in the forwarding entry is the source address carried in the third message, and the port identifier in the forwarding entry is used to indicate the virtual port, and the virtual port is used to indicate the first VPWS instance in the first network device.
[0062] Optionally, the first network device further includes:
[0063] A receiving module, configured to receive a fourth message;
[0064] The broadcast module is configured to broadcast the fourth message through multiple ports of the VPLS instance according to the absence of a port corresponding to the destination address carried in the fourth message in the VPLS instance of the first network device, where the multiple ports include the virtual port.
[0065] The technical effects of the third aspect and its various optional implementations can refer to the technical effects of the first aspect and its various optional implementations, and are not repeated here. The modules described in the third aspect can be implemented based on software, hardware, or a combination of software and hardware, and the modules can be arbitrarily combined or divided based on the specific implementation.
[0066] In a fourth aspect, a network device is provided, the network device including a memory and a processor;
[0067] The memory is used to store computer programs;
[0068] The processor is used to execute the computer program stored in the memory to perform the message transmission method provided by the first aspect or any optional manner of the first aspect.
[0069] In a fifth aspect, a computer-readable storage medium is provided, in which a computer program is stored. When the computer program is executed by a processor, the message transmission method provided in the first aspect or any optional method of the first aspect is implemented.
[0070] In a sixth aspect, a computer program product comprising instructions is provided, which, when run on a computer, enables the computer to execute the message transmission method provided in the first aspect or any optional method of the first aspect.
[0071] In a seventh aspect, a chip is provided, which includes a programmable logic circuit and / or program instructions, and when the chip is running, it is used to implement the message transmission method provided by the first aspect or any optional method of the first aspect.
[0072] In an eighth aspect, a message transmission system is provided, which includes a first network device and a second network device, the first network device being the network device provided in the third aspect, or the first network device being the network device provided in the fourth aspect, the first network device being used to send messages to the VPWS instance in the second network device through the VPWS instance indicated by the virtual port in the VPLS instance of the first network device.
[0073] The beneficial effects of the technical solution provided by this application are:
[0074] The present application provides a message transmission method, device, and system, which includes a first network device in a VPLS network and a second network device in a VPWS network. After receiving a first message, the first network device determines the virtual port corresponding to the destination address in the VPLS instance of the first network device based on the destination address carried in the first message, and sends the first message to the second network device based on the virtual port. The second network device can determine to forward the first message through the second VPWS instance. Thus, the first VPWS instance in the first network device can serve as a port member of the VPLS instance in the first network device. In this way, the first VPWS instance is bound to the VPLS instance to realize the connection between VPLS and VPWS in the first network device, so that the second network device can use the VPWS forwarding mechanism to forward messages without learning the user's MAC address, which helps to reduce the pressure on the second network device to learn MAC addresses, simplify the MAC table entries of the second network device, and ensure the message forwarding performance of the network system. BRIEF DESCRIPTION OF THE DRAWINGS
[0075] Figure 1 This is a schematic diagram of the structure of an EVPN network provided in an embodiment of the present application;
[0076] Figure 2 This is a schematic diagram of the structure of another EVPN network provided in an embodiment of the present application;
[0077] Figure 3 This is a schematic diagram of the structure of another EVPN network provided in an embodiment of the present application;
[0078] Figure 4 This is a flow chart of a message transmission method provided by an embodiment of the present application;
[0079] Figure 5 This is a schematic diagram of the relationship between a VPLS instance and a VPWS instance provided in an embodiment of the present application;
[0080] Figure 6 This is a schematic diagram of a message transmission method provided in an embodiment of the present application;
[0081] Figure 7 This is a flowchart of another message transmission method provided by an embodiment of the present application;
[0082] Figure 8 This is a schematic diagram of another message transmission method provided in an embodiment of the present application;
[0083] Figure 9 This is a flowchart of another message transmission method provided in an embodiment of the present application;
[0084] Figure 10 This is a schematic diagram of the logical structure of a first network device provided in an embodiment of the present application;
[0085] Figure 11 This is a schematic diagram of the hardware structure of a network device provided in an embodiment of the present application;
[0086] Figure 12 This is a schematic diagram of the hardware structure of another network device provided in an embodiment of the present application;
[0087] Figure 13 It is a structural diagram of a message transmission system provided in an embodiment of the present application. DETAILED DESCRIPTION
[0088] In order to make the principles, technical solutions and advantages of the present application clearer, the implementation methods of the present application will be further described in detail below with reference to the accompanying drawings.
[0089] In traditional L2VPN networks, PE devices can forward packets using VLL PWs, reducing the pressure on PE devices to learn MAC addresses. However, with technological advancements, various telecom services are currently evolving towards EVPN solutions. Because EVPN signaling does not support VLL PWs, PE devices in current EVPN networks need to learn MAC addresses to forward packets, placing significant pressure on PE devices to learn MAC addresses. The technical solutions provided in the embodiments of the present application, when applied to EVPN networks, can reduce the pressure on PE devices to learn MAC addresses. The technical solutions in the embodiments of the present application are described below.
[0090] First, the application scenarios of the embodiments of the present application are explained.
[0091] The technical solution provided in the embodiments of the present application can be applied to an EVPN network. The EVPN network may include multiple PE devices, which can communicate with each other to transmit user data, wherein the multiple PE devices can assume corresponding roles according to different application scenarios. Taking the user broadband access scenario as an example, the EVPN network applied to this scenario may include multiple broadband access devices and multiple PE devices. Depending on the different roles assumed by the multiple PE devices, the multiple PE devices may include user access PE devices and broadband access PE devices. Each broadband access PE device is connected to at least one broadband access device, and each user access PE device is used to access at least one user device to the EVPN network, and each broadband access PE device is connected to at least one user access PE device. Among them, the broadband access device is used to provide broadband access services for the user device mounted under the corresponding broadband access PE device (the user device can be mounted under the user access PE device, and mounted under the broadband access PE device through the user access PE device).
[0092] In an EVPN network applied to user broadband access scenarios, each PE device may be configured with at least one VPWS instance, and the broadband access PE device may also be configured with a VPLS instance. The at least one VPWS instance in the user access PE device corresponds one-to-one to the at least one VPWS instance in the broadband access PE device, and the VPLS instance in the broadband access PE device corresponds to the at least one broadband access device (or the VPLS instance in the broadband access PE device is bound to the at least one broadband access device). After receiving a message sent by a user device mounted under the user access PE device, the user access PE device may forward the message to the corresponding VPWS instance in the broadband access PE device via the VPWS instance in the user access PE device. After receiving the message via the VPWS instance in the broadband access PE device, the broadband access PE device may forward the message to the corresponding broadband access device via the corresponding VPLS instance in the broadband access PE device. The broadband access device provides broadband access services to the user device based on the message.
[0093] The broadband access device may be a BRAS. User equipment may be various types of devices, such as a host, user terminal, server, or virtual machine (VM) created on a server. The user equipment may typically be a dial-up device, such as an optical modem, also known as an optical modem or single-port optical terminal. PE devices may be network devices such as routers, switches, virtual routers, or virtual switches. Each PE device may be directly connected or connected through other network devices (such as core devices), which is not limited in this embodiment of the present application.
[0094] For example, please refer to Figure 1 , which shows a structural diagram of an EVPN network applied to a user broadband access scenario provided by an embodiment of the present application, Figure 1 Take the broadband access device as BRAS and the user device as VM as an example. Figure 1 As shown in the figure, the EVPN network includes three PE devices, PE1 to PE3 (that is, PE1, PE2 and PE3), and BRAS1. PE1 is connected to PE2 and PE3 respectively, and PE1 is connected to BRAS1. PE2 and PE3 are connected to VM1 respectively (that is, VM1 is mounted on PE2 and PE3 respectively, and VM1 accesses the EVPN network through PE2 and PE3). Depending on the roles played by PE1 to PE3, PE1 can be a broadband access PE device, and PE2 and PE3 can both be user access PE devices. Among them, PE1 to PE3 are each configured with at least one VPWS instance ( Figure 1Only one is shown, which is VPWS instance 1), and PE1 is also configured with a VPLS instance. The VPWS instances in PE1 to PE3 correspond one to one, and the VPLS instance in PE1 corresponds to BRAS1 (or the VPLS instance in PE1 is bound to BRAS1). Among them, the one-to-one corresponding VPWS instances in each PE device can be used to carry the same service. For example, Figure 1 VPWS instance 1 in PE1 to PE3 is used to carry the same service.
[0095] For example, after PE2 receives a packet from VM1 mounted on PE2, it can forward the packet to VPWS instance 1 in PE1 via VPWS instance 1 in PE2. After PE1 receives the packet via VPWS instance 1 in PE1, it forwards the packet to BRAS1 via VPLS instance in PE1. BRAS1 provides broadband access services to VM1 based on the packet. For another example, after PE1 receives a packet from BRAS1 via VPLS instance in PE1, it forwards the packet to VPWS instance 1 in PE2 via VPWS instance 1 in PE1. After PE2 receives the packet via VPWS instance 1 in PE2, it forwards the packet to VM1 via VPWS instance 1 in PE2. Optionally, after PE1 receives a message sent by BRAS1 through the VPLS instance in PE1, it may also forward the message to VPWS instance 1 in PE3 through VPWS instance 1 in PE1 based on a load balancing policy or a primary / secondary protection policy. After PE3 receives the message through VPWS instance 1 in PE3, it forwards the message to VM1 through VPWS instance 1 in PE3. VPWS instance 1 in PE1 may include two ports (e.g., EVPN peer ports) corresponding to PE2 and PE3, so that PE1 can forward messages to VPWS instance 1 in PE2 through VPWS instance 1 in PE1, or forward messages to VPWS instance 1 in PE3 through VPWS instance 1 in PE1.
[0096] Typically, an EVPN network applied to a user broadband access scenario may include multiple broadband access devices, multiple broadband access PE devices, and multiple user access PE devices. Each broadband access PE device may be connected to at least one user access PE device, and each broadband access PE device may be connected to at least one broadband access device. Each user access PE device may be mounted with at least one user device, and the same user device may be mounted with different user access PE devices. Furthermore, when the EVPN network includes multiple broadband access PE devices, the multiple broadband access PE devices may be connected to each other to implement dual homing protection for the broadband access PE devices. For example, when a forwarding path failure between a broadband access PE device among the multiple broadband access PE devices and a destination device (e.g., a user device) causes the broadband access PE device to be unable to send a message to the destination device through the forwarding path, the broadband access PE device may send the message to the broadband access PE device to which it is connected, and the broadband access PE device to which it is connected sends the message to the destination device, thereby implementing dual homing protection for the broadband access PE device.
[0097] For example, please refer to Figure 2 , which shows a structural diagram of another EVPN network applied to a user broadband access scenario provided by an embodiment of the present application, Figure 2 Let's take the broadband access device as BRAS and the user device as VM as an example. Figure 2 As shown, the EVPN network includes four PE devices, namely PE1 to PE4 (i.e., PE1, PE2, PE3, and PE4), and three broadband access devices, namely BRAS1 to BRAS3 (i.e., BRAS1, BRAS2, and BRAS3). PE1 and PE4 are connected to PE2 and PE3 respectively, and PE1 and PE4 are connected to BRAS1 to BRAS3 respectively. PE2 and PE3 are connected to VM1 to VM4 (i.e., VM1, VM2, VM3, and VM4), and PE1 is connected to PE4. Depending on the roles played by PE1 to PE4, PE1 and PE4 can both be broadband access PE devices, and PE2 and PE3 can both be user access PE devices. Among them, PE1 to PE4 are each configured with at least one VPWS instance ( Figure 2 Only two are shown, namely VPWS instance 1 and VPWS instance 2, and VPLS instances are also configured in PE1 and PE4. The VPWS instances in PE1 to PE4 correspond one to one, and the VPLS instance in PE1 and the VPLS instance in PE4 correspond to BRAS1 to BRAS3 respectively (or the VPLS instance in PE1 and the VPLS instance in PE4 are bound to BRAS1 to BRAS3 respectively). Among them, the one-to-one corresponding VPWS instances in each PE device can be used to carry the same service. For example Figure 2 There is a one-to-one correspondence between VPWS instance 1 in PE1 to PE4, and VPWS instance 1 in PE1 to PE4 is used to carry the same service. There is a one-to-one correspondence between VPWS instance 2 in PE1 to PE4, and VPWS instance 2 in PE1 to PE4 is used to carry the same service. The services carried by VPWS instance 1 and VPWS instance 2 can be different.
[0098] For example, after PE2 receives a packet from VM1 mounted on PE2, it can forward the packet to VPWS instance 1 in PE1 via VPWS instance 1 in PE2. After PE1 receives the packet via VPWS instance 1 in PE1, it forwards the packet to BRAS1 via VPLS instance in PE1. BRAS1 provides broadband access services to VM1 based on the packet. For another example, after PE1 receives a packet from BRAS1 via VPLS instance in PE1, it forwards the packet to VPWS instance 1 in PE2 via VPWS instance 1 corresponding to the VPLS instance. After PE2 receives the packet via VPWS instance 1 in PE2, it forwards the packet to VM1 via VPWS instance 1 in PE2. Optionally, after PE1 receives the message sent by BRAS1 through the VPLS instance in PE1, it can also forward the message to VPWS instance 1 in PE3 through VPWS instance 1 in PE1 based on the load sharing strategy or the active-standby protection strategy. After PE3 receives the message through VPWS instance 1 in PE3, it forwards the message to VM1 through VPWS instance 1 in PE3.
[0099] Optionally, after PE1 receives a message sent by BRAS1 through the VPLS instance in PE1, if a forwarding path failure between PE1 and VM1 (for example, a failure of VPWS instance 1 in PE1) causes PE1 to be unable to send a message to VM1 through the forwarding path, PE1 can forward the message to PE4 through the VPLS instance in PE1, and PE4 sends the message to VM1, thereby achieving dual homing protection between PE1 and PE4.
[0100] Typically, an EVPN network also includes edge access devices and core devices, and each PE device can be connected through the core device. In an EVPN network applied to a user broadband access scenario, the edge access device can be connected to the user access PE device, and the user device is connected to the user access PE device through the edge access device. That is, the user device is mounted under the edge access device and connected to the user access PE device through the edge access device. The edge access device can be, for example, a customer edge (CE) device, and the core device can be, for example, a provider (P) device. Both the CE device and the P device can be network devices such as routers, switches, virtual routers, or virtual switches, and the CE device can be an optical line terminal (OLT). Optionally, each P device can be configured with at least one VPWS instance. The VPWS instance in the P device corresponds one-to-one with the VPWS instance in the user access PE device and the VPWS instance in the broadband access PE device. The P device can forward packets between the user access PE device and the broadband access PE device through the VPWS instance in the P device.
[0101] For example, please refer to Figure 3 , which shows a structural diagram of an EVPN network applied to a user broadband access scenario provided by an embodiment of the present application. Figure 3 The broadband access device is BRAS and the user equipment is VM. Figure 3 ,exist Figure 2 On the basis of , the EVPN network also includes two CE devices, CE1 and CE2, and two P devices, P1 and P2. Each P device in P1 and P2 is connected to PE1 to PE4 respectively, each CE device in CE1 and CE2 is connected to PE2 and PE3 respectively, and CE1 is connected to VM1 to VM2 respectively, and CE2 is connected to VM3 to VM4 respectively. In other words, each PE device in PE1 and PE4 is connected to PE2 and PE3 respectively through P1 and P2, each VM in VM1 to VM4 is connected to PE2 and PE3 respectively through CE1 and CE2, and each VM in VM1 to VM4 is mounted under CE1 and CE2 respectively. For the description of PE1 to PE4 and the description of VPWS instances and VPLS instances in PE1 to PE4, please refer to Figure 2 The relevant description of the EVPN network shown in the embodiment of the present application will not be repeated here. Figure 3 As shown, P1 and P2 are each configured with at least one VPWS instance ( Figure 3Only two are shown, namely VPWS instance 1 and VPWS instance 2). The VPWS instance in P1 corresponds one-to-one with the VPWS instances in PE1 to PE4, and the VPWS instance in P2 corresponds one-to-one with the VPWS instances in PE1 to PE4. Among them, the one-to-one corresponding VPWS instances in each PE device and each P device can be used to carry the same service. For example Figure 3 There is a one-to-one correspondence between PE1 to PE4 and VPWS instance 1 in P1 to P2. VPWS instance 1 in PE1 to PE4 and P1 to P2 is used to carry the same service. There is a one-to-one correspondence between PE1 to PE4 and VPWS instance 2 in P1 to P2. VPWS instance 2 in PE1 to PE4 and P1 to P2 is used to carry the same service. The services carried by VPWS instance 1 and VPWS instance 2 can be different. Figure 3 In the EVPN network shown, the VPWS instances in each PE device and each P device can correspond one-to-one with the CE devices. For example, the VPWS instance 1 in each PE device and each P device corresponds to CE1, and the VPWS instance 2 in each PE device and each P device corresponds to CE2. This embodiment of the present application is not limited to this.
[0102] For example, after PE2 receives a message sent by VM1 mounted under PE2 (the message may be forwarded through CE1), it can forward the message to VPWS instance 1 in P1 through VPWS instance 1 corresponding to CE1 in PE2. After P1 receives the message through VPWS instance 1 in P1, it forwards the message to VPWS instance 1 in PE1 through VPWS instance 1 in P1. After PE1 receives the message through VPWS instance 1 in PE1, it forwards the message to BRAS1 through the corresponding VPLS instance in PE1. BRAS1 provides broadband access service for VM1 based on the message. For another example, after PE1 receives a message sent by BRAS1 through the VPLS instance in PE1, it forwards the message to VPWS instance 1 in P1 through the VPWS instance 1 corresponding to the VPLS instance. After P1 receives the message through the VPWS instance 1 in P1, it forwards the message to VPWS instance 1 in PE2 through the VPWS instance 1 in P1. After PE2 receives the message through the VPWS instance 1 in PE2, it forwards the message to CE1 through the VPWS instance 1 in PE2. CE1 then forwards the message to VM1 based on the destination address carried in the message. Optionally, after PE1 receives the message sent by BRAS1 through the VPLS instance in PE1, it can also forward the message to the VPWS instance 1 in P2 through the VPWS instance 1 in PE1 based on the load sharing policy or the active-standby protection policy. After P2 receives the message through the VPWS instance 1 in P2, it forwards the message to the VPWS instance 1 in PE3 through the VPWS instance 1 in P2. After PE3 receives the message through the VPWS instance 1 in PE3, it forwards the message to CE1 through the VPWS instance 1 in PE3, and CE1 forwards the message to VM1 according to the destination address carried in the message.
[0103] In the embodiments of this application, Figures 1 to 3The EVPN network shown is for example only and is not intended to limit the technical solutions of the embodiments of the present application. In the specific implementation process, the number of PE devices, CE devices, P devices, and BRAS can be configured as needed, and the specific roles that each type of device needs to assume can be determined according to the application scenario. In addition, the EVPN network can also include other network devices. For example, the EVPN network can also include a route reflector (RR), etc., which is not limited by the embodiments of the present application. In addition, for ease of description, in the embodiments of the present application, in the user broadband access scenario, the PE device connected to the user device is called a user access PE device, and the PE device connected to the broadband access device is called a broadband access PE device. However, this description is only exemplary. Both the user access PE device and the broadband access PE device are PE devices. In other implementation scenarios, the user access PE device and the broadband access PE device can be described using other names, or the types of PE devices may not be distinguished. The embodiments of the present application do not limit this.
[0104] In the aforementioned EVPN network, the VPWS instance and VPLS instance in a broadband access PE device (e.g., PE1) can be bound (or associated) to each other, so that the VPWS instance in the broadband access PE device corresponds to the VPLS instance. In other words, VPWS and VPLS are interconnected in the broadband access PE device. Consequently, after the broadband access PE device receives a message sent by a broadband access device (e.g., BRAS1) via the VPLS instance in the broadband access PE device, it can forward the message to the corresponding VPWS instance in the user access PE device (e.g., PE2) via the VPWS instance in the broadband access PE device that is bound (or associated) to the VPLS instance. The user access PE device can forward the message via the VPWS instance in the user access PE device, allowing the user access PE device to forward messages using the VPWS forwarding mechanism without having to learn MAC addresses, thereby reducing the burden on the user access PE device to learn MAC addresses.
[0105] In the technical solution provided by the embodiment of the present application, a virtual port for indicating a VPWS instance in the broadband access PE device can be configured in the VPLS instance in the broadband access PE device. In this way, the VPWS instance in the broadband access PE device is bound to the VPLS instance. As a result, the broadband access PE device can determine the VPWS instance in the broadband access PE device that is bound to the VPLS instance based on the virtual port in the VPLS instance, and thus forward packets to the user access PE device via the VPWS instance in the broadband access PE device. The technical solution provided by the embodiment of the present application enables the user access PE device to forward packets using the VPWS forwarding mechanism without having to learn MAC addresses, thereby reducing the pressure on the user access PE device to learn MAC addresses. The technical solution of the embodiment of the present application is described in detail below with reference to the accompanying drawings.
[0106] For example, please refer to Figure 4 , which shows a flow chart of a message transmission method provided by an embodiment of the present application, the message transmission method can be applied to a system including a first network device and a second network device, the first network device is a device in a VPLS network, and the second network device is a device in a VPWS network. Figures 1 to 3 As shown, the first network device may be PE1, and the second network device may be PE2. Figure 4 As shown, the method may include:
[0107] S401: A first network device determines, in a VPLS instance of the first network device, a virtual port corresponding to a destination address carried in a received first message, where the virtual port is used to indicate a first VPWS instance in the first network device.
[0108] Optionally, at least one VPLS instance may be configured in the first network device, and each VPLS instance in the at least one VPLS instance may include multiple ports, each port having a type, and the type of each port may be one of a virtual port type, an AC type, or an EVPN Peer type. A port of the virtual port type may be referred to as a virtual port, a port of the AC type may be referred to as an AC port, and a port of the EVPN Peer type may be referred to as an EVPN Peer port. The AC port may be used for communication between the first network device and a broadband access device (e.g., a BRAS), and the EVPN Peer port may be used for communication between the first network device and a remote network device (e.g., a remote PE device). In some implementation scenarios, a VPLS instance may also be referred to as a bridge domain (BD). For example, when a BD includes both an AC port and an EVPN Peer port, the VPLS instance described in the embodiment of the present application may also be referred to as a BD.
[0109] Optionally, the first network device may also be configured with at least one VPWS instance. A virtual port in a VPLS instance in the first network device may indicate the VPWS instance in the first network device, so that the VPLS instance in the first network device can be bound to the VPWS instance in the first network device via the virtual port in the VPLS instance, thereby achieving VPLS-VPWS interconnection. Optionally, the VPLS instance may include one or more virtual ports. If the VPLS instance includes multiple virtual ports, the multiple virtual ports may indicate different VPWS instances in the first network device. In the first network device, each VPWS instance may include at least one port. The port type in the VPWS instance may be an EVPN peer type, that is, the port in the VPWS instance may be an EVPN peer port. Optionally, the VPWS instance may also include an AC port, which is not limited in this embodiment of the present application. In this embodiment of the present application, if a VPLS instance includes multiple virtual ports, the multiple virtual ports may be isolated from each other, so that the VPWS instances indicated by the multiple virtual ports are isolated from each other, preventing user devices mounted under the VPWS instances indicated by the multiple virtual ports from accessing each other. For example, a switch may be configured in the VPLS instance, and the switch may be used to control the VPLS instance to isolate multiple virtual ports from each other.
[0110] For example, please refer to Figure 5 , which shows a first network device (eg Figures 1 to 3 Schematic diagram of the relationship between the VPLS instance and the VPWS instance in PE1). Figure 5 As shown, the first network device includes one VPLS instance and two VPWS instances, namely VPWS instance 1 and VPWS instance 2. The VPLS instance includes three AC ports, AC1, AC2, and AC3; three EVPN peer ports, EVPN Peer 1, EVPN Peer 2, and EVPN Peer 3; and two virtual ports, virtual port 1 and virtual port 2. Virtual port 1 indicates VPWS instance 1, and virtual port 2 indicates VPWS instance 2. VPWS instance 1 includes two EVPN peer ports, EVPN Peer 11 and EVPN Peer 12, and VPWS instance 2 includes two EVPN peer ports, EVPN Peer 21 and EVPN Peer 22. Virtual port 1 and virtual port 2 can be isolated from each other, so that the VPWS instance 1 indicated by virtual port 1 is isolated from the VPWS instance 2 indicated by virtual port 2, thereby preventing user devices mounted under VPWS instance 1 and VPWS instance 2 from accessing each other.
[0111] After the first network device receives the first message, it can parse the first message to determine the destination address carried by the first message from the first message, and then determine the virtual port corresponding to the destination address in the VPLS instance of the first network device based on the destination address carried by the first message. The virtual port is used to indicate the first VPWS instance in the first network device, and the first message can come from a broadband access device, such as a BRAS. In an embodiment of the present application, the VPLS instance includes a virtual port type port (that is, a virtual port). As an optional implementation method, the VPLS instance can also include at least one of an AC type port (that is, an AC port) and an EVPN Peer type port (that is, an EVPN Peer port), which is not limited in this embodiment of the present application. For example, the VPLS instance can be such as Figure 5 The VPLS instance shown includes two virtual ports, three AC ports, and two EVPN peer ports.
[0112] Optionally, the first network device can maintain a routing table for the VPLS instance of the first network device, and the first network device can determine the virtual port corresponding to the destination address based on the port corresponding to the destination address carried by the first message in the routing table of the VPLS instance as a virtual port. In an embodiment of the present application, the routing table of the VPLS instance records the correspondence between the address (e.g., MAC address) and the port identifier. In the routing table of the VPLS instance, the port identifier can be used to indicate the port corresponding to the corresponding address in the VPLS instance and the type of the port, or the port identifier is only used to indicate the port corresponding to the corresponding address in the VPLS instance. Depending on the content indicated by the port identifier in the routing table of the VPLS instance, the routing table of the VPLS instance may include two possible implementation methods. Accordingly, the first network device may determine the virtual port corresponding to the destination address carried by the first message based on the routing table of the VPLS instance, which also includes two possible implementation methods. The two implementation methods are described below.
[0113] The first implementation method: The routing table of the VPLS instance records the correspondence between the address and the port identifier, and the port identifier is used to indicate the port corresponding to the corresponding address in the VPLS instance and the type of the port. The type of port identifier for each type of port is different, and each type of port identifier can indicate a type of port, so that in the routing table of the VPLS instance, the port identifier can be used to indicate both the port and the type of the port. The first network device can determine from the routing table of the VPLS instance an address that matches (for example, is the same as) the destination address carried by the first message, and determine the port identifier corresponding to the address that matches the destination address, and determine the virtual port indicated by the port identifier corresponding to the address that matches the destination address as the virtual port corresponding to the destination address carried by the first message.
[0114] For example, the routing table of the VPLS instance may be as shown in Table 1 below. Table 1 takes the address in the routing table of the VPLS instance as a MAC address as an example. Each row in Table 1 below may be a routing table entry:
[0115] Table 1
[0116] address Port ID MAC address 1 V-P1 MAC Address 2 V-P2 MAC address 3 AC-P1 MAC address 4 AC-P2 MAC Address 5 AC-P3 MAC Address 6 EVPN Peer-P1 MAC address 7 EVPN Peer-P2 MAC address 8 EVPN Peer-P3
[0117] As shown in Table 1, the routing table of this VPLS instance records MAC addresses 1 to 8 and the port identifiers corresponding to each MAC address. Port identifiers V-P1 and V-P2 indicate virtual port 1 and virtual port 2, respectively (that is, the port types indicated by port identifiers V-P1 and V-P2 are both virtual port types). Port identifiers AC-P1, AC-P2, and AC-P3 indicate AC port 1, AC port 2, and AC port 3, respectively (that is, the port types indicated by port identifiers AC-P1, AC-P2, and AC-P3 are all AC type). Port identifiers EVPN Peer-P1, EVPN Peer-P2, and EVPN Peer-P3 indicate EVPN Peer port 1, EVPN Peer port 2, and EVPN Peer port 3, respectively (that is, the port types indicated by port identifiers EVPN Peer-P1, EVPN Peer-P2, and EVPN Peer-P3 are all EVPN Peer type).
[0118] Assume that the first network device determines from the routing table of the VPLS instance shown in Table 1 that the address matching the destination address carried by the first message is MAC address 1. According to Table 1, the port identifier corresponding to the MAC address 1 in the routing table of the VPLS instance is V-P1, and the port identifier V-P1 indicates virtual port 1 (that is, the type of the port indicated by the port identifier V-P1 is a virtual port type). The first network device determines the virtual port 1 indicated by the port identifier V-P1 as the virtual port corresponding to the destination address carried by the first message.
[0119] The second implementation method: The routing table of the VPLS instance records the correspondence between the address and the port identifier, and the port identifier is used to indicate the port corresponding to the corresponding address in the VPLS instance. In this case, the routing table of the VPLS instance can also record the port type, and the port type is used to indicate the type of the port indicated by the corresponding port identifier. That is, in the second implementation method, the routing table of the VPLS instance can record the correspondence between the address, the port identifier and the port type, and the port identifier is used to indicate the port corresponding to the corresponding address in the VPLS instance, and the port type is used to indicate the type of the port indicated by the corresponding port identifier. The first network device can determine from the routing table of the VPLS instance an address that matches (for example, is the same as) the destination address carried by the first message, and determine the port identifier corresponding to the address matching the destination address, and determine the virtual port indicated by the port identifier corresponding to the address matching the destination address as the virtual port corresponding to the destination address carried by the first message.
[0120] For example, the routing table of the VPLS instance may be as shown in Table 2 below. Table 2 takes the address in the routing table of the VPLS instance as a MAC address as an example. Each row in Table 2 below may be a routing table entry:
[0121] Table 2
[0122] address Port ID Port Type MAC address 1 P1 Virtual port type MAC Address 2 P2 Virtual port type MAC address 3 P3 AC Type MAC address 4 P4 AC Type MAC Address 5 P5 AC Type MAC Address 6 P6 EVPN Peer Type MAC address 7 P7 EVPN Peer Type MAC address 8 P8 EVPN Peer Type
[0123] As shown in Table 2, the routing table of this VPLS instance records MAC addresses 1 to 8 and the port identifiers corresponding to each MAC address. Port identifiers P1 to P8 indicate ports 1 to 8 in the VPLS instance, respectively. The ports indicated by port identifiers P1 and P2 are virtual port types. Port identifiers P3 to P5 indicate AC types. Port identifiers P6 to P8 indicate EVPN peer types. For example, port identifiers P1 and P2 indicate virtual port 1 and virtual port 2, respectively. Port identifiers P3 to P5 indicate AC port 1, AC port 2, and AC port 3, respectively. Port identifiers P6 to P8 indicate EVPN peer port 1, EVPN peer port 2, and EVPN peer port 3, respectively.
[0124] Assume that the first network device determines from the routing forwarding table of the VPLS instance shown in Table 2 that the address matching the destination address carried by the first message is MAC address 1. According to Table 2, the port identifier corresponding to the MAC address 1 in the routing forwarding table of the VPLS instance is P1, and the port type corresponding to the port identifier P1 is a virtual port type. Therefore, the first network device determines the virtual port 1 indicated by the port identifier P1 as the virtual port corresponding to the destination address carried by the first message.
[0125] The above description of the embodiment of the present application takes the example of the destination address carried in the first message hitting a forwarding table entry in the routing forwarding table of the VPLS instance (that is, there is a port identifier corresponding to the address matching the destination address carried in the first message in the routing forwarding table of the VPLS instance). In the actual implementation process, the destination address carried in the first message may hit at least two forwarding table entries in the routing forwarding table of the VPLS instance (that is, there are at least two port identifiers corresponding to the address matching the destination address carried in the first message in the routing forwarding table of the VPLS instance). Optionally, if the destination address carried in the first message hits at least two forwarding table entries in the routing forwarding table of the VPLS instance, the first network device can determine the virtual port corresponding to the destination address carried in the first message based on the primary-backup protection strategy. For example, if the destination address carried in the first message hits at least two forwarding entries in the routing forwarding table of the VPLS instance, and the at least two forwarding entries may include a primary forwarding entry and a backup forwarding entry, the first network device preferentially determines the virtual port corresponding to the destination address carried in the first message based on the primary forwarding entry. If the primary forwarding entry is unavailable, the first network device determines the virtual port corresponding to the destination address carried in the first message based on the backup forwarding entry, wherein the unavailability of the primary forwarding entry includes, but is not limited to: a port failure indicated by a port identifier in the primary forwarding entry, or a failure of other devices or ports connected to the port indicated by the port identifier in the primary forwarding entry. Optionally, if the destination address carried in the first message hits at least two forwarding entries in the routing forwarding table of the VPLS instance, the first network device may also determine the virtual port corresponding to the destination address carried in the first message based on the priority of the forwarding entries. Optionally, the ports capable of forming a primary and backup relationship may also be located in the same forwarding entry corresponding to the MAC address, and the primary and backup relationship may be determined by corresponding identification information. The embodiments of the present application will not be described in detail here.
[0126] It should also be noted that, in the embodiment of the present application, the virtual port included in the VPLS instance can actually be understood as identification information stored in the VPLS instance for indicating a VPWS instance. In a possible natural implementation, the identification information can be stored in the routing table of the VPLS instance and placed together with ports of types such as AC ports or EVPN peer ports in the port information column of the routing table of the VPLS instance, so that the first network device can query the routing table of the VPLS instance according to the destination address carried in the message received by the VPLS instance to determine whether the message needs to be forwarded through the AC port or EVPN peer port of the VPLS instance, or through the VPWS instance identified by the virtual port. Therefore, for the sake of ease of understanding, the identification information of the VPWS instance is referred to as a virtual port here. However, in other possible implementations, the identification information of the VPWS instance called a virtual port can also be stored in other possible locations of the VPLS instance, and can be obtained by the VPLS instance in some feasible manner to determine the VPWS instance connected to the VPLS instance. For example, the identification information of the VPWS instance called the virtual port can also be stored in another list independent of the routing table of the VPLS instance, and the information in the other list can be associated with the port information column of the routing table of the VPLS instance to indicate that the information in the other list and the information in the port information column of the routing table are of the same or similar nature. The identification information of the VPWS instance and the virtual port can be considered as equivalent concepts in the possible application scenarios of the present application.
[0127] S402: The first network device sends the first message to the second VPWS instance in the second network device according to the virtual port, wherein the second VPWS instance in the second network device and the first VPWS instance in the first network device are VPWS instances for carrying the same service.
[0128] Optionally, after determining the virtual port corresponding to the destination address carried in the first message, the first network device determines, based on the virtual port corresponding to the destination address, a routing table for a first VPWS instance indicated by the virtual port, determines, based on the routing table of the first VPWS instance, to send the first message to a second VPWS instance in a second network device, and further, sends the first message to the second VPWS instance in the second network device via the first VPWS instance in the first network device. The second VPWS instance in the second network device and the first VPWS instance in the first network device are VPWS instances used to carry the same service.
[0129] Optionally, the first network device determines the second VPWS instance in the second network device based on the routing table of the first VPWS instance, and determines the egress port of the first message in the port of the first VPWS instance by searching the routing table of the first VPWS instance, and sends the first message to the second VPWS instance in the second network device through the egress port of the first message in the first VPWS instance. The egress port of the first message in the first VPWS instance corresponds to the second VPWS instance in the second network device. Optionally, the routing table of the first VPWS instance records a correspondence between a port identifier and associated indication information, wherein the port identifier is used to indicate the port in the first VPWS instance corresponding to the corresponding associated indication information, and the associated indication information is used to indicate the VPWS instance corresponding to the first VPWS instance (e.g., the second VPWS instance in the second network device) in the remote device of the first network device (e.g., the second network device). For example, the association indication information may be an identifier of a VPN service carried in a VPWS instance in the remote device. The association indication information may be an identifier of a VPWS instance. For example, in an MPLS network, the association indication information may be a label of the VPN service, and in an SRv6 network, the association indication information may be a SID of the VPN service. In a possible implementation, the identifier of the VPN service may be used as the identifier of the VPWS instance. The first network device may determine the association indication information of the VPWS instance corresponding to the first VPWS instance in the routing table of the first VPWS instance, and determine the port indicated by the port identifier of the association indication information in the routing table of the first VPWS instance as the egress port of the first message.
[0130] For example, Figure 6 This is a schematic diagram of a message transmission method provided in an embodiment of the present application, see Figure 5 Combined with Figure 6, taking the first network device as PE1 as an example. PE1 determines that the virtual port corresponding to the destination address carried in the first message is virtual port 1 in the VPLS instance. The virtual port 1 indicates the VPWS instance 1 in the PE1 (that is, the first VPWS instance in the first network device). PE1 can determine the routing and forwarding table of the VPWS instance 1 in the PE1, and determine the port corresponding to the VPWS instance 1 in PE2 (that is, the second VPWS instance) according to the routing and forwarding table of the VPWS instance 1 in the PE1 as the egress port of the first message. Assuming that PE1 determines from the VPWS instance 1 of the PE1 that the egress port of the first message is EVPNPeer11, the EVPN Peer11 can correspond to the VPWS instance 1 in PE2. PE1 sends the first message from the EVPN Peer11 to the VPWS instance 1 in PE2 through the VPWS instance 1 in the PE1. Optionally, PE1 first sends the first message from EVPN Peer 11 to, for example, VPWS instance 1 in P1 via VPWS instance 1 in PE1. After receiving the first message, P1 sends the first message to VPWS instance 1 in PE2 via VPWS instance 1 in P1. The first message may carry associated indication information of VPWS instance 1, such as an identifier of a VPN service, to instruct PE2 to forward the first message to the CE device via VPWS instance 1. The above example is described as both PE1 and PE2 carrying VPWS instance 1. In specific implementations, the actual contents of the corresponding VPWS instances carried by PE1 and PE2 are usually different due to localized implementation. However, the two have a corresponding relationship because they carry the same service. For ease of understanding and description, both are referred to as VPWS instance 1.
[0131] In summary, in the message transmission method provided by the embodiment of the present application, the first network device is a device in a VPLS network, and the second network device is a device in a VPWS network. After receiving the first message, the first network device determines the virtual port corresponding to the destination address in the VPLS instance of the first network device based on the destination address carried in the first message, and sends the first message to the second VPWS instance in the second network device based on the virtual port. The second network device can forward the first message through the second VPWS instance. Thus, the first VPWS instance in the first network device can serve as a port member of the VPLS instance in the first network device. In this way, the first VPWS instance is bound to the VPLS instance to realize the docking of VPLS and VPWS in the first network device, so that the second network device can use the VPWS forwarding mechanism to forward messages without having to learn the MAC address on the user side, which helps to reduce the pressure on the second network device to learn MAC addresses, simplify the MAC table entries of the second network device, and ensure the forwarding performance of the entire network system.
[0132] In an embodiment of the present application, each virtual port in a VPLS instance of a first network device can point to VPWS instances in at least two network devices. The VPWS instances in the at least two network devices and the VPWS instance in the first network device indicated by the virtual port are used to carry the same service. The at least two network devices including the VPWS instance are located on at least two forwarding paths between the first network device and a destination device (e.g., the device indicated by the destination address carried by the first message). The at least two forwarding paths are load-sharing paths, or the at least two forwarding paths include a primary forwarding path and a backup forwarding path. For example, the routing table of the first VPWS instance in the first network device is used to record the correspondence between two port identifiers leading to the two forwarding paths and the associated indication information of the first VPWS instance, so that the first network device forwards messages to the corresponding VPWS instances in the network devices on the two forwarding paths according to the correspondence.
[0133] For example, the VPLS instance of the first network device may be as follows: Figure 5As shown, virtual port 1 can point to VPWS instance 1 in at least two network devices. The VPWS instance 1 in the at least two network devices to which virtual port 1 points and the VPWS instance 1 in the first network device are used to carry the same service. The at least two network devices including the VPWS instance 1 are located on at least two forwarding paths between the first network device and the destination device. Similarly, virtual port 2 can point to VPWS instance 2 in at least two network devices. The VPWS instance 2 in the at least two network devices to which virtual port 2 points and the VPWS instance 2 in the first network device are used to carry the same service. The at least two network devices including the VPWS instance 2 are located on at least two forwarding paths between the first network device and the destination device. It should be noted that, for the sake of convenience of description, the VPWS instance in the first network device and the VPWS instances in the at least two network devices pointed to by the virtual port are both described as VPWS instance 1 or VPWS instance 2. However, it can be understood that, in actual implementation, the specific contents included in the VPWS instance in the first network device and the VPWS instances in the at least two network devices pointed to by the virtual port of the VPLS instance in the first network device may actually be different from each other, but may be associated through a certain established relationship (such as carrying the same type of service) and may be identified by the same VPWS instance identification information, for example, by the same VPN service identifier, so as to enable service packets to be forwarded between these associated VPWS instances belonging to each network device.
[0134] In an embodiment of the present application, if at least two network devices including the VPWS instance pointed to by the virtual port are located on at least two forwarding paths between the first network device and the destination device (for example, the device indicated by the destination address carried in the first message), the first network device can send a message to the destination device through the at least two forwarding paths based on a load balancing strategy or a primary-backup protection strategy. For example, if the at least two forwarding paths are load balancing paths for each other, the first network device can send a message to the destination device through the at least two forwarding paths based on an equal cost multi-path (ECMP) strategy. If the at least two forwarding paths include a primary forwarding path and a backup forwarding path, the first network device preferentially sends a message to the destination device through the primary forwarding path. When the primary forwarding path fails, the first network device sends a message to the destination device through the backup forwarding path. The message transmission method provided by the present application is introduced below by taking the example of the first network device sending a message to the destination device through the at least two forwarding paths.
[0135] For example, please refer to Figure 7, which shows a flowchart of another message transmission method provided by an embodiment of the present application, the message transmission method can be applied to a system including a first network device, a second network device and a third network device, the first network device is a device in a VPLS network, the second network device and the third network device are both devices in a VPWS network, and the second network device and the third network device both include a VPWS instance pointed to by the same virtual port in the VPLS instance of the first network device. For example Figures 1 to 3 As shown, the first network device may be PE1, the second network device may be PE2, and the third network device may be PE3. Figure 7 As shown, the method may include:
[0136] S701: A first network device determines, in a VPLS instance of the first network device, a virtual port corresponding to a destination address carried in a received first message, where the virtual port is used to indicate a first VPWS instance in the first network device.
[0137] S702: The first network device sends the first message to the second VPWS instance in the second network device according to the virtual port, wherein the second VPWS instance in the second network device and the first VPWS instance in the first network device are VPWS instances for carrying the same service.
[0138] The implementation process of S701 to S702 can refer to the above Figure 4 The embodiments shown will not be described in detail here.
[0139] S703: The first network device determines, in the VPLS instance of the first network device, a virtual port corresponding to the destination address according to the destination address carried in the received second message, where the virtual port is used to indicate the first VPWS instance in the first network device.
[0140] After receiving the second message, the first network device may parse the second message to determine the destination address carried in the second message, and then determine a virtual port corresponding to the destination address in the VPLS instance of the first network device based on the destination address carried in the second message. The virtual port is used to indicate the first VPWS instance in the first network device, and the second message may originate from a broadband access device, such as a BRAS.
[0141] The process of the first network device determining the virtual port corresponding to the destination address carried by the second message in the VPLS instance of the first network device can refer to the aforementioned S401, and the embodiment of the present application will not be repeated here. It should be noted that in the embodiment of the present application, the destination address carried by the second message is the same as the destination address carried by the aforementioned first message. Therefore, the virtual port corresponding to the destination address carried by the second message determined by the first network device can be the same as the virtual port corresponding to the destination address carried by the first message determined by the first network device in the aforementioned S701. Optionally, the virtual port corresponding to the destination address carried by the second message determined by the first network device can also be different from the virtual port corresponding to the destination address carried by the first message determined by the first network device in the aforementioned S701. The embodiment of the present application does not limit this. The embodiment of the present application takes the virtual port corresponding to the destination address carried by the second message as the same as the virtual port corresponding to the destination address carried by the first message in the aforementioned S701 as an example for explanation.
[0142] S704: The first network device sends the second message to the third VPWS instance in the third network device according to the virtual port, wherein the third VPWS instance in the third network device and the first VPWS instance in the first network device are VPWS instances for carrying the same service.
[0143] Among them, the third network device can be a device in the VPWS network, and the third network device is configured with a third VPWS instance. The third VPWS instance in the third network device and the first VPWS instance in the first network device are VPWS instances used to carry the same service. As mentioned above, the second VPWS instance in the second network device and the first VPWS instance in the first network device are also VPWS instances used to carry the same service. Therefore, the first VPWS instance in the first network device, the second VPWS instance in the second network device, and the third VPWS instance in the third network device are VPWS instances used to carry the same service.
[0144] In an embodiment of the present application, the second VPWS instance in the second network device and the third VPWS instance in the third network device can both be VPWS instances pointed to by the virtual port corresponding to the destination address carried by the first message (or the destination address carried by the second message). The second network device and the third network device can be located on two forwarding paths between the first network device and the destination device (for example, the device indicated by the destination address carried by the first message or the second message). After executing the aforementioned S702, the first network device can send the second message to the third VPWS instance in the third network device according to the virtual port corresponding to the destination address carried by the second message based on the load balancing strategy or the active-standby protection strategy. That is, the first network device can send the aforementioned first message and the second message to the destination device through the two forwarding paths between the first network device and the destination device based on the load balancing strategy or the active-standby protection strategy.
[0145] Optionally, the two forwarding paths between the first network device and the destination device are load balancing paths with each other. The first network device, based on the load balancing policy, sends the second message to the third VPWS instance in the third network device according to the virtual port corresponding to the destination address carried by the second message. For example, the first network device, based on the ECMP policy, adopts flow-by-flow load balancing or packet-by-packet load balancing, and sends the second message to the third VPWS instance in the third network device according to the virtual port corresponding to the destination address carried by the second message. In the case of flow-by-flow load balancing, the second message and the aforementioned first message may be messages belonging to different service flows of the same service. For example, the second message and the aforementioned first message may be messages belonging to two adjacent service flows of the same service. In the case of packet-by-packet load balancing, the second message and the aforementioned first message may be messages belonging to the same service flow of the same service. For example, the second message and the aforementioned first message may be two adjacent messages in the service flow. This embodiment of the present application does not limit this.
[0146] Optionally, the two forwarding paths between the first network device and the destination device include a primary forwarding path and a backup forwarding path. The second network device may be located on the primary forwarding path, and the third network device may be located on the backup forwarding path. The first network device, based on the primary-backup protection strategy, sends the second message to the third VPWS instance in the third network device according to the virtual port corresponding to the destination address carried by the second message. In the primary-backup protection mode, the first network device preferentially sends messages to the destination device through the primary forwarding path. If the primary forwarding path fails, the first network device sends messages to the destination device through the backup forwarding path. Therefore, in an embodiment of the present application, the first network device may determine that the primary forwarding path has failed, and then send the second message to the third VPWS instance in the third network device based on the primary forwarding path failure and the virtual port corresponding to the destination address carried by the second message. The primary forwarding path failure may include a failure of at least one device in the primary forwarding path, or a port failure of at least one device in the primary forwarding path.
[0147] For example, combined with Figure 5 and Figure 6 Taking the first network device as PE1 and the destination device as VM1 as an example, the destination addresses carried in the first message and the second message both correspond to virtual port 1 of the VPLS instance of PE1. Virtual port 1 is used to indicate VPWS instance 1 in PE1, and virtual port 1 points to VPWS instance 1 in PE2 and VPWS instance 1 in PE3. VPWS instance 1 in PE1, VPWS instance 1 in PE2, and VPWS instance 1 in PE3 are used to carry the same service. Forwarding path S1 and forwarding path S2 are two forwarding paths between PE1 and VM1. PE2 is located on forwarding path S1, and PE3 is located on forwarding path S2. Optionally, forwarding path S1 and forwarding path S2 are load balancing paths for each other. PE1 can use flow-by-flow load balancing or packet-by-packet load balancing to send the first message to VPWS instance 1 in PE2 based on the virtual port 1 corresponding to the destination address carried by the first message, and to send the second message to VPWS instance 1 in PE3 based on the virtual port 1 corresponding to the destination address carried by the second message. Alternatively, the forwarding path S1 and the forwarding path S2 may include a primary forwarding path and a backup forwarding path. For example, the forwarding path S1 is the primary forwarding path, and the forwarding path S2 is the backup forwarding path. PE1 may send a first message to the VPWS instance 1 in PE2 according to the virtual port 1 corresponding to the destination address carried by the first message. Thereafter, the PE1 determines that the forwarding path S1 fails, and the PE1 sends a second message to the VPWS instance 1 in PE3 according to the virtual port 1 corresponding to the destination address carried by the second message.
[0148] Optionally, the first network device sending the second message to the third VPWS instance in the third network device according to the virtual port corresponding to the destination address carried by the second message may include: the first network device determining the routing and forwarding table of the first VPWS instance indicated by the virtual port according to the virtual port corresponding to the destination address carried by the second message, determining to send the second message to the third VPWS instance in the third network device according to the routing and forwarding table of the first VPWS instance, and sending the second message to the third VPWS instance in the third network device through the first VPWS instance in the first network device.
[0149] Optionally, the first network device determines a third VPWS instance in a third network device based on the routing table of the first VPWS instance, and determines the egress port of the second message in the port of the first VPWS instance by searching the routing table of the first VPWS instance, and sends the second message to the third VPWS instance in the third network device through the egress port of the second message in the first VPWS instance. The egress port of the second message in the first VPWS instance corresponds to the third VPWS instance in the third network device. Optionally, the routing table of the first VPWS instance records a correspondence between a port identifier and associated indication information of the third VPWS instance. The first network device can determine the port indicated by the port identifier as the egress port of the second message to send the second message to the third VPWS instance in the third network device.
[0150] For example, see Figure 5 Combined with Figure 6Taking PE1 as an example, the first network device determines that the virtual port corresponding to the destination address carried in the second message is virtual port 1 in the VPLS instance. This virtual port 1 indicates VPWS instance 1 in PE1 (that is, the first VPWS instance in the first network device). PE1 can determine the routing table of VPWS instance 1 in PE1, determine the association indication information corresponding to VPWS instance 1 in PE3 (that is, the third VPWS instance) based on the routing table of VPWS instance 1 in PE1, and determine the port corresponding to the association indication information in the routing table of VPWS instance 1 as the egress port of the second message. Assuming that PE1 determines from VPWS instance 1 in PE1 that the egress port of the second message is EVPN Peer 12, which may correspond to VPWS instance 1 in PE3, PE1 sends the second message from EVPN Peer 12 to VPWS instance 1 in PE3 via VPWS instance 1 in PE1. Optionally, the PE1 first sends the second message from the EVPN Peer12 to, for example, the VPWS instance 1 in P2 through the VPWS instance 1 in the PE1. After receiving the second message, the P2 sends the second message to the VPWS instance 1 in the PE3 through the VPWS instance 1 in the P2.
[0151] To summarize, in the message transmission method provided in the embodiment of the present application, the first network device is a device in a VPLS network, and the second network device and the third network device are both devices in a VPWS network. After the first network device receives the first message, it determines the virtual port corresponding to the destination address in the VPLS instance of the first network device according to the destination address carried in the first message, and sends the first message to the second VPWS instance in the second network device according to the virtual port, and the second network device can forward the first message through the second VPWS instance; and after the first network device receives the second message, it determines the virtual port corresponding to the destination address in the VPLS instance of the first network device according to the destination address carried in the second message, and sends the second message to the third VPWS instance in the third network device according to the virtual port, and the third network device can forward the first message through the third VPWS instance. Thus, the first VPWS instance in the first network device can serve as a port member of the VPLS instance in the first network device. By binding the first VPWS instance to the VPLS instance in this manner, VPLS and VPWS can be interconnected in the first network device, allowing the second network device and the third network device to both use the VPWS forwarding mechanism to forward packets. Neither the second network device nor the third network device needs to learn MAC addresses, which helps reduce the burden on the second network device and the third network device to learn MAC addresses, simplifies the MAC table entries of the second network device and the third network device, and ensures the forwarding performance of the second network device and the third network device. Furthermore, the first network device can forward packets to the same destination device via different forwarding paths, achieving load balancing or active / standby protection of the forwarding paths.
[0152] As described in the aforementioned implementation environment, an EVPN network may include multiple broadband access PE devices, which may be interconnected to provide dual-homing protection for the broadband access PE devices. For example, if a forwarding path failure between a broadband access PE device among the multiple broadband access PE devices and a destination device causes the broadband access PE device to be unable to send a message to the destination device via the forwarding path, the broadband access PE device may forward the message to a connected broadband access PE device, which then forwards the message to the destination device.
[0153] In an embodiment of the present application, the first network device may be a broadband access PE device in an EVPN network. There may be at least one EVPN Peer port in the VPLS instance of the first network device connected to another broadband access PE device. When a forwarding path between the first network device and the destination device (for example, the device indicated by the destination address carried by the first message) fails, the first network device may forward the message from the EVPN Peer port of the VPLS instance to the broadband access PE device connected to it through the VPLS instance of the first network device, and the broadband access PE device connected to it forwards the message to the destination device.
[0154] For example, please refer to Figure 8 , which shows a schematic diagram of another message transmission method provided by an embodiment of the present application. Taking the first network device as PE1 as an example, PE1 and PE4 can both be broadband access PE devices. The relationship between the VPLS instance and the VPWS instance in PE1 is shown in FIG. Figure 5 As shown in Figure 1, EVPN Peer3 in PE1's VPLS instance can connect to PE4. Figure 6 and Figure 8 When PE1 needs to send a message to VM1, if both forwarding path S1 and forwarding path S2 between PE1 and VM1 fail, PE1 can forward the message to PE4 through EVPN Peer3 in PE1's VPLS instance. PE4 then forwards the message to P2 through VPWS instance 1 in PE4. Finally, the message is forwarded to VM1 along forwarding path S3.
[0155] Optionally, in each of the aforementioned embodiments, before the first network device determines the virtual port corresponding to the destination address in the VPLS instance of the first network device based on the destination address carried in the received first message, the method further includes: the first network device receives a third message sent by the second network device through the first VPWS instance in the first network device; the first network device generates a forwarding entry in the routing forwarding table of the VPLS instance based on the source address carried in the third message and the first VPWS instance. The destination address in the forwarding entry is the source address carried in the third message, the port identifier in the forwarding entry is used to indicate the virtual port in the VPLS instance, and the virtual port is used to indicate the first VPWS instance in the first network device. The process of the first network device generating a forwarding entry is introduced below.
[0156] For example, the second network device can send a third message to the first VPWS instance in the first network device through the second VPWS instance in the second network device, and the first network device receives the third message through the first VPWS instance in the first network device. Thereafter, the first network device parses the third message to determine the source address carried in the third message from the third message, and determines the virtual port corresponding to the first VPWS instance in the VPLS instance of the first network device, and generates a forwarding entry in the routing forwarding table of the VPLS instance based on the source address carried in the third message and the port identifier of the virtual port corresponding to the first VPWS instance in the VPLS instance of the first network device.
[0157] Optionally, the port identifier of the virtual port may only indicate the virtual port, or the port identifier of the virtual port may indicate the virtual port and the type of the virtual port. Then, the first network device generating a forwarding entry in the routing forwarding table of the VPLS instance based on the source address carried in the third message and the port identifier of the virtual port may include: if the port identifier of the virtual port indicates the virtual port and the type of the virtual port, the first network device generating a forwarding entry in the routing forwarding table of the VPLS instance based on the source address and the port identifier of the virtual port carried in the third message; if the port identifier of the virtual port only indicates the virtual port, the first network device may also determine the type of the virtual port, and generate a forwarding entry in the routing forwarding table of the VPLS instance based on the source address, the port identifier of the virtual port, and the type of the virtual port carried in the third message.
[0158] For example, take the VPLS in the first network device as an example. Figure 5 Taking the example shown, the source address carried in the third message may be MAC address 1, and the virtual port corresponding to the first VPWS instance in the first network device may be virtual port 1 in the VPLS instance. The first network device determines that the port identifier of the virtual port 1 is V-P1. Since the port identifier V-P1 indicates the virtual port 1 and the type of the virtual port 1, the first network device generates a forwarding entry in the routing forwarding table of the VPLS instance based on the source address carried in the third message (that is, MAC address 1) and the port identifier V-P1 of the virtual port 1. The forwarding entry may be shown as the first row of forwarding entries in Table 1 above.
[0159] For example, take the VPLS in the first network device as an example. Figure 5Taking the example shown, the source address carried in the third message may be MAC address 1, and the virtual port corresponding to the first VPWS instance in the first network device may be virtual port 1 in the VPLS instance. The first network device determines that the port identifier of the virtual port 1 is P1. Since the port identifier P1 only indicates the virtual port 1, the first network device can determine the type of the virtual port 1, and generate a forwarding entry in the routing forwarding table of the VPLS instance according to the source address carried in the third message (that is, MAC address 1), the port identifier P1 of the virtual port 1, and the type of the virtual port 1. The forwarding entry can be shown as the first row of forwarding entries in Table 2 above.
[0160] In an embodiment of the present application, the port identifier used to indicate the virtual port in the routing forwarding table of the VPLS instance can be the identification information of the VPWS instance indicated by the virtual port, or other attribute information related to the VPWS instance indicated by the virtual port that enables the VPLS instance to determine the VPWS instance, for example, it can be information about a certain port in the VPWS instance. For ease of understanding, this embodiment of the present application refers to it as a port identifier. Optionally, after the first network device receives the third message through the first VPWS instance in the first network device, it generates a forwarding entry in the routing forwarding table of the VPLS instance based on the source address carried in the third message and the identification information of the first VPWS instance (or other attribute information that enables the VPLS instance to determine the VPWS instance). This embodiment of the present application does not limit this.
[0161] The above embodiments illustrate the existence of a port (e.g., a virtual port) in the VPLS instance of a first network device that corresponds to the destination address carried by a message (e.g., the first message and the second message). In actual implementation, the VPLS instance of the first network device may not contain a port corresponding to the destination address carried by the message. In this case, the first network device can broadcast the message. The message transmission method provided in this application can also be implemented through the following embodiments.
[0162] For example, please refer to Figure 9 , which shows a flowchart of another message transmission method provided by an embodiment of the present application, the message transmission method can be applied to the first network device, for example Figures 1 to 3 As shown, the first network device may be PE1. Figure 9 As shown, the method may include:
[0163] S901. A first network device receives a fourth message.
[0164] Optionally, the fourth message may originate from a broadband access device, such as a BRAS. The first network device may be configured with at least one VPLS instance, and the first network device may receive the fourth message through the VPLS instance in the first network device. Figure 6 and Figure 8 As shown, the first network device may be PE1, the fourth message may originate from BRAS1, and the PE1 receives the fourth message through the VPLS instance in the PE1.
[0165] S902. The first network device broadcasts the fourth message through multiple ports of the VPLS instance of the first network device, according to the absence of a port corresponding to the destination address carried in the fourth message in the VPLS instance of the first network device, where the multiple ports include a virtual port in the VPLS instance.
[0166] After receiving the fourth message, the first network device may parse the fourth message to determine the destination address carried in the fourth message from the fourth message, and then determine the port corresponding to the destination address in the VPLS instance of the first network device based on the destination address carried in the fourth message. If the VPLS instance of the first network device does not have a port corresponding to the destination address carried in the fourth message, the first network device broadcasts the fourth message through multiple ports of the VPLS instance of the first network device, where the multiple ports include virtual ports in the VPLS instance. Optionally, the multiple ports may also include ports of EVPN peers and / or AC ports in the VPLS instance. For example, if the VPLS instance of the first network device does not have a port corresponding to the destination address carried in the fourth message, the first network device broadcasts the fourth message through all ports of the VPLS instance of the first network device (including virtual ports, AC ports, and EVPN peer ports), or the first network device broadcasts the fourth message through all virtual ports of the VPLS instance of the first network device. This embodiment of the present application is not limited to this.
[0167] Optionally, the first network device may search the routing table of the VPLS instance of the first network device based on the destination address carried by the fourth message, and determine whether there is an address in the routing table of the VPLS instance that matches (for example, is the same as) the destination address carried by the fourth message. If there is an address in the routing table of the VPLS instance that matches the destination address carried by the fourth message, the first network device determines that there is a port corresponding to the destination address carried in the fourth message in the VPLS instance of the first network device. If there is no address in the routing table of the VPLS instance that matches the destination address carried by the fourth message, the first network device determines that there is no port corresponding to the destination address carried in the fourth message in the VPLS instance of the first network device. The embodiment of the present application takes the case where there is no address in the routing table of the VPLS instance that matches the destination address carried by the fourth message as an example. In this case, there is no port corresponding to the destination address carried in the fourth message in the VPLS instance of the first network device, and the first network device broadcasts the fourth message through multiple ports of the VPLS instance of the first network device.
[0168] For example, taking the destination address carried by the fourth message as MAC address 9, the routing forwarding table of the VPLS instance of the first network device can be as shown in Table 1 or Table 2. The first network device searches the routing forwarding table shown in Table 1 or Table 2 according to the MAC address 9 carried by the fourth message. Since there is no address matching (for example, the same as) MAC address 9 in the routing forwarding table shown in Table 1 or Table 2, the first network device determines that there is no port corresponding to the destination address carried in the fourth message in the VPLS instance of the first network device. Figure 5 Taking the example shown, the first network device may broadcast the fourth message through multiple ports among AC1, AC2, AC3, EVPN Peer1, EVPN Peer2, EVPN Peer3, virtual port 1, and virtual port 2 in the VPLS instance. For example, the first network device broadcasts the fourth message through virtual port 1 and virtual port 2 in the VPLS instance. Specifically, the first network device broadcasting the fourth message through virtual port 1 and virtual port 2 in the VPLS instance may mean that the first network device broadcasts the fourth message through multiple ports of VPWS instance 1 indicated by virtual port 1 and multiple ports of VPWS instance 2 indicated by virtual port 2.
[0169] The message transmission method provided in this embodiment can be used in conjunction with the message transmission method provided in the above embodiments. For example, in actual applications, the message transmission method can be executed before or after this embodiment. Figure 4 or Figure 7 The method of the embodiment shown, or the Figure 9The method provided by the embodiment shown can be used with Figure 7 The method provided in the embodiment shown can be executed in an interleaved manner. For example, the first network device first executes S701 to S702, and then executes the method after S702 is completed. Figure 9 In the embodiment shown, when executing the Figure 9 After the illustrated embodiment ends, S703 to S704 are continued to be executed, which is not limited in the embodiment of the present application.
[0170] To sum up, in the message transmission method provided in the embodiment of the present application, the first network device is a device in the VPLS network. After the first network device receives the fourth message, it determines the port corresponding to the destination address in the VPLS instance of the first network device based on the destination address carried in the fourth message. If there is no port corresponding to the destination address carried by the fourth message in the VPLS instance of the first network device, the first network device broadcasts the fourth message through multiple ports of the VPLS instance. Therefore, the message transmission scheme provided in the embodiment of the present application can be applied to message broadcast scenarios.
[0171] The above is an introduction to the embodiment of the method of the present application. The following describes the embodiment of the device of the present application, which can be used to perform the method of the present application. For details not disclosed in the embodiment of the device of the present application, please refer to the embodiment of the method of the present application.
[0172] Please refer to Figure 10 , which shows a logical structure diagram of a first network device 1000 provided in an embodiment of the present application. The first network device 1000 is located in a message transmission system. The message transmission system also includes a second network device. The first network device 1000 is a device in a VPLS network, and the second network device is a device in a VPWS network. Figure 10 The first network device 1000 may include but is not limited to:
[0173] Determining module 1010 is configured to determine, based on the destination address carried in the received first message, a virtual port corresponding to the destination address in the VPLS instance of the first network device 1000, where the virtual port indicates the first VPWS instance in the first network device 1000. The implementation of the functions of determining module 1010 may refer to the description of S401, S701, and S901 above.
[0174] A sending module 1020 is configured to send the first message to a second VPWS instance in the second network device according to the virtual port, wherein the second VPWS instance in the second network device and the first VPWS instance in the first network device 1000 are VPWS instances for carrying the same service. The implementation of the functions of sending module 1020 may refer to the description of S402, S702, and S902 above.
[0175] Optionally, the sending module 1020 is specifically configured to: determine a routing table of the first VPWS instance according to the virtual port; and determine to send the first message to a second VPWS instance in the second network device according to the routing table of the first VPWS instance.
[0176] Optionally, the message transmission system further includes a third network device, which is a device in the VPWS network.
[0177] The determining module 1010 is further configured to determine the virtual port according to the destination address carried in the received second message. The implementation of the function of the determining module 1010 may also refer to the relevant description of S703 and S903 above.
[0178] The sending module 1020 is further configured to send the second packet to a third VPWS instance in the third network device according to the virtual port, wherein the third VPWS instance in the third network device and the first VPWS instance in the first network device 1000 are VPWS instances for carrying the same service. For further implementation of the functions of the sending module 1020, reference may be made to the description of S704 and S904 above.
[0179] Optionally, the determining module 1010 is further configured to determine that a primary forwarding path between the first network device 1000 and the device indicated by the destination address for carrying the service is faulty, wherein the second network device is located on the primary forwarding path;
[0180] The sending module 1020 is specifically configured to send the second message to the third VPWS instance in the third network device based on the primary forwarding path failure and the virtual port, wherein the third network device is located on the backup forwarding path for carrying the service between the first network device 1000 and the device indicated by the destination address.
[0181] Optionally, the virtual port points to at least two VPWS instances of at least two network devices for carrying the service, and the at least two network devices including the VPWS instance are located on at least two forwarding paths between the first network device 1000 and the device indicated by the destination address, and the at least two forwarding paths are load sharing paths for each other, or the at least two forwarding paths include a main forwarding path and a backup forwarding path.
[0182] Optionally, the VPLS instance includes a port of a virtual port type.
[0183] Optionally, the VPLS instance further includes at least one of an AC type port and an EVPN Peer type port.
[0184] Optionally, the determining module 1010 is specifically configured to determine the virtual port corresponding to the destination address according to the port corresponding to the destination address in the routing forwarding table of the VPLS instance of the first network device 1000 being a virtual port.
[0185] Optionally, the determination module 1010 is specifically used to: determine the virtual port based on the destination address and port identifier in the routing and forwarding table of the VPLS instance, wherein the port identifier is used to indicate the virtual port corresponding to the destination address in the VPLS instance and the type of the virtual port; or determine the virtual port based on the destination address, port identifier and port type in the routing and forwarding table of the VPLS instance, wherein the port identifier indicates the port corresponding to the destination address in the VPLS instance, and the port type indicates that the type of the port is a virtual port type.
[0186] Optionally, please continue to refer to Figure 10 , the first network device 1000 further includes:
[0187] Receiving module 1030 is configured to receive, through the first VPWS instance of first network device 1000, a third message sent by the second network device before determining module 1010 determines, based on the destination address carried in the received first message, a virtual port corresponding to the destination address in the VPLS instance of first network device 1000. The implementation of the functions of receiving module 1030 may refer to the description of S905 above.
[0188] Processing module 1040 is configured to generate a forwarding entry in the routing table of the VPLS instance based on the source address carried in the third message and the first VPWS instance, wherein the destination address in the forwarding entry is the source address carried in the third message, and the port identifier in the forwarding entry is used to indicate the virtual port, which is used to indicate the first VPWS instance in the first network device 1000. For the functional implementation of processing module 1040, reference may be made to the relevant description of S906 above.
[0189] Optionally, the receiving module 1030 is further configured to receive a fourth message;
[0190] Please continue to refer to Figure 10The first network device 1000 also includes: a broadcast module 1050, which is used to broadcast the fourth message through multiple ports of the VPLS instance according to the fact that there is no port corresponding to the destination address carried in the fourth message in the VPLS instance of the first network device 1000, and the multiple ports include the virtual port.
[0191] In summary, the technical solution provided by the embodiment of the present application is that the first network device is a device in a VPLS network, and the second network device is a device in a VPWS network. After receiving the first message, the first network device determines the virtual port corresponding to the destination address in the VPLS instance of the first network device based on the destination address carried in the first message, and sends the first message to the second VPWS instance in the second network device based on the virtual port. The second network device can forward the first message through the second VPWS instance. As a result, the first VPWS instance in the first network device can be used as a port member of the VPLS instance in the first network device. In this way, the first VPWS instance is bound to the VPLS instance to realize the docking of VPLS and VPWS in the first network device, so that the second network device can use the VPWS forwarding mechanism to forward messages. The second network device does not need to learn MAC addresses, which helps reduce the pressure of learning MAC addresses on the second network device, simplifies the MAC table entries of the second network device, and ensures the forwarding performance of the second network device.
[0192] It should be understood that the network device provided in the embodiments of the present application can also be implemented using an application-specific integrated circuit (ASIC) or a programmable logic device (PLD), and the above-mentioned PLD can be a complex programmable logical device (CPLD), a field-programmable gate array (FPGA), a generic array logic (GAL), or any combination thereof. The message transmission method provided in the above-mentioned method embodiment can also be implemented by software. When the message transmission method provided in the above-mentioned method embodiment is implemented by software, each module in the network device can also be a software module.
[0193] Please refer to Figure 11 , which shows a hardware structure diagram of a network device 1100 provided in an embodiment of the present application. The network device 1100 may be the first network device in the above embodiment, and the network device 1100 may be a PE device. Figure 11 As shown, the network device 1100 includes: a main control board 1110, an interface board 1130 and an interface board 1140. In the case of multiple interface boards, a switching network board ( Figure 11 The switching network board is used to complete data exchange between the interface boards (the interface board is also called a line card or a service board).
[0194] The main control board 1110 performs functions such as system management, device maintenance, and protocol processing. The interface boards 1130 and 1140 provide various service interfaces (e.g., POS, GE, and ATM) and implement packet forwarding. The main control board 1110 primarily houses three functional units: the system management and control unit, the system clock unit, and the system maintenance unit. The main control board 1110, interface boards 1130, and interface boards 1140 are interconnected via a system bus and the system backplane. The interface board 1130 includes one or more processors 1131. Processors 1131 control and manage the interface boards 1130 and communicate with the central processing unit 1112 on the main control board 1110. The memory 1132 on the interface board 1130 is used to store a routing table, for example, a routing table of a VPLS instance and / or a routing table of a VPWS instance. The processor 1131 determines the virtual port corresponding to the destination address carried by the message in the VPLS instance by searching the routing table of the VPLS instance stored in the memory 1132, and determines the egress port of the message in the VPWS instance by searching the routing table of the VPWS instance stored in the memory 1132. Figure 11 As shown, the main control board 1110 may include a memory 1114. The memory 1114 on the main control board 1110 may also be used to store a routing table, which is not limited in this embodiment of the present application.
[0195] The interface board 1130 includes one or more network interfaces 1133 for receiving and forwarding packets. The processor 1131 determines, in the VPLS instance, the virtual port corresponding to the destination address of the packet received by the network interface 1133. The specific implementation process is not detailed here. The specific functions of the processor 1131 are also not detailed here.
[0196] It is understandable that Figure 11 As shown, this embodiment includes multiple interface boards and adopts a distributed forwarding mechanism. Under this mechanism, the operation on the interface board 1140 is basically similar to that of the interface board 1130. For the sake of brevity, it will not be repeated. In addition, it can be understood that Figure 11The processor 1131 in interface board 1130 and / or the processor 1141 in interface board 1140 can be dedicated hardware or chips, such as a network processor or an application-specific integrated circuit, to implement the aforementioned functions. This implementation is commonly referred to as employing dedicated hardware or chips for forwarding plane processing. In other embodiments, the processor 1131 in interface board 1130 and / or the processor 1141 in interface board 1140 can also be a general-purpose processor, such as a general-purpose central processing unit (CPU), to implement the aforementioned functions.
[0197] It should also be noted that there may be one or more main control boards, including a primary and backup main control board. There may also be one or more interface boards. The greater the data processing capabilities of the network device, the more interface boards are provided. With multiple interface boards, they can communicate with each other through one or more switching fabric boards, and when there are multiple boards, they can collectively implement load balancing and redundant backup. In a centralized forwarding architecture, the network device may not require a switching fabric board; the interface board handles the entire system's service data processing. In a distributed forwarding architecture, the network device includes multiple interface boards, which can exchange data between them through the switching fabric board, providing high-capacity data exchange and processing capabilities. Therefore, network devices with a distributed architecture have greater data access and processing capabilities than those with a centralized architecture. The specific architecture to adopt depends on the specific network deployment scenario and is not limited here.
[0198] In a specific embodiment, the memory 1132 can be a read-only memory (ROM) or other type of static storage device that can store static information and instructions, a random access memory (RAM) or other type of dynamic storage device that can store information and instructions, or an electrically erasable programmable read-only memory (EEPROM), a compact disc read-only memory (CD-ROM) or other optical disc storage, an optical disc storage (including a compact disc, laser disc, optical disc, digital versatile disc, Blu-ray disc, etc.), a magnetic disk or other magnetic storage device, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and can be accessed by a computer, but is not limited thereto. The memory 1132 can exist independently and be connected to the processor 1131 via a communication bus. The memory 1132 can also be integrated with the processor 1131.
[0199] The memory 1132 is used to store program codes, and is controlled by the processor 1131 to execute part or all of the steps of the message transmission method provided in the above embodiment. The processor 1131 is used to execute the program codes stored in the memory 1132. The program codes may include one or more software modules. The one or more software modules may be the above Figure 10 Functional modules provided in the embodiments. The memory 1114 may also be used to store program codes, and the central processing unit 1112 controls the execution thereof to execute part or all of the steps of the message transmission method provided in the above embodiments.
[0200] In a specific embodiment, the network interface 1133 may be a device such as any transceiver for communicating with other devices or communication networks, such as Ethernet, radio access network (RAN), wireless local area network (WLAN), etc.
[0201] Please refer to Figure 12 , which shows a hardware structure diagram of another network device 1200 provided in an embodiment of the present application. The network device 1200 may be the first network device in any of the above embodiments, and the network device 1200 may be a PE device. Figure 12 The network device 1200 includes a processor 1202, a memory 1204, a communication interface 1206, and a bus 1208. The processor 1202, the memory 1204, and the communication interface 1206 are communicatively connected to each other via the bus 1208. Figure 12 The connection manner among the processor 1202 , the memory 1204 and the communication interface 1206 shown is merely exemplary. During implementation, the processor 1202 , the memory 1204 and the communication interface 1206 may also be communicatively connected to each other using other connection manners besides the bus 1208 .
[0202] The memory 1204 may be used to store a computer program 12042, which may include instructions and data. In embodiments of the present application, the memory 1204 may be various types of storage media, such as RAM, ROM, non-volatile RAM (NVRAM), programmable ROM (PROM), erasable PROM (EPROM), electrically erasable PROM (EEPROM), flash memory, optical storage, and registers. Furthermore, the memory 1204 may include a hard disk and / or memory.
[0203] The processor 1202 may be a general-purpose processor. A general-purpose processor may be a processor that performs specific steps and / or operations by reading and executing a computer program (e.g., computer program 12042) stored in a memory (e.g., memory 1204). The general-purpose processor may use data stored in the memory (e.g., memory 1204) during the execution of the above steps and / or operations. The stored computer program may be executed, for example, to implement the related functions of the aforementioned determination module 1010 and processing module 1040. The general-purpose processor may be, for example, but not limited to, a CPU. In addition, the processor 1202 may also be a special-purpose processor. A special-purpose processor may be a processor specially designed to perform specific steps and / or operations. The special-purpose processor may be, for example, but not limited to, a digital signal processor (DSP), an ASIC, and an FPGA. In addition, the processor 1202 may also be a combination of multiple processors, such as a multi-core processor. The processor 1202 may include at least one circuit to execute all or part of the steps of the message transmission method provided in the above embodiment.
[0204] The communication interface 1206 may include input / output (I / O) interfaces, physical interfaces, and logical interfaces, etc., for interconnecting components within the network device 1200, as well as interfaces for interconnecting the network device 1200 with other devices (e.g., network devices or user equipment). The physical interface may be a Gigabit Ethernet (GE) interface, which may be used to interconnect the network device 1200 with other devices (e.g., network devices or user equipment). The logical interface is an interface within the network device 1200, which may be used to interconnect components within the network device 1200. It will be readily understood that the communication interface 1206 may be used for communication between the network device 1200 and other network devices and / or user equipment. For example, the communication interface 1206 may be used to send and receive messages between the network device 1200 and other network devices. The communication interface 1206 may implement the related functions of the aforementioned sending module 1120, receiving module 1130, and broadcast module 1150. In addition, the communication interface 1206 may also include a transceiver for sending and receiving messages, and the transceiver can also implement the related functions of the aforementioned sending module 1120, receiving module 1130 and broadcast module 1150.
[0205] The bus 1208 may be any type of communication bus for interconnecting the processor 1202 , the memory 1204 , and the communication interface 1206 , such as a system bus.
[0206] The above-mentioned devices can be provided on separate chips, or at least partially or entirely on the same chip. Whether to provide each device independently on different chips or to integrate them on one or more chips often depends on the product design requirements. The embodiments of this application do not limit the specific implementation of the above-mentioned devices.
[0207] Figure 12 The network device 1200 shown is merely exemplary. During implementation, the network device 1200 may further include other components, which are not listed here. Figure 12 The network device 1200 shown can forward messages by executing all or part of the steps of the message transmission method provided by the above embodiment.
[0208] Please refer to Figure 13 , which shows a schematic structural diagram of a message transmission system 1300 provided in an embodiment of the present application. The message transmission system 1300 includes a first network device 1310 and a second network device 1320. The first network device 1310 is a device in a VPLS network, and the second network device 1320 is a device in a VPWS network.
[0209] The first network device 1310 is configured to determine, in the VPLS instance of the first network device 1310, a virtual port corresponding to the destination address carried in the received first message, and send the first message to the second VPWS instance in the second network device 1320 according to the virtual port, wherein the virtual port is used to indicate the first VPWS instance in the first network device 1310, and the second VPWS instance in the second network device 1320 and the first VPWS instance in the first network device 1310 are VPWS instances for carrying the same service;
[0210] The second network device 1320 is configured to forward the first message through a second VPWS instance in the second network device 1320 .
[0211] Optionally, the first network device 1310 is specifically configured to: determine a routing table of the first VPWS instance according to the virtual port; and determine to send the first message to a second VPWS instance in the second network device 1320 according to the routing table of the first VPWS instance.
[0212] Optionally, please continue to refer to Figure 13 The message transmission system 1300 further includes a third network device 1330, which is a device in the VPWS network.
[0213] The first network device 1310 is further configured to determine the virtual port according to the destination address carried in the received second message, and send the second message to the third VPWS instance in the third network device 1330 according to the virtual port. The third VPWS instance in the third network device 1330 and the first VPWS instance in the first network device 1310 are VPWS instances used to carry the same service.
[0214] The third network device 1330 is configured to forward the second message through a third VPWS instance in the third network device 1330 .
[0215] Optionally, the first network device 1310 is specifically used to: determine that a primary forwarding path between the first network device 1310 and the device indicated by the destination address for carrying the service has failed, and based on the primary forwarding path failure and the virtual port, send the second message to the third VPWS instance in the third network device 1330, wherein the second network device 1320 is located on the primary forwarding path, and the third network device 1330 is located on the backup forwarding path between the first network device 1310 and the device indicated by the destination address for carrying the service.
[0216] Optionally, the virtual port points to at least two VPWS instances of at least two network devices for carrying the service, and the at least two network devices including the VPWS instance are located on at least two forwarding paths between the first network device 1310 and the device indicated by the destination address, and the at least two forwarding paths are load sharing paths for each other, or the at least two forwarding paths include a main forwarding path and a backup forwarding path.
[0217] Optionally, the VPLS instance includes a port of a virtual port type.
[0218] Optionally, the VPLS instance further includes at least one of an AC type port and an EVPN Peer type port.
[0219] Optionally, the first network device 1310 is specifically configured to determine the virtual port corresponding to the destination address according to the port corresponding to the destination address in the routing forwarding table of the VPLS instance of the first network device 1310 being a virtual port.
[0220] Optionally, the first network device 1310 is specifically used to: determine the virtual port based on the destination address and port identifier in the routing and forwarding table of the VPLS instance, wherein the port identifier is used to indicate the virtual port corresponding to the destination address in the VPLS instance and the type of the virtual port; or determine the virtual port based on the destination address, port identifier and port type in the routing and forwarding table of the VPLS instance, wherein the port identifier indicates the port corresponding to the destination address in the VPLS instance, and the port type indicates that the type of the port is a virtual port type.
[0221] Optionally, the second network device 1320 is further configured to send a third message to the first network device 1310;
[0222] The first network device 1310 is further configured to receive the third message sent by the second network device 1320 through the first VPWS instance in the first network device 1310, and generate a forwarding entry in the routing forwarding table of the VPLS instance based on the source address carried in the third message and the first VPWS instance, wherein the destination address in the forwarding entry is the source address carried in the third message, and the port identifier in the forwarding entry is used to indicate the virtual port, and the virtual port is used to indicate the first VPWS instance in the first network device 1310.
[0223] Optionally, the first network device 1310 is also used to receive a fourth message, and based on the fact that there is no port corresponding to the destination address carried in the fourth message in the VPLS instance of the first network device 1310, the fourth message is broadcast through multiple ports of the VPLS instance, and the multiple ports include the virtual port.
[0224] Optionally, the first network device 1310 , the second network device 1320 , and the third network device 1330 are all PE devices.
[0225] In a possible implementation, the first network device 1310 may be as follows: Figure 10 Network device 1000 is shown.
[0226] In another possible implementation, the first network device 1310 may be as follows: Figure 11 or Figure 12 The network devices shown.
[0227] In summary, in the message transmission system provided by the embodiment of the present application, the first network device is a device in a VPLS network, and the second network device is a device in a VPWS network. After receiving the first message, the first network device determines the virtual port corresponding to the destination address in the VPLS instance of the first network device based on the destination address carried in the first message, and sends the first message to the second VPWS instance in the second network device based on the virtual port. The second network device can forward the first message through the second VPWS instance. Thus, the first VPWS instance in the first network device can serve as a port member of the VPLS instance in the first network device. In this way, the first VPWS instance is bound to the VPLS instance to realize the docking of VPLS and VPWS in the first network device, so that the second network device can use the VPWS forwarding mechanism to forward messages. The second network device does not need to learn MAC addresses, which helps reduce the pressure of learning MAC addresses on the second network device, simplifies the MAC table entries of the second network device, and ensures the forwarding performance of the second network device.
[0228] An embodiment of the present application provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, all or part of the steps of the message transmission method provided in the above method embodiment are implemented.
[0229] An embodiment of the present application provides a computer program product comprising instructions. When the computer program product is run on a computer, the computer is caused to execute all or part of the steps of the message transmission method provided in the above method embodiment.
[0230] An embodiment of the present application provides a chip, which includes a programmable logic circuit and / or program instructions, and when the chip is running, is used to implement all or part of the steps of the message transmission method provided in the above method embodiment.
[0231] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When software is used for implementation, it can be implemented in whole or in part in the form of a computer program product, which includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from a website, computer, server or data center to another website, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line) or wireless (e.g., infrared, wireless, microwave, etc.) mode. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrations. The available medium can be a magnetic medium (e.g., a floppy disk, a hard disk, a tape), an optical medium, or a semiconductor medium (e.g., a solid-state hard disk).
[0232] It should be understood that "at least one" in this document refers to one or more, and "plurality" refers to two or more. "At least two" refers to two or more. In this application, unless otherwise specified, " / " means or. For example, A / B can mean A or B. "And / or" in this application is merely a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. In addition, for the sake of clarity of description, in this application, words such as "first", "second", and "third" are used to distinguish between identical or similar items with substantially the same functions and effects. Those skilled in the art will understand that words such as "first", "second", and "third" do not limit the quantity and order of execution.
[0233] The different types of embodiments, such as the method embodiments and device embodiments provided in the embodiments of this application, can refer to each other, and the embodiments of this application are not limited thereto. The order of the operations of the method embodiments provided in the embodiments of this application can be appropriately adjusted, and the operations can be increased or decreased in response to the circumstances. Any person skilled in the art who can easily think of a method of variation within the technical scope disclosed in this application should be included in the scope of protection of this application, and therefore will not be described in detail.
[0234] In the corresponding embodiments provided in the present application, it should be understood that the disclosed devices and the like can be implemented by other structural methods. For example, the device embodiments described above are merely schematic. For example, the division of units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. The functions that can be executed by each unit can be implemented by software, hardware, or a combination of software and hardware. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, and the indirect coupling or communication connection of devices or units can be electrical or other forms.
[0235] The units described as separate components may or may not be physically separate, and the components described as units may or may not be physical units, and may be located in one place or distributed across multiple network devices (e.g., terminal devices). Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.
[0236] The above description is merely an exemplary embodiment of the present application, but the scope of protection of the present application is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in this application, and such modifications or substitutions should be included in the scope of protection of this application. Therefore, the scope of protection of this application should be based on the scope of protection of the claims.
Claims
1. A message transmission method, characterized in that: The method is applied to an Ethernet virtual private network (EVPN) network including a first network device and a second network device, wherein the first network device is a device in a virtual private local area network service (VPLS) network, and the second network device is a device in a virtual private line service (VPWS) network. The method includes: The first network device determines, according to the destination address carried in the received first message, a virtual port corresponding to the destination address in the VPLS instance of the first network device, wherein the virtual port is used to indicate a first VPWS instance in the first network device that is bound to the VPLS instance; The first network device sends the first message to a second VPWS instance in the second network device according to the virtual port, wherein the second VPWS instance in the second network device and the first VPWS instance in the first network device are VPWS instances for carrying the same service.
2. The method according to claim 1, characterized in that The first network device sending the first message to the second VPWS instance in the second network device according to the virtual port includes: The first network device determines a routing forwarding table of the first VPWS instance according to the virtual port; The first network device determines, according to the routing and forwarding table of the first VPWS instance, to send the first message to the second VPWS instance in the second network device.
3. The method according to claim 1, characterized in that The EVPN network further includes a third network device, where the third network device is a device in the VPWS network. The method includes: The first network device determines the virtual port according to the destination address carried in the received second message; The first network device sends the second message to a third VPWS instance in the third network device according to the virtual port, wherein the third VPWS instance in the third network device and the first VPWS instance in the first network device are VPWS instances for carrying the same service.
4. The method according to claim 3, characterized in that The first network device sending the second message to the third VPWS instance in the third network device according to the virtual port includes: The first network device determines that a primary forwarding path between the first network device and the device indicated by the destination address for carrying the service fails, wherein the second network device is located on the primary forwarding path; The first network device sends the second message to the third VPWS instance in the third network device according to the primary forwarding path failure and the virtual port, wherein the third network device is located on a backup forwarding path for carrying the service between the first network device and the device indicated by the destination address.
5. The method according to any one of claims 1 to 4, characterized in that The virtual port points to at least two VPWS instances of at least two network devices for carrying the service, the at least two network devices including the VPWS instances are located on at least two forwarding paths between the first network device and the device indicated by the destination address, the at least two forwarding paths are load sharing paths with each other, or the at least two forwarding paths include a primary forwarding path and a backup forwarding path.
6. The method according to any one of claims 1 to 4, characterized in that The VPLS instance includes ports of a virtual port type.
7. The method according to any one of claims 1 to 4, characterized in that The VPLS instance is a bridge domain BD, and the BD further includes at least one of an access circuit AC type port and an Ethernet virtual private network peer EVPN Peer type port.
8. The method according to any one of claims 1 to 4, characterized in that The first network device determines, according to the destination address carried in the received first message, a virtual port corresponding to the destination address in the VPLS instance of the first network device, including: The first network device determines the virtual port corresponding to the destination address according to the port corresponding to the destination address in the routing forwarding table of the VPLS instance of the first network device being the virtual port.
9. The method according to claim 8, characterized in that The first network device determines, according to a routing forwarding table of the VPLS instance of the first network device, a port corresponding to the destination address as the virtual port, the virtual port, including: The first network device determines the virtual port according to the destination address and the port identifier in the routing table of the VPLS instance, wherein the port identifier is used to indicate the virtual port corresponding to the destination address in the VPLS instance and the type of the virtual port; or The first network device determines the virtual port according to the destination address, port identifier and port type in the routing table of the VPLS instance, wherein the port identifier indicates the port corresponding to the destination address in the VPLS instance, and the port type indicates that the type of the port is a virtual port type.
10. The method according to claim 8, characterized in that Before the first network device determines, in the VPLS instance of the first network device according to the destination address carried in the received first message, a virtual port corresponding to the destination address, the method further includes: The first network device receives, through the first VPWS instance in the first network device, a third message sent by the second network device; The first network device generates a forwarding entry in a routing forwarding table of the VPLS instance based on the source address carried in the third message and the first VPWS instance, wherein the destination address in the forwarding entry is the source address carried in the third message, and the port identifier in the forwarding entry is used to indicate the virtual port, and the virtual port is used to indicate the first VPWS instance in the first network device.
11. The method according to any one of claims 1 to 4, characterized in that The method further comprises: The first network device receives a fourth message; According to the fact that no port corresponding to the destination address carried in the fourth message exists in the VPLS instance of the first network device, the first network device broadcasts the fourth message through multiple ports of the VPLS instance, where the multiple ports include the virtual port.
12. A message transmission system in an Ethernet virtual private network (EVPN), characterized in that: The system includes a first network device and a second network device, wherein the first network device is a device in a virtual private local area network service (VPLS) network, and the second network device is a device in a virtual private wire service (VPWS) network. The first network device is configured to determine, in a VPLS instance of the first network device, a virtual port corresponding to a destination address carried in a received first message, and send the first message to a second VPWS instance in the second network device according to the virtual port, wherein the virtual port is used to indicate a first VPWS instance in the first network device that is bound to the VPLS instance, and the second VPWS instance in the second network device and the first VPWS instance in the first network device are VPWS instances used to carry the same service; The second network device is configured to forward the first message through the second VPWS instance in the second network device.
13. The system according to claim 12, wherein: The first network device is specifically configured to: Determine a routing forwarding table of the first VPWS instance according to the virtual port; Determine, according to the routing table of the first VPWS instance, that the first message is sent to the second VPWS instance in the second network device.
14. The system according to claim 12, wherein: The system further includes a third network device, which is a device in the VPWS network. The first network device is further configured to determine the virtual port according to the destination address carried in the received second message, and send the second message to a third VPWS instance in the third network device according to the virtual port, where the third VPWS instance in the third network device and the first VPWS instance in the first network device are VPWS instances used to carry the same service; The third network device is configured to forward the second message through the third VPWS instance in the third network device.
15. The system according to claim 14, wherein: The first network device is specifically configured to: Determine that a primary forwarding path for carrying the service between the first network device and the device indicated by the destination address fails, and send the second message to the third VPWS instance in the third network device based on the primary forwarding path failure and the virtual port, wherein the second network device is located on the primary forwarding path and the third network device is located on a backup forwarding path for carrying the service between the first network device and the device indicated by the destination address.
16. The system according to any one of claims 12 to 15, characterized in that The virtual port points to at least two VPWS instances of at least two network devices for carrying the service, the at least two network devices including the VPWS instances are located on at least two forwarding paths between the first network device and the device indicated by the destination address, the at least two forwarding paths are load sharing paths with each other, or the at least two forwarding paths include a primary forwarding path and a backup forwarding path.
17. The system according to any one of claims 12 to 15, characterized in that The VPLS instance includes ports of a virtual port type.
18. The system according to any one of claims 12 to 15, characterized in that The VPLS instance is a bridge domain BD, and the BD further includes at least one of an access circuit AC type port and an Ethernet virtual private network peer EVPN Peer type port.
19. The system according to any one of claims 12 to 15, characterized in that The first network device is specifically configured to determine the virtual port corresponding to the destination address according to the port corresponding to the destination address in the routing forwarding table of the VPLS instance of the first network device being the virtual port.
20. The system according to claim 19, wherein: The first network device is specifically configured to: Determine the virtual port according to the destination address and port identifier in the routing table of the VPLS instance, wherein the port identifier is used to indicate the virtual port corresponding to the destination address in the VPLS instance and the type of the virtual port; or The virtual port is determined according to the destination address, port identifier, and port type in the routing table of the VPLS instance, wherein the port identifier indicates the port corresponding to the destination address in the VPLS instance, and the port type indicates that the type of the port is a virtual port type.
21. The system according to claim 19, wherein: The second network device is further configured to send a third message to the first network device; The first network device is further configured to receive, through the first VPWS instance in the first network device, the third message sent by the second network device, and generate a forwarding entry in the routing forwarding table of the VPLS instance based on the source address carried in the third message and the first VPWS instance, wherein the destination address in the forwarding entry is the source address carried in the third message, and the port identifier in the forwarding entry is used to indicate the virtual port, and the virtual port is used to indicate the first VPWS instance in the first network device.
22. The system according to any one of claims 12 to 15, characterized in that The first network device is further used to receive a fourth message, and based on the fact that there is no port corresponding to the destination address carried in the fourth message in the VPLS instance of the first network device, broadcast the fourth message through multiple ports of the VPLS instance, where the multiple ports include the virtual port.
23. A network device, characterized in that: The network device includes a memory and a processor; The memory is used to store computer programs; The processor is configured to execute the computer program stored in the memory to perform the message transmission method according to any one of claims 1 to 11.
24. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the message transmission method according to any one of claims 1 to 11 is implemented.
Citation Information
Patent Citations
Access method and device of multiprotocol label switching double-layer virtual private network
CN101808042A