WO2022121466A1 - Data processing method and device for ethernet virtual private network, and storage medium - Google Patents

Data processing method and device for ethernet virtual private network, and storage medium Download PDF

Info

Publication number
WO2022121466A1
WO2022121466A1 PCT/CN2021/121710 CN2021121710W WO2022121466A1 WO 2022121466 A1 WO2022121466 A1 WO 2022121466A1 CN 2021121710 W CN2021121710 W CN 2021121710W WO 2022121466 A1 WO2022121466 A1 WO 2022121466A1
Authority
WO
WIPO (PCT)
Prior art keywords
node
bum
esi
label
data processing
Prior art date
Application number
PCT/CN2021/121710
Other languages
French (fr)
Chinese (zh)
Inventor
易放军
Original Assignee
中兴通讯股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2022121466A1 publication Critical patent/WO2022121466A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/50Routing or path finding of packets in data switching networks using label swapping, e.g. multi-protocol label switch [MPLS]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/46Interconnection of networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/46Interconnection of networks
    • H04L12/4641Virtual LANs, VLANs, e.g. virtual private networks [VPN]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/18Loop-free operations
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/74Address processing for routing

Definitions

  • the present application relates to the field of communication technologies, and in particular, to a data processing method, device and storage medium for an Ethernet virtual private network.
  • Ethernet Virtual Private Network when a client edge CE (Custom Edge) device is connected to multiple operator edge PE (Provider Edge) devices, multiple Ethernet segments ES (Ethernet Segments) are to be divided. ) and set the corresponding Ethernet segment label ESI (Ethernet Segment Identifier) for each ES to realize the orderly forwarding of packets between devices.
  • ES Ethernet Segment Identifier
  • the loopback problem needs to be solved.
  • the receiving end device of the BUM packet forms a forwarding table according to the route, so as to prevent the receiving end device from forwarding the BUM packet to other devices under the same ES.
  • the forwarding table The more label resources are consumed, and the forwarding tables need to be formed for different EVPN services, so a lot of forwarding table resources are occupied, which is not conducive to the effective use of forwarding table resources.
  • the embodiments of the present application provide a data processing method, device and storage medium for an Ethernet virtual private network, which combine multiple routes originating from the same PE in the same ES to form a forwarding table, thereby reducing the occupation of forwarding table resources.
  • an embodiment of the present application provides a data processing method for an Ethernet virtual private network, where the Ethernet virtual private network includes a first node and a second node that are adjacent nodes to each other, and the data processing method is applied to all The second node, including:
  • routing advertisement sent by the first node and obtain routing information according to the routing advertisement, where the routing information includes an Ethernet segment identifier ESI and a label value corresponding to the ESI;
  • each forwarding table entry of the forwarding table is composed of the network port identifier of the first node, the ESI and the label value;
  • the forwarding table is searched with the network port identifier of the first node and the first ESI corresponding to the source port of the BUM message, determine the first tag value;
  • the BUM-encapsulated message is forwarded to the first node, so that the first node decapsulates the BUM-encapsulated message and filters a local forwarding port according to the decapsulated first label value.
  • an embodiment of the present application further provides a data processing method for an Ethernet virtual private network, where the Ethernet virtual private network includes a first node and a second node that are adjacent nodes to each other, and the data processing method is applied to The first node includes:
  • the local forwarding port is filtered according to the first ESI.
  • an embodiment of the present application further provides a device, comprising at least one processor and a memory for being communicatively connected to the at least one processor; the memory stores a memory that can be executed by the at least one processor Instructions, which are executed by the at least one processor, so that the at least one processor can execute the data processing method of the Ethernet virtual private network of the first aspect or the second aspect.
  • embodiments of the present application provide a computer-readable storage medium, where the computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to cause a computer to execute the foregoing first aspect or the second A data processing method for an Ethernet virtual private network in the aspect.
  • the data processing method for an Ethernet virtual private network has at least the following beneficial effects: when the local device dual-homes to the first node and the second node that are mutually adjacent nodes, and the local device sends a BUM report to the second node message, after the second node receives the BUM message, in order to avoid the formation of a message loop when forwarding the BUM message to the first node, according to the ESI corresponding to the first node and the label corresponding to the ESI stored in the second node value, encapsulate the label value in the BUM packet and forward it to the first node.
  • the first node After receiving the encapsulated BUM packet, the first node decapsulates the packet, locates the field where the label value is located, and filters the local forwarding port according to the corresponding relationship between the ESI and the label value stored in the first node to prevent the packet from forming a loop.
  • the embodiment of the present application does not need to distinguish the EVPN service instance of the BUM packet when forwarding the BUM packet, thereby reducing the size of the forwarding table and reducing the occupation of forwarding table resources.
  • FIG. 1 is a flowchart of a data processing method for a second node provided by an embodiment of the present application
  • FIG. 2 is a flowchart of establishing a forwarding table by a second node provided by an embodiment of the present application
  • FIG. 3 is a flowchart of a data processing method of a first node provided by an embodiment of the present application
  • FIG. 4 is a schematic diagram of information exchange under the multi-homed network structure provided by the example of this application.
  • FIG. 5 is a schematic diagram of an apparatus structure of a device provided by an embodiment of the present application.
  • the embodiments of the present application provide a data processing method, device, and storage medium for an Ethernet virtual private network.
  • a forwarding table is constructed based on the correspondence between ESI and label value.
  • a search is performed based on the ESI corresponding to the BUM message.
  • the label value in the forwarding table, and the obtained label value is encapsulated in the BUM packet, so that when the device with the same ESI receives the BUM packet, the local forwarding port is filtered according to the label value in the BUM packet.
  • the construction of the above-mentioned forwarding table can reduce the occupation of forwarding table resources because there is no need to distinguish the EVPN service instances of the BUM packets.
  • an embodiment of the present application provides a data processing method for an Ethernet virtual private network.
  • the Ethernet virtual private network includes a first node and a second node that are adjacent nodes to each other.
  • the data processing method is applied to the second node, including But it is not limited to the following steps S100, S200, S300, S400 and S500.
  • Step S100 receiving a routing advertisement sent by the first node and obtaining routing information according to the routing advertisement, where the routing information includes an Ethernet segment identifier ESI and a label value corresponding to the ESI;
  • the CE device belongs to multiple PE devices. In this case, when the CE device reports BUM The PE device that receives the BUM packet will forward the BUM packet to other PE devices, and other PE devices will forward the BUM packet to the CE device after receiving the BUM packet, resulting in loopback of the BUM packet. .
  • RFC (Request For Comments) 7432 proposes to use the ES filter table to solve the problem of packet loopback, and allocate MPLS (Multi-Protocol Label Switching, multi-protocol label switching, multi-protocol labels) based on each platform to PE devices in multi-homing scenarios.
  • MPLS Multi-Protocol Label Switching, multi-protocol label switching, multi-protocol labels
  • the BUM packet After the BUM packet is reported to the current PE device from the ES port, if the current PE device forwards the BUM packet to the neighboring PE device, the BUM packet carries the corresponding ESI label value. , after receiving the BUM packet with the label value, the neighboring PE device recognizes and obtains the ESI corresponding to the label value, so that it no longer forwards to the local port with the same ESI.
  • the PE device that receives the BUM message forms a forwarding table according to the routing information corresponding to each advertised route of the adjacent PE device.
  • the resulting forwarding table is huge and consumes a lot of tag resources.
  • the embodiment of the present application uniformly manages the label values of BUM packets in the EVPN multi-homing scenario, and combines redundant routing information according to route advertisements to form a system that is suitable for multiple service scenarios at the same time.
  • Forwarding tables such as:
  • Step S200 combining routing information based on the same ESI to obtain a forwarding table, each forwarding table entry in the forwarding table is composed of the network port identifier, ESI and label value of the first node.
  • the first node and the second node represent two adjacent PE devices.
  • the first node sends a routing advertisement to the second node, and the routing information of the routing advertisement includes the corresponding local port of the first node.
  • the second node obtains the route advertisement through the port between the first node and the first node, it forms a forwarding table in the second node according to the routing information.
  • the content of the forwarding table It includes at least the above-mentioned ESI, the label value corresponding to the ESI, and the network port identifier of the first node.
  • the route advertisement should also include the service information corresponding to the local port of the first node.
  • the service information corresponding to the local port of the first node.
  • each AC corresponds to a port
  • the service instances of the port include MPLS and SRv6.
  • EVPN1, EVPN2 and EVPN3 are respectively used to represent its EVPN instance information.
  • each route sent by the first node to the second node The advertisements all contain ESI-label value-EVPN instance information.
  • the second node preliminarily forms a preliminary filtering table of the network port identifier-ESI-label value-EVPN instance information of the first node. It is divided by specific service types under EVPN, so the preliminary filter table formed under the three AC lines will occupy a lot of resources, and this is the filter table formed according to the RFC7432 specification; the embodiment of the present application attributes the first node in the preliminary filter table to the first node. The routing information of the same ESI is merged, and the EVPN instance information is removed to simplify the preliminary filtering table and reduce the occupation of label resources. Since the EVPN identifier is removed, the second node does not need to consider the EVPN service instance when encapsulating and forwarding BUM packets, which improves the speed of table lookup and encapsulation.
  • the forwarding table obtained by simplifying the above step S200 its entry is composed of the network port identifier of the first node-ESI-label value, different service instances under the same ESI share a label value, and is applicable to services such as MPLS and SRv6 at the same time.
  • the traditional forwarding table can only be applied to the problem of MPLS EVPN. It should be understood that in the traditional forwarding table established for MPLS EVPN services, the first node needs to allocate a label value for each ES in the MPLS label space, so that the ESI and the label value form a corresponding relationship.
  • MPLS labels are added, and when there are only SRv6 EVPN services in the Ethernet segment, the label value of the MPLS label space is also occupied, which is not conducive to EVPN label allocation. Since there is no need to distinguish service instances in this embodiment of the present application, the label value can be set according to needs when assigning it.
  • the ESI assigns the label value, and the specific value range of the label value can also be defined as needed, as long as the label value and the ESI can form a one-to-one correspondence, which solves the problem of MPLS label occupation.
  • Step S300 when forwarding the broadcast, unknown unicast, and multicast BUM messages to the first node, look up the forwarding table with the network port identifier of the first node and the first ESI corresponding to the source port of the BUM message, and determine the first label value .
  • the second node After receiving the BUM message, the second node determines the broadcast members of the BUM message, determines that the first node is an adjacent node, and forwards the BUM message to the first node; assuming that the first node and the second node are in the same ES, then the first node and the second node have the same ESI, the BUM message needs to be specially processed, so that the first node can break the loop after receiving the BUM message; if the first node and the second node If they are not in the same ES, when the second node queries the forwarding table according to the first ESI corresponding to the BUM packet, the corresponding forwarding table entry cannot be found, so the second node does not need to encapsulate the BUM packet when forwarding the BUM packet to the first node. Label value.
  • the forwarding table is searched based on the network port identifier of the first node and the first ESI corresponding to the source port of the BUM packet. , you can find the forwarding table entry of the network port identifier of the first node-first ESI-first label value, so as to obtain the first label value, and then encapsulate the obtained first label value in a BUM message, A BUM encapsulated packet is formed and sent to the first node.
  • Step S400 Encapsulate the first label value in the BUM packet according to the encapsulation structure of the BUM packet to obtain a BUM encapsulated packet.
  • Step S500 Forward the BUM-encapsulated message to the first node, so that the first node decapsulates the BUM-encapsulated message and filters the local forwarding port according to the decapsulated first label value.
  • the encapsulated BUM packet carries the first label value.
  • the first node receives the BUM encapsulated packet, it can locate the location of the first label value through decapsulation. According to the difference between the first label value and the first ESI Corresponding relationship, the first node can filter the local forwarding port, that is, as long as the port in the same ES will not forward the BUM packet, thereby avoiding the formation of packet loopback.
  • the embodiment of the present application reduces the occupation of label resources by simplifying the forwarding table, and does not occupy MPLS label resources in the label space. On this basis, the BUM packet loopback problem of different service instances is solved; the solution of the embodiment of the present application is easy to The implementation has high practical value.
  • the routing information obtained by the second node after receiving the route advertisement includes, in addition to the ESI and the label value, the network port identifier of the first node and the EVPN instance information published by the first node based on the Ethernet virtual private network EVPN instance.
  • the network port identifier can be represented by an IP address, which is used to indicate the destination IP of sending, or can be set based on the MAC address, and can also be used to determine the next hop of the route.
  • the route advertisement carries EVPN service instance information corresponding to the service type used by the local port in the first node, which is used to indicate the service type used by the local port.
  • the second node needs to organize and simplify the above-mentioned original data to obtain the final forwarding table. Therefore, referring to FIG. 2 , in step S100, the routing information is merged to create a forwarding table.
  • the forwarding table includes but is not limited to the following steps S110 and S120.
  • Step S110 forming a preliminary filtering table according to the routing information, and each filtering table entry of the preliminary filtering table is composed of the network port identifier of the first node, the EVPN instance information, the ESI and the label value. ;
  • Step S120 combining the filtering entries with the same ESI to remove the EVPN instance information to obtain a forwarding table.
  • the preliminary filtering table directly formed by the routing information contains the network port identifier of the first node-ESI-label value-EVPN instance information, based on the simplification method of the embodiment of the present application, the same network port
  • the information of different EVPN instances under one ESI is merged to form an entry of network port identifier-ESI, which is distinguished by label value, thereby finally forming a forwarding table whose forwarding table entry is network port identifier-ESI-label value.
  • the second node After receiving the BUM packet, the second node determines to which network port identifier to forward the BUM packet, and determines the first ESI corresponding to the source port of the BUM packet.
  • the text is packaged.
  • first ESI and the first tag value are respectively used to represent one of the ESIs and one of the many tag values in the multiple forwarding tables, and There is no specific numerical limitation on the first ESI and the first tag value.
  • BUM packets are encapsulated in different encapsulation locations according to different service types.
  • the second node After the second node receives the BUM packet, it needs to determine whether the service type of the BUM packet is suitable for the service type applicable to the current label value encapsulation method.
  • the service type of the BUM packet conforms to the preset service type, according to The packet encapsulation structure corresponding to the preset service type determines the encapsulation position of the label value.
  • the BUM packet should be encapsulated and sent in other ways.
  • the above-mentioned preset service types can be set as required, and are not limited here.
  • the embodiments of the present application illustrate the encapsulation position of the label value in the BUM packet under two different service types by way of example.
  • the first case is a first case:
  • the service type of the BUM packet is multi-protocol label switching MPLS EVPN
  • the first label value is placed in the field after VPN Label in the encapsulation structure.
  • the packet structure of the MPLS EVPN service has a label stack, including a top label (or outer label) and a bottom label (or inner label, stack bottom label). It is transmitted to the adjacent PE device, and the bottom label is used to instruct the CE device to which the PE device sends the packet data. Therefore, in order to filter the local forwarding port in the first node, the first label value should be added in the bottom label. Specifically, the first label value can be placed in the field behind the VPN Label. When the first node receives the BUM-encapsulated packet, it decapsulates the BUM-encapsulated packet and matches it to the VPN Label. If the VPN Label is not at the bottom of the stack, then the following field is the value of the first label, which is used to find the ESI to achieve The message is broken.
  • the BUM packet is an IPv6 segment routing SRv6 EVPN service packet
  • the first label value is filled in the Argument field of the SRv6 SID in the encapsulation structure.
  • the packet structure of the SRv6 EVPN service is represented by Segment id (SID for short) to represent the IPv6 address format.
  • SID is divided into two fields, Locator and Function. Locator is used for label routing, and Function is used to define the received device. Action after this tag. Therefore, in order to filter the local forwarding port in the first node, the first label value should be added in the Function field. Specifically, the label can be placed in the Argument field in the Function field.
  • the first node receives the BUM-encapsulated packet, it decapsulates the BUM-encapsulated packet and matches the Function field, and obtains the first label value by taking the part of the Argument field, which is used to find the ESI to break the packet.
  • an embodiment of the present application also provides a data processing method for an Ethernet virtual private network, where the Ethernet virtual private network includes a first node and a second node that are mutually adjacent nodes, and the data processing method is applied to the first node, Including but not limited to the following steps S600, S700, S800 and S900.
  • Step S600 obtaining the ESI corresponding to the local port and assigning a label value to the ESI, and constructing a local lookup table whose entry is the ESI and the label value;
  • Step S700 when receiving the BUM encapsulated message forwarded by the second node, decapsulate the BUM encapsulated message and determine a first label value in the BUM encapsulated message;
  • Step S800 look up the local lookup table according to the first tag value, and determine the first ESI;
  • Step S900 filtering the local forwarding port according to the first ESI.
  • the embodiment of the present application is applied to the first node, and the work to be performed by the first node includes decapsulating the BUM encapsulation message sent by the second node, and locating the BUM encapsulation packet.
  • the position of the label value in the packet is searched according to the first label value to obtain the ESI, so as to filter the local forwarding port, that is, when the ES corresponding to the ESI and the ES where the local forwarding port is located are the same, the local forwarding port will not be forwarded.
  • BUM message is, when the ES corresponding to the ESI and the ES where the local forwarding port is located are the same, the local forwarding port will not be forwarded.
  • the first node should also obtain the ES where the local forwarding port is located, and assign a label value to the ESI corresponding to the ES.
  • the routing advertisement sent by the first node to the second node send the ESI and ESI to the second node.
  • the label value corresponding to the ESI so that the second node establishes the forwarding table required by the embodiment of the present application.
  • the label value allocated for the ESI in the first node is not allocated in the traditional label space (such as MPLS label space), it is not defined according to the range of the traditional label value, because the label value in this embodiment of the present application needs to be located after the service label Therefore, it is a context label for assigning ES entities.
  • the context label needs to rely on each platform label to determine its behavior. This feature corresponds to the behavior of locating the first label value in the BUM encapsulation message.
  • the first node needs to determine the corresponding service type after decapsulating the BUM-encapsulated packets, in order to locate the label value in it, which can be implemented in the following ways:
  • the service type of the BUM-encapsulated packet is multi-protocol label switching MPLS EVPN
  • it matches the VPN Label in the BUM-encapsulated packet confirms that the VPN Label field is not the bottom of the label stack, and determines that the label at the bottom of the stack is the first label value
  • the service type of the BUM encapsulated packet is an IPv6 segment routing SRv6 EVPN service packet
  • locate the Function field of the SRv6 SID and determine that the Argument field in the Function field is the first label value.
  • the above judgment process corresponds to the process of encapsulating the BUM packet by the second node.
  • the service type is MPLS EVPN
  • the VPN Label is matched, and it is judged whether the VPN Label is a stack bottom label, and if not, then The field after VPN Label is the first label value.
  • the service type is SRv6 EVPN
  • locate the Function field of the SRv6 SID and find the Argument field from the Function field, thereby determining the first tag value.
  • the embodiment of the present application is applied to an EVPN multi-homing scenario.
  • the first node and the second node are connected to the same CE device as two adjacent PE devices.
  • the network port identifier of the node constructs the forwarding table, which does not distinguish EVPN service instances, thereby reducing the occupation of label resources in the forwarding table.
  • this example is provided with three PE devices, which are represented by A device, B device, and C device respectively.
  • the three PE devices are adjacent to each other, where A device and B device belong to the same ES, and C device and B device. They do not belong to the same ES.
  • the ACs under the same ES have the same names, namely AC1 (the service type is MPLS-EVPN1) and AC2 (the service type is MPLS) -EVPN2) and AC3 (service type is SRv6-EVPN3).
  • device A assigns a tag value of 1 to ES1 in an independent space (for the sake of illustration, the networking in the example only divides one ES, which is represented by ES1. If there are multiple ESs, then It can be represented by ES2, ES3, ..., ESn in turn), since each ES has a unique ESI, the corresponding relationship between ESI1 and label value 1 is formed in the A device (ES2, ES3, ..., ESn respectively correspond to the unique identifier ESI2 , ESI3, ..., ESIn).
  • Device A sends a route advertisement to device B, and device B learns the IP port of device A (represented by IP-a), ESI1, label value 1, and the EVPN instance information corresponding to the three ACs.
  • Device B obtains the information by sorting out the above information.
  • the preliminary filter table has a total of three entries, see Figure 4, which are:
  • IP-a+ESI1+EVPN1 label value 1
  • IP-a+ESI1+EVPN2 label value 1
  • IP-a+ESI1+EVPN3 label value 1
  • the above preliminary filter table is simplified, and the EVPN service type information is removed after merging, and the entries that constitute the forwarding table are obtained:
  • IP-a+ESI1 tag value 1
  • the data packets forwarded to device A need to be labeled An encapsulation of value 1.
  • the BUM packet corresponding to ESI1 sent to IP-a can be determined to be the label value 1, so that the label value 1 is encapsulated in the BUM packet; when the service type of the BUM packet is MPLS For EVPN, the label value 1 is pushed to the bottom of the label stack.
  • the label value 1 is filled in the Argument field of the SID, and the BUM encapsulated packet is finally obtained and sent to device A.
  • device C and device B do not belong to the same ES, they send packets to device C according to the conventional BUM packet forwarding method without carrying the label value.
  • device A After receiving the BUM-encapsulated packet, device A decapsulates the packet to determine the label value. For the BUM-encapsulated packet of MPLS EVPN type, if the VPN Label is not the bottom of the stack, the label at the bottom of the stack is the label value of 1. For the BUM of SRv6 EVPN type After encapsulating the packet, after determining the service through the Function field, take the Argument field to obtain the label value 1; device A filters out the three AC lines belonging to ES1 according to the corresponding relationship between the label value 1 obtained through decapsulation and ESI1.
  • An embodiment of the present application further provides a device, comprising at least one processor and a memory for communicating with the at least one processor; the memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor , so that at least one processor can execute the aforementioned data processing method of the Ethernet virtual private network.
  • control processor 1001 and the memory 1002 in the device 1000 may be connected through a bus.
  • the memory 1002 can be used to store non-transitory software programs and non-transitory computer-executable programs.
  • memory 1002 may include high-speed random access memory, and may also include non-transitory memory, such as at least one disk memory, flash memory device, or other non-transitory solid state storage device.
  • memory 1002 may optionally include memory located remotely from control processor 1001, which may be connected to device 1000 via a network. Examples of such networks include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
  • the device structure shown in FIG. 5 does not constitute a limitation on the device 1000, and may include more or less components than the one shown, or combine some components, or arrange different components.
  • Embodiments of the present application further provide a computer-readable storage medium, where computer-executable instructions are stored in the computer-readable storage medium, and the computer-executable instructions are executed by one or more control processors, for example, as shown in FIG. 5 .
  • the execution of one control processor 1001 of the above-mentioned one or more control processors can cause the above-mentioned one or more control processors to execute the data processing method of the Ethernet virtual private network in the above-mentioned method embodiments, for example, to perform the above-described method steps S100 to S500 in FIG. 1 . , the method steps S110 to S120 in FIG. 2 and the method steps S600 to S900 in FIG. 3 .
  • the data processing method for an Ethernet virtual private network has at least the following beneficial effects: when the local device is dual-homed to the first node and the second node that are mutually adjacent nodes, and the local device sends a BUM message to the second node message, after the second node receives the BUM message, in order to avoid the formation of a message loop when forwarding the BUM message to the first node, according to the ESI corresponding to the first node and the label corresponding to the ESI stored in the second node value, encapsulate the label value in the BUM packet and forward it to the first node.
  • the first node After receiving the encapsulated BUM packet, the first node decapsulates the packet, locates the field where the label value is located, and filters the local forwarding port according to the corresponding relationship between the ESI and the label value stored in the first node to prevent the packet from forming a loop.
  • the embodiment of the present application does not need to distinguish the EVPN service instance of the BUM packet when forwarding the BUM packet, thereby reducing the size of the forwarding table and reducing the occupation of forwarding table resources.
  • Computer storage media include, but are not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disk (DVD) or other optical disk storage, magnetic cartridges, magnetic tape, magnetic disk storage or other magnetic storage devices, or may Any other medium used to store desired information and which can be accessed by a computer.
  • communication media typically embodies computer readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and can include any information delivery media, as is well known to those of ordinary skill in the art .

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

A data processing method and device for an Ethernet virtual private network, and a storage medium. The data processing method comprises: receiving a routing advertisement sent by a first node, and obtaining routing information according to the routing advertisement (S100); merging the routing information on the basis of the same ESI, so as to obtain a forwarding table, wherein each forwarding entry in the forwarding table is composed of a network port identifier, ESI, and identifier value of the first node (S200); when a BUM packet is forwarded to the first node, searching in the forwarding table for a first identifier value (S300); encapsulating the first identifier value in the BUM packet according to an encapsulation structure of the BUM packet (S400); and forwarding the BUM packet to the first node, such that the first node decapsulates the BUM packet and filters local forwarding ports according to the first identifier value obtained by means of decapsulation (S500).

Description

以太虚拟专用网的数据处理方法、设备及存储介质Data processing method, device and storage medium of Ethernet virtual private network
相关申请的交叉引用CROSS-REFERENCE TO RELATED APPLICATIONS
本申请基于申请号为202011417069.6、申请日为2020年12月07日的中国专利申请提出,并要求该中国专利申请的优先权,该中国专利申请的全部内容在此引入本申请作为参考。This application is based on the Chinese patent application with the application number of 202011417069.6 and the filing date of December 07, 2020, and claims the priority of the Chinese patent application. The entire content of the Chinese patent application is incorporated herein by reference.
技术领域technical field
本申请涉及通信技术领域,尤其涉及一种以太虚拟专用网的数据处理方法、设备及存储介质。The present application relates to the field of communication technologies, and in particular, to a data processing method, device and storage medium for an Ethernet virtual private network.
背景技术Background technique
在以太虚拟专用网EVPN(Ethernet Virtual Private Network)中,当客户端边缘CE(Custom Edge)设备连接到多个运营商边缘PE(Provider Edge)设备,要划分出多个以太网段ES(Ethernet Segment)并为每个ES设置相应的以太网段标签ESI(Ethernet Segment Identifier),实现设备间报文的有序转发。In the Ethernet Virtual Private Network (EVPN), when a client edge CE (Custom Edge) device is connected to multiple operator edge PE (Provider Edge) devices, multiple Ethernet segments ES (Ethernet Segments) are to be divided. ) and set the corresponding Ethernet segment label ESI (Ethernet Segment Identifier) for each ES to realize the orderly forwarding of packets between devices.
在EVPN内转发广播、未知单播、组播BUM(Broadcast、Unkown-unicast、Multicast)报文,需要解决回环问题。目前的数据处理手段中,BUM报文的接收端设备按照路由形成转发表,避免接收端设备将BUM报文向同一ES下的其他设备转发,然而当PE设备和ES的数量越多,转发表消耗的标签资源就越大,并且不同的EVPN业务要各自形成转发表,因此会占用了大量的转发表资源,不利于转发表资源的有效利用。To forward broadcast, unknown unicast, and multicast BUM (Broadcast, Unkown-unicast, and Multicast) packets in the EVPN, the loopback problem needs to be solved. In the current data processing method, the receiving end device of the BUM packet forms a forwarding table according to the route, so as to prevent the receiving end device from forwarding the BUM packet to other devices under the same ES. However, when the number of PE devices and ESs increases, the forwarding table The more label resources are consumed, and the forwarding tables need to be formed for different EVPN services, so a lot of forwarding table resources are occupied, which is not conducive to the effective use of forwarding table resources.
发明内容SUMMARY OF THE INVENTION
以下是对本文详细描述的主题的概述。本概述并非是为了限制权利要求的保护范围。The following is an overview of the topics detailed in this article. This summary is not intended to limit the scope of protection of the claims.
本申请实施例提供了一种以太虚拟专用网的数据处理方法、设备及存储介质,将同一ES内来源于相同PE的多条路由合并形成一个转发表,减小转发表资源的占用。The embodiments of the present application provide a data processing method, device and storage medium for an Ethernet virtual private network, which combine multiple routes originating from the same PE in the same ES to form a forwarding table, thereby reducing the occupation of forwarding table resources.
第一方面,本申请实施例提供了一种以太虚拟专用网的数据处理方法,所述以太虚拟专用网包括互为相邻节点的第一节点和第二节点,所述数据处理方法应用于所述第二节点,包括:In a first aspect, an embodiment of the present application provides a data processing method for an Ethernet virtual private network, where the Ethernet virtual private network includes a first node and a second node that are adjacent nodes to each other, and the data processing method is applied to all The second node, including:
接收所述第一节点发送的路由通告并根据所述路由通告得到路由信息,所述路由信息包括以太网段标识ESI和与所述ESI对应的标签值;Receive a routing advertisement sent by the first node and obtain routing information according to the routing advertisement, where the routing information includes an Ethernet segment identifier ESI and a label value corresponding to the ESI;
基于相同的ESI将所述路由信息合并,得到转发表,所述转发表的每个转发表项由所述第一节点的网络端口标识、所述ESI和所述标签值构成;Combining the routing information based on the same ESI to obtain a forwarding table, each forwarding table entry of the forwarding table is composed of the network port identifier of the first node, the ESI and the label value;
当向所述第一节点转发广播、未知单播、组播BUM报文,以所述第一节点的网络端口标识和所述BUM报文的源端口对应的第一ESI查找所述转发表,确定第一标签值;When forwarding a broadcast, unknown unicast, and multicast BUM message to the first node, the forwarding table is searched with the network port identifier of the first node and the first ESI corresponding to the source port of the BUM message, determine the first tag value;
根据所述BUM报文的封装结构将所述第一标签值封装在所述BUM报文中,得到BUM封装报文;以及Encapsulating the first label value in the BUM packet according to the encapsulation structure of the BUM packet to obtain a BUM encapsulation packet; and
将所述BUM封装报文转发到所述第一节点,以使所述第一节点解封装所述BUM封装报文并根据解封装所得的所述第一标签值过滤本地转发端口。The BUM-encapsulated message is forwarded to the first node, so that the first node decapsulates the BUM-encapsulated message and filters a local forwarding port according to the decapsulated first label value.
第二方面,本申请实施例还提供了一种以太虚拟专用网的数据处理方法,所述以太虚拟专用网包括互为相邻节点的第一节点和第二节点,所述数据处理方法应用于所述第一节点,包括:In a second aspect, an embodiment of the present application further provides a data processing method for an Ethernet virtual private network, where the Ethernet virtual private network includes a first node and a second node that are adjacent nodes to each other, and the data processing method is applied to The first node includes:
获取本地端口对应的ESI并为所述ESI分配标签值,构建表项为所述ESI和所述标签值的本地查询表;Obtain the ESI corresponding to the local port and assign a label value to the ESI, and construct a local lookup table whose entry is the ESI and the label value;
当接收到所述第二节点转发的BUM封装报文,解封装所述BUM封装报文并确定所述BUM封装报文中的第一标签值;When receiving the BUM-encapsulated message forwarded by the second node, decapsulate the BUM-encapsulated message and determine the first label value in the BUM-encapsulated message;
根据所述第一标签值查找所述本地查询表,确定第一ESI;以及Look up the local lookup table according to the first tag value to determine the first ESI; and
根据所述第一ESI过滤本地转发端口。The local forwarding port is filtered according to the first ESI.
第三方面,本申请实施例还提供了一种设备,包括至少一个处理器和用于与所述至少一个处理器通信连接的存储器;所述存储器存储有能够被所述至少一个处理器执行的指令,所述指令被所述至少一个处理器执行,以使所述至少一个处理器能够执行前述第一方面或第二方面的以太虚拟专用网的数据处理方法。In a third aspect, an embodiment of the present application further provides a device, comprising at least one processor and a memory for being communicatively connected to the at least one processor; the memory stores a memory that can be executed by the at least one processor Instructions, which are executed by the at least one processor, so that the at least one processor can execute the data processing method of the Ethernet virtual private network of the first aspect or the second aspect.
第四方面,本申请实施例提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机可执行指令,所述计算机可执行指令用于使计算机执行前述第一方面或第二方面的以太虚拟专用网的数据处理方法。In a fourth aspect, embodiments of the present application provide a computer-readable storage medium, where the computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to cause a computer to execute the foregoing first aspect or the second A data processing method for an Ethernet virtual private network in the aspect.
本申请实施例提供的以太虚拟专用网的数据处理方法,至少具有如下有益效果:当本地设备双归属于互为相邻节点的第一节点和第二节点并且本地设备向第二节点发送BUM报文,在第二节点接收到BUM报文后,为了避免向第一节点转发该BUM报文时形成报文环路,根据第二节点中保存的第一节点对应的ESI以及该ESI对应的标签值,将标签值封装在该BUM报文中并向第一节点转发。第一节点收到封装过的BUM报文后解封装,并定位到该标签值所在的字段,根据第一节点中保存ESI和标签值的对应关系,过滤本地转发端口,避免报文成环。本申请实施例在对BUM报文转发时不需要区分BUM报文的EVPN业务实例,从而精简了转发表尺寸,能够降低转发表资源的占用。The data processing method for an Ethernet virtual private network provided by the embodiment of the present application has at least the following beneficial effects: when the local device dual-homes to the first node and the second node that are mutually adjacent nodes, and the local device sends a BUM report to the second node message, after the second node receives the BUM message, in order to avoid the formation of a message loop when forwarding the BUM message to the first node, according to the ESI corresponding to the first node and the label corresponding to the ESI stored in the second node value, encapsulate the label value in the BUM packet and forward it to the first node. After receiving the encapsulated BUM packet, the first node decapsulates the packet, locates the field where the label value is located, and filters the local forwarding port according to the corresponding relationship between the ESI and the label value stored in the first node to prevent the packet from forming a loop. The embodiment of the present application does not need to distinguish the EVPN service instance of the BUM packet when forwarding the BUM packet, thereby reducing the size of the forwarding table and reducing the occupation of forwarding table resources.
本申请的其它特征和优点将在随后的说明书中阐述,并且,部分地从说明书中变得显而易见,或者通过实施本申请而了解。本申请的目的和其他优点可通过在说明书、权利要求书以及附图中所特别指出的结构来实现和获得。Other features and advantages of the present application will be set forth in the description which follows, and in part will be apparent from the description, or may be learned by practice of the present application. The objectives and other advantages of the application may be realized and attained by the structure particularly pointed out in the description, claims and drawings.
附图说明Description of drawings
附图用来提供对本申请技术方案的进一步理解,并且构成说明书的一部分,与本申请的示例一起用于解释本申请的技术方案,并不构成对本申请技术方案的限制。The accompanying drawings are used to provide a further understanding of the technical solutions of the present application, and constitute a part of the specification. They are used to explain the technical solutions of the present application together with the examples of the present application, and do not constitute a limitation on the technical solutions of the present application.
图1是本申请实施例提供的第二节点的数据处理方法的流程图;1 is a flowchart of a data processing method for a second node provided by an embodiment of the present application;
图2是本申请实施例提供的第二节点建立转发表的流程图;FIG. 2 is a flowchart of establishing a forwarding table by a second node provided by an embodiment of the present application;
图3是本申请实施例提供的第一节点的数据处理方法的流程图;3 is a flowchart of a data processing method of a first node provided by an embodiment of the present application;
图4是本申请示例提供的多归属网络结构下的信息交互示意图;以及FIG. 4 is a schematic diagram of information exchange under the multi-homed network structure provided by the example of this application; and
图5是本申请实施例提供的设备的装置结构示意图。FIG. 5 is a schematic diagram of an apparatus structure of a device provided by an embodiment of the present application.
具体实施方式Detailed ways
为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处所描述的具体实施例仅用以解释本申请,并不用于限定本申请。In order to make the purpose, technical solutions and advantages of the present application more clearly understood, the present application will be described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application, but not to limit the present application.
本申请实施例提供了一种以太虚拟专用网的数据处理方法、设备及存储介质,由ESI和标签值的对应关系构建转发表,当需要转发BUM报文时,基于BUM报文对应的ESI查找转发表中的标签值,并将查找得到的标签值封装在BUM报文中,从而使得具有同一ESI的设备在接收到该BUM报文时,根据BUM报文中的标签值过滤本地转发端口,上述转发表的构建由于无需区分BUM报文的EVPN业务实例,因此能够降低转发表资源的占用。The embodiments of the present application provide a data processing method, device, and storage medium for an Ethernet virtual private network. A forwarding table is constructed based on the correspondence between ESI and label value. When a BUM message needs to be forwarded, a search is performed based on the ESI corresponding to the BUM message. The label value in the forwarding table, and the obtained label value is encapsulated in the BUM packet, so that when the device with the same ESI receives the BUM packet, the local forwarding port is filtered according to the label value in the BUM packet. The construction of the above-mentioned forwarding table can reduce the occupation of forwarding table resources because there is no need to distinguish the EVPN service instances of the BUM packets.
下面结合附图,对本申请实施例作进一步阐述。The embodiments of the present application will be further described below with reference to the accompanying drawings.
参照图1,本申请实施例提供了一种以太虚拟专用网的数据处理方法,以太虚拟专用网包括互为相邻节点的第一节点和第二节点,数据处理方法应用于第二节点,包括但不限于以下步骤S100、步骤S200、步骤S300、步骤S400和步骤S500。1 , an embodiment of the present application provides a data processing method for an Ethernet virtual private network. The Ethernet virtual private network includes a first node and a second node that are adjacent nodes to each other. The data processing method is applied to the second node, including But it is not limited to the following steps S100, S200, S300, S400 and S500.
步骤S100,接收第一节点发送的路由通告并根据路由通告得到路由信息,路由信息包括以太网段标识ESI和与ESI对应的标签值;Step S100, receiving a routing advertisement sent by the first node and obtaining routing information according to the routing advertisement, where the routing information includes an Ethernet segment identifier ESI and a label value corresponding to the ESI;
在现有的EVPN中,一个CE设备连接到多个PE设备,那么该CE设备多归属于多个PE设备,在这种情况下,当CE设备向PE设备上报BUM报文,基于BUM报文的特性,接收到BUM报文的PE设备会向其他PE设备转发该BUM报文,其他PE设备在接收到该BUM报文后又会向该CE设备转发BUM报文,导致BUM报文环回。为了克服上述问题,RFC(Request For Comments)7432中提出了采用ES过滤表解决报文环回问题,为多归属场景下的PE设备分配基于每平台的MPLS(Multi-Protocol Label Switching,多协议标签交换)的ESI标签,当BUM报文从ES端口上报到当前PE设备后,若当前PE设备向相邻PE设备转发该BUM报文,则在该BUM报文中携带相对应的ESI的标签值,相邻PE设备接收到带有标签值的BUM报文后识别得到该标签值对应的ESI,从而不再往本地相同ESI的端口进行转发。In the existing EVPN, if a CE device is connected to multiple PE devices, the CE device belongs to multiple PE devices. In this case, when the CE device reports BUM The PE device that receives the BUM packet will forward the BUM packet to other PE devices, and other PE devices will forward the BUM packet to the CE device after receiving the BUM packet, resulting in loopback of the BUM packet. . In order to overcome the above problems, RFC (Request For Comments) 7432 proposes to use the ES filter table to solve the problem of packet loopback, and allocate MPLS (Multi-Protocol Label Switching, multi-protocol label switching, multi-protocol labels) based on each platform to PE devices in multi-homing scenarios. After the BUM packet is reported to the current PE device from the ES port, if the current PE device forwards the BUM packet to the neighboring PE device, the BUM packet carries the corresponding ESI label value. , after receiving the BUM packet with the label value, the neighboring PE device recognizes and obtains the ESI corresponding to the label value, so that it no longer forwards to the local port with the same ESI.
然而在RFC7432的规范下,接收BUM报文的PE设备按照相邻PE设备的每个通告路由对应路由信息形成转发表,其规模与PE设备的邻居数目、EVPN的业务数目和ES的数目有关,最终形成的转发表非常巨大,消耗了大量的标签资源。However, under the specification of RFC7432, the PE device that receives the BUM message forms a forwarding table according to the routing information corresponding to each advertised route of the adjacent PE device. The resulting forwarding table is huge and consumes a lot of tag resources.
基于此,为了精简转发表,本申请实施例在EVPN多归属场景下对BUM报文的标签值进行统一管理,根据路由通告将冗余的路由信息进行合并,形成同时适用于多种业务场景的转发表,如:Based on this, in order to simplify the forwarding table, the embodiment of the present application uniformly manages the label values of BUM packets in the EVPN multi-homing scenario, and combines redundant routing information according to route advertisements to form a system that is suitable for multiple service scenarios at the same time. Forwarding tables, such as:
步骤S200,基于相同的ESI将路由信息合并,得到转发表,转发表的每个转发表项由第一节点的网络端口标识、ESI和标签值构成。Step S200, combining routing information based on the same ESI to obtain a forwarding table, each forwarding table entry in the forwarding table is composed of the network port identifier, ESI and label value of the first node.
本申请实施例以第一节点和第二节点表示两个相邻的PE设备,通过步骤S100,由第一节点向第二节点发送路由通告,路由通告的路由信息包括第一节点的本地端口对应的ESI和由第一节点对应不同ESI分配的标签值,第二节点通过与第一节点之间端口获取到该路由通告后,根据路由信息在第二节点中形成转发表,该转发表的内容至少包括上述的ESI、该ESI对应的标签值和第一节点的网络端口标识。In this embodiment of the present application, the first node and the second node represent two adjacent PE devices. Through step S100, the first node sends a routing advertisement to the second node, and the routing information of the routing advertisement includes the corresponding local port of the first node. The ESI and the label value assigned by the first node corresponding to different ESIs. After the second node obtains the route advertisement through the port between the first node and the first node, it forms a forwarding table in the second node according to the routing information. The content of the forwarding table It includes at least the above-mentioned ESI, the label value corresponding to the ESI, and the network port identifier of the first node.
可以理解的是,路由通告中还应该包括第一节点的本地端口对应的业务信息,例如,以图1中的第一节点为例,第一节点下连接有三条AC(Attachment Circuit,接入电路),每条AC对应一个端口,端口的业务实例包括MPLS和SRv6,在本实施例中分别以EVPN1、EVPN2和EVPN3表示其EVPN实例信息,这样,第一节点向第二节点发送的每次路由通告都包含有ESI-标签值-EVPN实例信息,按照RFC7432的规范,第二节点初步形成第一节点的网络端口标识-ESI-标签值-EVPN实例信息的初步过滤表,由于初步过滤表是按照EVPN下具体业务类 型来划分的,因此三条AC线路下形成的初步过滤表将占用大量的资源,这就是按照RFC7432规范形成的过滤表;本申请实施例通过将初步过滤表中归属于第一节点的相同ESI的路由信息进行合并,去掉EVPN实例信息从而精简初步过滤表,减小对标签资源的占用。由于去掉了EVPN标识,因此第二节点在进行BUM报文封装转发时,无需考虑EVPN的业务实例,提高了查表封装的速度。It can be understood that the route advertisement should also include the service information corresponding to the local port of the first node. For example, taking the first node in FIG. 1 as an example, there are three AC (Attachment Circuits) connected to the first node. ), each AC corresponds to a port, and the service instances of the port include MPLS and SRv6. In this embodiment, EVPN1, EVPN2 and EVPN3 are respectively used to represent its EVPN instance information. In this way, each route sent by the first node to the second node The advertisements all contain ESI-label value-EVPN instance information. According to the specification of RFC7432, the second node preliminarily forms a preliminary filtering table of the network port identifier-ESI-label value-EVPN instance information of the first node. It is divided by specific service types under EVPN, so the preliminary filter table formed under the three AC lines will occupy a lot of resources, and this is the filter table formed according to the RFC7432 specification; the embodiment of the present application attributes the first node in the preliminary filter table to the first node. The routing information of the same ESI is merged, and the EVPN instance information is removed to simplify the preliminary filtering table and reduce the occupation of label resources. Since the EVPN identifier is removed, the second node does not need to consider the EVPN service instance when encapsulating and forwarding BUM packets, which improves the speed of table lookup and encapsulation.
通过上述步骤S200精简所得的转发表,其条目由第一节点的网络端口标识-ESI-标签值构成,相同ESI下不同的业务实例共用一个标签值,同时适用于MPLS和SRv6等业务,解决了传统转发表仅能适用于MPLS EVPN的问题。应该理解的是,针对MPLS EVPN业务建立的传统转发表的方式下,第一节点需要在MPLS标签空间为每个ES分配标签值,从而使ESI与标签值形成对应关系,因此标签值分配时占用了MPLS标签,并且当以太网段内只有SRv6 EVPN业务时,也会占用MPLS标签空间的标签值,因此不利于EVPN的标签分配。本申请实施例由于不需要区分业务实例,因此在分配标签值的时候可以根据需要自行设定,例如在第一节点中划分出一个独立空间(如新设的标签空间)用来为本地端口对应的ESI分配标签值,而标签值的具体数值范围也可以按需划定,只要标签值与ESI能够形成一一对应的关系即可,解决了MPLS标签的占用问题。The forwarding table obtained by simplifying the above step S200, its entry is composed of the network port identifier of the first node-ESI-label value, different service instances under the same ESI share a label value, and is applicable to services such as MPLS and SRv6 at the same time. The traditional forwarding table can only be applied to the problem of MPLS EVPN. It should be understood that in the traditional forwarding table established for MPLS EVPN services, the first node needs to allocate a label value for each ES in the MPLS label space, so that the ESI and the label value form a corresponding relationship. MPLS labels are added, and when there are only SRv6 EVPN services in the Ethernet segment, the label value of the MPLS label space is also occupied, which is not conducive to EVPN label allocation. Since there is no need to distinguish service instances in this embodiment of the present application, the label value can be set according to needs when assigning it. The ESI assigns the label value, and the specific value range of the label value can also be defined as needed, as long as the label value and the ESI can form a one-to-one correspondence, which solves the problem of MPLS label occupation.
步骤S300,当向第一节点转发广播、未知单播、组播BUM报文,以第一节点的网络端口标识和BUM报文的源端口对应的第一ESI查找转发表,确定第一标签值。Step S300, when forwarding the broadcast, unknown unicast, and multicast BUM messages to the first node, look up the forwarding table with the network port identifier of the first node and the first ESI corresponding to the source port of the BUM message, and determine the first label value .
第二节点在接收到BUM报文后,确定BUM报文的广播成员,判断出第一节点是相邻的节点,向第一节点转发该BUM报文;假设第一节点和第二节点处于相同的ES,那么第一节点和第二节点具有相同的ESI,则BUM报文需要进行特殊处理,才能使第一节点在接收到该BUM报文后进行破环;如果第一节点和第二节点不是处于相同的ES,那么第二节点根据BUM报文对应的第一ESI来查询转发表时,无法找到对应的转发表项,从而第二节点向第一节点转发BUM报文时也不需要封装标签值。After receiving the BUM message, the second node determines the broadcast members of the BUM message, determines that the first node is an adjacent node, and forwards the BUM message to the first node; assuming that the first node and the second node are in the same ES, then the first node and the second node have the same ESI, the BUM message needs to be specially processed, so that the first node can break the loop after receiving the BUM message; if the first node and the second node If they are not in the same ES, when the second node queries the forwarding table according to the first ESI corresponding to the BUM packet, the corresponding forwarding table entry cannot be found, so the second node does not need to encapsulate the BUM packet when forwarding the BUM packet to the first node. Label value.
当第一节点和第二节点处于相同的ES,第一节点和第二节点具有相同的ESI,则基于第一节点的网络端口标识和BUM报文的源端口对应的第一ESI,查找转发表,就可以查找到第一节点的网络端口标识-第一ESI-第一标签值的转发表项,从而查找得到第一标签值,然后将查找得到的第一标签值封装在BUM报文中,形成BUM封装报文,并向第一节点发送。When the first node and the second node are in the same ES, and the first node and the second node have the same ESI, the forwarding table is searched based on the network port identifier of the first node and the first ESI corresponding to the source port of the BUM packet. , you can find the forwarding table entry of the network port identifier of the first node-first ESI-first label value, so as to obtain the first label value, and then encapsulate the obtained first label value in a BUM message, A BUM encapsulated packet is formed and sent to the first node.
步骤S400,根据BUM报文的封装结构将第一标签值封装在BUM报文中,得到BUM封装报文。Step S400: Encapsulate the first label value in the BUM packet according to the encapsulation structure of the BUM packet to obtain a BUM encapsulated packet.
可以理解的是,由于本申请实施例的转发表不区分EVPN业务实例,因此在封装时需要先判断BUM报文的业务实例,不同的业务类实例下,报文的封装格式不同,因此第一标签值的封装位置不同,这将在后面针对不同封装格式的BUM报文的封装方式进行详细说明。It can be understood that, since the forwarding table of this embodiment of the present application does not distinguish EVPN service instances, the service instance of the BUM packet needs to be judged before encapsulation. The encapsulation locations of the label values are different, which will be described in detail later for the encapsulation methods of BUM packets of different encapsulation formats.
步骤S500,将BUM封装报文转发到第一节点,以使第一节点解封装BUM封装报文并根据解封装所得的第一标签值过滤本地转发端口。Step S500: Forward the BUM-encapsulated message to the first node, so that the first node decapsulates the BUM-encapsulated message and filters the local forwarding port according to the decapsulated first label value.
封装后的BUM报文携带有第一标签值,当第一节点接收到BUM封装报文后,通过解封装可以定位到第一标签值所在的位置,根据第一标签值和第一ESI之间对应关系,第一节点即可对本地转发端口进行过滤,即只要是处于相同ES的端口都不会转发该BUM报文,从而避免报文环回的形成。The encapsulated BUM packet carries the first label value. When the first node receives the BUM encapsulated packet, it can locate the location of the first label value through decapsulation. According to the difference between the first label value and the first ESI Corresponding relationship, the first node can filter the local forwarding port, that is, as long as the port in the same ES will not forward the BUM packet, thereby avoiding the formation of packet loopback.
本申请实施例通过精简转发表从而减少标签资源的占用,也不占用标签空间中的MPLS标签资源,在此基础上解决了不同业务实例的BUM报文环回问题;本申请实施例的方案易于实施,具有较高的实用价值。The embodiment of the present application reduces the occupation of label resources by simplifying the forwarding table, and does not occupy MPLS label resources in the label space. On this basis, the BUM packet loopback problem of different service instances is solved; the solution of the embodiment of the present application is easy to The implementation has high practical value.
根据上述步骤S100可知,第二节点接收到路由通告后得到的路由信息除了ESI和标签值,还包括第一节点的网络端口标识和第一节点基于以太虚拟专用网EVPN实例发布的EVPN实例信息。网络端口标识可以用IP地址表示,用于表示发送的目的IP,也可以基于MAC地址设定网络端口标识,也能够用于确定路由的下一跳。另一方面,路由通告中带有第一节点中本地端口所用业务类型对应的EVPN业务实例信息,用来表示本地端口所用的业务类型。由此可知,第二节点在形成本申请实施例的转发表过程中,需要对上述原始数据进行整理和精简,才能得到最终的转发表,因此,参照图2,步骤S100中通过合并路由信息建立转发表包括但不限于以下步骤S110和步骤S120。According to the above step S100, the routing information obtained by the second node after receiving the route advertisement includes, in addition to the ESI and the label value, the network port identifier of the first node and the EVPN instance information published by the first node based on the Ethernet virtual private network EVPN instance. The network port identifier can be represented by an IP address, which is used to indicate the destination IP of sending, or can be set based on the MAC address, and can also be used to determine the next hop of the route. On the other hand, the route advertisement carries EVPN service instance information corresponding to the service type used by the local port in the first node, which is used to indicate the service type used by the local port. It can be seen from this that in the process of forming the forwarding table of the embodiment of the present application, the second node needs to organize and simplify the above-mentioned original data to obtain the final forwarding table. Therefore, referring to FIG. 2 , in step S100, the routing information is merged to create a forwarding table. The forwarding table includes but is not limited to the following steps S110 and S120.
步骤S110,根据所述路由信息形成初步过滤表,所述初步过滤表的每个过滤表项由所述第一节点的网络端口标识、所述EVPN实例信息、所述ESI和所述标签值构成;Step S110, forming a preliminary filtering table according to the routing information, and each filtering table entry of the preliminary filtering table is composed of the network port identifier of the first node, the EVPN instance information, the ESI and the label value. ;
步骤S120,将具有相同ESI的所述过滤表项合并从而去掉所述EVPN实例信息,得到转发表。Step S120, combining the filtering entries with the same ESI to remove the EVPN instance information to obtain a forwarding table.
由路由信息直接形成的初步过滤表,过滤表项中包含了第一节点的网络端口标识-ESI-标签值-EVPN实例信息,基于本申请实施例的精简方法,对同一个网络端口标识、同一个ESI下不同的EVPN实例信息进行合并,形成网络端口标识-ESI的条目,该条目通过标签值区分,从而最终形成转发表项为网络端口标识-ESI-标签值的转发表。当第二节点接收到BUM报文后,确定要向哪个网络端口标识进行转发,以及确定BUM报文的源端口对应的第一ESI,即可通过查找转发表得到第一标签值,对BUM报文进行封装。The preliminary filtering table directly formed by the routing information, the filtering table entry contains the network port identifier of the first node-ESI-label value-EVPN instance information, based on the simplification method of the embodiment of the present application, the same network port The information of different EVPN instances under one ESI is merged to form an entry of network port identifier-ESI, which is distinguished by label value, thereby finally forming a forwarding table whose forwarding table entry is network port identifier-ESI-label value. After receiving the BUM packet, the second node determines to which network port identifier to forward the BUM packet, and determines the first ESI corresponding to the source port of the BUM packet. The text is packaged.
可以理解的是,转发表中具有多个ESI和多个标签值,因此上述第一ESI和第一标签值是分别用于表示众多转发表中ESI的其中一个以及众多标签值的其中一个,并不是对第一ESI和第一标签值的具体数值限定。It can be understood that there are multiple ESIs and multiple tag values in the forwarding table, so the above-mentioned first ESI and the first tag value are respectively used to represent one of the ESIs and one of the many tag values in the multiple forwarding tables, and There is no specific numerical limitation on the first ESI and the first tag value.
BUM报文的封装根据业务类型的不同,采用不同的封装位置。首先,当第二节点接收到BUM报文后,需要判断BUM报文的业务类型是否适用于当前的标签值封装方式所适用的业务类型,当BUM报文的业务类型符合预设业务类型,根据预设业务类型对应的报文封装结构确定标签值的封装位置,当BUM报文的业务类型不符合预设业务类型,应按照其他方式对BUM报文进行封装和发送。BUM packets are encapsulated in different encapsulation locations according to different service types. First, after the second node receives the BUM packet, it needs to determine whether the service type of the BUM packet is suitable for the service type applicable to the current label value encapsulation method. When the service type of the BUM packet conforms to the preset service type, according to The packet encapsulation structure corresponding to the preset service type determines the encapsulation position of the label value. When the service type of the BUM packet does not conform to the preset service type, the BUM packet should be encapsulated and sent in other ways.
上述预设业务类型可以根据需要设定,在此不作限制。本申请实施例以举例的方式说明两种不同业务类型下,标签值在BUM报文中的封装位置。The above-mentioned preset service types can be set as required, and are not limited here. The embodiments of the present application illustrate the encapsulation position of the label value in the BUM packet under two different service types by way of example.
第一种情况:The first case:
当BUM报文的业务类型是多协议标签交换MPLS EVPN,根据MPLS EVPN对应的报文封装结构,将第一标签值置于封装结构中VPN Label后面的字段。When the service type of the BUM packet is multi-protocol label switching MPLS EVPN, according to the packet encapsulation structure corresponding to MPLS EVPN, the first label value is placed in the field after VPN Label in the encapsulation structure.
MPLS EVPN业务的报文结构具有标签栈,包括顶部标签(或称外层标签)和底部标签(或称内层标签、栈底标签),顶部标签在MPLS网络中用来指导如何从一个PE设备传到相邻的PE设备的,而底部标签是用来指导PE设备将报文数据发给哪个CE设备的。因此为了实现在第一节点中过滤本地转发端口,第一标签值应添加在底部标签中,具体地,可以将第一标签值置于VPN Label后面的字段。当第一节点接收到BUM封装报文,对BUM封装报文解封装后 匹配到VPN Label,判断若VPN Label不为栈底,那么其后的字段为第一标签值,用于查找ESI从而实现报文破环。The packet structure of the MPLS EVPN service has a label stack, including a top label (or outer label) and a bottom label (or inner label, stack bottom label). It is transmitted to the adjacent PE device, and the bottom label is used to instruct the CE device to which the PE device sends the packet data. Therefore, in order to filter the local forwarding port in the first node, the first label value should be added in the bottom label. Specifically, the first label value can be placed in the field behind the VPN Label. When the first node receives the BUM-encapsulated packet, it decapsulates the BUM-encapsulated packet and matches it to the VPN Label. If the VPN Label is not at the bottom of the stack, then the following field is the value of the first label, which is used to find the ESI to achieve The message is broken.
第二种情况:Second case:
当BUM报文是IPv6分段路由SRv6 EVPN业务报文,根据SRv6 EVPN业务报文的封装结构,将第一标签值填入封装结构中SRv6 SID的Argument字段。When the BUM packet is an IPv6 segment routing SRv6 EVPN service packet, according to the encapsulation structure of the SRv6 EVPN service packet, the first label value is filled in the Argument field of the SRv6 SID in the encapsulation structure.
SRv6 EVPN业务的报文结构,以Segment id(简称SID)表示IPv6地址格式,SID分为两部分字段,分别是Locator和Function,其中Locator用于进行标签路由,而Function用于定义所属设备收到该标签后的操作。因此为了实现在第一节点中过滤本地转发端口,第一标签值应添加在Function字段中,具体地,可以将标签置于Function字段中的Argument字段。当第一节点接收到BUM封装报文,对BUM封装报文解封后匹配到Function字段,取Argument字段部分得到第一标签值,用于查找ESI从而实现报文破环。The packet structure of the SRv6 EVPN service is represented by Segment id (SID for short) to represent the IPv6 address format. The SID is divided into two fields, Locator and Function. Locator is used for label routing, and Function is used to define the received device. Action after this tag. Therefore, in order to filter the local forwarding port in the first node, the first label value should be added in the Function field. Specifically, the label can be placed in the Argument field in the Function field. When the first node receives the BUM-encapsulated packet, it decapsulates the BUM-encapsulated packet and matches the Function field, and obtains the first label value by taking the part of the Argument field, which is used to find the ESI to break the packet.
参照,4,本申请实施例还提供了一种以太虚拟专用网的数据处理方法,以太虚拟专用网包括互为相邻节点的第一节点和第二节点,数据处理方法应用于第一节点,包括但不限于以下步骤S600、步骤S700、步骤S800和步骤S900。Referring to 4, an embodiment of the present application also provides a data processing method for an Ethernet virtual private network, where the Ethernet virtual private network includes a first node and a second node that are mutually adjacent nodes, and the data processing method is applied to the first node, Including but not limited to the following steps S600, S700, S800 and S900.
步骤S600,获取本地端口对应的ESI并为所述ESI分配标签值,构建表项为所述ESI和所述标签值的本地查询表;Step S600, obtaining the ESI corresponding to the local port and assigning a label value to the ESI, and constructing a local lookup table whose entry is the ESI and the label value;
步骤S700,当接收到所述第二节点转发的BUM封装报文,解封装所述BUM封装报文并确定所述BUM封装报文中的第一标签值;Step S700, when receiving the BUM encapsulated message forwarded by the second node, decapsulate the BUM encapsulated message and determine a first label value in the BUM encapsulated message;
步骤S800,根据所述第一标签值查找所述本地查询表,确定第一ESI;Step S800, look up the local lookup table according to the first tag value, and determine the first ESI;
步骤S900,根据所述第一ESI过滤本地转发端口。Step S900, filtering the local forwarding port according to the first ESI.
与上述应用于第二节点的实施例相对应,本申请实施例应用于第一节点,第一节点需要执行的工作包括解封装第二节点发送过来的BUM封装报文,并定位到该BUM封装报文中的标签值的位置,根据第一标签值来查找得到ESI,从而过滤本地转发端口,即当ESI对应的ES和本地转发端口所在的ES是相同的,则不向该本地转发端口转发BUM报文。Corresponding to the above-mentioned embodiment applied to the second node, the embodiment of the present application is applied to the first node, and the work to be performed by the first node includes decapsulating the BUM encapsulation message sent by the second node, and locating the BUM encapsulation packet. The position of the label value in the packet is searched according to the first label value to obtain the ESI, so as to filter the local forwarding port, that is, when the ES corresponding to the ESI and the ES where the local forwarding port is located are the same, the local forwarding port will not be forwarded. BUM message.
可以理解的是,第一节点还应包括获取本地转发端口所在的ES,并为ES对应的ESI分配标签值,在第一节点向第二节点发送的路由通告中,向第二节点发送ESI和ESI对应的标签值,从而使第二节点建立本申请实施例所需要的转发表。It can be understood that the first node should also obtain the ES where the local forwarding port is located, and assign a label value to the ESI corresponding to the ES. In the routing advertisement sent by the first node to the second node, send the ESI and ESI to the second node. The label value corresponding to the ESI, so that the second node establishes the forwarding table required by the embodiment of the present application.
由于第一节点中为ESI分配的标签值不在传统的标签空间分配(如MPLS标签空间),因此不按照传统标签值的范围进行定义,由于本申请实施例中的标签值要定位到业务标签后才能确定,因此是一种用于为ES实体分配的上下文标签,上下文标签需要依赖每平台标签才能确定其行为,这一特性跟在BUM封装报文中定位到第一标签值的行为相对应。Since the label value allocated for the ESI in the first node is not allocated in the traditional label space (such as MPLS label space), it is not defined according to the range of the traditional label value, because the label value in this embodiment of the present application needs to be located after the service label Therefore, it is a context label for assigning ES entities. The context label needs to rely on each platform label to determine its behavior. This feature corresponds to the behavior of locating the first label value in the BUM encapsulation message.
上述步骤S700中,针对不同的业务类型的BUM封装报文,第一节点需要在解封装BUM封装报文后确定对应的业务类型,才能定位到里面的标签值,具体可以通过以下方式实现:In the above step S700, for BUM-encapsulated packets of different service types, the first node needs to determine the corresponding service type after decapsulating the BUM-encapsulated packets, in order to locate the label value in it, which can be implemented in the following ways:
确定BUM封装报文的EVPN业务类型;Determine the EVPN service type of BUM-encapsulated packets;
当BUM封装报文的业务类型是多协议标签交换MPLS EVPN,匹配到BUM封装报文中的VPN Label,确定VPN Label字段不为标签栈栈底,确定栈底标签为第一标签值;When the service type of the BUM-encapsulated packet is multi-protocol label switching MPLS EVPN, it matches the VPN Label in the BUM-encapsulated packet, confirms that the VPN Label field is not the bottom of the label stack, and determines that the label at the bottom of the stack is the first label value;
当BUM封装报文的业务类型是IPv6分段路由SRv6 EVPN业务报文,定位到SRv6 SID的Function字段,确定Function字段中的Argument字段为第一标签值。When the service type of the BUM encapsulated packet is an IPv6 segment routing SRv6 EVPN service packet, locate the Function field of the SRv6 SID, and determine that the Argument field in the Function field is the first label value.
上述判断过程与第二节点对BUM报文进行封装的过程相对应,在解封装过程中,当业务类型是MPLS EVPN,则匹配到VPN Label,并判断VPN Label是否为栈底标签,如果不是则VPN Label后面的字段为第一标签值。当业务类型是SRv6 EVPN,则定位到SRv6 SID的Function字段,并由Function字段找到Argument字段,从而确定第一标签值。The above judgment process corresponds to the process of encapsulating the BUM packet by the second node. In the decapsulation process, when the service type is MPLS EVPN, the VPN Label is matched, and it is judged whether the VPN Label is a stack bottom label, and if not, then The field after VPN Label is the first label value. When the service type is SRv6 EVPN, locate the Function field of the SRv6 SID, and find the Argument field from the Function field, thereby determining the first tag value.
本申请实施例应用于EVPN多归属场景,第一节点和第二节点作为两个相邻的PE设备连接同一个CE设备,第二节点根据第一节点发送过来的ESI和标签值,以及第一节点的网络端口标识构建转发表,不区分EVPN业务实例,从而减少转发表标签资源的占用。当CE设备向第二节点发送BUM报文情况下,根据第一ESI和第一标签值的对应关系,将查找到的第一标签值封装于BUM报文中的恰当位置,再向第一节点发送,从而使第一节点解封装后根据第一标签值过滤本地转发端口,实现报文破环。The embodiment of the present application is applied to an EVPN multi-homing scenario. The first node and the second node are connected to the same CE device as two adjacent PE devices. The network port identifier of the node constructs the forwarding table, which does not distinguish EVPN service instances, thereby reducing the occupation of label resources in the forwarding table. When the CE device sends a BUM packet to the second node, according to the corresponding relationship between the first ESI and the first label value, the found first label value is encapsulated in an appropriate position in the BUM packet, and then sent to the first node. Then, the first node can filter the local forwarding port according to the first label value after decapsulation, so as to realize the packet loop breaking.
下面以一个实际例子对本申请实施例进行说明:The embodiments of the present application will be described below with an actual example:
参照图4,本示例设置有三个PE设备,分别以A设备、B设备和C设备来表示,三个PE设备两两相邻,其中A设备和B设备属于同一个ES,C设备与B设备不属于同一个ES,A设备和B设备下都设有三条AC,为了方便表示,同一ES下的AC采用相同的名称,分别为AC1(业务类型是MPLS-EVPN1)、AC2(业务类型是MPLS-EVPN2)和AC3(业务类型是SRv6-EVPN3)。Referring to Figure 4, this example is provided with three PE devices, which are represented by A device, B device, and C device respectively. The three PE devices are adjacent to each other, where A device and B device belong to the same ES, and C device and B device. They do not belong to the same ES. There are three ACs under device A and device B. For convenience, the ACs under the same ES have the same names, namely AC1 (the service type is MPLS-EVPN1) and AC2 (the service type is MPLS) -EVPN2) and AC3 (service type is SRv6-EVPN3).
由于A设备和B设备属于同一个ES,那么A设备在独立空间为ES1分配标签值1(为便于说明,示例中的组网只划分出一个ES,以ES1表示,如有多个ES,则可以依次用ES2、ES3、…、ESn表示),由于每个ES都具有唯一的ESI,因此A设备中形成ESI1和标签值1的对应关系(ES2、ES3、…、ESn分别对应有唯一标识ESI2、ESI3、…、ESIn)。Since device A and device B belong to the same ES, device A assigns a tag value of 1 to ES1 in an independent space (for the sake of illustration, the networking in the example only divides one ES, which is represented by ES1. If there are multiple ESs, then It can be represented by ES2, ES3, ..., ESn in turn), since each ES has a unique ESI, the corresponding relationship between ESI1 and label value 1 is formed in the A device (ES2, ES3, ..., ESn respectively correspond to the unique identifier ESI2 , ESI3, …, ESIn).
A设备向B设备发送路由通告,B设备由此得知A设备的IP端口(以IP-a表示)以及ESI1、标签值1以及三个AC对应的EVPN实例信息,B设备通过整理上述信息得到初步过滤表,其条目一共有三个,参见图4,分别是:Device A sends a route advertisement to device B, and device B learns the IP port of device A (represented by IP-a), ESI1, label value 1, and the EVPN instance information corresponding to the three ACs. Device B obtains the information by sorting out the above information. The preliminary filter table has a total of three entries, see Figure 4, which are:
IP-a+ESI1+EVPN1:标签值1IP-a+ESI1+EVPN1: label value 1
IP-a+ESI1+EVPN2:标签值1IP-a+ESI1+EVPN2: label value 1
IP-a+ESI1+EVPN3:标签值1IP-a+ESI1+EVPN3: label value 1
按照本示例的方法精简上述初步过滤表,合并后去掉EVPN业务类型信息,得到构成转发表的条目:According to the method of this example, the above preliminary filter table is simplified, and the EVPN service type information is removed after merging, and the entries that constitute the forwarding table are obtained:
IP-a+ESI1:标签值1IP-a+ESI1: tag value 1
当B设备接收到其中一条AC发送的BUM报文(源端口属于ES1,具有ESI1的值),判断该BUM报文需要向A设备和C设备转发,那么向A设备转发的数据包要进行标签值1的封装。利用上述转发表的条目查找可知,向IP-a发送的对应ESI1的BUM报文,可确定为标签值1,从而将标签值1封装在BUM报文中;当BUM报文的业务类型是MPLS EVPN,则将标签值1压入标签栈底,当BUM报文的业务类型是SRv6 EVPN,则将标签值1填入SID的Argument字段,最终得到BUM封装报文,并向A设备发送。而C设备由于和B设备不属于同一ES,按照常规BUM报文转发方式向C设备发送报文,无需携带标签值。When device B receives a BUM packet sent by one of the ACs (the source port belongs to ES1 and has the value of ESI1), and determines that the BUM packet needs to be forwarded to device A and device C, the data packets forwarded to device A need to be labeled An encapsulation of value 1. Using the entry search in the forwarding table above, we can see that the BUM packet corresponding to ESI1 sent to IP-a can be determined to be the label value 1, so that the label value 1 is encapsulated in the BUM packet; when the service type of the BUM packet is MPLS For EVPN, the label value 1 is pushed to the bottom of the label stack. When the service type of the BUM packet is SRv6 EVPN, the label value 1 is filled in the Argument field of the SID, and the BUM encapsulated packet is finally obtained and sent to device A. However, since device C and device B do not belong to the same ES, they send packets to device C according to the conventional BUM packet forwarding method without carrying the label value.
当A设备接收到BUM封装报文后,解封装确定标签值,对于MPLS EVPN类型的BUM封装报文,若VPN Label不为栈底,则栈底标签为标签值1,对于SRv6 EVPN类型的BUM封装报文,通过Function字段确定业务后,取Argument字段得到标签值1;A设备根据通过解封装得到的标签值1与ESI1的对应关系,过滤掉属于ES1的三条AC线路。After receiving the BUM-encapsulated packet, device A decapsulates the packet to determine the label value. For the BUM-encapsulated packet of MPLS EVPN type, if the VPN Label is not the bottom of the stack, the label at the bottom of the stack is the label value of 1. For the BUM of SRv6 EVPN type After encapsulating the packet, after determining the service through the Function field, take the Argument field to obtain the label value 1; device A filters out the three AC lines belonging to ES1 according to the corresponding relationship between the label value 1 obtained through decapsulation and ESI1.
本申请实施例的还提供了一种设备,包括至少一个处理器和用于与至少一个处理器通信连接的存储器;存储器存储有能够被至少一个处理器执行的指令,指令被至少一个处理器执行,以使至少一个处理器能够执行前述的以太虚拟专用网的数据处理方法。An embodiment of the present application further provides a device, comprising at least one processor and a memory for communicating with the at least one processor; the memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor , so that at least one processor can execute the aforementioned data processing method of the Ethernet virtual private network.
参照图5,以设备1000中的控制处理器1001和存储器1002可以通过总线连接为例。存储器1002作为一种非暂态计算机可读存储介质,可用于存储非暂态软件程序以及非暂态性计算机可执行程序。此外,存储器1002可以包括高速随机存取存储器,还可以包括非暂态存储器,例如至少一个磁盘存储器、闪存器件、或其他非暂态固态存储器件。在一些实施方式中,存储器1002可选包括相对于控制处理器1001远程设置的存储器,这些远程存储器可以通过网络连接至设备1000。上述网络的实例包括但不限于互联网、企业内部网、局域网、移动通信网及其组合。Referring to FIG. 5 , it is taken as an example that the control processor 1001 and the memory 1002 in the device 1000 may be connected through a bus. As a non-transitory computer-readable storage medium, the memory 1002 can be used to store non-transitory software programs and non-transitory computer-executable programs. Additionally, memory 1002 may include high-speed random access memory, and may also include non-transitory memory, such as at least one disk memory, flash memory device, or other non-transitory solid state storage device. In some embodiments, memory 1002 may optionally include memory located remotely from control processor 1001, which may be connected to device 1000 via a network. Examples of such networks include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
本领域技术人员可以理解,图5中示出的装置结构并不构成对设备1000的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。Those skilled in the art can understand that the device structure shown in FIG. 5 does not constitute a limitation on the device 1000, and may include more or less components than the one shown, or combine some components, or arrange different components.
本申请实施例的还提供了一种计算机可读存储介质,该计算机可读存储介质存储有计算机可执行指令,该计算机可执行指令被一个或多个控制处理器执行,例如,被图5中的一个控制处理器1001执行,可使得上述一个或多个控制处理器执行上述方法实施例中的以太虚拟专用网的数据处理方法,例如,执行以上描述的图1中的方法步骤S100至步骤S500、图2中的方法步骤S110至步骤S120和图3中的方法步骤S600至步骤S900。Embodiments of the present application further provide a computer-readable storage medium, where computer-executable instructions are stored in the computer-readable storage medium, and the computer-executable instructions are executed by one or more control processors, for example, as shown in FIG. 5 . The execution of one control processor 1001 of the above-mentioned one or more control processors can cause the above-mentioned one or more control processors to execute the data processing method of the Ethernet virtual private network in the above-mentioned method embodiments, for example, to perform the above-described method steps S100 to S500 in FIG. 1 . , the method steps S110 to S120 in FIG. 2 and the method steps S600 to S900 in FIG. 3 .
本申请实施例提供的以太虚拟专用网的数据处理方法,至少具有如下有益效果:当本地设备双归属于互为相邻节点的第一节点和第二节点并且本地设备向第二节点发送BUM报文,在第二节点接收到BUM报文后,为了避免向第一节点转发该BUM报文时形成报文环路,根据第二节点中保存的第一节点对应的ESI以及该ESI对应的标签值,将标签值封装在该BUM报文中并向第一节点转发。第一节点收到封装过的BUM报文后解封装,并定位到该标签值所在的字段,根据第一节点中保存ESI和标签值的对应关系,过滤本地转发端口,避免报文成环。本申请实施例在对BUM报文转发时不需要区分BUM报文的EVPN业务实例,从而精简了转发表尺寸,能够降低转发表资源的占用。The data processing method for an Ethernet virtual private network provided by the embodiment of the present application has at least the following beneficial effects: when the local device is dual-homed to the first node and the second node that are mutually adjacent nodes, and the local device sends a BUM message to the second node message, after the second node receives the BUM message, in order to avoid the formation of a message loop when forwarding the BUM message to the first node, according to the ESI corresponding to the first node and the label corresponding to the ESI stored in the second node value, encapsulate the label value in the BUM packet and forward it to the first node. After receiving the encapsulated BUM packet, the first node decapsulates the packet, locates the field where the label value is located, and filters the local forwarding port according to the corresponding relationship between the ESI and the label value stored in the first node to prevent the packet from forming a loop. The embodiment of the present application does not need to distinguish the EVPN service instance of the BUM packet when forwarding the BUM packet, thereby reducing the size of the forwarding table and reducing the occupation of forwarding table resources.
以上所描述的装置实施例仅仅是示意性的,其中作为分离部件说明的单元可以是或者也可以不是物理上分开的,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目的。The apparatus embodiments described above are only illustrative, and the units described as separate components may or may not be physically separated, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution in this embodiment.
本领域普通技术人员可以理解,上文中所公开方法中的全部或某些步骤、系统可以被实施为软件、固件、硬件及其适当的组合。某些物理组件或所有物理组件可以被实施为由处理器,如中央处理器、数字信号处理器或微处理器执行的软件,或者被实施为硬件,或者被实施为集成电路,如专用集成电路。这样的软件可以分布在计算机可读介质上,计算机可读介质可以包括计算机存储介质(或非暂时性介质)和通信介质(或暂时性介质)。如本领域普通技术人员公知的,术语计算机存储介质包括在用于存储信息(诸如计算机可读指令、数据结构、程序模块或其他数据)的任何方法或技术中实施的易失性和非易失性、可移除和不可移除介质。计算机存储介质包括但不限于RAM、ROM、EEPROM、闪存或其他存储器技术、CD-ROM、数字多功能盘(DVD)或其他光盘存储、磁盒、磁带、磁盘存储或其他磁存储装置、或者可以用于存储期望的信息并且可以被计算机访问的任何其他的介质。此外,本领域普通技术人员 公知的是,通信介质通常包含计算机可读指令、数据结构、程序模块或者诸如载波或其他传输机制之类的调制数据信号中的其他数据,并且可包括任何信息递送介质。Those of ordinary skill in the art can understand that all or some of the steps and systems in the methods disclosed above can be implemented as software, firmware, hardware, and appropriate combinations thereof. Some or all physical components may be implemented as software executed by a processor, such as a central processing unit, digital signal processor or microprocessor, or as hardware, or as an integrated circuit, such as an application specific integrated circuit . Such software may be distributed on computer-readable media, which may include computer storage media (or non-transitory media) and communication media (or transitory media). As known to those of ordinary skill in the art, the term computer storage media includes both volatile and nonvolatile implemented in any method or technology for storage of information, such as computer readable instructions, data structures, program modules or other data flexible, removable and non-removable media. Computer storage media include, but are not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disk (DVD) or other optical disk storage, magnetic cartridges, magnetic tape, magnetic disk storage or other magnetic storage devices, or may Any other medium used to store desired information and which can be accessed by a computer. In addition, communication media typically embodies computer readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and can include any information delivery media, as is well known to those of ordinary skill in the art .
以上是对本申请的较佳实施进行了具体说明,但本申请并不局限于上述实施方式,熟悉本领域的技术人员在不违背本申请精神的前提下还可作出种种的等同变形或替换,这些等同的变形或替换均包含在本申请权利要求所限定的范围内。The above is a specific description of the preferred implementation of the application, but the application is not limited to the above-mentioned embodiments. Those skilled in the art can also make various equivalent deformations or replacements on the premise of not violating the spirit of the application. These Equivalent modifications or substitutions are included within the scope defined by the claims of the present application.

Claims (10)

  1. 一种以太虚拟专用网的数据处理方法,所述以太虚拟专用网包括互为相邻节点的第一节点和第二节点,所述数据处理方法应用于所述第二节点,包括:A data processing method for an Ethernet virtual private network, wherein the Ethernet virtual private network includes a first node and a second node that are adjacent nodes to each other, and the data processing method is applied to the second node, comprising:
    接收所述第一节点发送的路由通告并根据所述路由通告得到路由信息,所述路由信息包括以太网段标识ESI和与所述ESI对应的标签值;Receive a routing advertisement sent by the first node and obtain routing information according to the routing advertisement, where the routing information includes an Ethernet segment identifier ESI and a label value corresponding to the ESI;
    基于相同的ESI将所述路由信息合并,得到转发表,所述转发表的每个转发表项由所述第一节点的网络端口标识、所述ESI和所述标签值构成;Combining the routing information based on the same ESI to obtain a forwarding table, each forwarding table entry of the forwarding table is composed of the network port identifier of the first node, the ESI and the label value;
    当向所述第一节点转发广播、未知单播、组播BUM报文,以所述第一节点的网络端口标识和所述BUM报文的源端口对应的第一ESI查找所述转发表,确定第一标签值;When forwarding a broadcast, unknown unicast, and multicast BUM message to the first node, the forwarding table is searched with the network port identifier of the first node and the first ESI corresponding to the source port of the BUM message, determine the first tag value;
    根据所述BUM报文的封装结构将所述第一标签值封装在所述BUM报文中,得到BUM封装报文;以及Encapsulating the first label value in the BUM packet according to the encapsulation structure of the BUM packet to obtain a BUM encapsulation packet; and
    将所述BUM封装报文转发到所述第一节点,以使所述第一节点解封装所述BUM封装报文并根据解封装所得的所述第一标签值过滤本地转发端口。The BUM-encapsulated message is forwarded to the first node, so that the first node decapsulates the BUM-encapsulated message and filters a local forwarding port according to the decapsulated first label value.
  2. 根据权利要求1所述的以太虚拟专用网的数据处理方法,其中,所述路由信息还包括所述第一节点的网络端口标识和所述第一节点基于以太虚拟专用网EVPN实例发布的EVPN实例信息。The data processing method for an Ethernet virtual private network according to claim 1, wherein the routing information further comprises a network port identifier of the first node and an EVPN instance published by the first node based on the Ethernet virtual private network EVPN instance information.
  3. 根据权利要求2所述的以太虚拟专用网的数据处理方法,其中,所述基于相同的ESI将所述路由信息合并,得到转发表,包括:The data processing method for an Ethernet virtual private network according to claim 2, wherein the routing information is combined based on the same ESI to obtain a forwarding table, comprising:
    根据所述路由信息形成初步过滤表,所述初步过滤表的每个过滤表项由所述第一节点的网络端口标识、所述EVPN实例信息、所述ESI和所述标签值构成;以及A preliminary filtering table is formed according to the routing information, and each filtering table entry of the preliminary filtering table is composed of the network port identifier of the first node, the EVPN instance information, the ESI and the label value; and
    将具有相同ESI的所述过滤表项合并从而去掉所述EVPN实例信息,得到转发表。The filtering table entries with the same ESI are combined to remove the EVPN instance information to obtain a forwarding table.
  4. 根据权利要求2或3所述的以太虚拟专用网的数据处理方法,其中,所述网络端口标识为IP地址。The data processing method for an Ethernet virtual private network according to claim 2 or 3, wherein the network port identifier is an IP address.
  5. 根据权利要求1所述的以太虚拟专用网的数据处理方法,其中,所述根据所述BUM报文的封装结构将所述第一标签值封装在所述BUM报文中,包括:The data processing method for an Ethernet virtual private network according to claim 1, wherein the encapsulating the first label value in the BUM packet according to the encapsulation structure of the BUM packet, comprising:
    当所述BUM报文的业务类型符合预设业务类型,根据预设业务类型对应的报文封装结构确定所述第一标签值的封装位置。When the service type of the BUM packet conforms to the preset service type, the encapsulation position of the first label value is determined according to the packet encapsulation structure corresponding to the preset service type.
  6. 根据权利要求5所述的以太虚拟专用网的数据处理方法,其中,所述根据预设业务类型对应的报文封装结构确定所述第一标签值的封装位置,包括:The data processing method for an Ethernet virtual private network according to claim 5, wherein the determining the encapsulation position of the first label value according to the packet encapsulation structure corresponding to the preset service type comprises:
    当所述BUM报文的业务类型是多协议标签交换MPLS EVPN,根据MPLS EVPN对应的报文封装结构,将所述第一标签值置于所述封装结构中VPN Label后面的字段;以及When the service type of the BUM message is multi-protocol label switching MPLS EVPN, according to the message encapsulation structure corresponding to MPLS EVPN, the first label value is placed in the field behind the VPN Label in the encapsulation structure; and
    当所述BUM报文是IPv6分段路由SRv6 EVPN业务报文,根据SRv6 EVPN业务报文的封装结构,将所述第一标签值填入所述封装结构中SRv6 SID的Argument字段。When the BUM message is an IPv6 segment routing SRv6 EVPN service message, according to the encapsulation structure of the SRv6 EVPN service message, the first label value is filled in the Argument field of the SRv6 SID in the encapsulation structure.
  7. 一种以太虚拟专用网的数据处理方法,所述以太虚拟专用网包括互为相邻节点的第一节点和第二节点,所述数据处理方法应用于所述第一节点,所述述数据处理方法包括:A data processing method for an Ethernet virtual private network, the Ethernet virtual private network includes a first node and a second node that are adjacent nodes to each other, the data processing method is applied to the first node, and the data processing Methods include:
    获取本地端口对应的ESI并为所述ESI分配标签值,构建表项为所述ESI和所述标签值的本地查询表;Obtain the ESI corresponding to the local port and assign a label value to the ESI, and construct a local lookup table whose entry is the ESI and the label value;
    当接收到所述第二节点转发的BUM封装报文,解封装所述BUM封装报文并确定所述BUM封装报文中的第一标签值;When receiving the BUM-encapsulated message forwarded by the second node, decapsulate the BUM-encapsulated message and determine the first label value in the BUM-encapsulated message;
    根据所述第一标签值查找所述本地查询表,确定第一ESI;以及Look up the local lookup table according to the first tag value to determine the first ESI; and
    根据所述第一ESI过滤本地转发端口。The local forwarding port is filtered according to the first ESI.
  8. 根据权利要求7所述的以太虚拟专用网的数据处理方法,其中,所述解封装所述BUM封装报文并确定所述BUM封装报文中的第一标签值,包括:The data processing method for an Ethernet virtual private network according to claim 7, wherein the decapsulating the BUM encapsulation packet and determining the first label value in the BUM encapsulation packet comprises:
    确定所述BUM封装报文的EVPN业务类型;Determine the EVPN service type of the BUM encapsulated message;
    当所述BUM封装报文的业务类型是多协议标签交换MPLS EVPN,匹配到所述BUM封装报文中的VPN Label,确定所述VPN Label字段不为标签栈栈底,确定栈底标签为第一标签值;以及When the service type of the BUM encapsulated message is multi-protocol label switching MPLS EVPN, it is matched to the VPN Label in the BUM encapsulated message, it is determined that the VPN Label field is not the bottom of the label stack, and it is determined that the label at the bottom of the stack is the first a tag value; and
    当所述BUM封装报文的业务类型是IPv6分段路由SRv6 EVPN业务报文,定位到SRv6 SID的Function字段,确定Function字段中的Argument字段为第一标签值。When the service type of the BUM encapsulation message is an IPv6 segment routing SRv6 EVPN service message, locate the Function field of the SRv6 SID, and determine that the Argument field in the Function field is the first label value.
  9. 一种设备,包括至少一个处理器和用于与所述至少一个处理器通信连接的存储器,其中,所述存储器存储有能够被所述至少一个处理器执行的指令,所述指令被所述至少一个处理器执行,以使所述至少一个处理器能够执行如权利要求1至6中任意一项所述的以太虚拟专用网的数据处理方法或者执行如权利要求7或8的以太虚拟专用网的数据处理方法。An apparatus comprising at least one processor and a memory for communicative connection with the at least one processor, wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor One processor executes, so that the at least one processor can execute the data processing method of the Ethernet virtual private network as claimed in any one of claims 1 to 6 or execute the Ethernet virtual private network as claimed in claim 7 or 8. data processing method.
  10. 一种计算机可读存储介质,所述计算机可读存储介质存储有计算机可执行指令,所述计算机可执行指令用于使计算机执行如权利要求1至6中任意一项所述的以太虚拟专用网的数据处理方法或者执行如权利要求7或8的以太虚拟专用网的数据处理方法。A computer-readable storage medium storing computer-executable instructions for causing a computer to execute the Ethernet virtual private network according to any one of claims 1 to 6 The data processing method or the data processing method of the Ethernet virtual private network according to claim 7 or 8 is implemented.
PCT/CN2021/121710 2020-12-07 2021-09-29 Data processing method and device for ethernet virtual private network, and storage medium WO2022121466A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202011417069.6A CN114666267A (en) 2020-12-07 2020-12-07 Data processing method, equipment and storage medium of Ethernet virtual private network
CN202011417069.6 2020-12-07

Publications (1)

Publication Number Publication Date
WO2022121466A1 true WO2022121466A1 (en) 2022-06-16

Family

ID=81974042

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/121710 WO2022121466A1 (en) 2020-12-07 2021-09-29 Data processing method and device for ethernet virtual private network, and storage medium

Country Status (2)

Country Link
CN (1) CN114666267A (en)
WO (1) WO2022121466A1 (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115037690A (en) * 2022-06-21 2022-09-09 阿里巴巴(中国)有限公司 Traffic scheduling method and device, electronic equipment and storage medium
CN115277309A (en) * 2022-07-26 2022-11-01 中国电信股份有限公司 Message forwarding method and device, storage medium and electronic equipment
WO2024082462A1 (en) * 2022-10-21 2024-04-25 锐捷网络股份有限公司 Service forwarding method and apparatus, and electronic device

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117640505A (en) * 2022-08-09 2024-03-01 中兴通讯股份有限公司 Data message processing method and device, storage medium and electronic device

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104135420A (en) * 2014-07-31 2014-11-05 华为技术有限公司 A method, apparatus and system for forwarding message
CN105099846A (en) * 2014-04-30 2015-11-25 华为技术有限公司 Method of transmitting data messages and provider edge (PE) devices
CN106254244A (en) * 2016-07-28 2016-12-21 上海斐讯数据通信技术有限公司 A kind of merging stream list item method based on SDN
CN108259291A (en) * 2016-12-29 2018-07-06 华为技术有限公司 VXLAN message processing methods, equipment and system
CN108809847A (en) * 2017-05-05 2018-11-13 华为技术有限公司 Realize the method, apparatus and network system of load balancing
WO2019119220A1 (en) * 2017-12-18 2019-06-27 Telefonaktiebolaget Lm Ericsson (Publ) Provider edge device and method implemented thereon for ethernet virtual private network
US10841216B1 (en) * 2017-03-29 2020-11-17 Juniper Networks, Inc. Local-bias forwarding of L2 multicast, unknown unicast, and broadcast traffic for an ethernet VPN

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105099846A (en) * 2014-04-30 2015-11-25 华为技术有限公司 Method of transmitting data messages and provider edge (PE) devices
CN104135420A (en) * 2014-07-31 2014-11-05 华为技术有限公司 A method, apparatus and system for forwarding message
CN106254244A (en) * 2016-07-28 2016-12-21 上海斐讯数据通信技术有限公司 A kind of merging stream list item method based on SDN
CN108259291A (en) * 2016-12-29 2018-07-06 华为技术有限公司 VXLAN message processing methods, equipment and system
US10841216B1 (en) * 2017-03-29 2020-11-17 Juniper Networks, Inc. Local-bias forwarding of L2 multicast, unknown unicast, and broadcast traffic for an ethernet VPN
CN108809847A (en) * 2017-05-05 2018-11-13 华为技术有限公司 Realize the method, apparatus and network system of load balancing
WO2019119220A1 (en) * 2017-12-18 2019-06-27 Telefonaktiebolaget Lm Ericsson (Publ) Provider edge device and method implemented thereon for ethernet virtual private network

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
P. BRISSETTE, ED. A. SAJASSI L. BURDET CISCO SYSTEMS D. VOYER BELL CANADA: "EVPN Multi-Homing Mechanism for Layer-2 Gateway Protocols; draft-brissette-bess-evpn-l2gw-proto-05.txt", EVPN MULTI-HOMING MECHANISM FOR LAYER-2 GATEWAY PROTOCOLS; DRAFT-BRISSETTE-BESS-EVPN-L2GW-PROTO-05.TXT; INTERNET-DRAFT: BESS WORKING GROUP, INTERNET ENGINEERING TASK FORCE, IETF; STANDARDWORKINGDRAFT, INTERNET SOCIETY (ISOC) 4, RUE DES FALAISES CH- 1, no. 05, 4 November 2019 (2019-11-04), Internet Society (ISOC) 4, rue des Falaises CH- 1205 Geneva, Switzerland , pages 1 - 12, XP015136093 *

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115037690A (en) * 2022-06-21 2022-09-09 阿里巴巴(中国)有限公司 Traffic scheduling method and device, electronic equipment and storage medium
CN115277309A (en) * 2022-07-26 2022-11-01 中国电信股份有限公司 Message forwarding method and device, storage medium and electronic equipment
WO2024082462A1 (en) * 2022-10-21 2024-04-25 锐捷网络股份有限公司 Service forwarding method and apparatus, and electronic device

Also Published As

Publication number Publication date
CN114666267A (en) 2022-06-24

Similar Documents

Publication Publication Date Title
WO2022121466A1 (en) Data processing method and device for ethernet virtual private network, and storage medium
CN109995634B (en) Bearing method and equipment for multicast virtual private network
US8898334B2 (en) System for network deployment and method for mapping and data forwarding thereof
WO2016101646A1 (en) Access method and apparatus for ethernet virtual network
US20160036773A1 (en) Internet protocol address resolution
US11792044B2 (en) Offset label for aggregating multicasts from multiple virtual private networks on a single multicast distribution tree
CN104660508A (en) Message forwarding method and device
US10148458B2 (en) Method to support multi-protocol for virtualization
WO2015165311A1 (en) Method for transmitting data packet and provider edge device
US10187293B2 (en) Apparatus and method for multicast data packet forwarding
CN108964940B (en) Message sending method and device and storage medium
CN106453025A (en) Tunnel creating method and device
CN110798403B (en) Communication method, communication device and communication system
CN112511444A (en) Multicast traffic transmission method, device, communication node and storage medium
US11962491B2 (en) Source routing tunnel ingress protection
US20230300070A1 (en) Packet Sending Method, Device, and System
CN110417655B (en) Method and device for forwarding data message
CN108156067B (en) Method and system for realizing Ethernet-based virtual private network
WO2013139270A1 (en) Method, device, and system for implementing layer3 virtual private network
CN113132235A (en) Data message processing method based on virtual circuit and construction method of forwarding table item
CN108494686A (en) Route processing method and device
WO2021052381A1 (en) Message sending method and apparatus
CN110620715B (en) Virtual extended local area network communication method, tunnel endpoint and controller
US20230081052A1 (en) Method and apparatus for sending multicast packet
CN108881024B (en) Multicast traffic forwarding method and device

Legal Events

Date Code Title Description
NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205 DATED 03/11/2023)