A message processing method, device and network equipment

By encapsulating MPLS labels in the G-SRv6 network, the problem of G-SRv6's difficulty in traversing MPLS networks is solved, enabling end-to-end deployment of G-SRv6 networks and smooth upgrades of devices.

CN116418739BActive Publication Date: 2026-01-06CHINA MOBILE COMM LTD RES INST +1
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202111635558.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-29
Publication Date
2026-01-06
Estimated Expiration
2041-12-29

AI Technical Summary

Technical Problem

In existing technologies, G-SRv6 has difficulty traversing MPLS networks, making it difficult to form end-to-end path planning.

Method used

When the end-to-end deployment path of the G-SRv6 network includes MPLS network nodes, the MPLS labels of the MPLS network nodes are encapsulated in the G-SRv6 packets. The MPLS labels are then extracted and encapsulated in the outer layer of the G-SRv6 packets through the critical nodes between the G-SRv6 network and the MPLS network, enabling the G-SRv6 packets to traverse the MPLS network.

Benefits of technology

It enables G-SRv6 packets to traverse MPLS networks, achieves end-to-end deployment of G-SRv6 networks, and supports smooth upgrades of existing network equipment and coexistence with MPLS networks.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116418739B_ABST
    Figure CN116418739B_ABST
Patent Text Reader

Abstract

The application provides a message processing method and device and network equipment, and relates to the fields of transmission and IP. The method comprises the following steps: acquiring an end-to-end deployment path; if the end-to-end deployment path of the G-SRv6 network comprises a multiprotocol label switching (MPLS) network node, then the MPLS label of the MPLS network node is encapsulated in a G-SRv6 message. The scheme of the application solves the problem that, in the prior art, it is difficult to form an end-to-end path planning because the G-SRv6 is difficult to pass through an MPLS network.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of transmission and IP, and in particular to a message processing method, apparatus and network equipment. Background Technology

[0002] Due to the large number of existing devices in operator networks, most networks and devices are currently deployed with Multi-Protocol Label Switching (MPLS). Upgrading to G-SRv6 (Segment Routing IPv6) cannot be completed in a short time. Therefore, equipment upgrades will inevitably be carried out in different regions, resulting in some areas running G-SRv6 and others running MPLS. Alternatively, existing network equipment may be too old to be upgraded to G-SRv6 and will continue to run MPLS. This leads to scenarios where G-SRv6 and MPLS networks coexist.

[0003] The current G-SRv6 scheme unifies the forwarding of standard 128-bit SID (Segment ID) and compressed SID, unifying the forwarding plane to IPv6. However, if the network traversed is an MPLS network, the existing G-SRv6 path orchestration cannot cross it, and it will be interrupted by the MPLS network into two or more G-SRv6 paths, making it impossible to deploy G-SRv6 end-to-end. Summary of the Invention

[0004] The purpose of this invention is to provide a message processing method, apparatus, and network device that solves the problem in the prior art where G-SRv6 is difficult to traverse MPLS networks, making it difficult to form end-to-end path planning.

[0005] To achieve the above objectives, embodiments of the present invention provide a message processing method applied to a first node, wherein the first node is the first node in the end-to-end deployment path of a G-SRv6 network, the method comprising:

[0006] Obtain the end-to-end deployment path of the G-SRv6 network;

[0007] If the end-to-end deployment path of the G-SRv6 network includes a Multiprotocol Label Switching (MPLS) network node, then the MPLS label of the MPLS network node is encapsulated in the G-SRv6 message.

[0008] To achieve the above objectives, embodiments of the present invention provide a message processing method applied to a second node, which is a critical node between the G-SRv6 network and the MPLS network in an end-to-end deployment path of a G-SRv6 network. The end-to-end deployment path of the G-SRv6 network includes both G-SRv6 network nodes and MPLS network nodes. The method includes:

[0009] Obtain the first message; wherein, the first message is the message obtained after the G-SRv6 message generated by the first node is transmitted to the second node;

[0010] If the segment identifier (SID) of the second node carries an indication identifier, the first message is processed to obtain the second message; wherein the indication identifier is used to indicate that the next hop of the SID of the second node is an MPLS label, and the outer encapsulation of the second message is the MPLS label.

[0011] Optionally, the indication identifier is: the segment endpoint behavior type of the SID of the second node, or a first identifier bound to the segment endpoint behavior type of the SID of the second node.

[0012] Optionally, if the segment identifier (SID) of the second node carries an indicator identifier, then the first message is processed to obtain a second message, including:

[0013] If the first message carries the indication identifier, then the MPLS label following the SID of the second node is extracted as the outer encapsulation, and the G-SRv6 message is used as the inner message.

[0014] The destination address of the first message is updated to the SID of the first G-SRv6 after the consecutive MPLS labels to obtain the second message.

[0015] Optionally, if the first message carries the indication identifier, then extracting the consecutive MPLS labels following the SID of the second node as the outer encapsulation, and using the G-SRv6 message as the inner message, includes:

[0016] The MPLS labels in the MPLS label stack of the first message are read sequentially, and the MPLS labels are encapsulated in the outer layer of the first message until the MPLS label stack is completely read.

[0017] Optionally, the step of sequentially reading the MPLS labels in the MPLS label stack of the first packet and encapsulating the MPLS labels in the outer layer of the first packet until the MPLS label stack is completely read includes:

[0018] Based on SL (Segment Left, the remaining segment identifier), read the MPLS tag in the G-SID container pointed to by the value of SL, and decrement the value of SL by 1;

[0019] Repeat the steps of reading the MPLS tag in the G-SID container pointed to by the value of SL according to SL, and decrementing the value of SL by 1, until the MPLS tag stack is completely read.

[0020] Optionally, reading the MPLS tag in the G-SID container pointed to by the value of the SL includes:

[0021] Based on SI (SID Index, Tag Index), read the MPLS tag pointed to by the value of SI in the G-SID container pointed to by the value of SL, and decrement the value of SI by 1;

[0022] Repeat the steps of reading the MPLS tag pointed to by the value of SI in the G-SID container pointed to by the value of SL according to the tag index SI, and decrementing the value of SI by 1 until the value of SI is 0.

[0023] Optionally, updating the destination address of the first packet to the SID of the first G-SRv6 after the consecutive MPLS labels includes:

[0024] The destination address of the first packet is updated according to the SID of the first G-SRv6 in the G-SID container pointed to by the target value of SL; wherein, the target value is the value of SL when the MPLS label stack is read.

[0025] To achieve the above objectives, embodiments of the present invention provide a message processing apparatus applied to a second node, the second node being a critical node between the G-SRv6 network and the MPLS network in an end-to-end deployment path of a G-SRv6 network. The end-to-end deployment path of the G-SRv6 network includes G-SRv6 network nodes and MPLS network nodes, comprising:

[0026] The path acquisition module is used to acquire the end-to-end deployment path of the G-SRv6 network;

[0027] The first processing module is configured to encapsulate the MPLS label of the MPLS network node in a G-SRv6 message if the end-to-end deployment path of the G-SRv6 network includes a Multiprotocol Label Switching (MPLS) network node.

[0028] To achieve the above objectives, embodiments of the present invention provide a message processing apparatus applied to a second node, the second node being a critical node between the G-SRv6 network and the MPLS network in an end-to-end deployment path of a G-SRv6 network. The end-to-end deployment path of the G-SRv6 network includes G-SRv6 network nodes and MPLS network nodes, comprising:

[0029] The message acquisition module is used to acquire a first message; wherein, the first message is a message obtained after the G-SRv6 message generated by the first node is transmitted to the second node;

[0030] The second processing module is used to process the first message to obtain a second message if the segment identifier (SID) of the second node carries an indication identifier; wherein the indication identifier is used to indicate that the next hop of the SID of the second node is an MPLS label, and the outer encapsulation of the second message is the MPLS label.

[0031] Optionally, the indication identifier is: the segment endpoint behavior type of the SID of the second node, or a first identifier bound to the segment endpoint behavior type of the SID of the second node.

[0032] Optionally, the second processing module includes:

[0033] The first processing submodule is configured to extract the MPLS labels following the SID of the second node as an outer encapsulation and to use the G-SRv6 message as an inner message if the first message carries the indication identifier.

[0034] The second processing submodule is used to update the destination address of the first packet to the SID of the first G-SRv6 after the consecutive MPLS tags, so as to obtain the second packet.

[0035] Optionally, the first processing submodule includes:

[0036] The processing unit is configured to sequentially read the MPLS labels in the MPLS label stack of the first message and encapsulate the MPLS labels in the outer layer of the first message until the MPLS label stack has been read.

[0037] Optionally, the processing unit includes:

[0038] The first processing subunit is configured to read the MPLS tag in the G-SID container pointed to by the value of the remaining segment identifier SL, and decrement the value of SL by 1;

[0039] The second processing subunit is used to repeatedly execute the steps of reading the MPLS tag in the G-SID container pointed to by the value of SL according to SL, and decrementing the value of SL by 1, until the MPLS tag stack is completely read.

[0040] Optionally, the first processing subunit includes:

[0041] The third processing subunit is used to read the MPLS tag pointed to by the value of SI in the G-SID container pointed to by the value of SI according to SI, and decrement the value of SI by 1;

[0042] The fourth processing subunit is used to repeatedly execute the steps of reading the MPLS tag pointed to by the value of SI in the G-SID container pointed to by the value of SL according to the tag index SI, and decrementing the value of SI by 1 until the value of SI is 0.

[0043] Optionally, the second processing submodule includes:

[0044] The fifth processing subunit is used to update the destination address of the first packet according to the SID of the first G-SRv6 in the G-SID container pointed to by the target value of SL; wherein, the target value is the value of SL when the MPLS label stack is read.

[0045] To achieve the above objectives, embodiments of the present invention provide a network device, which is a first node, including a processor and a transceiver, wherein the processor is used for:

[0046] Obtain the end-to-end deployment path of the G-SRv6 network;

[0047] If the end-to-end deployment path of the G-SRv6 network includes a Multiprotocol Label Switching (MPLS) network node, then the MPLS label of the MPLS network node is encapsulated in the G-SRv6 message.

[0048] To achieve the above objectives, embodiments of the present invention provide a network device, which is a first node, including a processor and a transceiver, wherein the processor is used for:

[0049] Obtain the first message; wherein, the first message is the message obtained after the G-SRv6 message generated by the first node is transmitted to the second node;

[0050] If the segment identifier (SID) of the second node carries an indication identifier, the first message is processed to obtain the second message; wherein the indication identifier is used to indicate that the next hop of the SID of the second node is an MPLS label, and the outer encapsulation of the second message is the MPLS label.

[0051] Optionally, the indication identifier is: the segment endpoint behavior type of the SID of the second node, or a first identifier bound to the segment endpoint behavior type of the SID of the second node.

[0052] Optionally, when the processor processes the first message to obtain the second message if the segment identifier (SID) of the second node carries an indication identifier, it specifically performs the following:

[0053] If the first message carries the indication identifier, then the MPLS label following the SID of the second node is extracted as the outer encapsulation, and the G-SRv6 message is used as the inner message.

[0054] The destination address of the first message is updated to the SID of the first G-SRv6 after the consecutive MPLS labels to obtain the second message.

[0055] Optionally, when the processor extracts the consecutive MPLS labels following the SID of the second node as the outer encapsulation and uses the G-SRv6 message as the inner message if the first message carries the indication identifier, it is specifically used for:

[0056] The MPLS labels in the MPLS label stack of the first message are read sequentially, and the MPLS labels are encapsulated in the outer layer of the first message until the MPLS label stack is completely read.

[0057] Optionally, the processor sequentially reads the MPLS labels in the MPLS label stack of the first packet and encapsulates the MPLS labels in the outer layer of the first packet until the MPLS label stack is completely read, specifically for:

[0058] Based on the remaining segment identifier SL, read the MPLS tag in the G-SID container pointed to by the value of SL, and decrement the value of SL by 1;

[0059] Repeat the steps of reading the MPLS tag in the G-SID container pointed to by the value of SL according to SL, and decrementing the value of SL by 1, until the MPLS tag stack is completely read.

[0060] Optionally, the processor, when reading the MPLS tag in the G-SID container pointed to by the value of the SL, specifically uses the following methods:

[0061] Based on SI, read the MPLS tag pointed to by the value of SI in the G-SID container pointed to by the value of SI, and decrement the value of SI by 1;

[0062] Repeat the steps of reading the MPLS tag pointed to by the value of SI in the G-SID container pointed to by the value of SL according to the tag index SI, and decrementing the value of SI by 1 until the value of SI is 0.

[0063] Optionally, the processor updates the destination address of the first packet to the SID of the first G-SRv6 after the consecutive MPLS labels, specifically for:

[0064] The destination address of the first packet is updated according to the SID of the first G-SRv6 in the G-SID container pointed to by the target value of SL; wherein, the target value is the value of SL when the MPLS label stack is read.

[0065] To achieve the above objectives, embodiments of the present invention provide a network device, which is a first node, including a transceiver, a processor, a memory, and a program or instructions stored in the memory and executable on the processor; when the processor executes the program or instructions, it implements the message processing method described above.

[0066] To achieve the above objectives, embodiments of the present invention provide a readable storage medium having a program or instructions stored thereon, which, when executed by a processor, implement the steps in the message processing method described above.

[0067] The beneficial effects of the above-described technical solution of the present invention are as follows:

[0068] In the method of this invention, when the end-to-end deployment path of the G-SRv6 network includes MPLS network nodes, the MPLS labels of the MPLS network nodes can be encapsulated in the G-SRv6 packets at the head node. This allows the MPLS labels to be extracted and encapsulated in the outer layer of the G-SRv6 packets when they are transmitted to the critical node between the G-SRv6 network and the MPLS network, thereby enabling the G-SRv6 packets to traverse the MPLS network and achieve end-to-end deployment of G-SRv6. Attached Figure Description

[0069] Figure 1 This is a schematic diagram illustrating the structural principle of G-SRv6 compression.

[0070] Figure 2 This is a schematic diagram illustrating the relationship between the G-SID container, compressed G-SID, and standard SRv6 SID according to an embodiment of the present invention.

[0071] Figure 3 A flowchart of the message processing method according to an embodiment of the present invention;

[0072] Figure 4A schematic diagram of the end-to-end deployment path of the G-SRv6 network according to an embodiment of the present invention;

[0073] Figure 5 This is a flowchart of a message processing method according to another embodiment of the present invention;

[0074] Figure 6 This is a schematic diagram illustrating the format of encapsulating G-SID and MPLS tags according to an embodiment of the present invention;

[0075] Figure 7 This is a schematic diagram of the structure defined by the extended G-SID container in an embodiment of the present invention;

[0076] Figure 8 This is a schematic diagram of the forwarding process of G-SRv6 network and MPLS network mixed encoding in an embodiment of the present invention;

[0077] Figure 9 This is a structural diagram of the message processing apparatus according to an embodiment of the present invention;

[0078] Figure 10 This is a structural diagram of a message processing apparatus according to another embodiment of the present invention;

[0079] Figure 11 This is a structural diagram of a network device according to an embodiment of the present invention;

[0080] Figure 12 This is a structural diagram of a network device according to another embodiment of the present invention. Detailed Implementation

[0081] To make the technical problems, technical solutions and advantages of the present invention clearer, a detailed description will be given below in conjunction with the accompanying drawings and specific embodiments.

[0082] It should be understood that the phrase "one embodiment" or "an embodiment" throughout the specification means that a specific feature, structure, or characteristic related to the embodiment is included in at least one embodiment of the invention. Therefore, "in one embodiment" or "in an embodiment" appearing throughout the specification do not necessarily refer to the same embodiment. Furthermore, these specific features, structures, or characteristics can be combined in any suitable manner in one or more embodiments.

[0083] In various embodiments of the present invention, it should be understood that the sequence number of each process described below does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention.

[0084] In addition, the terms "system" and "network" are often used interchangeably in this article.

[0085] In the embodiments provided in this application, it should be understood that "B corresponding to A" means that B is associated with A, and B can be determined based on A. However, it should also be understood that determining B based on A does not mean determining B solely based on A; B can also be determined based on A and / or other information.

[0086] The standard SRv6 128-bit SID uses an IPv6 address format. Compared to MPLS Label format SIDs, SRv6 SIDs offer routable attributes, simplified inter-domain path creation, and the ability to quickly establish end-to-end paths in IPv6 networks. Furthermore, SRv6 SIDs support programmability, meeting flexible network and service function requirements. SRv6, combined with the coordinated support of centralized and distributed control planes, can flexibly meet the needs of various services and network functions, adapting to the evolving needs of networks and services.

[0087] However, standard SRv6 suffers from poor carrying efficiency, complex hardware, and difficulties in upgrading existing networks. G-SRv6, while inheriting the simplicity and network programmability of the SRv6 protocol, proposes a header compression optimization scheme that extracts the common prefix and concatenates the SID. Compressed SIDs and native SIDs are carried using a unified container, G-SID Container, which is compatible with the native SRv6 packet structure, enabling smooth network upgrades and evolution. An extended SID attribute compression tag is used for SRv6 path orchestration, flexibly applied to hybrid SRv6 compressed and uncompressed networks, enabling end-to-end deployment based on SRv6. A second-level index for the SRH (Segment Routing Header) is proposed, based on the SRv6 Argument field, to maintain compatibility with the native SRv6 packet format and significantly reduce the hardware implementation complexity of forwarding caused by compression. The structural principle of G-SRv6 compression is as follows: Figure 1 As shown.

[0088] When compressed G-SIDs and standard SIDs are cataloged in the SRH SID List, to accurately locate the G-SIDs, they must be cataloged in a 128-bit aligned manner. That is, a 128-bit row needs to hold four 32-bit compressed G-SIDs, or multiple compressed G-SIDs of other lengths. G-SRv6 specifically defines the concept of a G-SID Container, which is a 128-bit value. A G-SID Container can contain one SRv6 standard SID or multiple compressed G-SIDs, such as four 32-bit G-SIDs. The relationship between the G-SID Container and compressed G-SIDs and standard SRv6 SIDs is as follows: Figure 2 As shown.

[0089] like Figure 3As shown, an embodiment of the present invention provides a message processing method applied to a first node, which is the first node in the end-to-end deployment path of a G-SRv6 network, comprising:

[0090] Step 301: Obtain the end-to-end deployment path of the G-SRv6 network.

[0091] It should be noted that the end-to-end deployment path of the G-SRv6 network can be determined by calculating the path through the controller or deploying the ingress device (i.e., the first node).

[0092] Step 302: If the end-to-end deployment path of the G-SRv6 network includes a Multiprotocol Label Switching (MPLS) network node, then the MPLS label of the MPLS network node is encapsulated in the G-SRv6 message.

[0093] In this step, when the end-to-end deployment path of the G-SRv6 network includes MPLS network nodes, the first node can encapsulate the MPLS label in the G-SRv6 message. In this way, by using the MPLS label as a special form of G-SID, G-SRv6 can traverse the MPLS network.

[0094] In this embodiment, the first node in the end-to-end deployment path of the G-SRv6 network can encapsulate the MPLS label of the MPLS network node in the G-SRv6 packet to achieve unified orchestration of the G-SRv6 network and the MPLS network. This allows the MPLS label to be extracted and encapsulated in the outer layer of the G-SRv6 packet when it is transmitted to the critical node between the G-SRv6 network and the MPLS network, thereby enabling the G-SRv6 packet to traverse the MPLS network and achieving a better technical effect of network-wide path planning.

[0095] like Figure 4As shown, nodes N0-N4 and N8-N12 are in the G-SRv6 domain (i.e., G-SRv6 domain), node N4 is the boundary node for switching from the G-SRv6 domain to the MPLS domain (i.e., MPLS domain), node N8 is the boundary node for switching from the MPLS domain to the G-SRv6 domain, and nodes N5-N8 are in the SR MPLS domain. Node N0 is the first node in the end-to-end deployment path of the G-SRv6 network. The next hop for the payload route query by node N0 is node N12. Therefore, the last hop for G-SRv6 encapsulation is node N12. The packet's IPv6 source address is A::0:1::, and the IPv6 destination address is A::1:1:: (i.e., the END SID of N1). The SRH (Segment Routing Header) header follows G-SRv6 rules, first encapsulating the END SIDs of nodes N1-N4, where the N1 END SID is not compressed; then, encapsulating the MPLS Node SIDs (i.e., MPLS labels) of nodes N5-N8; then, encapsulating the END SIDs of nodes N9-N11; finally, encapsulating the END.DT4 SID of N12. The packet is then unicast-forwarded based on the IPv6 destination address. Nodes N1-N3 forward packets according to the original G-SRv6 process, which will not be elaborated here. Among them, END and END.DT4 both belong to the segment endpoint behavior type of SID.

[0096] In this embodiment, when the end-to-end deployment path of the G-SRv6 network includes MPLS network nodes, the message processing method can encapsulate the MPLS labels of the MPLS network nodes in the G-SRv6 message at the header node. This allows the MPLS labels to be extracted and encapsulated in the outer layer of the G-SRv6 message when it is transmitted to the critical node between the G-SRv6 network and the MPLS network, thereby enabling the G-SRv6 message to traverse the MPLS network and achieve end-to-end deployment of G-SRv6.

[0097] like Figure 5 As shown, an embodiment of the present invention provides a message processing method applied to a second node, which is a critical node between the G-SRv6 network and the MPLS network in an end-to-end deployment path of a G-SRv6 network. The end-to-end deployment path of the G-SRv6 network includes G-SRv6 network nodes and MPLS network nodes. The method includes:

[0098] Step 501, obtain the first message; wherein, the first message is the message obtained after the G-SRv6 message generated by the first node is transmitted to the second node;

[0099] Step 502: If the segment identifier (SID) of the second node carries an indication identifier, then the first message is processed to obtain a second message; wherein, the indication identifier is used to indicate that the next hop of the SID of the second node is an MPLS label, and the outer encapsulation of the second message is the MPLS label.

[0100] Here, when a G-SRv6 packet is forwarded to the MPLS network, the second node, acting as the boundary router between the G-SRv6 network and the MPLS network, receives the first packet and can look up its local SRv6 SID table based on the IPv6 destination address of the first packet. If the lookup finds that the second node's SID carries an indicator, it indicates that the next hop of the second node is a network node in the MPLS network. Therefore, the first packet needs to be processed to obtain the second packet, and then the second packet is sent out.

[0101] In this embodiment, the second node can determine that the G-SRv6 packet contains an MPLS label by using an indicator, indicating that the next hop of the second node is a network node in the MPLS network (i.e., the next SID of the second node's SID is an MPLS Label format SID). The second node then processes the first packet to obtain a second packet encapsulated with the MPLS label and sends it out. In this way, the second packet can be forwarded normally in the MPLS network, thus enabling G-SRv6 packets to traverse the MPLS network and form an end-to-end path plan for the G-SRv6 network. This achieves the effect of smoothly upgrading and deploying G-SRv6 on existing network equipment, and the upgraded G-SRv6 network can coexist with MPLS networks that cannot be upgraded or are upgraded in stages.

[0102] Optionally, the indication identifier is: the segment endpoint behavior type of the SID of the second node, or a first identifier bound to the segment endpoint behavior type of the SID of the second node.

[0103] It should be noted that the Segment Endpoint Behavior is defined locally on the executing node. It is a packet processing behavior performed on the SRv6 segment endpoint. The network node (e.g., the second node) can determine the segment endpoint behavior type corresponding to the second node by looking up the local SRv6 SID table.

[0104] In this embodiment, the indicator can be one of the following two types: First, the segment endpoint behavior type of the SID of the second node, which can be a newly defined segment endpoint behavior type, for example, it can be represented as END.COM (i.e., Continue of MPLS); Second, a first identifier bound to the segment endpoint behavior type of the SID of the second node, which is a newly defined Flavor type, for example, the first identifier can be represented as COM Flavor. The segment endpoint behavior type can be a segment endpoint behavior already defined in the prior art (e.g., END, END.X, or END.T, etc.), that is, COM Flavor is carried through segment endpoint behaviors such as END, END.X, or END.T.

[0105] Optionally, if the segment identifier (SID) of the second node carries an indicator identifier, then the first message is processed to obtain a second message, including:

[0106] If the first message carries the indication identifier, then the MPLS label following the SID of the second node is extracted as the outer encapsulation, and the G-SRv6 message is used as the inner message.

[0107] The destination address of the first message is updated to the SID of the first G-SRv6 after the consecutive MPLS labels to obtain the second message.

[0108] Specifically, this step may include: updating the destination address of the first packet according to the SID of the first G-SRv6 in the G-SID container pointed to by the target value of SL; wherein, the target value is the value of SL when the MPLS label stack is read.

[0109] It should be noted that in SRv6, the IPv6 destination address field is a constantly changing field. Its value is determined by the Segment Left field and the Segment List. When the pointer Segment Left points to an active segment, such as Segment List[2], the IPv6 address of Segment List[2] needs to be copied to the IPv6 destination address field.

[0110] In this embodiment, if the SID of the second node carries an indicator identifier, for example, the segment endpoint behavior type of the SID of the second node is END.COM, or the SID of the second node carries COM Flavor, then the MPLS labels following the SID of the second node are extracted as an outer encapsulation, and the G-SRv6 message is encapsulated in the inner layer to form a second message, so that the second message can be transmitted in the MPLS network, achieving the purpose of G-SRv6 message traversing the MPLS network.

[0111] Optionally, if the first message carries the indication identifier, then extracting the consecutive MPLS labels following the SID of the second node as the outer encapsulation, and using the G-SRv6 message as the inner message, includes:

[0112] The MPLS labels in the MPLS label stack of the first message are read sequentially, and the MPLS labels are encapsulated in the outer layer of the first message until the MPLS label stack is completely read.

[0113] Specifically, this step may include: reading the MPLS tag in the G-SID container pointed to by the value of the remaining segment identifier SL, and decrementing the value of SL by 1; repeating the step of reading the MPLS tag in the G-SID container pointed to by the value of SL and decrementing the value of SL by 1 until the MPLS tag stack is read completely.

[0114] It should be noted that, in order to unify the 128-bit native SID (i.e., complete SID) and compressed SIDs of lengths such as 32 bits and 16 bits, the G-SRv6 scheme introduces the concept of a G-SID container. This facilitates the mixing of G-SIDs and complete SIDs while ensuring 128-bit alignment. Here, a G-SID container can be understood as a 128-bit space. A G-SID container can contain: one SRv6 standard SID (i.e., native SID), or multiple compressed SRv6 SIDs (i.e., G-SIDs), such as four 32-bit G-SIDs.

[0115] In an optional embodiment of the present invention, the G-SID includes both the IPv6-based SRv6 SID format and the MPLS label format. Both SID formats can be uniformly carried by a G-SID container. For example, one G-SID container contains four MPLS labels, each MPLS label having a standard length of 32 bits. Figure 7The diagram shown is a structural schematic of the G-SIDContainer extended definition according to an embodiment of the present invention. It should be noted that the encapsulation type contained in each G-SID container must be consistent; if it is less than 128 bits, it needs to be padded.

[0116] It's also worth noting that to implement SRv6, IPv6 packets have added an extension header, the SRH. The SRH contains two key pieces of information: one is a Segment List in IPv6 address format, arranged in an ordered manner to form the explicit path in SRv6; the other key field is the Segment Left (SL), a pointer indicating the currently active Segment List, i.e., the next hop network node. Since the G-SID type within the same 128-bit space pointed to by the SL is the same (both are 32-bit compressed G-SIDs or 32-bit MPLS labels), and the MPLS label can be identified by the S flag, the SL can still be used as a pointer to the native 128-bit SID, while the SI can be expanded to serve as the position index for each MPLS label. Figure 6 The diagram shown is a schematic representation of the format of SRH encapsulation of G-SID and MPLS tags in an optional embodiment of the present invention.

[0117] Optionally, reading the MPLS tag in the G-SID container pointed to by the value of SL includes: reading the MPLS tag pointed to by the value of SI in the G-SID container pointed to by the value of SL according to the tag index SI, and decrementing the value of SI by 1; repeating the step of reading the MPLS tag pointed to by the value of SI in the G-SID container pointed to by the value of SL according to the tag index SI, and decrementing the value of SI by 1, until the value of SI is 0.

[0118] It should be noted that in the existing G-SRv6 definition, a G-SID Container can contain one native SRv6 SID or multiple compressed G-SIDs. In an optional embodiment of the present invention, the G-SID Container can be extended to contain four MPLS tags, wherein the SRH header SI index extension is used to point to the MPLS tags. In this way, the value of SI can be reset to 3 each time an MPLS tag in the G-SID Container is read; the value of SI is decremented by 1 after each MPLS tag is read; when the value of SI is equal to 0, it means that the MPLS tags in the G-SID Container have been read completely, and the value of SL is decremented by 1, and the reading of MPLS tags in the 128-bit G-SID Container space pointed to by the current SL begins.

[0119] In this embodiment of the invention, if the segment endpoint behavior type of the SID of the second node is END.COM, or if the SID of the second node carries COM Flavor, then the value of SL in the SRH header is decremented by 1, SI is reset to 3, and the MPLS label indexed by SI in the 128-bit G-SID Container space pointed to by the current SL is continuously read. In this process, the value of SI is decremented by 1 for each MPLS label read. When SI equals 0, the MPLS label pointed to by SI has been read. Then, the value of SL is decremented by 1, SI is reset to 3, and the 128-bit space pointed to by SL continues to be read until the last MPLS label with the S bit set (the determination of the last label in the MPLS label stack has a standard definition, i.e., it is determined by whether the S bit is set) is read. At this point, it indicates that the entire MPLS label stack has been read. SL is then decremented by 1, and the entire MPLS label stack is used as the outer encapsulation, with the original G-SRv6 message as the inner message. Finally, the 128-bit SID pointed to by SL in the SRH header (that is, the first SRv6 G-SID after the last label in the MPLS label stack) is replaced with the IPv6 destination address of the inner message. It should be noted that, according to the existing definition of G-SRv6, the starting SID of each network area is not compressed but remains 128 bits. Therefore, the SID pointed to by SL at this time is the first SID after leaving the MPLS network and entering the G-SRv6 network, which can be directly replaced with the destination address.

[0120] The following provides specific examples of the solutions provided in the embodiments of this application.

[0121] First, the relevant configuration in an optional embodiment of the present invention is as follows:

[0122] Nodes N0-N4 and N8-N12 are in the G-SRv6 domain. The G-SRv6 configurations for each device (i.e., node) are as follows:

[0123] The A::0:1::, A::1:1::, A::2:1::, A::3:1::, A::4:1:: of nodes N0-N4 and the A::8:1::, A::9:1::, A::A:1::, A::B:1::, A::C:1:: of nodes N8-N12 are all End type carrying SRv6SIDs of COC Flavor, that is, the SID that identifies the next node is a 32-bit compressed SID. The compressed SID can be represented as 0:1, 1:1, etc., which will not be listed here.

[0124] Node N4 is the boundary node for switching from the G-SRv6 domain to the MPLS domain, and node N8 is the boundary node for switching from the MPLS domain to the G-SRv6 domain.

[0125] Nodes N5-N8 are located in the SR MPLS domain, and the MPLS Node SIDs assigned to nodes N5-N8 are 1005-1008 respectively.

[0126] A::4:3:: is the SID of node N4. This SID is of type End and carries a COM flavor, which indicates that the next SID is in MPLS label format (i.e., the next SID is an MPLS label). A::B:2:: is the SID of node N11. This SID is of type End and does not carry any flavor. A::C:66:: is the VPN SID of type End.DT4 of node N12. In this example, it is not compressed.

[0127] The basic forwarding process of G-SRv6 and MPLS network co-location is as follows:

[0128] like Figure 8 As shown, node N0 is the first node in the end-to-end deployment path of the G-SRv6 network, i.e., the first node. Node N0 encapsulates the MPLS labels of nodes N5-N8 in the G-SRv6 message.

[0129] Nodes N1-N3 forward data according to the original G-SRv6 process, which will not be elaborated here.

[0130] Node N4 is the critical node between the G-SRv6 network and the MPLS network in the end-to-end deployment path of the G-SRv6 network; that is, node N4 is the second node.

[0131] When node N4 receives the packet (i.e., the first packet), the destination address A::4:3:: is node N4's local address. Node N4 looks up its local SRv6 SID table and confirms that its SID carries COM Flavor. It then reads the four MPLS labels 1005, 1006, 1007, and 1008 (corresponding to nodes N5, N6, N7, and N8, respectively) and encapsulates the entire MPLS label stack (all MPLS labels in the first packet) as the outer layer, using the original G-SRv6 packet as the inner layer. Next, it replaces the N9 node END SID A::9:1:: adjacent to the MPLS label in the SRH header with the IPv6 destination address field of the inner packet, resulting in the second packet encapsulated with MPLS labels. After that, it begins forwarding packets based on the encapsulated MPLS labels.

[0132] Nodes N5-N7 forward data according to the original process of the SR MPLS network, which will not be elaborated here.

[0133] When node N8 receives the packet, it pops the last label 1008 from the outer MPLS label stack. At this point, the packet becomes a G-SRv6 packet again and continues to be unicasted and forwarded according to the IPv6 destination address A::9:1::.

[0134] Nodes N9-N11 forward data according to the original G-SRv6 process, which will not be elaborated here;

[0135] When node N12 receives the packet, the destination address A::C:66:: is the local address of node N12. Node N12 looks up the local SRv6 SID table and confirms that the SID type of node N12 is END.DT4. Then, it looks up the local VPN instance corresponding to the SID of node N12. After decapsulating the packet with G-SRv6, the payload enters the corresponding VPN instance for private network forwarding.

[0136] In this embodiment, intermediate nodes of the MPLS network forward packets according to the outer MPLS label stack until the last label is popped and reaches the MPLS network boundary device (i.e., node N8). Here, the packet is forwarded by looking up the table based on the SID of the destination address field of the inner IPv6 packet and enters the G-SRv6 network. According to the existing definition of G-SRv6, the G-SID of the SRH can be read and forwarded further in the G-SRv6 network.

[0137] In this embodiment of the message processing method, when a G-SRv6 message arrives at the MPLS network ingress, the critical node between the G-SRv6 network and the MPLS network can identify that the G-SRv6 message is encapsulated with an MPLS label through an indicator. This allows the MPLS label to be extracted and encapsulated in the outer layer of the G-SRv6 message, enabling the G-SRv6 message to traverse the MPLS network and achieve end-to-end deployment of G-SRv6.

[0138] like Figure 9 As shown, an embodiment of the present invention provides a message processing apparatus applied to a second node, which is a critical node between the G-SRv6 network and the MPLS network in an end-to-end deployment path of a G-SRv6 network. The end-to-end deployment path of the G-SRv6 network includes G-SRv6 network nodes and MPLS network nodes, comprising:

[0139] The path acquisition module 910 is used to acquire the end-to-end deployment path of the G-SRv6 network;

[0140] The first processing module 920 is configured to encapsulate the MPLS label of the MPLS network node in a G-SRv6 message if the end-to-end deployment path of the G-SRv6 network includes a Multiprotocol Label Switching (MPLS) network node.

[0141] In this embodiment, the first node in the end-to-end deployment path of the G-SRv6 network can encapsulate the MPLS label of the MPLS network node in the G-SRv6 packet to achieve unified orchestration of the G-SRv6 network and the MPLS network. This allows the MPLS label to be extracted and encapsulated in the outer layer of the G-SRv6 packet when it is transmitted to the critical node between the G-SRv6 network and the MPLS network, thereby enabling the G-SRv6 packet to traverse the MPLS network and achieving a better technical effect of network-wide path planning.

[0142] In this embodiment, when the end-to-end deployment path of the G-SRv6 network includes MPLS network nodes, the message processing device can encapsulate the MPLS labels of the MPLS network nodes in the G-SRv6 message at the header node. This allows the MPLS labels to be extracted and encapsulated in the outer layer of the G-SRv6 message when it is transmitted to the critical node between the G-SRv6 network and the MPLS network, thereby enabling the G-SRv6 message to traverse the MPLS network and achieve end-to-end deployment of G-SRv6.

[0143] It should be noted that the resource configuration device provided in this embodiment of the invention can implement all the method steps implemented in the resource configuration method embodiment applied to the first node, and can achieve the same technical effect. Here, the parts that are the same as those in the method embodiment and the beneficial effects will not be described in detail.

[0144] like Figure 10 As shown, an embodiment of the present invention provides a message processing apparatus applied to a second node, which is a critical node between the G-SRv6 network and the MPLS network in an end-to-end deployment path of a G-SRv6 network. The end-to-end deployment path of the G-SRv6 network includes G-SRv6 network nodes and MPLS network nodes, comprising:

[0145] The message acquisition module 1010 is used to acquire a first message; wherein, the first message is a message obtained after the G-SRv6 message generated by the first node is transmitted to the second node;

[0146] The second processing module 1020 is used to process the first message to obtain a second message if the segment identifier (SID) of the second node carries an indication identifier; wherein the indication identifier is used to indicate that the next hop of the SID of the second node is an MPLS label, and the outer encapsulation of the second message is the MPLS label.

[0147] In this embodiment, the second node can determine that the G-SRv6 message contains an MPLS label by using an indicator, indicating that the next hop of the second node is a network node in the MPLS network. The second node then processes the first message to obtain a second message encapsulated with the MPLS label and sends it out. In this way, the second message can be forwarded normally in the MPLS network, thus enabling G-SRv6 messages to traverse the MPLS network and forming end-to-end path planning for the G-SRv6 network. This achieves the effect of smoothly upgrading and deploying G-SRv6 on existing network equipment, and the upgraded G-SRv6 network can coexist with MPLS networks that cannot be upgraded or are upgraded in stages.

[0148] Optionally, the indication identifier is: the segment endpoint behavior type of the SID of the second node, or a first identifier bound to the segment endpoint behavior type of the SID of the second node.

[0149] Optionally, the second processing module 1020 includes:

[0150] The first processing submodule is configured to extract the MPLS labels following the SID of the second node as an outer encapsulation and to use the G-SRv6 message as an inner message if the first message carries the indication identifier.

[0151] The second processing submodule is used to update the destination address of the first packet to the SID of the first G-SRv6 after the consecutive MPLS tags, so as to obtain the second packet.

[0152] Optionally, the first processing submodule includes:

[0153] The processing unit is configured to sequentially read the MPLS labels in the MPLS label stack of the first message and encapsulate the MPLS labels in the outer layer of the first message until the MPLS label stack has been read.

[0154] Optionally, the processing unit includes:

[0155] The first processing subunit is configured to read the MPLS tag in the G-SID container pointed to by the value of the remaining segment identifier SL, and decrement the value of SL by 1;

[0156] The second processing subunit is used to repeatedly execute the steps of reading the MPLS tag in the G-SID container pointed to by the value of SL according to SL, and decrementing the value of SL by 1, until the MPLS tag stack is completely read.

[0157] Optionally, the first processing subunit includes:

[0158] The third processing subunit is used to read the MPLS tag pointed to by the value of SI in the G-SID container pointed to by the value of SI according to SI, and decrement the value of SI by 1;

[0159] The fourth processing subunit is used to repeatedly execute the steps of reading the MPLS tag pointed to by the value of SI in the G-SID container pointed to by the value of SL according to the tag index SI, and decrementing the value of SI by 1 until the value of SI is 0.

[0160] Optionally, the second processing submodule includes:

[0161] The fifth processing subunit is used to update the destination address of the first packet according to the SID of the first G-SRv6 in the G-SID container pointed to by the target value of SL; wherein, the target value is the value of SL when the MPLS label stack is read.

[0162] In this embodiment, when a G-SRv6 packet arrives at the MPLS network ingress, the critical node between the G-SRv6 network and the MPLS network can identify that the G-SRv6 packet is encapsulated with an MPLS label through an indicator. This allows the MPLS label to be extracted and encapsulated in the outer layer of the G-SRv6 packet, enabling the G-SRv6 packet to traverse the MPLS network and achieve end-to-end deployment of G-SRv6.

[0163] It should be noted that the resource configuration device provided in this embodiment of the invention can implement all the method steps implemented in the resource configuration method embodiment applied to the second node, and can achieve the same technical effect. Here, the parts that are the same as those in the method embodiment and the beneficial effects will not be described in detail.

[0164] like Figure 11 As shown in the figure, a network device 1100 according to an embodiment of the present invention is a first node, including a processor 1110 and a transceiver 1120, wherein the processor is used for:

[0165] Obtain the end-to-end deployment path of the G-SRv6 network;

[0166] If the end-to-end deployment path of the G-SRv6 network includes a Multiprotocol Label Switching (MPLS) network node, then the MPLS label of the MPLS network node is encapsulated in the G-SRv6 message.

[0167] In this embodiment, the first node in the end-to-end deployment path of the G-SRv6 network can encapsulate the MPLS label of the MPLS network node in the G-SRv6 packet to achieve unified orchestration of the G-SRv6 network and the MPLS network. This allows the MPLS label to be extracted and encapsulated in the outer layer of the G-SRv6 packet when it is transmitted to the critical node between the G-SRv6 network and the MPLS network, thereby enabling the G-SRv6 packet to traverse the MPLS network and achieving a better technical effect of network-wide path planning.

[0168] In this embodiment, when the network device includes MPLS network nodes in the end-to-end deployment path of the G-SRv6 network, it can encapsulate the MPLS labels of the MPLS network nodes in the G-SRv6 packets at the header node. This allows the MPLS labels to be extracted and encapsulated in the outer layer of the G-SRv6 packets when they are transmitted to the critical node between the G-SRv6 network and the MPLS network, thereby enabling the G-SRv6 packets to traverse the MPLS network and achieve end-to-end deployment of G-SRv6.

[0169] like Figure 11As shown in the figure, a network device 1100 according to an embodiment of the present invention is a second node, which adopts the same structure as the first node, including a processor 1110 and a transceiver 1120, wherein the processor is used for:

[0170] Obtain the first message; wherein, the first message is the message obtained after the G-SRv6 message generated by the first node is transmitted to the second node;

[0171] If the segment identifier (SID) of the second node carries an indication identifier, the first message is processed to obtain the second message; wherein the indication identifier is used to indicate that the G-SRv6 message contains an MPLS label, and the outer encapsulation of the second message is the MPLS label.

[0172] In this embodiment, the second node can determine that the G-SRv6 message contains an MPLS label by using an indicator, indicating that the next hop of the second node is a network node in the MPLS network. The second node then processes the first message to obtain a second message encapsulated with the MPLS label and sends it out. In this way, the second message can be forwarded normally in the MPLS network, thus enabling G-SRv6 messages to traverse the MPLS network and forming end-to-end path planning for the G-SRv6 network. This achieves the effect of smoothly upgrading and deploying G-SRv6 on existing network equipment, and the upgraded G-SRv6 network can coexist with MPLS networks that cannot be upgraded or are upgraded in stages.

[0173] Optionally, the indication identifier is: the segment endpoint behavior type of the SID of the second node, or a first identifier bound to the segment endpoint behavior type of the SID of the second node.

[0174] Optionally, when the processor 1110 processes the first message to obtain the second message if the segment identifier (SID) of the second node carries an indication identifier, it specifically performs the following operations:

[0175] If the first message carries the indication identifier, then the MPLS label following the SID of the second node is extracted as the outer encapsulation, and the G-SRv6 message is used as the inner message.

[0176] The destination address of the first message is updated to the SID of the first G-SRv6 after the consecutive MPLS labels to obtain the second message.

[0177] Optionally, when the processor 1110 extracts the consecutive MPLS tags following the SID of the second node as the outer encapsulation and uses the G-SRv6 message as the inner message if the first message carries the indication identifier, it is specifically used for:

[0178] The MPLS labels in the MPLS label stack of the first message are read sequentially, and the MPLS labels are encapsulated in the outer layer of the first message until the MPLS label stack is completely read.

[0179] Optionally, the processor 1110 sequentially reads the MPLS labels in the MPLS label stack of the first packet and encapsulates the MPLS labels in the outer layer of the first packet until the MPLS label stack is completely read, specifically for:

[0180] Based on the remaining segment identifier SL, read the MPLS tag in the G-SID container pointed to by the value of SL, and decrement the value of SL by 1;

[0181] Repeat the steps of reading the MPLS tag in the G-SID container pointed to by the value of SL according to SL, and decrementing the value of SL by 1, until the MPLS tag stack is completely read.

[0182] Optionally, the processor 1110, when reading the MPLS tag in the G-SID container pointed to by the value of the SL, specifically uses the following methods:

[0183] Based on SI, read the MPLS tag pointed to by the value of SI in the G-SID container pointed to by the value of SI, and decrement the value of SI by 1;

[0184] Repeat the steps of reading the MPLS tag pointed to by the value of SI in the G-SID container pointed to by the value of SL according to the tag index SI, and decrementing the value of SI by 1 until the value of SI is 0.

[0185] Optionally, the processor 1110 updates the destination address of the first packet to the SID of the first G-SRv6 after the consecutive MPLS labels, specifically for:

[0186] The destination address of the first packet is updated according to the SID of the first G-SRv6 in the G-SID container pointed to by the target value of SL; wherein, the target value is the value of SL when the MPLS label stack is read.

[0187] In this embodiment, when a G-SRv6 packet arrives at the MPLS network ingress, the critical node between the G-SRv6 network and the MPLS network can identify that the G-SRv6 packet is encapsulated with an MPLS label through an indicator. This allows the MPLS label to be extracted and encapsulated in the outer layer of the G-SRv6 packet, enabling the G-SRv6 packet to traverse the MPLS network and achieve end-to-end deployment of G-SRv6.

[0188] A network device according to an embodiment of the present invention, such as Figure 12 As shown, it includes a transceiver 1210, a processor 1200, a memory 1220, and a program or instructions stored in the memory 1220 and executable on the processor 1200; when the processor 1200 executes the program or instructions, it implements the above-described message processing method applied to the first node or the second node.

[0189] The transceiver 1210 is used to receive and send data under the control of the processor 1200.

[0190] Among them, Figure 12 In this context, the bus architecture may include any number of interconnected buses and bridges, specifically linking various circuits together, represented by one or more processors (processor 1200) and memory (memory 1220). The bus architecture may also link together various other circuits such as peripheral devices, voltage regulators, and power management circuits, which are well known in the art and therefore will not be described further herein. The bus interface provides an interface. The transceiver 1210 may be multiple elements, including transmitters and receivers, providing a unit for communicating with various other devices over a transmission medium. The processor 1200 is responsible for managing the bus architecture and general processing, and the memory 1220 may store data used by the processor 1200 during operation.

[0191] This invention provides a readable storage medium storing a program or instructions. When executed by a processor, the program or instructions implement the steps of the message processing method described above and achieve the same technical effect. To avoid repetition, further details are omitted here. The computer-readable storage medium may include read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk.

[0192] It should be further noted that the terminals described in this specification include, but are not limited to, smartphones, tablets, etc., and many of the functional components described are referred to as modules in order to emphasize the independence of their implementation.

[0193] In this embodiment of the invention, the module can be implemented in software so that it can be executed by various types of processors. For example, an identified executable code module may include one or more physical or logical blocks of computer instructions, which may be constructed as objects, procedures, or functions. Nevertheless, the executable code of the identified module does not need to be physically located together, but may include different instructions stored in different bits, which, when logically combined, constitute the module and achieve the module's intended purpose.

[0194] In practice, an executable code module can be a single instruction or many instructions, and can even be distributed across multiple different code segments, different programs, and across multiple memory devices. Similarly, operational data can be identified within the module and can be implemented in any suitable form and organized within any suitable type of data structure. This operational data can be collected as a single dataset or distributed across different locations (including different storage devices), and can exist, at least in part, solely as electronic signals within the system or network.

[0195] When a module can be implemented using software, considering the current level of hardware technology, modules that can be implemented in software can be implemented using hardware circuits by those skilled in the art to achieve the corresponding functions, without considering cost. These hardware circuits include conventional very-large-scale integrated circuits (VLSI) or gate arrays, as well as existing semiconductors such as logic chips and transistors, or other discrete components. Modules can also be implemented using programmable hardware devices, such as field-programmable gate arrays, programmable array logic, and programmable logic devices.

[0196] The exemplary embodiments described above are with reference to the accompanying drawings. Many different forms and embodiments are feasible without departing from the spirit and teachings of the invention. Therefore, the invention should not be construed as limiting the exemplary embodiments set forth herein. Rather, these exemplary embodiments are provided to make the invention complete and convey the scope of the invention to those skilled in the art. In these drawings, component dimensions and relative dimensions may be exaggerated for clarity. The terminology used herein is for the purpose of describing particular exemplary embodiments only and is not intended to be limiting. As used herein, unless clearly indicated otherwise, the singular forms “a,” “an,” and “the” are intended to include all such forms. It will be further understood that the terms “comprising” and / or “including”, when used in this specification, indicate the presence of the stated features, integers, steps, operations, components, and / or elements, but do not exclude the presence or addition of one or more other features, integers, steps, operations, components, and / or groups thereof. Unless otherwise indicated, when stated, a range of values ​​includes the upper and lower limits of the range and any subranges in between.

[0197] The above description represents the preferred embodiments of the present invention. It should be noted that those skilled in the art can make various improvements and modifications without departing from the principles of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.

Claims

1. A packet processing method applied to a second node, the second node being a critical node of a G-SRv6 network and an MPLS network in an end-to-end deployment path of the G-SRv6 network, the end-to-end deployment path of the G-SRv6 network comprising G-SRv6 network nodes and MPLS network nodes, the method comprising: The method comprises: ​ acquiring a first packet; wherein the first packet is a packet obtained after a G-SRv6 packet generated by a first node is transmitted to the second node; if an indication identifier is carried in a segment identifier (SID) of the second node, processing the first packet to obtain a second packet; wherein the indication identifier is used to indicate that a next hop of the SID of the second node is an MPLS label, and outer encapsulation of the second packet is the MPLS label; wherein the indication identifier is a segment endpoint behavior type of the SID of the second node, or a first identifier bound to the segment endpoint behavior type of the SID of the second node.

2. The method of claim 1, wherein, The step of processing the first packet to obtain a second packet if an indication identifier is carried in a segment identifier (SID) of the second node comprises: if the indication identifier is carried in the first packet, taking out MPLS labels continuous after the SID of the second node as outer encapsulation, and taking the G-SRv6 packet as an inner packet; updating a destination address of the first packet to a first G-SRv6 SID after the continuous MPLS labels to obtain the second packet.

3. The method of claim 2, wherein, The step of taking out MPLS labels continuous after the SID of the second node as outer encapsulation if the indication identifier is carried in the first packet, and taking the G-SRv6 packet as an inner packet comprises: reading MPLS labels in an MPLS label stack in the first packet in sequence, and encapsulating the MPLS labels in an outer layer of the first packet until the MPLS label stack is read completely.

4. The method of claim 3, wherein, The step of reading MPLS labels in an MPLS label stack in the first packet in sequence, and encapsulating the MPLS labels in an outer layer of the first packet until the MPLS label stack is read completely comprises: reading the MPLS labels in a G-SID container pointed to by a value of a segment identifier (SL) according to the SL, and reducing the value of the SL by 1; repeating the steps of reading the MPLS labels in the G-SID container pointed to by the value of the SL according to the SL, and reducing the value of the SL by 1 until the MPLS label stack is read completely.

5. The method of claim 4, wherein, The step of reading the MPLS labels in the G-SID container pointed to by the value of the SL comprises: reading the MPLS labels in the G-SID container pointed to by a value of a label index (SI) according to the SI, and reducing the value of the SI by 1; repeating the steps of reading the MPLS labels in the G-SID container pointed to by the value of the SI according to the SI, and reducing the value of the SI by 1 until the value of the SI is 0.

6. The method of claim 2, wherein, The step of updating the destination address of the first packet to the first G-SRv6 SID after the continuous MPLS labels comprises: Update a destination address of the first packet according to a first G-SRv6 in a G-SID container pointed by a target value of the SL, wherein the target value is a value of the SL when the MPLS label stack is read completely.

7. A packet processing apparatus applied to a second node, the second node being a critical node of a G-SRv6 network and an MPLS network in an end-to-end deployment path of the G-SRv6 network, the end-to-end deployment path of the G-SRv6 network comprising G-SRv6 network nodes and MPLS network nodes, characterized in that, Comprise: A packet acquisition module, configured to acquire a first packet; wherein the first packet is a packet obtained after a G-SRv6 packet generated by a first node is transmitted to the second node; A second processing module, configured to process the first packet to obtain a second packet if an indication identifier is carried in a segment identifier (SID) of the second node; wherein the indication identifier is used to indicate that a next hop of the SID of the second node is an MPLS label, and an outer encapsulation of the second packet is the MPLS label; Wherein the indication identifier is a segment endpoint behavior type of the SID of the second node, or a first identifier bound on the segment endpoint behavior type of the SID of the second node.

8. A network device, the network device being a second node, the second node being a critical node of a G-SRv6 network and an MPLS network in an end-to-end deployed path of the G-SRv6 network, the end-to-end deployed path of the G-SRv6 network comprising G-SRv6 network nodes and MPLS network nodes, comprising: A transceiver and a processor; The processor is configured to: Acquire a first packet; wherein the first packet is a packet obtained after a G-SRv6 packet generated by a first node is transmitted to the second node; Process the first packet to obtain a second packet if an indication identifier is carried in a segment identifier (SID) of the second node; wherein the indication identifier is used to indicate that a next hop of the SID of the second node is an MPLS label, and an outer encapsulation of the second packet is the MPLS label; Wherein the indication identifier is a segment endpoint behavior type of the SID of the second node, or a first identifier bound on the segment endpoint behavior type of the SID of the second node.

9. A network device comprising: A transceiver, a processor, a memory, and a program or instructions stored on the memory and executable on the processor; characterized in that, When the network device is the second node, the processor implements the steps in the packet processing method of any one of claims 1 to 6 when executing the program or instructions; wherein the second node is a critical node of a G-SRv6 network and an MPLS network in an end-to-end deployment path of the G-SRv6 network.

10. A readable storage medium, on which a program or instructions are stored, characterized in that, The program or instructions are executable on the processor to implement the steps in the packet processing method of any one of claims 1 to 6.

Citation Information

Patent Citations

  • Packet network interworking including segment routing

    CN111713079A