CN118055017A - Ethernet segment identifier processing method and device - Google Patents

Ethernet segment identifier processing method and device Download PDF

Info

Publication number
CN118055017A
CN118055017A CN202211438346.0A CN202211438346A CN118055017A CN 118055017 A CN118055017 A CN 118055017A CN 202211438346 A CN202211438346 A CN 202211438346A CN 118055017 A CN118055017 A CN 118055017A
Authority
CN
China
Prior art keywords
ethernet segment
segment identifier
target
format
format type
Prior art date
Legal status (The legal status 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 status listed.)
Pending
Application number
CN202211438346.0A
Other languages
Chinese (zh)
Inventor
舒晔
艾青
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
ZTE Corp
Original Assignee
ZTE Corp
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 ZTE Corp filed Critical ZTE Corp
Priority to CN202211438346.0A priority Critical patent/CN118055017A/en
Priority to PCT/CN2023/106169 priority patent/WO2024103806A1/en
Publication of CN118055017A publication Critical patent/CN118055017A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0803Configuration setting
    • H04L41/084Configuration by using pre-existing information, e.g. using templates or copying from other elements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/085Retrieval of network configuration; Tracking network configuration history
    • H04L41/0853Retrieval of network configuration; Tracking network configuration history by actively collecting configuration information or by backing up configuration information

Landscapes

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

Abstract

The embodiment of the application provides a method and a device for processing an Ethernet segment identifier, wherein the method comprises the following steps: the Ethernet segment identifier ESID of the Ethernet segment ES is configured, the format type corresponding to the Ethernet segment identifier ESID is configured, the Ethernet segment identifier ESID is converted into the target Ethernet segment identifier ESID with a preset format according to the format type, and the border gateway protocol BGP message carrying the format type and the target Ethernet segment identifier ESID is issued to the EVPN network, so that a far-end operator edge router PE in the EVPN network analyzes the BGP message to obtain the Ethernet segment identifier ESID. The application can solve the problems that the Ethernet segment identifiers ESID planned by different operators in the related technology are different in form and cannot be displayed according to the original intention of the user, realizes that the Ethernet segment identifiers ESID are always displayed according to the original requirement of the user, simplifies the workflow of planning and deploying the Ethernet segment identifiers ESID by the user, and saves the planning and deploying time.

Description

Ethernet segment identifier processing method and device
Technical Field
The present application relates to the field of communications, and in particular, to a router and a switch product, and more particularly, to a method and an apparatus for processing an ethernet segment identifier.
Background
The ethernet virtual private network (Ethernet Virtual Private Network, abbreviated as EVPN) is a technology of a virtual private network (Virtual Private Network, abbreviated as VPN) interconnected by two-layer networks, and the EVPN technology transfers media access Control (MEDIA ACCESS Control, abbreviated as MAC)/address resolution protocol (Address Resolution Protocol, abbreviated as ARP)/routing information between two-layer networks by establishing multiprotocol border gateway protocol neighbors, and performs two-layer or three-layer message forwarding through the generated address forwarding table entry, that is, the transfer of entries such as MAC, ARP, routing, etc. is completed independent of a data plane, but is completed through the EVPN Control plane.
In the EVPN technology, an ethernet segment (ETHERNET SEGMENT, abbreviated as ES) is used for multi-homing protection of a two-layer EVPN; the related Route types include RT1 (Ethernet Auto-Discovery Route ), RT2 (MAC/IP address advertisement Route, MAC/IP ADVERTISEMENT Route), RT4 (Ethernet segment Route ); the RT1/RT2/RT4 routing messages are provided with Ethernet segment identifiers (ETHERNET SEGMENT IDENTIFIER, ESI or ESID for short), the ESI is 10 16-system bytes, such as (00.11.22.33.44.55.66.77.88.99), the RT1 routing messages form an ESI forwarding protection according to the ESI, the RT2 routing messages point to the ESI forwarding formed by RT1 according to the ESI in the messages, the RT4 routing messages carry out DF election according to the ESI, and the Ethernet segment identifiers ESI require the whole network to be unique.
In the prior art, the Ethernet segment to which the message belongs can be effectively judged according to the ESI index carried in the routing message, and the corresponding ESI forwarding is formed, but the original 16-system ESI configuration mode brings huge workload to the Ethernet segment planning work in engineering deployment; and a single 16 system cannot meet the requirements of multiple forms of Ethernet segment planning of different users, and when the forms of Ethernet segment identifiers planned by different operators are different, the Ethernet segment identifiers cannot be displayed according to the original user will in the prior art.
Disclosure of Invention
The embodiment of the application provides a method and a device for processing Ethernet segment identifiers, a storage medium and an electronic device, which are used for at least solving the problems that the Ethernet segment identifiers planned by different operators in the related technology are different in form and cannot be displayed according to the original intention of a user.
According to an embodiment of the present application, there is provided an ethernet segment identifier processing method, including:
Configuring an Ethernet segment identifier of the Ethernet segment;
configuring a format type corresponding to the Ethernet segment identifier;
Converting the Ethernet segment identifier into a target Ethernet segment identifier with a preset format according to the format type;
And issuing a Border Gateway Protocol (BGP) message carrying the format type and the target Ethernet segment identifier to an EVPN network so that a remote operator edge router (PE) in the EVPN network analyzes the BGP message to obtain the Ethernet segment identifier.
According to another embodiment of the present application, there is provided an ethernet segment identifier processing method, including:
Receiving a Border Gateway Protocol (BGP) message issued by an operator edge router (PE) from an EVPN network, wherein the BGP message carries the format type of an Ethernet segment identifier and a target Ethernet segment identifier in a preset format;
Extracting the format type and the target Ethernet segment identifier from the BGP message;
and analyzing the target Ethernet segment identifier according to the format type to obtain the Ethernet segment identifier.
According to still another embodiment of the present application, there is also provided an ethernet segment identifier processing apparatus, including:
a configuration module, configured to configure an ethernet segment identifier of the located ethernet segment;
The configuration module is further configured to configure a format type corresponding to the ethernet segment identifier;
The conversion module is used for converting the Ethernet segment identifier into a target Ethernet segment identifier with a preset format according to the format type;
And the issuing module is used for issuing a Border Gateway Protocol (BGP) message carrying the format type and the target Ethernet segment identifier to an EVPN network so that a remote operator edge router (PE) in the EVPN network can analyze the BGP message to obtain the Ethernet segment identifier.
According to still another embodiment of the present application, there is also provided an ethernet segment identifier processing apparatus, including:
The receiving module is used for receiving a Border Gateway Protocol (BGP) message issued by an operator edge router (PE) from an EVPN network, wherein the BGP message carries the format type of an Ethernet segment identifier and a target Ethernet segment identifier in a preset format;
An extracting module, configured to extract the format type and the target ethernet segment identifier from the BGP packet;
And the analysis module is used for analyzing the target Ethernet segment identifier according to the format type to obtain the Ethernet segment identifier.
According to a further embodiment of the present application, there is also provided a computer-readable storage medium having stored therein a computer program, wherein the computer program, when executed by a processor, performs the steps of any of the method embodiments described above.
According to a further embodiment of the application, there is also provided an electronic device comprising a memory having stored therein a computer program and a processor arranged to run the computer program to perform the steps of any of the method embodiments described above.
In the embodiment of the application, the Ethernet segment identifier of the Ethernet segment is configured at the local router, the format type corresponding to the Ethernet segment identifier is configured, the Ethernet segment identifier is converted into the target Ethernet segment identifier with the preset format according to the format type, the Border Gateway Protocol (BGP) message carrying the format type and the target Ethernet segment identifier is issued to the EVPN network, and then the BGP message is received and analyzed at the far-end router to obtain the Ethernet segment identifier configured by the user. The scheme can solve the problems that the Ethernet segment identifiers planned by different operators in the related technology are different in form and cannot be displayed according to the original intention of the user, realizes that the Ethernet segment identifiers are always displayed according to the original requirement of the user, simplifies the workflow of planning and deploying the Ethernet segment identifiers by the user, and saves the planning and deploying time.
Drawings
FIG. 1 is a flow chart of a method of Ethernet segment identifier processing according to an embodiment of the application;
FIG. 2 is a flow chart of a method of Ethernet segment identifier processing according to another embodiment of the application;
Fig. 3 is a schematic diagram of formats of two BGP messages according to an embodiment of the present application;
FIG. 4 is a schematic diagram of triple encoding for carrying format types in an embodiment of the present application;
Fig. 5 is a schematic diagram of an EVPN network according to an embodiment of the present application;
fig. 6 is a schematic diagram of an EVPN network according to another embodiment of the present application;
FIG. 7 is a block diagram of an Ethernet segment identifier processing device according to an embodiment of the application;
fig. 8 is a block diagram of another ethernet segment identifier processing device in accordance with an embodiment of the present application.
Detailed Description
Embodiments of the present application will be described in detail below with reference to the accompanying drawings in conjunction with the embodiments.
It should be noted that the terms "first," "second," and the like in the description and the claims of the present application and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order.
In this embodiment, an ethernet segment identifier processing method running on a router or a switch is provided, fig. 1 is a flowchart of the ethernet segment identifier processing method according to an embodiment of the present application, and the ethernet segment identifier processing method is applied to an operator edge router, as shown in fig. 1, where the flowchart includes the following steps:
step S102, an Ethernet segment identifier of the Ethernet segment is configured;
Step S104, configuring a format type corresponding to the Ethernet segment identifier;
step S106, converting the Ethernet segment identifier into a target Ethernet segment identifier with a preset format according to the format type;
step S108, the border gateway protocol BGP message carrying the format type and the target Ethernet segment identifier is issued to the EVPN network, so that a remote operator edge router PE in the EVPN network analyzes the BGP message to obtain the Ethernet segment identifier.
In this embodiment, before step S102, an EVPN two-layer VPLS instance needs to be configured for a local PE and a remote PE, where the EVPN network includes a remote PE and a local PE, where the remote PE and the local PE communicate through BGP messages, and multiple local PEs are connected to a local customer network edge device CE through ethernet links respectively, and multiple ethernet links connected to the same local CE belong to the same ethernet segment.
Specifically, the ethernet virtual private network (Ethernet Virtual Private Network, EVPN) includes a Provider Edge (PE) and a Customer Edge (CE), where each CE may be connected to two or more PEs by the EVPN multi-homing technique, where the PE connected to the local CE is a local PE, and the other PEs not connected to the local CE are remote PEs.
In this embodiment, in the step S102, the ethernet segment identifier may be configured in various forms, for example, using an IPv4 address and a MAC address, or may be directly configured into a preset format.
Specifically, the IPv4 address is 4 bytes 10, for example: 101.102.103.104, the mac address is 6 bytes 16, for example: 0001.0002.0003, both the ipv4 address and the MAC address are in a non-default format, the default format being 10 bytes 16 bytes, such as 00.11.22.33.44.55.66.77.88.99.
Further, the ethernet segment identifier is a unique identifier of the whole network, and since there may be multiple local CEs with the same IPv4 address or the same MAC address, when the ethernet segment is configured by using the IPv4 address or the MAC address, a unique identifier is further added as the ethernet segment number X, for example, IPv4: x or MAC: x is a metal alloy.
In this embodiment, the step S104 may specifically include:
When the Ethernet segment identifier is in a preset format of 10 bytes 16 system, configuring the format type to be 0;
When the Ethernet segment identifier comprises an IPv4 address and an Ethernet segment number, configuring the format type as 1;
When the Ethernet segment identifier comprises a MAC address and an Ethernet segment number, configuring the format type as 2;
the IPv4 address is in a non-preset format of 4 bytes and 10 system, the MAC address is in a non-preset format of 6 bytes and 16 system, the Ethernet segment number is a local unique identification, and the format is 2 bytes and 10 system bytes. The correspondence between the ethernet segment identifier and the format type in the embodiment of the present application is merely used as an example, and is not limited to the above three configuration manners.
In this embodiment, the above step S106 may be specifically divided into the following cases:
if the format type is 0, directly taking the Ethernet segment identifier of the preset format as the target Ethernet segment identifier;
If the format type is 1, converting the IPv4 address and the Ethernet segment number into a target Ethernet segment identifier of the preset format;
And if the format type is 2, converting the MAC address and the Ethernet segment number into the target Ethernet segment identifier with the preset format.
In this embodiment, when the format type is 1, converting the iPv4 address and the ethernet segment number into the target ethernet segment identifier in the preset format may specifically include: converting the IPv4 address into hexadecimal, and taking the obtained lPv th bit byte to 5 th bit byte of the target Ethernet segment identifier as the result of converting the lPv th bit address; converting the Ethernet segment number into hexadecimal, and taking the obtained Ethernet segment number conversion result as the 6 th to 7 th bytes of the target Ethernet segment identifier; setting the 1 st bit byte and 8 th to 10 th bit bytes remaining in the target ethernet segment identifier as preset bytes.
Specifically, the preset byte may be 00, or may be set to other hexadecimal bytes.
In this embodiment, when the format type is 2, converting the MAC address and the ethernet segment number into the target ethernet segment identifier in the preset format may specifically include: setting bits 2 to 7 of the destination ethernet segment identifier as the MAC address; converting the Ethernet segment number into hexadecimal, and taking the obtained Ethernet segment number conversion result as the 8 th to 9 th bytes of the target Ethernet segment identifier; and setting the 1 st bit byte and the 10 th bit byte remained in the target Ethernet segment identifier as preset bytes.
In this embodiment, before step S108, the method further includes: adding a TLV triple structure for carrying the format type in the BGP message, wherein the BGP message comprises a target Ethernet segment identifier with a preset format, and the BGP message comprises one of the following components: the Ethernet automatically discovers the routing message, the MAC address or the IP address announces the routing message and the Ethernet segment routing message.
Specifically, the TLV is one of basic coding rules (BasicEncoding Rules, abbreviated BER) codes, and the TLV is fully called as corresponding to Tag, length, value, respectively. The embodiment of the application adds an extra TLV structure to the routing message originally carrying ESI to carry the format type.
The embodiment of the application reduces the workload of the planning and configuration flow of the Ethernet segment identifier through the steps S102 to S108, and can also utilize the target Ethernet segment identifier with a preset format which is automatically generated by the existing MAC address or IPv4 address information of the local CE equipment, thereby simplifying the Ethernet segment deployment flow and saving the user time.
Fig. 2 is a flowchart of a method for processing an ethernet segment identifier according to another embodiment of the present application, which is applied to another PE or a remote PE adjacent to the above-mentioned operator edge router PE, as shown in fig. 1, and includes the following steps:
Step S202, receiving a Border Gateway Protocol (BGP) message issued by an operator edge router (PE) from an EVPN network, wherein the BGP message carries the format type of an Ethernet segment identifier and a target Ethernet segment identifier in a preset format;
step S204, extracting the format type and the target Ethernet segment identifier from the BGP message;
step S206, analyzing the target Ethernet segment identifier according to the format type to obtain the Ethernet segment identifier.
In this embodiment, the BGP message in step S202 includes one of the following: the Ethernet automatically discovers the routing message, the MAC address or the IP address announces the routing message and the Ethernet segment routing message; specifically, the BGP message further includes a TLV triplet structure for carrying the format type.
In this embodiment, the target ethernet segment identifier in step S204 is in a preset format of 10 bits 16, for example: 00.11.22.33.44.55.66.77.88.99.
In this embodiment, the step S206 may be specifically divided into several cases:
if the format type is 0, directly taking the target Ethernet segment identifier as an Ethernet segment identifier with a preset format, wherein the preset format is 10-bit 16-system bytes;
If the format type is 1, the Ethernet segment identifier comprises an IPv4 address and an Ethernet segment number, and the target Ethernet segment identifier is analyzed to obtain the IPv4 address and the Ethernet segment number, wherein the IPv4 address is in a non-preset format of 4-bit 10 system, and the Ethernet segment number is a local unique identifier;
if the format type is 2, the ethernet segment identifier includes a MAC address and an ethernet segment number, and the target ethernet segment identifier is parsed to obtain the MAC address and the ethernet segment number, where the MAC address is a non-preset format with a 6-bit 16-ary system.
In this embodiment, when the format type is 1, resolving the target ethernet segment identifier to obtain the IPv4 address and the ethernet segment number may specifically include: converting the 2 nd to 5 th bit bytes of the target Ethernet segment identifier into decimal, and obtaining the IPv4 address; and converting the 6 th to 7 th bytes of the target Ethernet segment identifier into decimal, and obtaining the Ethernet segment number.
In this embodiment, when the format type is 2, resolving the target ethernet segment identifier to obtain the MAC address and the ethernet segment number may specifically include: extracting bits 2 to 7 of the target ethernet segment identifier as the MAC address; and converting the 8 th to 9 th bytes of the target Ethernet segment identifier into decimal, and obtaining the Ethernet segment number.
In this embodiment, after step S206, in any information visible to the user, such as a message or a forwarding table, the ethernet segment identifier and the ethernet segment number obtained by parsing in step S206 are used to replace the original target ethernet segment identifier in the preset format.
In this embodiment, through the steps S202 to S206, real-time format conversion of the received routing message can be implemented, and the ethernet segment identifiers are displayed in the format type originally configured by the user, so that the user can know which ethernet segments have been deployed, and the workload of planning and deployment is reduced. And when different users perform Ethernet segment deployment in different forms, the Ethernet segment identifier can be always displayed at the original user will.
Fig. 3 is a schematic diagram of formats of two BGP messages according to an embodiment of the present application, where, as shown in fig. 3, both the RT1 route and the RT4 route messages include a 10-byte ethernet segment identifier (ETHERNET SEGMENT IDENTIFIER, ESI for short).
In this embodiment, an Ethernet Auto-Discovery Route (RT 1) is used to notify other PEs whether the access point is reachable by the home PE, a MAC/IP address notification Route (MAC/IP ADVERTISEMENT Route, RT 2) is used to issue reachable information of unicast MAC/IP addresses from the home PE to other PEs, and an Ethernet segment Route (ETHERNET SEGMENT Route, RT 4) is used to implement mutual Auto-Discovery between PE devices connected to the same CE.
Fig. 4 is a schematic diagram of triple encoding for carrying format types in the embodiment of the present application, as shown in fig. 4, the format type (format type) is two bytes (0-65535), and different format types are used to identify the configuration modes of different ethernet segment identifiers.
In another embodiment, different format types are used to identify different configuration modes, and table 1 is local configuration information (ethernet segment identifier), message carrying information (target ethernet segment identifier) and remote resolution information corresponding to the different format types.
As shown in table 1, the different format types in this embodiment correspond to the following three local configuration modes respectively:
When the format type is 0, the local configuration ESI is 16 binary 10 bytes, for example: 00.11.22.33.44.55.66.77.88.99;
When the format type is 1, the local configuration ESI can be reduced to IPv4: x, IPv4, represents an IPv4 address, X represents an ethernet segment number, for example: 101.102.103.104:100.
TABLE 1
When the format type is 2, the local configuration ESI can be reduced to MAC: x, MAC stands for MAC address, X stands for ethernet segment number, for example: aaaa.bbbb:100.
In this embodiment, the local configuration ESI in different formats is carried in the same 16-system 10 bytes in the message, and the different format types respectively correspond to the following three format conversion modes:
When the format type is 0, the message carrying ESI is consistent with the local configuration ESI;
When the format type is 1, the 1 st byte and the 8 th to 10 th bytes in the ESI are fixed, the 2 nd to 5 th bytes in the ESI are 16 system of IPv4 address conversion in the local configuration ESI, and the 6 th to 7 th bytes are 16 system of Ethernet segment number conversion in the local configuration ESI.
When the format type is 2, the 1 st byte and the 10 th byte in the message carrying ESI are fixed, the 2-7 th byte in the message carrying ESI is consistent with the MAC address in the local configuration ESI, and the 8 th-9 th byte in the message carrying ESI is 16 th system of Ethernet segment number conversion in the local configuration ESI.
In this embodiment, the step of converting the packet-carried ESI into the remote analysis ESI is opposite to the step of converting the local configuration ESI into the packet-carried ESI, and is an inverse operation process. The message carries the ESI corresponding to the target Ethernet segment identifier in the preset format in the previous method, and the local configuration ESI and the remote analysis ESI corresponding to the Ethernet segment identifier in the previous method.
Fig. 5 is a schematic diagram of an EVPN network according to an embodiment of the present application, where the EVPN network includes: an operator Edge router (PE), a Customer Edge device (CE), an Access Controller (AC).
In this embodiment, the ethernet segment identifier processing method specifically includes the following steps:
step S501, configuring an EVPN VPLS two-layer instance for PE;
In this embodiment, step S501 may specifically include: the PE1, the PE2, the PE3 and the PE4 are configured with an EVPN VPLS two-layer example, a direct connection port with the CE is used as a two-layer AC port, and the PE1 and the PE2 are classified as CE1; AC1 of PE1, AC2 of PE2 belong to ethernet segment ES1, AC3 of PE3 and AC4 of PE4 belong to one ethernet segment ES2. Wherein ES1, ES2 are Ethernet segments (ETHERNET SEGMENT).
Step S502, ESI (ETHERNET SEGMENT IDENTIFIER ) and format type (format type) are configured for ES 1;
In this embodiment, step S502 may specifically include: on PE1 and PE2, an ethernet segment identifier of ESI1 (10 bytes 00.11.22.33.44.55.66.77.88.99) is configured for ES1, and format type is specified as 0.
Step S503, ESI and format type are configured for ES 2;
In this embodiment, step S503 may specifically include: on PE3 and PE4, the Ethernet segment identifier is configured for ES2 as ESI2 (6 bytes 101.102.103.104:100, including 4 bytes of IPv4 address and 2 bytes of Ethernet segment local number), and the format type is designated as 1.
Step S504, converting ESI1 and issuing a route carrying REAL-ESI1 and format type;
In this embodiment, step S504 may specifically include: PE1 generates RT1 and RT4 routes for AC1 and VPLS (Virtual PRIVATE LAN SERVICE ), checks that the format type of ES1 to which AC1 belongs is 0, fills 10 bytes of ESI1 (00.11.22.33.44.55.66.77.88.99) as REAL-ESI1 to RT1, carries in RT4 route message, fills format type (0) in the newly added TLV, and issues routes to the EVPN network.
Step S505, converting ESI2 and issuing a route carrying REAL-ESI2 and format type;
In this embodiment, step S505 may specifically include: PE3 generates RT1 and RT4 routes for AC3 and VPLS, checks that format type of ES2 to which AC3 belongs is 1, converts IPv4 address in 6 bytes of ESI2 (101.102.103.104:100) into 4 bytes 16 system 65.66.67.68, converts local unique index 100 into 2 bytes 16 system 00.64, fills in 2-7 bytes of 10 bytes REAL-ESI2, supplements other bytes with 0 to obtain REAL-ESI2 (00.65.66.67.68.00.64.00.00.00), carries REAL-ESI2 and format type in route message, and issues to EVPN network.
Step S506, analyzing the received route and displaying ESI1;
in this embodiment, step S506 may specifically include: PE5 receives RT1 and RT4 routes issued by PE1, analyzes the format type in the message, judges that the format type is 0, directly uses REAL-ESI1 (00.11.22.33.44.55.66.77.88.99) in the message for forming a local route and forwarding table without conversion, and checks that ESI1 information displayed in the route table is 00.11.22.33.44.55.66.77.88.99;
step S507, the received route is analyzed and ESI2 is displayed.
In this embodiment, step S507 may specifically include: PE5 receives RT1 and RT4 routes issued by PE3, analyzes format type in the message, judges the format type to be 1, and according to iPV4: x is used for analysis, the 2 nd to 5 th bytes (65.66.67.68) of REAL-ESI2 (00.65.66.67.68.00.64.00.00.00) in the message are converted into decimal (101.102.103.104) to be used as IPv4, the 6 th to 7 th bytes (00.64) are converted into decimal (100) to be used as X (Ethernet segment number) for analysis, ESi2 (101.102.103.104:100) is obtained, and the PE5 displays a routing table and a forwarding table by using the ESI 2.
In this embodiment, the REAL-ESI corresponds to the target Ethernet identifier and is in a predetermined format.
Fig. 6 is a schematic view of an EVPN network according to another embodiment of the present application, where the EVPN network includes: an operator Edge router (PE), a Customer Edge device (CE), an Access Controller (AC). ESI1 is configured in a 10-byte preset format, and ESI2 is configured in a MAC: the format of X is configured.
In this embodiment, the ethernet segment identifier processing method specifically includes the following steps:
In step S601, an EVPN VPLS two-layer instance is configured at PE1, PE2, PE3, and PE 4. The direct connection port of the CE is used as a two-layer AC port, wherein the PE1 is used for deploying the VPLS1 and the AC1, the PE2 is used for deploying the VPLS2 and the AC2, the PE3 is used for deploying the VPLS3 and the AC3, and the PE4 is used for deploying the VPLS4 and the AC4;
Step S602, the Ethernet segments ES1 of the same genus as the AC1 and the AC2, wherein on the PE1 and the PE2, the ESI is configured to be 10 bytes ESI1 (00.11.22.33.44.55.66.77.88.99) for the ES1, and the format type is designated as format-type1 (0);
Step S603, the PE1 identifies the format type of ESI1 as format-type1 (0), directly uses the configured 10-byte ESI1 (00.11.22.33.44.55.66.77.88.99) as the REAL-ESI1 of ES1, and writes the REAL-ESI1 in ETHERNET SEGMENT LDENTIFIER (ethernet segment identifier, ESl) fields of the RT1 routing and RT4 routing messages, and writes the format-type1 (0) in the format type field (2 bytes) of the RT1 and RT4 routing new TLV;
Step S604, PE1 issues RT1 and RT4 routes to the EVPN network;
Step S605, AC3 of PE3 and AC4 of PE4 belong to the same Ethernet segment ES2, on PE3 and PE4, format type of ESI2 is designated as format-type3 (2), and ESI is configured as 8-byte ESI2 (6-byte MAC: 2-byte X) format (0000. AAAA. BBBBBB: 100) for ES 2;
Step S606, PE3 recognizes format type of ESI2 as 2, takes the first 6 bytes of 8 bytes of ESI2 (0000. AAAA. BBBB: 100) as 2-7 bytes of REAL-ESI2, and converts the last two bytes X (100) of ESI2 into 16 (00.64) as 8-9 bytes of REAL-ESI2, the other bytes supplement REAL-ESI2 (00.00.AA.BB.00.64.00) forming ESI2 with fixed bytes 00, take REAL-ESI2 as ETHERNET SEGMENT IDENTIFIER of RT1 routing and RT4 routing messages, and take format-type1 (2) as the format type field (2 bytes) of RT1 and RT4 routing new TLVs;
step S607, PE3 issues RT1 and RT4 routes to the EVPN network;
Step S608, PE5 receives the RT1 and RT4 route of PE1, reads ETHERNET SEGMENT IDENTIFIER in the message as REAL-ESI1 (00.11.22.33.44.55.66.77.88.99), analyzes formattype of the newly added TLV as 0, and directly displays REAL-ESI1 as ESI1 in the route and forwarding information;
In step S609, PE5 receives the RT1 and RT4 routes of PE3, reads the ETHERNET SEGMENT IDENTIFIER in the message as REAL-ESi2 (00.00.00.AA.AA.BB.00.64.00), parses formattype of the newly added TLV as 2, performs hexadecimal-to-decimal conversion on the 2 nd-7 th byte (00.00.AA.AA.BB.BB) of REAL-ESi2 as MAC (0000.AAAA.BBBB), reads the 8 th-9 th byte (64.00) of REAL-ESi2 as X (100), forms ESI2 (0000.AAAA.BBBB: 100), and displays the ESI2 in the route and forwarding information.
The application is not limited to the format type, corresponding ESI configuration format and REAL-ESI conversion mode, and other algorithms or mathematical models can be used to configure and convert the Ethernet segment identifier 6
According to another aspect of the embodiment of the present application, there is further provided an ethernet segment identifier processing apparatus, and fig. 7 is a block diagram of the ethernet segment identifier processing apparatus according to an embodiment of the present application, as shown in fig. 7, where the apparatus includes:
A configuration module 72, configured to configure an ethernet segment identifier of the located ethernet segment; the configuration module 72 is further configured to configure a format type corresponding to the ethernet segment identifier;
A conversion module 74, configured to convert the ethernet segment identifier into a target ethernet segment identifier in a preset format according to the format type;
And a publishing module 76, configured to publish a border gateway protocol BGP message carrying the format type and the target ethernet segment identifier to an EVPN network, so that a remote operator edge router PE in the EVPN network parses the BGP message to obtain the ethernet segment identifier.
In this embodiment, the apparatus is applied to an operator Edge router (PE for short) configured with an EVPN two-layer virtual private lan service VPLS instance, and particularly a local PE.
In this embodiment, the Ethernet segment identifier in configuration module 72 includes several formats: 10 bits 16 bytes (00.11.22.33.44.55.66.77.88.99) of the preset format, and the IPv4 address of the 4 bits 10 bytes is added with the Ethernet segment number, IPv4: x (101.102.103.104:100), the MAC address of the 6-bit 16-ary byte is ethernet segment numbered, MAC: x (0001.0002.0003:100), X is a locally unique Ethernet segment number.
In this embodiment, the configuration module 72 may specifically further include:
the first configuration module is used for configuring the format type to be 0 when the Ethernet segment identifier is in a preset format of 10-bit 16-system;
A second configuration module, configured to configure the format type to be 1 when the ethernet segment identifier includes an IPv4 address and an ethernet segment number;
a third configuration module, configured to configure the format type to be 2 when the ethernet segment identifier includes a MAC address and an ethernet segment number;
Specifically, the IPv4 address is in a non-preset format of 4 bits and 10 system, the MAC address is in a non-preset format of 6 bits and 16 system, the ethernet segment number is a local unique identifier, and the format is 2 bits and 10 system bytes.
In this embodiment, the conversion module 74 may specifically further include:
The first conversion module is configured to directly use the ethernet segment identifier of the preset format as the target ethernet segment identifier if the format type is 0;
The second conversion module is used for converting the IPv4 address and the Ethernet segment number into a target Ethernet segment identifier of the preset format if the format type is 1;
And the third conversion module is used for converting the MAC address and the Ethernet segment number into the target Ethernet segment identifier with the preset format if the format type is 2.
In this embodiment, the second conversion module is specifically further configured to convert the IPv4 address into hexadecimal, and use the obtained IPv4 address conversion result as the 2 nd to 5 th bytes of the target ethernet segment identifier; converting the Ethernet segment number into hexadecimal, and taking the obtained Ethernet segment number conversion result as the 6 th to 7 th bytes of the target Ethernet segment identifier; setting the 1 st bit byte and 8 th to 10 th bit bytes remaining in the target ethernet segment identifier as preset bytes.
In this embodiment, the third conversion module is specifically further configured to convert the MAC address and the ethernet segment number into the target ethernet segment identifier in the preset format may specifically include: setting bits 2 to 7 of the destination ethernet segment identifier as the MAC address; converting the Ethernet segment number into hexadecimal, and taking the obtained Ethernet segment number conversion result as the 8 th to 9 th bytes of the target Ethernet segment identifier; and setting the 1 st bit byte and the 10 th bit byte remained in the target Ethernet segment identifier as preset bytes.
In this embodiment, the apparatus further includes a packet generation module, configured to add a TLV triplet structure for carrying the format type to the BGP packet, where the BGP packet includes a target ethernet segment identifier in a preset format, and the BGP packet includes one of the following: the Ethernet automatically discovers the routing message, the MAC address or the IP address announces the routing message and the Ethernet segment routing message.
According to another aspect of the embodiment of the present application, there is further provided an ethernet segment identifier processing device, and fig. 8 is a block diagram of another ethernet segment identifier processing device according to an embodiment of the present application, as shown in fig. 8, where the device includes:
A receiving module 82, configured to receive, from an EVPN network, a BGP packet of a border gateway protocol issued by an edge router PE, where the BGP packet carries a format type of an ethernet segment identifier and a target ethernet segment identifier of a preset format;
an extracting module 84, configured to extract the format type and the target ethernet segment identifier from the BGP packet;
And a parsing module 86, configured to parse the target ethernet segment identifier according to the format type to obtain an ethernet segment identifier.
In this embodiment, the device is applied to an operator Edge router (PE for short) configured with an EVPN two-layer virtual private lan service VPLS instance, especially a far-end PE or a neighboring PE belonging to the same ethernet segment as the local PE.
In this embodiment, the BGP message received by the receiving module 82 includes one of the following: the Ethernet automatically discovers the routing message, the MAC address or the IP address announces the routing message and the Ethernet segment routing message; specifically, the BGP message further includes a TLV triplet structure for carrying the format type.
In this embodiment, the parsing module 86 may specifically further include:
The first analysis module is used for directly taking the target Ethernet segment identifier as an Ethernet segment identifier with a preset format if the format type is 0, wherein the preset format is 10-bit 16-system bytes;
The second analyzing module is configured to analyze the target ethernet segment identifier to obtain the IPv4 address and the ethernet segment number if the format type is 1, where the IPv4 address is a non-preset format of 4-bit 10 system, and the ethernet segment number is a local unique identifier;
And a third parsing module, configured to parse the target ethernet segment identifier to obtain the MAC address and the ethernet segment number if the format type is 2, where the MAC address is a non-preset format of 6-bit 16-system.
In this embodiment, the second parsing module is specifically further configured to convert the 2 nd to 5 th bytes of the target ethernet segment identifier into decimal, to obtain the IPv4 address; and converting the 6 th to 7 th bytes of the target Ethernet segment identifier into decimal, and obtaining the Ethernet segment number.
In this embodiment, the third parsing module is specifically further configured to extract, as the MAC address, the 2 nd to 7 th bytes of the target ethernet segment identifier; and converting the 8 th to 9 th bytes of the target Ethernet segment identifier into decimal, and obtaining the Ethernet segment number.
Embodiments of the present application also provide a computer-readable storage medium having a computer program stored therein, wherein the computer program, when executed by a processor, performs step 6 in any of the method embodiments described above
In one exemplary embodiment, the computer readable storage medium may include, but is not limited to: a usb disk, a Read-Only Memory (ROM), a random access Memory (Random Access Memory RAM), a removable hard disk, a magnetic disk, or an optical disk, or other various media capable of storing a computer program.
An embodiment of the application also provides an electronic device comprising a memory having stored therein a computer program and a processor arranged to run the computer program to perform the steps of any of the method embodiments described above.
In an exemplary embodiment, the electronic apparatus may further include a transmission device connected to the processor, and an input/output device connected to the processor.
Specific examples in this embodiment may refer to the examples described in the foregoing embodiments and the exemplary implementation, and this embodiment is not described herein.
It will be appreciated by those skilled in the art that the modules or steps of the application described above may be implemented in a general purpose computing device, they may be concentrated on a single computing device, or distributed across a network of computing devices, they may be implemented in program code executable by computing devices, so that they may be stored in a storage device for execution by computing devices, and in some cases, the steps shown or described may be performed in a different order than that shown or described herein, or they may be separately fabricated into individual integrated circuit modules, or multiple modules or steps of them may be fabricated into a single integrated circuit module. Thus, the present application is not limited to any specific combination of hardware and software.
The above description is only of the preferred embodiments of the present application and is not intended to limit the present application, but various modifications and variations can be made to the present application by those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the principle of the present application should be included in the protection scope of the present application.

Claims (16)

1. A method for processing an ethernet segment identifier, the method comprising:
Configuring an Ethernet segment identifier of the Ethernet segment;
configuring a format type corresponding to the Ethernet segment identifier;
Converting the Ethernet segment identifier into a target Ethernet segment identifier with a preset format according to the format type;
And issuing a Border Gateway Protocol (BGP) message carrying the format type and the target Ethernet segment identifier to an EVPN network so that a remote operator edge router (PE) in the EVPN network analyzes the BGP message to obtain the Ethernet segment identifier.
2. The method of claim 1, wherein prior to configuring the ethernet segment identifier of the located ethernet segment, the method further comprises:
And configuring an EVPN two-layer virtual private local area network service (VPLS) instance for the local PE and the far-end PE, wherein the EVPN network comprises the far-end PE and the local PE, the far-end PE and the local PE are communicated through BGP messages, a plurality of local PEs are respectively connected with a local user network edge device (CE) through Ethernet links, and a plurality of Ethernet links connected with the same local CE belong to the same Ethernet segment.
3. The method of claim 1, wherein configuring the format type corresponding to the ethernet segment identifier comprises:
When the Ethernet segment identifier is in a preset format of 10 bytes 16 system, configuring the format type to be 0;
When the Ethernet segment identifier comprises an IPv4 address and an Ethernet segment number, configuring the format type as 1;
When the Ethernet segment identifier comprises a MAC address and an Ethernet segment number, configuring the format type as 2;
The IPv4 address is in a non-preset format of 4 bytes and 10 system, the MAC address is in a non-preset format of 6 bytes and 16 system, and the Ethernet segment number is a local unique identifier;
Wherein the preset format is a 10-byte 16 system, and the non-preset format comprises a 4-byte 10 system and a 6-byte 16 system.
4. A method according to claim 3, wherein converting the ethernet segment identifier into a target ethernet segment identifier in a pre-set format according to the format type comprises:
if the format type is 0, directly taking the Ethernet segment identifier of the preset format as the target Ethernet segment identifier;
If the format type is 1, converting the IPv4 address and the Ethernet segment number into a target Ethernet segment identifier of the preset format;
And if the format type is 2, converting the MAC address and the Ethernet segment number into the target Ethernet segment identifier with the preset format.
5. The method of claim 4, wherein converting the IPv4 address and the ethernet segment number into the pre-formatted target ethernet segment identifier comprises:
converting the IPv4 address into hexadecimal, and taking the obtained IPv4 address conversion result as the 2 nd to 5 th bytes of the target Ethernet segment identifier;
Converting the Ethernet segment number into hexadecimal, and taking the obtained Ethernet segment number conversion result as the 6 th to 7 th bytes of the target Ethernet segment identifier;
setting the 1 st byte and 8 th to 10 th bytes remaining in the target ethernet segment identifier as preset bytes.
6. The method of claim 4, wherein converting the MAC address and the ethernet segment number to the destination ethernet segment identifier in the preset format comprises:
Setting the 2 nd to 7 th bytes of the target ethernet segment identifier as the MAC address;
Converting the Ethernet segment number into hexadecimal, and taking the obtained Ethernet segment number conversion result as the 8 th to 9 th bytes of the target Ethernet segment identifier;
And setting the 1 st byte and the 10 th byte remained in the target Ethernet segment identifier into preset bytes.
7. The method of claim 1, wherein prior to publishing border gateway protocol BGP messages carrying the format type and the target ethernet segment identifier to an EVPN network, the method further comprises:
adding a TLV triple structure for carrying the format type in the BGP message, wherein the BGP message comprises a target Ethernet segment identifier with a preset format, and the BGP message comprises one of the following components: the Ethernet automatically discovers the routing message, the MAC address or the IP address announces the routing message and the Ethernet segment routing message.
8. A method for processing an ethernet segment identifier, the method comprising:
Receiving a Border Gateway Protocol (BGP) message issued by an operator edge router (PE) from an EVPN network, wherein the BGP message carries the format type of an Ethernet segment identifier and a target Ethernet segment identifier in a preset format;
Extracting the format type and the target Ethernet segment identifier from the BGP message;
and analyzing the target Ethernet segment identifier according to the format type to obtain the Ethernet segment identifier.
9. The method of claim 8, wherein parsing the target ethernet segment identifier according to the format type to obtain an ethernet segment identifier comprises:
if the format type is 0, directly taking the target Ethernet segment identifier as an Ethernet segment identifier with a preset format, wherein the preset format is 10 bytes 16 system;
if the format type is 1, the Ethernet segment identifier comprises an IPv4 address and an Ethernet segment number, and the target Ethernet segment identifier is analyzed to obtain the IPv4 address and the Ethernet segment number, wherein the IPv4 address is in a non-preset format of 4 bytes and 10 system, and the Ethernet segment number is a local unique identifier;
If the format type is2, the ethernet segment identifier includes a MAC address and an ethernet segment number, and the target ethernet segment identifier is parsed to obtain the MAC address and the ethernet segment number, where the MAC address is a non-preset format with a 16-byte system of 6 bytes.
10. The method of claim 9, wherein resolving the target ethernet segment identifier to obtain the IPv4 address and the ethernet segment number comprises:
Converting the 2 nd to 5 th bytes of the target Ethernet segment identifier into decimal, and obtaining the IPv4 address;
Converting the 6 th to 7 th bytes of the target Ethernet segment identifier into decimal, and obtaining the Ethernet segment number.
11. The method of claim 9, wherein resolving the destination ethernet segment identifier to obtain the MAC address and the ethernet segment number comprises:
extracting the 2 nd to 7 th bytes of the target ethernet segment identifier as the MAC address;
and converting the 8 th to 9 th bytes of the target Ethernet segment identifier into decimal, and obtaining the Ethernet segment number.
12. The method of claim 8, wherein the step of determining the position of the first electrode is performed,
The BGP message includes one of: the Ethernet automatically discovers the routing message, the MAC address or the IP address announces the routing message and the Ethernet segment routing message;
the BGP message includes a TLV triplet structure for carrying the format type.
13. An ethernet segment identifier processing device, the device comprising:
a configuration module, configured to configure an ethernet segment identifier of the located ethernet segment;
The configuration module is further configured to configure a format type corresponding to the ethernet segment identifier;
The conversion module is used for converting the Ethernet segment identifier into a target Ethernet segment identifier with a preset format according to the format type;
And the issuing module is used for issuing a Border Gateway Protocol (BGP) message carrying the format type and the target Ethernet segment identifier to an EVPN network so that a remote operator edge router (PE) in the EVPN network can analyze the BGP message to obtain the Ethernet segment identifier.
14. An ethernet segment identifier processing device, the device comprising:
The receiving module is used for receiving a Border Gateway Protocol (BGP) message issued by an operator edge router (PE) from an EVPN network, wherein the BGP message carries the format type of an Ethernet segment identifier and a target Ethernet segment identifier in a preset format;
An extracting module, configured to extract the format type and the target ethernet segment identifier from the BGP packet;
And the analysis module is used for analyzing the target Ethernet segment identifier according to the format type to obtain the Ethernet segment identifier.
15. A computer-readable storage medium, in which a computer program is stored, wherein the computer program, when run by a processor, performs the method of any one of claims 1 to 12.
16. An electronic device comprising a memory in which a computer program is stored and a processor arranged to run the computer program to perform the method of any of claims 1 to 12.
CN202211438346.0A 2022-11-16 2022-11-16 Ethernet segment identifier processing method and device Pending CN118055017A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202211438346.0A CN118055017A (en) 2022-11-16 2022-11-16 Ethernet segment identifier processing method and device
PCT/CN2023/106169 WO2024103806A1 (en) 2022-11-16 2023-07-06 Processing method and apparatus for ethernet segment identifier

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211438346.0A CN118055017A (en) 2022-11-16 2022-11-16 Ethernet segment identifier processing method and device

Publications (1)

Publication Number Publication Date
CN118055017A true CN118055017A (en) 2024-05-17

Family

ID=91043735

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211438346.0A Pending CN118055017A (en) 2022-11-16 2022-11-16 Ethernet segment identifier processing method and device

Country Status (2)

Country Link
CN (1) CN118055017A (en)
WO (1) WO2024103806A1 (en)

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104365066B (en) * 2013-05-24 2017-11-24 华为技术有限公司 Method and apparatus for ether Virtual Private Network
CN108574630B (en) * 2017-03-14 2020-06-02 华为技术有限公司 EVPN message processing method, device and system
US10637687B2 (en) * 2017-04-20 2020-04-28 Cisco Technology, Inc. EVPN implicit aliasing
US11012349B2 (en) * 2019-06-28 2021-05-18 Arista Networks, Inc. Route reflector optimizations for interconnecting MPLS-based L3-VPN and L3-EVPN networks

Also Published As

Publication number Publication date
WO2024103806A1 (en) 2024-05-23

Similar Documents

Publication Publication Date Title
CN106936777B (en) Cloud computing distributed network implementation method and system based on OpenFlow
US7577142B2 (en) Derived VLAN mapping technique
EP2252011B1 (en) Scalable routing policy construction using dynamic redefinition of routing preference value
CN103534993B (en) Connect the system of selection of Tag switching route and the device in low-power network territory
EP4113919A1 (en) Method for forwarding message in srv6 service function chain, sff and sf device
CN114915585A (en) Message processing method, device, equipment and system
US20100027549A1 (en) Method and apparatus for providing virtual private network identifier
CN102938795B (en) The method of IPv6 address access IPv4 resource is realized by tunnel and address transition
CN105024985A (en) Message processing method and apparatus
CN107733795B (en) Ethernet virtual private network EVPN and public network intercommunication method and device
CN103905283A (en) Communication method and apparatus based on expandable virtual local area network
CN101310486A (en) Techniques for inserting internet protocol services in a broadband access network
CN103944826A (en) Entry aggregation method in SPBM (shortest path bridging MAC mode) network and equipment
CN114095305A (en) BIER message forwarding method, equipment and system
CN101001264B (en) Method, device, network edge equipment and addressing server for L1VPN address distribution
CN108347392B (en) Cross-board processing method, device and system for service message
CN108471390B (en) Cross-board processing system for service message and redirection method for service message
CN107360089A (en) A kind of method for routing foundation, business datum conversion method and device
EP4152704A1 (en) Bier multicast traffic statistics method, device and system
WO2021052381A1 (en) Message sending method and apparatus
JP2002354006A (en) Network system for duplicate address
CN118055017A (en) Ethernet segment identifier processing method and device
CN113163276A (en) Method, device and system for issuing routing information
CN114244763B (en) Dynamic network topology management method and system based on rule engine
CN113285878B (en) Load sharing method and first network equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication