Data processing method and device of Ethernet virtual private network, switch and storage medium

By receiving, matching, and replacing message tags in the switch, the data transmission barrier between virtual networks is resolved, stable data transmission between multiple virtual networks is achieved, and the reliability of data transmission is improved.

CN116016030BActive Publication Date: 2026-03-31WXILICON TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-12-27
Publication Date
2026-03-31

AI Technical Summary

Technical Problem

In data transmission between multiple virtual networks, different message types can cause transmission obstacles, making it difficult for existing technologies to achieve stable data transmission.

Method used

By receiving messages from the receiving device, forwarding and matching are performed according to the message type to determine the interface and target label, and the original label is replaced to generate the target message, thus achieving stable transmission between multiple virtual networks.

Benefits of technology

It improves the reliability of data transmission between multiple virtual networks, ensuring that messages can be correctly forwarded in different virtual networks.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116016030B_ABST
    Figure CN116016030B_ABST
Patent Text Reader

Abstract

The application discloses a data processing method and device of an Ethernet virtual private network, a switch and a storage medium, relates to virtual network technology, and comprises the following steps: receiving a first message sent by a first device through an entry interface; performing forwarding matching according to the type of the first message, determining at least one exit interface and a target label adapted to each exit interface; replacing original labels in the first message with target labels respectively according to the target labels, to obtain at least one target message; and transmitting the target message adapted to the exit interface according to the type of the first message through a target virtual network connected with the at least one exit interface. The original labels in the first message from a first virtual network can be replaced with target labels to generate a target message. The target message can be transmitted in other virtual networks, the message can be transmitted between multiple virtual networks, and the reliability of data transmission between the multiple virtual networks is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present invention relate to virtual network technology, and more particularly to a data processing method, apparatus, switch and storage medium for an Ethernet virtual private network. Background Technology

[0002] As a Layer 2 forwarding device, a switch is capable of routing packets within a Virtual Local Area Network (VLAN) to enable packet transmission within the VLAN.

[0003] When multiple virtual networks exist, there is usually no need for data exchange between them. However, with the development of network topologies and the application of complex use cases such as the Internet of Things (IoT), the need arises for devices to transmit data through multiple virtual networks. Because different virtual networks use different message types, obstacles exist in transmitting messages across multiple virtual networks.

[0004] How to reliably provide data transmission between multiple virtual networks is a problem that urgently needs to be solved. Summary of the Invention

[0005] This invention provides a data processing method, apparatus, switch, and storage medium for Ethernet Virtual Private Networks (VPNs) to achieve stable data transmission between multiple virtual networks and improve the reliability of data transmission between virtual networks.

[0006] In a first aspect, embodiments of the present invention provide a data processing method for an Ethernet Virtual Private Network, comprising:

[0007] The system receives a first message sent by a first device through an ingress interface, wherein the first device belongs to a first virtual network.

[0008] Based on the type of the first message, forwarding matching is performed to determine at least one outgoing interface and the target label adapted to each outgoing interface;

[0009] The original tags in the first message are replaced according to the target tags to obtain at least one target message, and the target message corresponds one-to-one with the outgoing interface;

[0010] The target virtual network connected through the at least one outgoing interface transmits the target message adapted to the outgoing interface according to the type of the first message.

[0011] Secondly, embodiments of the present invention also provide a data processing device for an Ethernet Virtual Private Network, applied to a switch, comprising:

[0012] The receiving module is used to receive a first message sent by a first device through an ingress interface, wherein the first device belongs to a first virtual network;

[0013] The matching module is used to perform forwarding matching based on the type of the first message, and determine at least one outgoing interface and the target label adapted to each outgoing interface.

[0014] The target message generation module is used to replace the original tags in the first message according to the target tags to obtain at least one target message, and the target message corresponds one-to-one with the outgoing interface;

[0015] The sending module is used to transmit a target message adapted to the outgoing interface according to the type of the first message to the target virtual network connected through the at least one outgoing interface.

[0016] Thirdly, embodiments of the present invention also provide a switch, including a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that the processor executes the program to implement the data processing method for Ethernet Virtual Private Network as shown in the embodiments of the present invention.

[0017] Fourthly, embodiments of the present invention also provide a storage medium containing computer-executable instructions, which, when executed by a computer processor, are used to perform the data processing method for an Ethernet virtual private network as shown in the embodiments of the present invention.

[0018] The data processing method for Ethernet Virtual Private Networks provided by this invention receives a first message sent by a first device belonging to a first virtual network through an ingress interface; performs forwarding matching based on the type of the first message to determine at least one egress interface and a target label adapted to each egress interface; replaces the original label in the first message with the target label to obtain at least one target message, each target message corresponding to one of the egress interfaces; and transmits the target message adapted to the egress interface through the target virtual network connected by the at least one egress interface, according to the type of the first message. The target label in the target message enables message forwarding in the virtual network corresponding to the egress interface based on the target label, source address, and destination address. This message forwarding can be known unicast, known multicast, unknown unicast, unknown multicast, or broadcast, etc. By replacing the label, the first message transmitted in the first virtual network is converted into a target message that can be transmitted in the virtual network corresponding to the egress interface, enabling message transmission between multiple virtual networks and improving the reliability of data transmission between multiple virtual networks. Attached Figure Description

[0019] Figure 1 This is a schematic diagram of an Ethernet Virtual Private Network scenario provided in an embodiment of the present invention;

[0020] Figure 2This is a flowchart of the data processing method for Ethernet Virtual Private Network in Embodiment 1 of the present invention;

[0021] Figure 3 This is a flowchart of the data processing method for Ethernet Virtual Private Network in Embodiment 2 of the present invention;

[0022] Figure 4 This is a flowchart of the data processing method for Ethernet Virtual Private Network in Embodiment 3 of the present invention;

[0023] Figure 5 This is a schematic diagram of the data processing device for the Ethernet Virtual Private Network in Embodiment 4 of the present invention;

[0024] Figure 6 This is a schematic diagram of the switch device in Embodiment 5 of the present invention. Detailed Implementation

[0025] The present invention will now be described in further detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and not intended to limit it. Furthermore, it should be noted that, for ease of description, the accompanying drawings show only the parts relevant to the present invention, and not all of the structures.

[0026] Figure 1 This is a schematic diagram of an Ethernet Virtual Private Network (EVP) scenario provided by an embodiment of the present invention. The EVP includes a switch and multiple virtual networks that interact with each other through the switch. The number of virtual local area networks (VLANs) is not limited. As an example, as shown in Figure 1, the EVP scenario includes a first virtual network, a second virtual network, and a third virtual network. An Ethernet Virtual Private Network (EVP-LAN) is used to interconnect established virtual network VLANs. Currently, when implementing an EVP, if the virtual networks use different packet structures, packet forwarding cannot be performed, resulting in packet transmission failure. This embodiment of the present invention provides a data processing method for an EVP, which adapts the packet structure to the virtual network by converting the packet tag (TAG) to enable packet transmission in different virtual networks. The present invention will be described in detail below through embodiments.

[0027] Example 1

[0028] Figure 2 This is a flowchart of a data processing method for an Ethernet Virtual Private Network provided in Embodiment 1 of the present invention. This embodiment is applicable to situations where packets are forwarded by a switch between multiple virtual networks that adapt to different packet formats. The method can be executed by a switch and specifically includes the following steps:

[0029] Step S110: Receive the first message sent by the first device through the ingress interface. The first device belongs to the first virtual network.

[0030] The switch's ingress interface is connected to the first virtual network. The first device belonging to the first virtual network sends the first packet to the switch's ingress interface. The switch can be configured with multiple interfaces, and each interface can be pre-configured to adapt to a specific virtual network.

[0031] Step S120: Perform forwarding matching based on the type of the first message to determine at least one outgoing interface and the target label adapted to each outgoing interface.

[0032] The switch parses the received first packet, obtaining the packet type and the original tag from the packet's field content. The first packet includes a tag. The first packet can include three types: untagged packet, single-layer VLAN tag packet, and double-layer VLAN tag packet. The format of the determined target tag is consistent with the type of the tag field in the first packet. For example, it can be an untagged packet (applicable to the port's default VLAN), a single-layer tagged packet (applicable to a specified VLAN), or a double-layer tagged packet (applicable to a specified service in a specified VLAN).

[0033] Route matching is performed based on the first packet. If a pre-configured or pre-learned path is matched, it is considered a known packet, and the destination address is known. If it is a known unicast packet, there can be one outgoing interface. If it is a known multicast packet, there can be multiple outgoing interfaces.

[0034] If no pre-configured or pre-learned path is matched, the message is considered unknown. If it is an unknown message, such as an unknown unicast, unknown combinatorial, or broadcast message, the destination address is unknown, and it can be forwarded to other member ports in adjacent virtual LANs via flooding.

[0035] Optionally, a physical address table can be generated through MAC address learning, recording the outgoing interface corresponding to the destination address and the virtual network to which the destination address belongs. The target label is then determined based on the virtual network to which the destination address belongs.

[0036] Step S130: Replace the original label in the first message according to the target label to obtain at least one target message.

[0037] The original label in the TAG field of the first message is replaced with the target label to form the target message, so that the message format of the target message matches the message format of the virtual network transmission corresponding to the outgoing interface.

[0038] Step S140: Transmit the target message adapted to the outgoing interface through the target virtual network connected through at least one outgoing interface, according to the type of the first message.

[0039] The target packet is sent to a second device belonging to the virtual network corresponding to the outgoing interface through the outgoing interface. The target packet with the replaced target label can be recognized by the second device in the virtual network corresponding to the outgoing interface. The second device then transmits the target packet in the virtual network, realizing Layer 2 forwarding of the target packet.

[0040] The target message can be a known unicast or a known multicast. If it is a known unicast, the target message is transmitted within the virtual network corresponding to the outgoing interface, and sent to the target address through a single outgoing port. If it is a known multicast, one or more ports in the virtual network corresponding to the multicast are obtained in step 130, and the target message for the known multicast is sent to each port through the virtual network connected to the outgoing interface, thus realizing the multicast of the target message. The known multicast message is sent to different outgoing ports in one or more virtual local area networks to complete the multicast transmission of the target message.

[0041] The destination message can also be an unknown unicast, an unknown combination, or a broadcast. In this case, the destination address is unknown, and it can be forwarded to other member ports in the virtual LAN via flooding.

[0042] Optionally, before receiving the first message sent by the first device through the ingress interface, the method further includes: configuring Quality of Service (QoS) service for the transmission of the first message.

[0043] Configure QoS services for the transmission of the first message to provide services such as bandwidth guarantees and burst management. Furthermore, the QoS service extends to the transmission of the target message until the message reaches its destination address.

[0044] The data processing method for Ethernet Virtual Private Networks provided by this invention receives a first message sent by a first device belonging to a first virtual network through an ingress interface; performs forwarding matching based on the type of the first message to determine at least one egress interface and a target label adapted to each egress interface; replaces the original label in the first message with the target label to obtain at least one target message, each target message corresponding to one of the egress interfaces; and transmits the target message adapted to the egress interface through the target virtual network connected by the at least one egress interface, according to the type of the first message. The target label in the target message enables message forwarding in the virtual network corresponding to the egress interface based on the target label, source address, and destination address. This message forwarding can be known unicast, known multicast, unknown unicast, unknown multicast, or broadcast, etc. By replacing the label, the first message transmitted in the first virtual network is converted into a target message that can be transmitted in the virtual network corresponding to the egress interface, enabling message transmission between multiple virtual networks and improving the reliability of data transmission between multiple virtual networks.

[0045] Example 2

[0046] Figure 3 The flowchart of the data processing method for an Ethernet Virtual Private Network provided in Embodiment 2 of the present invention serves as a further illustration of the above embodiment. After receiving the first packet sent by the first device through the ingress interface, the method further includes: determining the original label based on the first packet; performing a matching verification based on the ingress interface and the original label; and if the verification is successful, forwarding the packet based on its type. This method can be implemented in the following manner:

[0047] Step S210: Receive the first message sent by the first device through the ingress interface. The first device belongs to the first virtual network.

[0048] Step S220: Determine the original tag based on the first message.

[0049] The first message is parsed, and the original tag is obtained through the TAG field.

[0050] Step S230: Perform matching and verification based on the input interface and the original label.

[0051] Pre-configure the virtual network adapted to the ingress interface. Determine if the virtual network marked in the original label is the same as the virtual network adapted to the ingress interface. If they are the same, the matching verification is successful; otherwise, the matching verification fails. Cancel the execution of step S250 and subsequent steps.

[0052] Furthermore, before step S230, which involves matching and verifying based on the input interface and the original tag, the following steps are also included:

[0053] Configure the adaptation relationship between the input interface and the labels of the first virtual network and the target virtual network.

[0054] An adaptation relationship can be established between the ingress interface and multiple virtual networks. In this embodiment of the invention, the first virtual network and the target virtual network are virtual networks using different message formats; in actual use, they can also use the same message format. Furthermore, more virtual network adaptation relationships can be configured for the ingress interface.

[0055] Accordingly, step S230, matching and verifying the input interface and the original label, can be implemented as follows:

[0056] Determine whether the input interface is compatible with the virtual network represented by the original tag based on the adaptation relationship.

[0057] When the ingress interface receives the first message, it determines whether there is an adaptation relationship between the original tag in the first message and the ingress interface.

[0058] The above method allows for the configuration of different virtual networks for the same interface, enabling the interface to receive packets from multiple virtual networks and improving interface utilization efficiency. Furthermore, interface matching and verification can improve the accuracy of packet reception.

[0059] Step S240: If the verification is successful, forward the matching according to the type of the first message.

[0060] Step S250: Perform forwarding matching based on the type of the first message to determine at least one outgoing interface and the target label adapted to each outgoing interface.

[0061] Step S260: Replace the original label in the first message according to the target label to obtain at least one target message.

[0062] Step S270: Transmit the target message adapted to the outgoing interface through the target virtual network connected via at least one outgoing interface, according to the type of the first message.

[0063] The data processing method for Ethernet Virtual Private Networks provided in this invention can match and verify the sending behavior of a first packet based on the port number and the original tag. If the verification is successful, the original tag of the first packet is replaced to generate the target packet. This matching and verification effectively prevents port attacks and improves switch security.

[0064] Example 3

[0065] Figure 4The flowchart of the data processing method for an Ethernet Virtual Private Network provided in Embodiment 3 of the present invention serves as a further illustration of the above embodiments. Forwarding and matching are performed based on the type of the first packet to determine the outgoing interface and target label, including: determining the original label, source address, and destination address based on the first packet; querying a physical address table to find at least one outgoing interface matching the original label, source address, and destination address, as well as the target label adapted to each outgoing interface. The physical address table is obtained through physical address learning or virtual network partitioning. This method can be implemented in the following ways:

[0066] Step S310: Receive the first message sent by the first device through the ingress interface. The first device belongs to the first virtual network.

[0067] Step S320: Determine the original label, source address, and destination address based on the first message.

[0068] Step S330: Query at least one outgoing interface that matches the original label, source address, and destination address, as well as the target label adapted to each outgoing interface, through the physical address table. The physical address table is obtained through physical address learning or virtual network partitioning.

[0069] The physical address table can be generated through MAC address learning or manually configured through virtual network partitioning.

[0070] Optionally, by querying the physical address table to find the matching outgoing interface and destination label based on the original label, source address, and destination address, the following implementation can be adopted:

[0071] Based on the original label, source address, and destination address, query the physical address table for the matching target record. Retrieve the target label and outgoing interface recorded in the target record; the target label can be a single-layer virtual network label or a double-layer virtual network label.

[0072] The physical MAC address table includes the source physical MAC address, destination physical MAC address, virtual network identifier (VLAN-ID), and interface. The physical address table is used for packet forwarding by the switch; the outgoing interface can be determined by querying the physical address table. In this embodiment of the invention, the physical address table also includes the incoming interface that received the first packet and the first virtual network identifier. If the physical address table already contains a record including the incoming interface, source label, source address, and destination address, then that record also contains the outgoing interface and the virtual network identifier adapted to the outgoing interface. The target label is determined based on the virtual network identifier adapted to the outgoing interface.

[0073] The type of the target label recorded in the physical address table can be the same as or different from the type of the original label. The target label is adapted to the virtual network of the transmitting target message. Specifically, it can be a single-layer virtual network label or a double-layer virtual network label. A single-layer virtual network label contains one virtual network identifier, while a double-layer virtual network label contains two virtual network identifiers.

[0074] Step S340: Replace the original label in the first message according to the target label to obtain at least one target message.

[0075] Replace the original labels in the first message with the target labels to obtain at least one target message.

[0076] Step S350: Transmit the target message adapted to the outgoing interface through the target virtual network connected via at least one outgoing interface, according to the type of the first message.

[0077] The data processing method for Ethernet Virtual Private Network provided in this embodiment of the invention can accurately determine the outgoing interface and target label of known unicast or multicast packets through an improved physical address table, thereby improving the reliability of target packets.

[0078] Based on the above implementation, for location unicast or location multicast, forwarding matching is performed according to the type of the first message to determine the interface and target label. This can be implemented as follows: if the destination address of the first message is an unknown unicast or an unknown multicast, it is flooded to at least one virtual network connected to the switch.

[0079] The flooded virtual network can be all or part of the virtual network connected to the switch. Figure 1 In the example shown, if flooding is applied to all virtual networks, it will flood to the first, second, and third virtual networks. The target label is determined based on the message format adapted to the second and third virtual networks, and the original label in the first message is replaced. Then, transmission occurs in the second and third virtual networks respectively.

[0080] The above implementation method can flood unknown unicast or multicast, improving the fault tolerance of message transmission.

[0081] Example 4

[0082] Figure 5 This is a schematic diagram of the data processing device for an Ethernet Virtual Private Network provided in Embodiment 4 of the present invention. This embodiment is applicable to situations where a switch forwards packets between multiple virtual networks that adapt to different packet formats. The device can be executed by a switch and specifically includes: a receiving module 410, a matching module 420, a target packet generation module 430, and a sending module 440.

[0083] The receiving module 410 is used to receive a first message sent by a first device through an ingress interface, wherein the first device belongs to a first virtual network;

[0084] The matching module 420 is used to perform forwarding matching based on the type of the first message, and to determine at least one outgoing interface and the target label adapted to each outgoing interface.

[0085] The target message generation module 430 is used to replace the original tags in the first message according to the target tags to obtain at least one target message;

[0086] The sending module 440 is used to transmit a target message adapted to the outgoing interface according to the type of the first message to the target virtual network connected through at least one outgoing interface.

[0087] Based on the above implementation method, a matching verification module is also included. The matching verification module is used for:

[0088] The original tag was determined based on the first message;

[0089] Perform matching and verification based on the input interface and the original tag;

[0090] If the verification is successful, forwarding and matching will be performed based on the type of the first message.

[0091] Based on the above implementation method, an interface configuration module is also included. The interface configuration module is used for:

[0092] Configure the adaptation relationship between the input interface and the labels of the first virtual network and the target virtual network;

[0093] Accordingly, the matching and verification module is used for:

[0094] Determine whether the input interface is compatible with the virtual network represented by the original tag based on the adaptation relationship.

[0095] Based on the above implementation method, the matching module 420 is used for:

[0096] The original tag, source address, and destination address are determined based on the first message;

[0097] The physical address table is obtained by querying the original label, source address, and destination address to find at least one outgoing interface that matches the original label, source address, and destination address, as well as the target label that each outgoing interface is adapted to. The physical address table is obtained through physical address learning or virtual network partitioning.

[0098] Based on the above implementation method, the matching module 420 is used for:

[0099] Based on the original tag, source address, and destination address, query the physical address table to find the target record that matches the target record.

[0100] Obtain the target label and outgoing interface recorded in the target record. The target label includes a single-layer virtual network label or a double-layer virtual network label.

[0101] Based on the above implementation method, the matching module 420 is used for:

[0102] If the destination address of the first message is an unknown unicast or an unknown multicast, it is flooded to at least one virtual network connected to the switch.

[0103] Based on the above implementation method, a service configuration module is also included, which is used for:

[0104] Configure Quality of Service (QoS) for the transmission of the first message.

[0105] The data processing apparatus for Ethernet Virtual Private Network provided in the embodiments of the present invention can execute the data processing method for Ethernet Virtual Private Network provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of executing the method.

[0106] Example 5

[0107] Figure 6 This is a schematic diagram of the structure of a switch provided in Embodiment 5 of the present invention, as shown below. Figure 6 As shown, the switch includes a processor 50 and a memory 51; the number of processors 50 in the switch can be one or more. Figure 6 Taking a processor 50 as an example; the processor 50 and memory 51 in the switch can be connected via a bus or other means. Figure 6 Taking the bus connection between China and Israel as an example, the switch can use the KD6630 communication chip.

[0108] The memory 51, as a computer-readable storage medium, can be used to store software programs, computer-executable programs, and modules, such as the program instructions / modules corresponding to the Ethernet Virtual Private Network data processing method in this embodiment of the invention (e.g., receiving module 410, matching module 420, target packet generation module 430, sending module 440, matching verification module, interface configuration module, and service configuration module). The processor 50 executes various functional applications and data processing of the switch by running the software programs, instructions, and modules stored in the memory 51, thereby implementing the aforementioned Ethernet Virtual Private Network data processing method.

[0109] The memory 51 may primarily include a program storage area and a data storage area. The program storage area may store the operating system and at least one application program required for a given function; the data storage area may store data created based on terminal usage. Furthermore, the memory 51 may include high-speed random access memory and non-volatile memory, such as at least one disk storage device, flash memory, or other non-volatile solid-state storage device. In some instances, the memory 51 may further include memory remotely located relative to the processor 50, which can be connected to a switch via a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.

[0110] Example 6

[0111] Embodiment 6 of the present invention also provides a storage medium containing computer-executable instructions, which, when executed by a computer processor, are used to execute a data processing method for an Ethernet Virtual Private Network, applied to a switch, the method comprising:

[0112] The first device, belonging to the first virtual network, receives the first message sent by the first device through the ingress interface.

[0113] Based on the type of the first message, forwarding matching is performed to determine at least one outgoing interface and the target label adapted to each outgoing interface;

[0114] Replace the original tags in the first message with the target tags to obtain at least one target message;

[0115] The target virtual network connected through at least one outgoing interface transmits the target message adapted to the outgoing interface according to the type of the first message.

[0116] Based on the above implementation method, after receiving the first message sent by the first device through the input interface, the method further includes:

[0117] The original tag was determined based on the first message;

[0118] Perform matching and verification based on the input interface and the original tag;

[0119] If the verification is successful, forwarding and matching will be performed based on the type of the first message.

[0120] Based on the above implementation method, before performing matching verification based on the input interface and the original tag, the method further includes:

[0121] Configure the adaptation relationship between the input interface and the labels of the first virtual network and the target virtual network;

[0122] Accordingly, matching and verification are performed based on the input interface and the original tag, including:

[0123] Determine whether the input interface is compatible with the virtual network represented by the original tag based on the adaptation relationship.

[0124] Based on the above implementation method, forwarding matching is performed according to the type of the first message to determine at least one outgoing interface and the target label adapted for each outgoing interface, including:

[0125] The original tag, source address, and destination address are determined based on the first message;

[0126] The physical address table is obtained by querying the original label, source address, and destination address to find at least one outgoing interface that matches the original label, source address, and destination address, as well as the target label that each outgoing interface is adapted to. The physical address table is obtained through physical address learning or virtual network partitioning.

[0127] Based on the above implementation method, the physical address table is used to query the outgoing interface and target label that match the original label, source address, and destination address, including:

[0128] Based on the original tag, source address, and destination address, query the physical address table to find the target record that matches the target record.

[0129] Obtain the target label and outgoing interface recorded in the target record. The target label includes a single-layer virtual network label or a double-layer virtual network label.

[0130] Based on the above implementation method, forwarding matching is performed according to the type of the first message to determine at least one outgoing interface and the target label adapted for each outgoing interface, including:

[0131] If the destination address of the first message is an unknown unicast or an unknown multicast, it is flooded to at least one virtual network connected to the switch.

[0132] Based on the above implementation method, before receiving the first message sent by the first device through the ingress interface, the method further includes:

[0133] Configure Quality of Service (QoS) for the transmission of the first message.

[0134] Of course, the computer-executable instructions provided in the embodiments of the present invention are not limited to the above-described method operations, but can also perform related operations in the data processing method of Ethernet Virtual Private Network provided in any embodiment of the present invention.

[0135] Based on the above description of the implementation methods, those skilled in the art can clearly understand that the present invention can be implemented using software and necessary general-purpose hardware, and of course, it can also be implemented using hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as a computer floppy disk, read-only memory (ROM), random access memory (RAM), flash memory, hard disk, or optical disk, etc., including several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods of the various embodiments of the present invention.

[0136] It is worth noting that in the embodiments of the search device described above, the various units and modules included are only divided according to functional logic, but are not limited to the above division, as long as the corresponding functions can be achieved; in addition, the specific names of each functional unit are only for easy differentiation and are not used to limit the scope of protection of the present invention.

[0137] Note that the above description is merely a preferred embodiment of the present invention and the technical principles employed. Those skilled in the art will understand that the present invention is not limited to the specific embodiments described herein, and various obvious changes, readjustments, and substitutions can be made without departing from the scope of protection of the present invention. Therefore, although the present invention has been described in detail through the above embodiments, the present invention is not limited to the above embodiments, and may include many other equivalent embodiments without departing from the concept of the present invention, the scope of which is determined by the scope of the appended claims.

Claims

1. A data processing method of an Ethernet virtual private network, characterized by, Applied to a switch, comprising: receiving a first message sent by a first device through an ingress interface, the first device belonging to a first virtual network; performing forwarding matching according to a type of the first message to determine at least one egress interface and a target label adapted to each egress interface; replacing an original label in the first message with the target label to obtain at least one target message according to the target label, the target message having a same source address and destination address as the first message; transmitting the target message adapted to the egress interface according to the type of the first message through a target virtual network connected by the egress interface; the performing forwarding matching according to the type of the first message to determine at least one egress interface and a target label adapted to each egress interface, comprising: determining an original label, a source address and a destination address according to the first message; querying at least one egress interface and a target label adapted to each egress interface matched with the original label, the source address and the destination address through a physical address table, the physical address table being obtained through physical address learning or virtual network division; if the destination address of the first message is unknown unicast or unknown multicast, flooding to at least one virtual network connected by the switch.

2. The method of claim 1, wherein, after receiving the first message sent by the first device through the ingress interface, further comprising: determining an original label according to the first message; performing matching verification according to the ingress interface and the original label; if the verification is successful, performing forwarding matching according to the type of the first message.

3. The method of claim 2, wherein, before the performing matching verification according to the ingress interface and the original label, further comprising: configuring an adaptation relationship between the ingress interface and labels of the first virtual network and labels of a target virtual network; correspondingly, the performing matching verification according to the ingress interface and the original label, comprising: judging whether the ingress interface is adapted to a virtual network represented by the original label according to the adaptation relationship.

4. The method of claim 1, wherein, the querying at least one egress interface and a target label matched with the original label, the source address and the destination address through the physical address table, comprising: querying a target record matched in the physical address table according to the original label, the source address and the destination address; obtaining a target label and an egress interface recorded in the target record, the target label including a single-layer virtual network label or a double-layer virtual network label.

5. The method of claim 1, wherein, before receiving the first message sent by the first device through the ingress interface, further comprising: configuring a quality of service (Qos) service for transmission of the first message.

6. A data processing apparatus for an Ethernet virtual private network, characterized by comprising: Applied to a switch, comprising: a receiving module, configured to receive a first message sent by a first device through an ingress interface, the first device belonging to a first virtual network; a matching module, configured to perform forwarding matching according to a type of the first message to determine at least one egress interface and a target label adapted to each egress interface; a target message generation module, configured to replace an original label in the first message with the target label to obtain at least one target message according to the target label, the target message having a same source address and destination address as the first message; The sending module is configured to transmit the target packet adapted to the egress interface according to the type of the first packet through a target virtual network connected by the at least one egress interface. The matching module is specifically configured to determine an original label, a source address and a destination address according to the first packet. The matching module is specifically configured to determine an original label, a source address and a destination address according to the first packet. The matching module is specifically configured to determine an original label, a source address and a destination address according to the first packet.

7. A switch comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, wherein the computer program comprises computer program code adapted to cause the processor to perform the steps of any of claims 1 to 6. 7 The matching module is specifically configured to flood the first packet to at least one virtual network connected by the switch if the destination address of the first packet is unknown unicast or unknown multicast. The processor implements the data processing method of the Ethernet virtual private network according to any one of claims 1-5 when executing the program.

8. A storage medium containing computer executable instructions for executing the data processing method of the Ethernet virtual private network according to any one of claims 1-5 when executed by a computer processor.

Citation Information

Patent Citations

  • Support protocol irrelative software defined networking virtualization management platform

    CN107222353A

  • Method for realizing QinQ routing termination, switching chip and switch

    CN107968749A