CN115333896A - Method, equipment and system for forwarding message - Google Patents

Method, equipment and system for forwarding message Download PDF

Info

Publication number
CN115333896A
CN115333896A CN202110444013.8A CN202110444013A CN115333896A CN 115333896 A CN115333896 A CN 115333896A CN 202110444013 A CN202110444013 A CN 202110444013A CN 115333896 A CN115333896 A CN 115333896A
Authority
CN
China
Prior art keywords
packet
network device
header
information
tunnel
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
CN202110444013.8A
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.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
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 Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN202110444013.8A priority Critical patent/CN115333896A/en
Publication of CN115333896A publication Critical patent/CN115333896A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/46Interconnection of networks
    • H04L12/4633Interconnection of networks using encapsulation techniques, e.g. tunneling
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/74Address processing for routing

Landscapes

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

Abstract

The application provides a method, equipment and a system for forwarding a message. The method comprises the following steps: the method comprises the steps that a first network device receives a first message from a second network device, wherein the first message comprises a first message header, and the first message header comprises identification information; the first network equipment determines tunnel information according to the identification information; the first network device generates a second message based on the first message, wherein the second message includes a second message header, the second message header includes the tunnel information, and a tunnel corresponding to the tunnel information is used for forwarding the second message. When the message forwarding method provided by the application is used for forwarding the message, the second network equipment does not need to sense the tunnel information, the exchange of the tunnel information between the first network equipment and the second network equipment is not needed, and the message forwarding can be flexibly realized.

Description

Method, equipment and system for forwarding message
Technical Field
The present application relates to the field of network communication technologies, and in particular, to a method, a device, and a system for forwarding a packet.
Background
Tunneling (tunnel) technology is a way to transfer data between networks through the internet infrastructure, and the data transferred using tunneling may be data frames or packets of different protocols. In the tunnel technology, a tunnel packet header is encapsulated at the outer layer for data frames or data packets of different protocols on tunnel entrance equipment to obtain a tunnel message, and the tunnel message is forwarded between equipment at two ends of a tunnel through a public internet. Once the tunnel message reaches the tunnel's egress device, the tunnel message is decapsulated and forwarded to the final destination. In the whole transmission process, a logical path through which the tunnel message is transmitted on the public internet is called a tunnel. Tunneling is the overall process that includes data encapsulation, transmission, and decapsulation.
When forwarding service data based on the existing tunnel technology, the user access device needs to sense internal information of the public internet (for example, tunnel path information for forwarding service data in the public internet), and in the process of forwarding a message, the user access device needs to perform more interaction with edge devices of the public internet, and the implementation is complex, so that the speed of forwarding the message is low.
Disclosure of Invention
The application provides a method, equipment and a system for forwarding a message, which can flexibly realize the forwarding of the message.
In a first aspect, a method for forwarding a packet is provided, where the method includes:
the method comprises the steps that a first network device receives a first message from a second network device, wherein the first message comprises a first message header, and the first message header comprises identification information;
the first network equipment determines tunnel information according to the identification information;
the first network device generates a second message based on the first message, wherein the second message includes a second message header, the second message header includes the tunnel information, and a tunnel corresponding to the tunnel information is used for forwarding the second message.
The first network device may determine the tunnel information according to the identification information, that is, after recognizing that the first packet header of the received first packet carries the identification information, the first network device may determine the tunnel information for forwarding the first packet according to the identification information. In the process of forwarding the second packet, the first network device does not need to perform more interaction with the second network device (e.g., the second network device interacts with the first network device to sense the internal path information of the network accessed by the first network device, etc.).
In the above technical solution, the first network device may determine the tunnel information according to the identification information included in the first packet header of the first packet from the second network device, and generate the second packet based on the tunnel information, and forward the packet based on the method without the second network device perceiving the tunnel information, and without exchanging the tunnel information between the first network device and the second network device, the packet forwarding process is relatively simple, and the packet forwarding can be flexibly implemented.
With reference to the first aspect, in certain implementations of the first aspect,
the identification information is a Binding Segment Identifier (BSID); or,
the identification information is a tunnel identifier (tunnel ID).
The identification information is a BSID, which may be understood as that the value of the identification information is the same as that of the BSID, or the identification information is the BSID. The identification information is a tunnel identifier, which is understood to mean that the value of the identification information is the same as the value of the tunnel identifier, or the identification information is a tunnel identifier, which is used to uniquely identify a tunnel. When the second header carries the SRH, the identification information may be a BSID or a tunnel identifier. When the second header does not carry the SRH, the identification information may be a tunnel identification.
In the above technical solution, the first network device may determine the tunnel information according to the BSID or the tunnel identifier carried in the first packet header, and the manner of determining the tunnel information is relatively simple, which is beneficial to improving the flexibility of packet forwarding.
With reference to the first aspect, in certain implementations of the first aspect,
the tunnel information includes segment identifier list information (SID) list of a tunnel corresponding to the tunnel information; or,
the tunnel information includes source node information of a tunnel corresponding to the tunnel information and destination node information of the tunnel corresponding to the tunnel information.
When the tunnel information includes the segment identifier list information SID list of the tunnel corresponding to the tunnel information, the tunnel may be an Internet Protocol version 6 (Internet Protocol version 6, IPv 6) Segment Routing (SR) tunnel, and the IPv6 SR is also called an IPv6data plane-based segment routing (SRv 6). When the tunnel information includes source node information of a tunnel corresponding to the tunnel information and destination node information of a tunnel corresponding to the tunnel information, the tunnel includes, but is not limited to: GRE tunnels, multi-Protocol label switching (MPLS) tunnels, internet Protocol version 4 (IPv 4) tunnels, and IPv6 tunnels.
With reference to the first aspect, in some implementation manners of the first aspect, the type of the first header is a specific type, and the first header is used to carry the identification information. Optionally, the type of the first header is a newly defined type or an existing type of the header in the embodiment of the present application.
The type of the first packet header is a specific type, and it may be understood that, a field in the first packet header may indicate that the type of the first packet header is the specific type, and the field is a routing type field or a routing field, based on which, it may be determined that the first packet header carries identification information.
With reference to the first aspect, in some implementations of the first aspect, the type of the first header is different from the type of the second header.
The type of the first header is different from the type of the second header, and it can be understood that the first header and the second header are both IP headers, but the extension type of the first header is different from the extension type of the second header. Illustratively, the extension type of the first header is a type for carrying the above-mentioned identification information (e.g., the extension type of the first header is an extension based on an IPv4 header), and the extension type of the second header is an SRH. The type of the first header is different from that of the second header, and it can be understood that the first header is not extended and the second header is extended.
With reference to the first aspect, in some implementation manners of the first aspect, the second packet header is a Segment Routing Header (SRH).
And when the header of the second message is an SRH, the tunnel for forwarding the second message is an SRv6 tunnel. In one example, when the second header is an SRH, the first header is not an SRH. Illustratively, the first packet header may be an IPv4 header, and the first packet header may also be an extended IPv4 header, for example, the extended IPv4 header may be extended in a manner similar to the extension of a Generic Routing Encapsulation (GRE) header, and the first packet header may also be an IPv6 header or an extended IPv6 header, but is not an SRH.
With reference to the first aspect, in some implementation manners of the first aspect, the generating, by the first network device, a second packet based on the first packet includes:
the first network equipment adds the second message header in front of the message header of the service message carried by the first message; or,
the first network device adds the second message header in front of the first message header included in the first message.
In the above technical scheme, the first network device adds the second header before the first header, the packet encapsulation process is relatively simple, decapsulation of the first header is avoided, and improvement of flexibility in forwarding the packet is facilitated.
In combination with the first aspect, in certain implementations of the first aspect,
the first network device is an operator edge device, and the second network device is a user access device.
With reference to the first aspect, in certain implementations of the first aspect, the first network device stores a correspondence between the identification information and the tunnel information,
the first network device determines the tunnel information according to the identification information, and the method includes:
and the first network equipment determines the tunnel information according to the identification information and the corresponding relation.
With reference to the first aspect, in certain implementations of the first aspect, the method further includes:
the first network device sends the identification information to a controller, which is a controller for managing the second network device.
With reference to the first aspect, in some implementation manners of the first aspect, the first message further includes a destination address of a service packet sent by the second network device.
In the above technical solution, the first packet carries a destination address of the service packet, and the first network device can successfully forward the service packet carried in the first packet to the destination according to the determined tunnel, so as to meet a user requirement.
It is understood that the first network device performs the following operations when any one of the following conditions is satisfied:
the first network equipment determines the tunnel information according to the identification information; and
the first network equipment generates the second message based on the first message;
wherein, the condition satisfying any one of the following conditions includes: the first network device does not find the routing table according to the destination address of the first packet, or the first network device is not used for finding the routing table according to the destination address of the first packet.
In a second aspect, a method for forwarding a packet is provided, where the method includes:
the second network equipment receives the identification information from the controller;
the second network device generates a first message based on the identification information, and sends the first message, where the first message includes a first message header, the first message header includes the identification information, and the identification information corresponds to tunnel information used for forwarding the first message.
In the above technical solution, the first packet header of the first packet generated by the second network device carries identification information, and the identification information corresponds to the tunnel information used for forwarding the first packet, so that the network device receiving the first packet can determine the tunnel information for forwarding the first packet directly according to the identification information, and the second network device does not need to sense the tunnel information in the process, and therefore, the exchange of the tunnel information between the first network device and the second network device is not needed, the packet forwarding process is relatively simple, and the forwarding of the packet can be flexibly implemented.
With reference to the second aspect, in some implementation manners of the second aspect, the generating, by the second network device, the first packet based on the identification information includes:
the second network equipment receives the service message;
the second network device determines the identification information from the one or more candidate identification information according to any one or more of the following information, including at least:
one or more information in the five-tuple information of the service packet, a DSCP (differentiated services code point) of the service packet, a flow identifier of the service packet, an EXP field of the service packet, a CoS (class of service) of the service packet, or a TC (time series) field of the service packet.
The quintuple information of the service packet may specifically include: a source IP address, a source port, a destination IP address, a destination port, and a transport layer Protocol (e.g., internet Protocol (IP)).
In the above technical solution, the second network device may determine the identification information corresponding to the service according to the information of the identified service packet, thereby avoiding the network device that receives the first packet from identifying the service packet.
In combination with the second aspect, in certain implementations of the second aspect,
the identification information is a binding segment identifier BSID; or,
the identification information is a tunnel identifier.
In combination with the second aspect, in certain implementations of the second aspect,
the type of the first message header is a specific type, and the first message header is used for carrying the identified information.
With reference to the second aspect, in some implementations of the second aspect, the first packet header is not a segment routing header SRH.
It is understood that what is not described in detail in the system of the second aspect is the same as that of the first aspect, and specifically, reference may be made to what is described in the first aspect.
In a third aspect, a first network device is provided, which comprises means for a method of any one of the possible implementations of the first aspect.
In a fourth aspect, there is provided a second network device comprising means for a method of any one of the possible implementations of the second aspect described above.
In a fifth aspect, a system for forwarding a packet is provided, where the system includes: a first network device and a second network device,
the second network device is used for receiving identification information;
the second network device is further configured to generate a first packet based on the identification information and send the first packet, where the first packet includes a first packet header, the first packet header includes the identification information, and the identification information corresponds to tunnel information used for forwarding the first packet;
the first network equipment is used for receiving a first message from the second network equipment;
the first network equipment is also used for determining tunnel information according to the identification information;
the first network device is further configured to generate a second packet based on the first packet, where the second packet includes a second packet header, the second packet header includes the tunnel information, and a tunnel corresponding to the tunnel information is used to forward the second packet.
In the above technical solution, the first network device may determine the tunnel information according to the identification information included in the first packet header of the received first packet, and generate the second packet based on the tunnel information, and during the process of forwarding the second packet, the first network device does not need to perform more interaction with the second network device (e.g., the first network device sends the determined tunnel information to the second network device), which is beneficial to implementing fast forwarding of the packet.
With reference to the fifth aspect, in certain implementations of the fifth aspect,
the identification information is a binding segment identifier BSID; or,
the identification information is a tunnel identifier.
With reference to the fifth aspect, in certain implementations of the fifth aspect,
the tunnel information includes segment identifier list information SID list of a tunnel corresponding to the tunnel information; or,
the tunnel information includes source node information of a tunnel corresponding to the tunnel information and destination node information of the tunnel corresponding to the tunnel information.
With reference to the fifth aspect, in certain implementations of the fifth aspect,
the type of the first message header is a specific type, and the first message header is used for carrying the identified information.
With reference to the fifth aspect, in certain implementations of the fifth aspect,
the first header is of a different type than the second header.
With reference to the fifth aspect, in certain implementations of the fifth aspect,
the type of the second header is a segment routing header SRH.
With reference to the fifth aspect, in some implementation manners of the fifth aspect, the generating, by the second network device, a first packet based on the identification information includes:
the second network equipment is also used for receiving the service message;
the second network device is further configured to determine the identification information from the one or more candidate identification information according to any one or more of the following information, where the any one or more of the following information at least includes:
one or more pieces of information in the five-tuple information of the service packet, a Differentiated Services Code Point (DSCP) of the service packet, a stream identifier of the service packet, an EXP field of the service packet, a class of service (CoS) of the service packet, or a TC field of the service packet.
It is to be understood that, in case the first condition is satisfied, the first network device is further configured to perform the following operations:
the first network device is used for determining the tunnel information according to the identification information; and
the first network device is configured to generate the second packet based on the first packet;
wherein the satisfying the first condition comprises: the first network device is configured to not find the routing table according to the destination address of the first packet, or the first network device is not configured to find the routing table according to the destination address of the first packet.
With reference to the fifth aspect, in some implementation manners of the fifth aspect, the generating, by the first network device, a second packet based on the first packet includes:
the first network device is configured to add the second packet header in front of a packet header of a service packet carried by the first packet; or,
the first network device is further configured to add the second header to the first packet included in the first packet.
With reference to the fifth aspect, in some implementations of the fifth aspect, the first network device stores a correspondence between the identification information and the tunnel information,
the first network device is configured to determine tunnel information according to the identification information, and includes:
the first network device is configured to determine the tunnel information according to the identification information and the corresponding relationship.
With reference to the fifth aspect, in certain implementations of the fifth aspect, the system further includes a second controller, the second controller being a controller for managing the second network device,
the second network device is configured to receive identification information, and includes:
the second controller is configured to send the identification information to the second network device;
the second network device is configured to receive the identification information.
Wherein, in some implementations, the second controller may be referred to as an NCE-Super controller.
With reference to the fifth aspect, in certain implementations of the fifth aspect, the system further includes a first controller, the first controller being a controller for managing the first network device,
the first controller is further configured to send the corresponding relationship to the first network device, so that the corresponding relationship is stored in the first network device.
Wherein, in some implementations, the first controller may be referred to as an NCE-IP controller.
With reference to the fifth aspect, in certain implementations of the fifth aspect, the system further includes a first controller, the first controller being a controller for managing the first network device,
the first network device or the first controller is further configured to send the identification information to the second controller;
the second controller is further configured to send the identification information to the second network device.
The first controller may send the identification information to the second controller through a northbound interface (northbound interface). For example, the northbound interface may be a Restful interface.
With reference to the fifth aspect, in certain implementations of the fifth aspect, the first controller and the second controller are the same controller.
In the above technical solution, the first controller and the second controller are the same controller, and based on this, interaction between the first controller and the second controller is avoided, which is beneficial to reducing communication overhead.
With reference to the fifth aspect, in some implementations of the fifth aspect, the first network device is an operator edge device, and the second network device is a user access device.
It is understood that what is not described in detail in the system according to the fifth aspect is the same as that described in the first aspect and the second aspect, and in particular, reference may be made to what is described in the first aspect and the second aspect.
In a sixth aspect, the present application provides a first network device, where the first network device has a function of implementing the method in any one of the first aspect and the possible implementation manners of the first aspect. The functions may be implemented by hardware, or by hardware executing corresponding software. The hardware or software includes one or more units corresponding to the above functions.
In a seventh aspect, the present application provides a second network device, where the second network device has a function of implementing the method in any possible implementation manner of the second aspect and the second aspect. The functions may be implemented by hardware, or by hardware executing corresponding software. The hardware or software includes one or more units corresponding to the above functions.
In an eighth aspect, the present application provides a first network device or other combined devices, components and the like that can implement the functions of the first network device, including at least one processor and a communication interface. The at least one processor is configured to execute a computer program or instructions to enable the first network device to implement the communication method in any one of the possible implementations of the first aspect and the first aspect.
Optionally, the first network device further comprises at least one memory coupled with the at least one processor, the computer program or instructions being stored in the at least one memory. Wherein the memory may be integrated with the processor or provided separately from the processor.
In one implementation, the first network device is a first network device. When the first network device is a first network device, the communication interface may be a transceiver, or an input/output interface.
In another implementation, the first network device is a chip or a system-on-a-chip. When the first network device is a chip or a system of chips, the communication interface may be an input/output interface, an interface circuit, an output circuit, an input circuit, a pin or related circuit on the chip or the system of chips, and the like. A processor may also be embodied as a processing circuit or a logic circuit.
In another implementation, the first network device is a chip or a system of chips configured in the first network device.
Alternatively, the transceiver may be a transceiver circuit. Alternatively, the input/output interface may be an input/output circuit.
In a ninth aspect, the present application provides a second network device or other combined devices, components and the like that can implement the functions of the second network device, including at least one processor and a communication interface. The at least one processor is configured to execute a computer program or instructions to enable the second network device to implement the communication method in any one of the second aspect and the possible implementation manner of the second aspect.
Optionally, the second network device further comprises at least one memory coupled with the at least one processor, the computer program or instructions being stored in the at least one memory. Wherein the memory may be integrated with the processor or provided separately from the processor.
In one implementation, the second network device is a second network device. When the second network device is a second network device, the communication interface may be a transceiver, or an input/output interface.
In another implementation, the second network device is a chip or a system-on-a-chip. When the second network device is a chip or a system of chips, the communication interface may be an input/output interface, an interface circuit, an output circuit, an input circuit, a pin or related circuit on the chip or the system of chips, etc. A processor may also be embodied as a processing circuit or a logic circuit.
In another implementation, the second network device is a chip or a system of chips configured in the second network device.
Alternatively, the transceiver may be a transmit-receive circuit. Alternatively, the input/output interface may be an input/output circuit.
A tenth aspect provides a computer-readable storage medium for storing a computer program comprising instructions for performing the method of the first aspect or the second aspect above, and any possible implementation of the first aspect or the second aspect above.
In an eleventh aspect, a chip system is provided, comprising at least one processor and an interface; the at least one processor is configured to invoke and execute a computer program to enable the chip system to execute the instructions of the first aspect or the second aspect, and the method in any possible implementation manner of the first aspect or the second aspect.
The chip system may be a System On Chip (SOC), a baseband chip, and the like, where the baseband chip may include a processor, a channel encoder, a digital signal processor, a modem, an interface module, and the like.
In a twelfth aspect, a system for forwarding a packet is provided, where the system includes the foregoing first network device and the foregoing first network device, or the system includes the foregoing first network device, the foregoing second network device, the foregoing first controller, and the foregoing second controller.
Drawings
Fig. 1 is a schematic diagram of a system architecture 100 according to an embodiment of the present application.
Fig. 2 is a schematic flow chart of a method 200 for forwarding a packet according to an embodiment of the present application.
Fig. 3 is a schematic diagram of a header format of a first packet according to an embodiment of the present disclosure.
Fig. 4 is a schematic diagram of another header format of a first packet according to an embodiment of the present application.
Fig. 5 is a schematic format diagram of a second packet generated by a first network device according to an embodiment of the present application.
Fig. 6 is a schematic diagram of a method 600 for forwarding a packet according to an embodiment of the present application.
Fig. 7 is a schematic diagram of a first network device 700 according to an embodiment of the present application.
Fig. 8 is a schematic diagram of a second network device 800 according to an embodiment of the present application.
Fig. 9 is a schematic hardware structure diagram of a network device 900 according to an embodiment of the present disclosure.
Fig. 10 is a schematic diagram of a system 1000 for forwarding a packet according to an embodiment of the present application.
Detailed Description
The technical solution in the present application will be described below with reference to the accompanying drawings.
The terminology used in the description of the embodiments section of the present application is for the purpose of describing particular embodiments of the present application only and is not intended to be limiting of the present application.
The terms "first," "second," "third," and the like in this application are used for distinguishing between similar or identical items having substantially the same function and/or functionality, and it should be understood that "first," "second," and "third" do not have a logical or chronological dependency, and do not limit the number or order of execution.
This application is intended to present various aspects, embodiments, or features around a system that may include a number of devices, components, modules, and the like. It is to be understood and appreciated that the various systems may include additional devices, components, modules, etc. and/or may not include all of the devices, components, modules etc. discussed in connection with the figures. Furthermore, a combination of these schemes may also be used.
In addition, in the embodiments of the present application, words such as "exemplary", "for example", etc. are used to mean serving as examples, illustrations or explanations. Any embodiment or design described herein as "exemplary" is not necessarily to be construed as preferred or advantageous over other embodiments or designs. Rather, the term using examples is intended to present concepts in a concrete fashion.
The network architecture and the service scenario described in the embodiment of the present application are for more clearly illustrating the technical solution of the embodiment of the present application, and do not form a limitation on the technical solution provided in the embodiment of the present application, and as a person of ordinary skill in the art knows that along with the evolution of the network architecture and the appearance of a new service scenario, the technical solution provided in the embodiment of the present application is also applicable to similar technical problems.
Reference throughout this specification to "one embodiment" or "some embodiments," or the like, means that a particular feature, structure, or characteristic described in connection with the embodiment is included in one or more embodiments of the present application. Thus, appearances of the phrases "in one embodiment," "in some embodiments," "in other embodiments," or the like, in various places throughout this specification are not necessarily all referring to the same embodiment, but rather "one or more but not all embodiments" unless specifically stated otherwise. The terms "comprising," "including," "having," and variations thereof mean "including, but not limited to," unless expressly specified otherwise.
In the present application, "at least one" means one or more, "a plurality" means two or more. "and/or" describes the association relationship of the associated object, indicating that there may be three relationships, for example, a and/or B, which may indicate: a alone, A and B together, and B alone, wherein A and B may be singular or plural. The character "/" generally indicates that the former and latter associated objects are in an "or" relationship. "at least one of the following" or similar expressions refer to any combination of these items, including any combination of the singular or plural items. For example, at least one (one) of a, b, or c, may represent: a, b, c, a-b, a-c, b-c, or a-b-c, wherein a, b, c may be single or multiple.
Next, a related art of the embodiment of the present application is described:
first, a system architecture suitable for the embodiment of the present application is described with reference to fig. 1.
Fig. 1 is a schematic diagram of a system architecture 100 according to an embodiment of the present disclosure.
As shown in fig. 1, the system architecture 100 includes: a plurality of nodes (i.e., node a, node B, node C, node D, node E), a user access device 110, a user access device 120, a controller 130, and a controller 140.
Each of the plurality of nodes may be a network device or a network element (network element) in a network (e.g., an operator network), etc. Taking node a as an example, node a may be a switch, router, repeater, or host in an operator network, for example. Wherein, the node A and the node E can communicate through the tunnel. The node a is also called an entry node of the tunnel, and is configured to receive a packet from the user access device 100, perform tunnel encapsulation on the obtained packet, and send the encapsulated tunnel packet according to an encapsulated tunnel path. The node E is also referred to as an egress node of the tunnel, and the node E is configured to acquire a packet sent by the node E, and may perform tunnel decapsulation on the acquired packet, search for a route, send the decapsulated packet to the user access device 120, and send the decapsulated packet to a destination terminal device (not shown in fig. 1) by the user access device 120. A Virtual Private Network (VPN) service may be configured on node a and node E, and is used to connect user equipment 110 and user access equipment 120. The node B, the node C and the node D are intermediate nodes in the tunnel, and are configured to forward the received tunnel packet.
In some implementations, the nodes a and E may be ACC devices or provider edge routers (PEs), and the nodes B, C, and D may be any one of the following devices: PE equipment or provider backbone routers (P). Illustratively, node a is an ACC device, node E is a PE device, node B is a PE device, node C is a PE device, and node D is a P device.
The network type of the network to which the plurality of nodes access is not particularly limited. In an example, the network accessed by the plurality of nodes may be Internet Protocol version 6 (Internet Protocol version 6, IPv 6), based on which the node a may perform IPv6 encapsulation on the obtained packet, and at this time, the tunnel for the node a and the node E to communicate may be an IPv6 tunnel or an SRv6 tunnel. In another example, the network accessed by the plurality of nodes may be Internet Protocol version 4 (IPv 4), based on which the node a may perform IPv4 encapsulation on the obtained packet, and at this time, a tunnel for the node a and the node E to communicate may be an IPv4 tunnel. In another example, the network accessed by the plurality of nodes may be a multi-protocol label switching (MPLS) network, based on which the node a may perform MPLS encapsulation on the acquired packet, and at this time, a tunnel for the node a and the node E to communicate may be an MPLS tunnel.
The user access device 110 may be connected to one or more terminal devices (not shown in fig. 1) through a Local Area Network (LAN). The user access device 110 is configured to encapsulate (e.g., internet Protocol (IP) encapsulation, generic Routing Encapsulation (GRE), or MPLS encapsulation) a service packet of a received terminal device, and send the encapsulated packet to an entry node (i.e., node a) of a network, which is also called an entry node of a tunnel, where the user access device 120 may be connected to one or more terminal devices (not shown in fig. 1) through a LAN, and the user access device 120 is configured to receive a packet sent by the node E, and send the received packet to a destination terminal device (not shown in fig. 1) corresponding to a destination address based on the destination address carried in the packet.
The controller 130 is a controller for managing an ingress node (i.e., node a) and an egress node (i.e., node E) of the network. For example, the controller 130 may issue configuration information to the ingress node, where the configuration information includes a correspondence between the identification information and the tunnel information. Alternatively, in some implementations, the controller 130 may be referred to as an NCE-IP controller.
The controller 140 is a controller for managing the user access devices (i.e., the user access device 110 and the user access device 120). The controller 140 may interact with the controller 130 via a northbound interface (e.g., restful interface) to obtain configuration information that the controller 130 configures to a network entry node (i.e., node a). For example, the controller 140 may send the configuration information obtained from the controller 130 to the user access device 110. Alternatively, in some implementations, the controller 140 may be referred to as an NCE-Super controller.
Alternatively, the controller 130 and the controller 140 may be the same controller, and in this case, the one controller has the functions of the controller 130 and the controller 140.
It should be understood that fig. 1 is only an illustration and does not constitute any limitation to the system architecture provided by the embodiments of the present application. For example, a greater number of tunnels may also be included between node a and node E. For example, the operator network in which the plurality of nodes in system architecture 100 reside may also include a greater or lesser number of nodes. For example, only one controller may be included in the system architecture 100, in which case the one controller has both the functions of the controller 130 and the functions of the controller 140.
The embodiment of the application provides a new message forwarding method, which can flexibly realize the forwarding of the message. The new message forwarding method has low requirement on the capability of encapsulating the message by the user access equipment (for example, the user access equipment only needs to support simple IP encapsulation), and the new message forwarding method can shield the internal information of the network (for example, an operator network) to which the user access equipment is accessed from the user access equipment, and shield the specific information (for example, service information or configuration information and the like) deployed in the user access equipment from the network to which the user access equipment is accessed.
Next, a method for forwarding a packet provided in the embodiment of the present application is described in detail with reference to fig. 2 to fig. 6.
Fig. 2 is a schematic flow chart of a method 200 for forwarding a packet according to an embodiment of the present application.
As shown in fig. 2, the method 200 includes steps 210 to 240. The method 200 may be, but is not limited to, applied to the system architecture 100 shown in fig. 1 and 2, in which case, the first network device in the method 200 may be the node a in the system architecture 100, and the second network device may be the user access device 110. Next, steps 210 to 240 will be described in detail.
In step 210, the second network device generates a first packet based on the identification information, where the first packet includes a first packet header, and the first packet header includes the identification information, where the identification information corresponds to tunnel information used for forwarding the first packet.
Optionally, the following steps may be further included before the step 210:
the second network device receives the identification information transmitted from the controller.
Wherein the controller is a controller for managing the second network device. Illustratively, when the second network device is a user access device 110 in the system architecture 100, the controller may be the controller 140 in the system architecture 100. It is to be understood that, before the second network device generates the first packet based on the identification information, one or more identification information may be stored in the second network device, where the one or more identification information are one or more candidate identification information for the service packet received by the second network device.
In one example, the identification information sent by the controller to the second network device may be the controller receiving the identification information from the first network device or the controller managing the first network device. When the controller is connected with the controller for managing the first network device and is two independent controllers, the controller can receive the identification information from the controller for managing the first network device through the northbound interface. Illustratively, when the first network device is node a in the system architecture 100, the controller managing the first network device may be the controller 130 in the system architecture 100. It can be understood that the identification information stored in the first network device may be information included in configuration information that is issued to the first network device by a controller that manages the first network device.
The controller includes, but is not limited to, sending the identification information to the second network device based on any one of the following protocols: a network configuration protocol (Netconf), a Border Gateway Protocol (BGP) -based SR tunnel, or a path computing element communication protocol (PCEP).
Wherein the controller may obtain the identification information from the controller managing the first network device via the Restful interface.
In step 210, the first packet header includes the identification information, and it can be understood that the first packet header is a packet header for carrying the identification information. That is to say, after receiving a message including a first header, the network device may identify the message and then obtain identification information carried by the first header in the message.
In step 210, the identification information corresponds to the tunnel information for forwarding the first packet, and the identification information may be understood as information that shields the tunnel information for forwarding the first packet and is available to the third-party network. Based on this, the third-party network does not need to sense the specific tunnel information, such as the tunnel path information, for forwarding the first packet.
In step 210, the generating, by the second network device, the first message based on the identification information includes:
the second network equipment receives the service message;
the second network device determines identification information from the one or more candidate identification information according to any one or more of the following information, wherein the any one or more of the following information at least comprises:
one or more pieces of information in the five-tuple information of the service packet, a Differentiated Services Code Point (DSCP) of the service packet, a stream identifier of the service packet, an EXP field of the service packet, a class of service (CoS) of the service packet, or a TC field of the service packet.
The quintuple information of the service packet may include: source end IP address, source port, destination end IP address, destination port, and transport layer protocol (e.g., IP protocol).
In the embodiment of the present application, a manner of determining the identification information from the plurality of candidate identification information based on any one or more of the above-mentioned information is not particularly limited. For example, the second network device stores a plurality of pieces of acquired candidate identification information (i.e., a plurality of pieces of identification information acquired from the controller) and CoS of a service packet of a plurality of service packets corresponding to the plurality of pieces of candidate identification information, based on which, after receiving the service packet #1, the second network device determines, from the plurality of pieces of candidate identification information, one piece of identification information corresponding to the service packet #1 according to the CoS carried in the service packet #1, and the CoS of the service packet corresponding to the one piece of identification information is the same as the CoS in the service packet #1, where the CoS of the plurality of services corresponding to the plurality of pieces of candidate identification information stored in the second network device may be information included in configuration information sent to the second network device by the controller, and the controller is used for managing the second network device. Exemplarily, the second network device stores a mapping relationship between the identification information and the color, where the mapping relationship may be configured in the second network device in advance, and a value of the color is used to represent different bearing appeals, and the color does not represent a certain actual tunnel but represents a set of tunnels with a class of bearing capacity, for example, red of the value of the color is a service appeal of a low latency class, and green of the value of the color is a service appeal of a high bandwidth guarantee class with an unfavorable latency. After the second network device receives the service packet #1, one color #1 may be matched according to the flow identifier of the service packet #1, and the identification information corresponding to the color #1 stored in the second network device is the identification information #1, based on which, the second network device may determine the service packet #1 and the identification information #1.
In this embodiment, the type of the first packet header is a specific type, and the first packet header is used to carry the identification information. Optionally, the type of the first header is a newly defined type or an existing type of the header in the embodiment of the present application.
The type of the first header is a specific type, and it can be understood that the type of the first header is indicated to be the specific type through a field in the first header, and the field is a routing type field or a routing field, based on which it can be determined that the first header carries identification information.
In some implementations, the first header is not a Segment Routing Header (SRH). For example, the first packet header may be an IPv4 header or an extended IPv4 header, and the extended IPv4 header may carry an existing packet header (e.g., a GRE header or an MPLS header, etc.) or a newly defined packet header. Alternatively, the first header may be an IPv6 encapsulated extension header, but the header does not include the SRH.
Optionally, the identification information is a Binding Segment Identifier (BSID); alternatively, the identification information is a tunnel identifier (tunnel id).
The identification information is a BSID, which may be understood as that the value of the identification information is the same as that of the BSID, or the identification information is the BSID. The identification information is a tunnel identifier, which may be understood as the value of the identification information being the same as the value of the tunnel identifier, or the identification information is a tunnel identifier, which is used to uniquely identify a tunnel. When the second header carries the SRH, the identification information may be a BSID or a tunnel identifier. When the second header does not carry the SRH, the identification information may be a tunnel identification.
Next, with reference to fig. 3 and fig. 4, how to carry the identification information based on the header of the first packet is specifically described. It should be understood that the header format of the first packet shown in fig. 3 and 4 is only illustrative and not limiting.
For example, when the packet encapsulation mode of the second network device generating the first packet is IPv6, the format of the packet header of the first packet may specifically refer to fig. 3. As shown in fig. 3, a value of a new routing type (routing type) in a header of the first packet, for example, "8", may be used to identify an extension carrying identification information. That is to say, when the network device recognizes that the value of the routing type in the header of the first packet is equal to "8", it may be determined that the first packet is a packet carrying identification information. Optionally, a value of the routing type may be the same as a value of the BSID in the header of the first packet, and at this time, it may be understood that the identification information is the BSID. It should be understood that the IPv6 message format shown in fig. 3 is only illustrative and is not intended to be limiting in any way. For example, the identification information may also be carried by other fields (e.g., a free field or a newly extended field) in the header of the IPv6 packet.
For example, when the packet encapsulation mode of generating the first packet by the second network device is IPv4, the format of the packet header of the first packet may specifically refer to (a) in fig. 4. As shown in fig. 4 (a), a value of a protocol (protocol) in the first packet header is a specific value, and the value of the protocol may be used to identify that the first packet header carries identification information, where the value of the protocol is "1001", which indicates that the first packet header carries identification information. The identification information in the first header may be specifically carried in optional fields (options) or in padding fields (padding). Optionally, a message header may be added after the first message header, and a field in the message header added after the first message header carries identification information, where the newly added message header may be an existing message header, and the newly added message header may also be a newly defined message header, which is not limited thereto. For example, taking the newly added packet header as the GRE header, how to carry the identification information through the GRE header is described. In some implementations, the header added after the first header may be a GRE header, and a format of the GRE header may be as shown in (b) in fig. 4. As shown in fig. 4 (b), the identification information may be carried by a key field (key) in the GRE header.
The first network device may be an operator edge device (e.g., an ACC device or a PE device), and the second network device may be a user access device, such as a Customer Premises Equipment (CPE). Optionally, the first network device may also be a network device including an operator edge device. The second network device may also be a network device that includes a user access device.
The first message in step 210 further includes a destination address of the service message sent by the second network device.
Step 220, the second network device sends the first packet to the first network device. Accordingly, the first network device receives a first message from the second network device.
In step 230, the first network device determines the tunnel information according to the identification information.
In step 230, after the first network device receives the first packet from the second network device, the first network device may determine the tunnel information according to the identification information carried in the packet header of the first packet.
In the embodiment of the application, the tunnel information includes section identifier list information SID list of a tunnel corresponding to the tunnel information; or the tunnel information includes source node information of a tunnel corresponding to the tunnel information and destination node information of the tunnel corresponding to the tunnel information. Specifically, when the tunnel information includes the segment identifier list information SID list of the tunnel corresponding to the tunnel information, the tunnel may be an Internet Protocol version 6 (Internet Protocol version 6, IPv 6) Segment Routing (SR) tunnel, and the IPv6 SR is also called an IPv6data plane-based segment routing (SRv 6). When the tunnel information includes source node information of a tunnel corresponding to the tunnel information and destination node information of a tunnel corresponding to the tunnel information, the tunnel includes, but is not limited to: GRE tunnels, multi-Protocol label switching (MPLS) tunnels, internet Protocol version 4 (IPv 4) tunnels, and IPv6 tunnels.
In this embodiment of the present application, a correspondence between identification information and tunnel information is stored in a first network device, and the determining, by the first network device, the tunnel information according to the identification information includes:
and the first network equipment determines the tunnel information according to the identification information and the corresponding relation.
For example, the first network device stores therein a correspondence relationship #1 of identification information #1 and tunnel information #1, and a correspondence relationship #2 of identification information #2 and tunnel information #2. The first network device may determine that the tunnel information #1 is the tunnel information corresponding to the identification information #1 carried in the first packet according to the identification information #1 and the correspondence #2 stored in the local, where the identification information #1 is carried in the received first packet.
Optionally, the first network device may further perform the following operations: the identification information is transmitted to a controller, which is a controller for managing the second network device.
Step 240, the first network device generates a second packet based on the first packet, where the second packet includes a second packet header, the second packet header includes tunnel information, and a tunnel corresponding to the tunnel information is used to forward the second packet.
The type of the first packet header is different from that of the second packet header, and it can be understood that the first packet header and the second packet header are both IP packet headers, but the extension type of the first packet header is different from that of the second packet header. Illustratively, the extension type of the first header is a type used for carrying the identification information in the embodiment of the present application, and the extension type of the second header is SRH. The type of the first header is different from that of the second header, and it can be understood that the first header is not extended and the second header is extended. In one example, the first header may be an IPv4 header extension-based header (e.g., an IPv4 header carries a new header, the new header may be an existing header (e.g., a GRE header or an MPLS header), or the new header may be a newly defined header, etc.), and the second header may be an SRH. Based on this, the first packet may be a packet obtained by the second network device based on IPv4 encapsulation. After that, the first network device encapsulates the SID list of the tunnel corresponding to the determined tunnel information in the SRH of the second packet, so as to obtain the second packet. In another example, the first header may be an IPv6 header, but not an SRH, and the second header may be an SRH. Based on this, the first packet may be a packet obtained by the second network device based on IPv6 encapsulation. After that, the first network device encapsulates the SID list of the tunnel corresponding to the determined tunnel information in the SRH of the second packet, so as to obtain the second packet.
In step 240, the generating, by the first network device, the second packet based on the first packet includes:
the first network equipment adds a second message header in front of the message header of the service message carried by the first message; or,
the first network equipment adds a second message header in front of the first message header included in the first message.
Next, a schematic format diagram of the second packet generated by the first network device is described with reference to fig. 5. For example, as shown in fig. 5 (a), the original service data packet header may be understood as a packet header of a service packet, and fig. 5 (a) is a schematic diagram illustrating a format in which the first network device adds a second packet header before the packet header of the service packet carried by the first packet to generate the second packet. For example, fig. 5 (b) shows a schematic format diagram of the first network device adding the second packet header before the first packet header included in the first packet to generate the second packet.
Optionally, the first message further includes a destination address of a service message sent by the second network device.
The first network device performs the following operations when any one of the following conditions is satisfied:
the first network equipment determines tunnel information according to the identification information; and
the first network equipment generates a second message based on the first message;
satisfying any one of the following conditions includes: the first network device does not find the routing table according to the destination address of the first packet, or the first network device is not used for finding the routing table according to the destination address of the first packet.
That is to say, after the first network device identifies the destination address of the service packet carried in the first packet, the first network device still determines the tunnel information according to the identification information carried in the first packet, and further generates the second packet.
It can be understood that the method for forwarding a packet provided based on the embodiment of the present application is not only applicable to a scenario in which the network accessed by the first network device is an IPv6 network, but also can be migrated to a scenario in which the network accessed by the first network device is an MPLS network and an IPv4 network.
In this embodiment of the present application, the first network device may determine tunnel information according to identification information included in a first packet header of a first packet from the second network device, generate a second packet based on the tunnel information, and forward the packet based on the method without the need for the second network device to sense the tunnel information, i.e., without the need for exchanging tunnel information between the first network device and the second network device, where the packet forwarding process is relatively simple, and the packet forwarding may be flexibly implemented. In addition, when the method is used for forwarding the packet, the first network device does not need to sense specific service information or configuration information deployed in the second network device, that is, internal information of the second network device is shielded for the first network device, and the method for forwarding the packet provided by the embodiment of the present application has a low requirement on the second network device (for example, only the second network device needs to support simple IP encapsulation (such as IPv4 encapsulation or IPv6 encapsulation, but does not include SRH)), so that the applicable scenarios are wider.
Referring to fig. 6, a method for forwarding a packet provided in the embodiment of the present application is described below by taking "a first packet header is an IPv6 packet header but is not an SRH, a second packet header is an SRH, and identification information is a BSID" as an example. It is understood that in the scenario shown in fig. 6, the network to which the first network device is accessed is an IPv6 network. It should be understood that the example of fig. 6 is merely to assist those skilled in the art in understanding the embodiments of the present application, and is not intended to limit the embodiments of the application to the specific values or specific scenarios illustrated. It will be apparent to those skilled in the art that various equivalent modifications or variations are possible in light of the example of fig. 6 given below, and such modifications and variations also fall within the scope of the embodiments of the present application. For example, the method for forwarding a packet provided based on the embodiment of the present application is not only applicable to the network to which the first network device accesses being an IPv6 network, but also applicable to the network to which the first network device accesses being an MPLS network and an IPv4 network.
Fig. 6 is a schematic diagram of a method 600 for forwarding a packet according to an embodiment of the present application.
As shown in fig. 6, the network includes: CPE1 (i.e., the second network device in method 200 above), router R1 (i.e., the first network device in method 200 above), router R2, router R3, router R4, router R5, CPE2, controller #2 (i.e., the second controller in method 200 above), and controller #1 (i.e., the first controller in method 200 above). In one example, CPE1 may be a customer access device 110 in system architecture 100. R1 may be node a, R2 is node B, R3 is node C, R4 is node D, and R5 is node E in system architecture 100. CPE2 may be the customer access device 120 in system architecture 100, controller #2 may be the controller 140 in system architecture 100, and controller #1 may be the controller 130 in system architecture 100.
Optionally, in this embodiment of the present application, the forwarding planes of CPE1 and CPE2 do not support SRv6, and the forwarding planes of R2 and R4 also do not support SRv6. The forwarding planes of R1, R3 and R5 support SRv6. It can be understood that, in the forwarding plane, if a node (e.g., R2) does not support SRv6, the node does not need to process SRH in the IPv6 packet, and the node searches the IPv6 routing table only according to the IPv6 destination address field, and performs ordinary IPv6 forwarding by using the longest matching principle. It can also be understood that if a node does not support SRv6, the node may perform message sending and receiving based on an Interior Gateway routing Protocol (IGP) routing principle. On the forwarding level, if a node (e.g. R3) supports SRv6 and the address of the node appears in the segment list, the node needs to process SRH, subtract 1 from the rest field (segment left, SL), then shift the pointer to the new active segment, then copy an SID in the segment list information to the IPv6 destination address field, and then forward the packet to the next node. When the SL field is reduced to 0, the node may pop up the SRH header and then proceed to the next processing of the message.
In this embodiment of the present application, the configuration information sent by the controller #1 to the R1 includes: a correspondence relationship #1 of identification information #1 and tunnel information #1, a correspondence relationship #2 of identification information #2 and tunnel information #2, and a correspondence relationship #3 of identification information #3 and tunnel information #3. The controller #1 may transmit the identification information #1, the identification information #2, and the identification information #3 included in the configuration information to the controller #2 through the Restful interface. Thereafter, the controller #2 can transmit the acquired 3 pieces of identification information to the CPE1 based on the Netconf protocol or the PCEP protocol. Accordingly, CPE1 saves the 3 pieces of identification information received to the local. It can be understood that, the DSCP of the service packet corresponding to each identification information is also stored in the CPE1, for example, the DSCP of the service packet corresponding to the identification information #1 stored in the CPE1 is DSCP #1, and these information may be information included in the configuration information sent by the controller #2 to the CPE1. The controller #2 may also send the address of the destination user access device (i.e., CPE2 address, CPE2 IP) of the service packet forwarded by the CPE1 to the CPE1.
After the CPE1 receives the service packet #1, the CPE1 may determine, according to the DSCP #1 carried in the service packet #1 and information locally stored by the CPE1, an identification information corresponding to the service packet #1, for example, the identification information corresponding to the service packet #1 is the identification information #1. Based on this, the CPE1 may encapsulate the service packet #1 and the identification information #1 based on IPv6 to obtain the packet #1, specifically, the identification information #1 is pressed into a packet header of the packet #1, the packet header of the encapsulated packet #1 further carries a destination address of the service packet #1 (that is, the service destination address learned by the CPE 2), and optionally, the packet header of the encapsulated packet #1 further carries a VPN SID of a VPN to which the service packet #1 belongs. The identification information #1 in the header of the packet #1 may be carried by a value of the routing type in fig. 3, that is, a value of the routing type is equal to "8" to identify that the identification information carried in the header of the packet #1 is the identification information #1. Thereafter, CPE1 looks up the routing table and sends the packet #1 encapsulated based on IPv6 to R1.
The message #1 enters the R1 (i.e., the source node of the SRv6 tunnel), the R1 recognizes that the header of the message #1 carries the identification information #1, and the tunnel information corresponding to the identification information #1 stored in the R1 is the tunnel information #1, so that the R1 may tunnel-encapsulate the message #1 based on the tunnel corresponding to the tunnel information #1. Where the tunnel information #1 includes segment identifier list information SID list of a tunnel corresponding to the tunnel information #1, the identification information #1 and the tunnel information #1 can be referred to table 1 below. When the R1 performs tunnel encapsulation on the packet #1, the R1 adds SRH to the packet #1, specifies the relevant operation of the SR node in the tunnel path corresponding to the tunnel information #1, and encapsulates the standard IPv6 header on the outer layer. Wherein the SRH comprises segment list [1] =2001::3, segment list [0] =2001::5, SL is 1 (because 2 SRv6 nodes need to pass from R1 to R5); the outer IPv6 header has the source address 2001::1 (R1 address) and the destination address 2001::3 (R3 address) copied from segment list [1] in SRH.
TABLE 1
Identification information #1 SID list of tunnel corresponding to tunnel information #1
R1.BSID 2001::3,2001::5
When the message #2 is forwarded to the R2 node, because R2 only supports conventional IPv6 but not SRv6, after the message #2 is received by R2, according to the specification of the IPv6 standard protocol (RFC protocol), when R2 determines that the destination address of the message #2 is not the self network segment address of R2, R2 does not process the extended SRH header in the message #2, and R2 directly forwards the message #2 along the IGP shortest path direction R3 according to the destination address (i.e., the R3 address) in the IPv6 header of the message #2.
When R3 receives the message #2, R3 searches the local SID table according to the outer layer IPv6 address 2001::3, hits the local SID table, and executes the related instruction. And (3) subtracting 1 from SL, pointing the pointer to segment list [0], copying the address of the segment list [0] to the destination address in the outer-layer IPv6 header, and then forwarding according to the IPv6 destination address.
When the message #2 is forwarded to the R4, since the R4 only supports the conventional IPv6 and does not support the SRv6, after the R4 receives the message #2, according to the specification of IPv6 RFC, when the destination address of the message #2 is not the own network segment address of the R4, the R4 does not process the extended SRH header in the message #2, and the R4 directly forwards the message #2 along the IGP shortest path direction R5 according to the destination address (i.e., the R5 address) in the IPv6 header of the message #2.
When the R5 receives the message #2, it recognizes that the destination address is the node, and the SL is 0. At this time, R5 strips the SRH and IPv6 headers, looks up the destination address in the routing table in a routing manner, and sends the payload to CPE2.
It should be understood that fig. 6 is only an illustration and does not limit the method for forwarding a packet provided in the embodiment of the present application in any way. For example, in some implementations, the CPE1 performs IPv4 encapsulation on the received service packet #1 and the identification information #1, and at this time, the header format of the IPv4 encapsulated packet #1 may refer to the header format shown in fig. 4. For example, the controller #2 and the controller #1 may also be the same controller, which has the functions of the controller #2 and the functions of the controller #1.
In this embodiment of the application, the R1 device does not need to sense the configuration of the service carried in the packet #1 received from the CPE1 device, and determines to forward the tunnel information of the packet #1 only according to the identification information #1 carried in the received packet #1. Meanwhile, the CPE1 does not need to sense the specific path information of the tunnel for forwarding the message #1, and interaction between the devices is reduced. In addition, the method has low requirements on CPE1 equipment, and only CPE1 needs to support the extended encapsulation of IPv 6. The method is simple in the implementation process of forwarding the message, and the message can be flexibly forwarded.
The system architecture suitable for the present application and the message forwarding method provided by the present application are described in detail above with reference to fig. 1 to 6. The first network device, the second network device and the message forwarding system provided in the present application are described in detail below with reference to fig. 7 to 10. It is to be understood that the description of the method embodiments corresponds to the description of the apparatus embodiments, and therefore reference may be made to the preceding method embodiments for parts not described in detail.
Fig. 7 is a schematic diagram of a first network device 700 according to an embodiment of the present application. The first network device 700 as shown in figure 7 comprises a transceiver module 710 and a processing module 720,
in some implementations, the transceiver module 710 is configured to perform the steps of transceiving messages or information (e.g., identification information or configuration information) by the first network device in the method 200, for example, the transceiver module 710 is configured to perform the steps of receiving the first message by the first network device in the method 200, and the transceiver module 710 is configured to perform the steps of sending the second message and the identification information by the first network device in the method 200. For a specific method for the transceiver module 710 to execute the method for the first network device to receive and send the message or the information in the method 200, reference may be made to the related description in the method 200, and details are not repeated here.
Optionally, in another implementation manner, the transceiver module 710 is configured to perform the step of transceiving the message or the information by R1 in the method 600, for example, the transceiver module 710 is configured to perform the step of receiving the message #1 by R1 in the method 600, and the transceiver module 710 is configured to perform the step of transmitting the message #2 and the identification information #1 by R1 in the method 600. For a specific method for the transceiver module 710 to execute the R1 in the method 600 to receive and transmit the message or the information, reference may be made to the related description in the method 600, which is not described in detail herein.
In some implementations, the processing module 720 is configured to perform step 230 and step 240 of the method 200, that is, the processing module 720 is configured to determine the tunnel information according to the identification information and to generate the second packet based on the first packet. For a specific method of the processing module 720 for executing the steps 230 and 240, reference may be made to the related description in the method 200, and details are not described herein again.
Optionally, in other implementation manners, the processing module 720 is configured to execute the step that R1 determines the tunnel information #1 according to the identification information #1 in the method 600, and the step that R1 generates the packet #2 based on the packet #1, and specific methods for the processing module 720 to execute the steps executed by R1 in the method 600 may refer to the relevant description about the first network device in the method 600, and details are not described here again.
Fig. 8 is a schematic diagram of a second network device 800 according to an embodiment of the present application. The second network device 800 as shown in figure 8 includes a transceiver module 810 and a processing module 820,
in some implementation manners, the transceiver module 810 is configured to perform the step of the second network device in the method 200 to transmit and receive a message or information (such as identification information or configuration information), for example, the transceiver module 810 is configured to perform the step 220 in the method 200, and perform the step of the second network device to receive a service message and identification information, where specific methods of the transceiver module 810 for performing the steps performed by the second network device in the method 200 may refer to the related description about the second network device in the method 200, and are not described in detail herein.
Optionally, in another implementation manner, the transceiver module 810 is configured to execute a step of transceiving a message or information by the CPE1 in the method 600, for example, the transceiver module 810 is configured to execute a step of receiving the service message #1 and the identification information #1 by the CPE1 in the method 600, and a step of sending the message #1, where a specific method for the transceiver module 810 to execute the steps executed by the CPE1 in the method 600 may refer to a related description about the CPE1 in the method 600, and details are not repeated here.
In some implementation manners, the processing module 820 is configured to execute step 210 in the method 200, that is, the processing module 820 is configured to generate the first packet according to the identification information, where the specific method for executing step 210 by the processing module 820 may refer to the related description about the second network device in the method 200, and details are not described herein again.
Optionally, in other implementation manners, the processing module 820 is configured to execute the step of the CPE1 generating the message #1 according to the identification information #1 in the method 600, where a specific method for the processing module 820 to execute the steps executed by the R1 in the method 600 may refer to a relevant description about the CPE1 in the method 600, and details are not repeated here.
Fig. 9 is a schematic hardware structure diagram of a network device 900 according to an embodiment of the present application.
As shown in fig. 9, the network device 900 includes a processor 910, a communication interface 920, a memory 930, and a bus 940. Wherein the communication interface 920 may be implemented by wireless or wired means, and specifically may be a network card. The processor 910, memory 930, and communication interface 920 are coupled by a bus 940.
In some implementations, the network device 900 shown in fig. 9 may perform the corresponding steps performed by the first network device in the method 200 of the above-described embodiment, and the corresponding steps performed by R1 in the method 600 of the above-described embodiment. For corresponding steps executed by the network device 900 to execute the first network device in the method 200, reference may be specifically made to the related description of the first network device in the method 200, and details are not described here again, and for corresponding steps executed by the network device 900 to execute the R1 in the method 600, reference may be specifically made to the related description of the R1 in the method 600, and details are not described here again.
The specific functions of the processor 910 are the same as the specific functions of the processing module 720 shown in fig. 7, and details that are not described herein may specifically refer to the description of the processing module 720 in fig. 7.
The communication interface 920 may specifically include a transmitter and a receiver, and a specific function of the transmitter is the same as the transmission function of the transceiver module 710 shown in fig. 7. For example, the transmitter is configured to transmit the identification information to a controller, and the controller is a controller configured to manage the second network device. The functions of the transmitter, which are not described in detail herein, can be referred to the transmitting function of the transceiver module 710 shown in fig. 7. The specific function of the receiver is the same as the receiving function of the transceiver module 710 shown in fig. 7. For example, the receiver is configured to receive a first packet from a second network device, where the first packet includes a first packet header, and the first packet header includes identification information. The functions of the receiver not described in detail herein can be referred to the receiving function of the transceiver module 710 shown in fig. 7.
The memory 930 comprises, inter alia, an operating system 931 and an application 932, for storing programs, code or computer-executable instructions that, when executed by a processor or hardware device, may perform the processes of the method 200 embodiments involving R1 in the first network device or the method 600 embodiments involving R1. Alternatively, the memory 930 may include a read-only memory (ROM) and a Random Access Memory (RAM). Wherein the ROM includes a basic input/output system (BIOS) or an embedded system; the RAM includes an application program and an operating system. When the first network device or R1 needs to be operated, the first network device or R1 is booted to enter a normal operation state by booting the BIOS which is solidified in the ROM or the bootloader boot system in the embedded system. After the first network device or R1 enters the normal operation state, the application program and the operating system that are run in the RAM, thereby completing the processing procedures related to the first network device or R1 in the method embodiment.
In other implementations, the network device 900 shown in fig. 9 may perform the corresponding steps performed by the second network device in the method 200 of the above-described embodiment and the corresponding steps performed by the CPE1 in the method 600 of the above-described embodiment. For the corresponding steps executed by the network device 900 to execute the second network device in the method 200, reference may be specifically made to the related description of the second network device in the method 200, which is not described in detail herein, and for the corresponding steps executed by the network device 900 to execute the CPE1 in the method 600, reference may be specifically made to the related description of the CPE1 in the method 600, which is not described in detail herein.
The specific functions of the processor 910 are the same as the specific functions of the processing module 820 shown in fig. 8, and details that are not described herein may specifically refer to the description about the processing module 820 in fig. 8.
The communication interface 920 may specifically include a transmitter and a receiver, and a specific function of the transmitter is the same as the transmission function of the transceiver module 810 shown in fig. 8. The functions of the transmitter, which are not described in detail herein, can be referred to the transmitting function of the transceiver module 810 shown in fig. 8. The specific function of the receiver is the same as the receiving function of the transceiver module 810 shown in fig. 8. The functions of the receiver not described in detail herein can refer to the receiving functions of the transceiver module 810 shown in fig. 8.
The memory 930 comprises, inter alia, an operating system 931 and an application 932, for storing programs, code or computer-executable instructions which, when executed by a processor or hardware device, may perform the processing of method embodiment 200 involving the second network device or CPE1 of method embodiment 600. Alternatively, the memory 930 may include a read-only memory (ROM) and a Random Access Memory (RAM). Wherein the ROM includes a basic input/output system (BIOS) or an embedded system; the RAM includes an application program and an operating system. When the second network device or CPE1 needs to be operated, the second network device or CPE1 is booted to enter a normal operation state by booting the BIOS which is fixed in the ROM or the bootloader boot system in the embedded system. After the second network device or CPE1 enters the normal operation state, the application and operating system running in the RAM thereby completing the processing procedures involving the second network device or CPE1 in the method embodiment.
It is to be appreciated that fig. 9 illustrates only a simplified design of network device 900. In some implementations, network device 900 may also include any number of processors 910, communication interfaces 920, or memories 930. In other implementations, network device 900 may include only any number of processors 910 and communication interfaces 920.
Fig. 10 is a schematic diagram of a system 1000 for forwarding a packet according to an embodiment of the present application.
As shown in fig. 10, a system 1000 for message forwarding may include: a network device 1010 and a network device 1020,
in some implementations, the network device 1010 may be the first network device 700 shown in fig. 7 described above. At this time, the specific functions of the network device 1010 are the same as the specific functions of the first network device 700 shown in fig. 7, and details that are not described herein may specifically refer to the description in fig. 7. The network device 1020 may be the second network device 800 shown in fig. 8 and described above. At this time, the specific functions of the network device 1020 are the same as the specific functions of the second network device 800 shown in fig. 8, and details that are not described in detail herein may specifically refer to the description in fig. 8.
In other implementations, when the specific functions of the network device 900 shown in fig. 9 are the same as the specific functions of the first network device 700 shown in fig. 7, the network device 1010 may also be the network device 900 shown in fig. 9. At this time, the specific functions of the network device 1010 are the same as the specific functions of the first network device 700 shown in fig. 7, and details that are not described herein may specifically refer to the description in fig. 7. When the specific functions of the network device 900 shown in fig. 9 are the same as those of the second network device 800 shown in fig. 8, the network device 1020 may also be the network device 900 shown in fig. 9. At this time, the specific functions of the network device 1020 are the same as the specific functions of the second network device 800 shown in fig. 8, and details that are not described in detail herein may specifically refer to the description in fig. 8.
The present application provides a computer program product, which, when running on a network device, causes the network device to execute the method in the above method embodiments.
The embodiment of the application provides a computer readable storage medium for storing a computer program, wherein the computer program comprises a program for executing the method in the embodiment of the method.
The embodiment of the application provides a chip system, which comprises at least one processor and an interface; the at least one processor is configured to call and run a computer program, so that the chip system executes the method in the above method embodiment.
The apparatuses in the various product forms respectively have any function of the network device in the method embodiments, and are not described herein again.
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the technical solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
It can be clearly understood by those skilled in the art that, for convenience and simplicity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one type of logical functional division, and other divisions may be realized in practice, for example, multiple units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application or portions thereof that substantially contribute to the prior art may be embodied in the form of a software product stored in a storage medium and including instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a read-only memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
The above description is only for the specific embodiments of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present application, and shall be covered by the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.

Claims (30)

1. A method for forwarding a packet, the method comprising:
a first network device receives a first message from a second network device, wherein the first message comprises a first message header, and the first message header comprises identification information;
the first network equipment determines tunnel information according to the identification information;
the first network device generates a second packet based on the first packet, where the second packet includes a second packet header, the second packet header includes the tunnel information, and a tunnel corresponding to the tunnel information is used to forward the second packet.
2. The method of claim 1,
the identification information is a binding segment identifier BSID; or,
the identification information is a tunnel identifier.
3. The method according to claim 1 or 2,
the tunnel information comprises section identifier list information SID list of a tunnel corresponding to the tunnel information; or,
the tunnel information includes source node information of a tunnel corresponding to the tunnel information and destination node information of the tunnel corresponding to the tunnel information.
4. The method according to any one of claims 1 to 3,
the type of the first message header is a specific type, and the first message header is used for carrying the identification information.
5. The method of claim 4,
the type of the first header is different from the type of the second header.
6. The method according to any one of claims 1 to 5,
the second message header is a segment routing header SRH.
7. The method according to any of claims 1 to 6, wherein the first network device generating a second packet based on the first packet comprises:
the first network equipment adds the second message header in front of the message header of the service message carried by the first message; or,
and the first network equipment adds the second message header in front of the first message header included in the first message.
8. The method according to any one of claims 1 to 7,
the first network device is an operator boundary device, and the second network device is a user access device.
9. The method according to any of claims 1 to 8, wherein a correspondence between the identification information and the tunnel information is stored in the first network device,
the first network device determines tunnel information according to the identification information, and the tunnel information includes:
and the first network equipment determines the tunnel information according to the identification information and the corresponding relation.
10. The method according to any one of claims 1 to 9, further comprising:
the first network device sends the identification information to a controller, which is a controller for managing the second network device.
11. The method according to any one of claims 1 to 10,
the first message further includes a destination address of a service message sent by the second network device.
12. A method for forwarding a message, the method comprising:
the second network equipment receives the identification information from the controller;
the second network device generates a first packet based on the identification information, and sends the first packet, where the first packet includes a first packet header, the first packet header includes the identification information, and the identification information corresponds to tunnel information used for forwarding the first packet.
13. The method of claim 12, wherein the second network device generates the first packet based on the identification information, comprising:
the second network equipment receives a service message;
the second network device determines the identification information from one or more candidate identification information according to any one or more of the following information, including at least:
one or more information in the five-tuple information of the service packet, a DSCP (differentiated services code point) of the service packet, a flow identifier of the service packet, an EXP field of the service packet, a CoS (class of service) of the service packet, or a TC (time series) field of the service packet.
14. The method according to claim 12 or 13,
the identification information is a binding segment identifier BSID; or,
the identification information is a tunnel identifier.
15. The method according to any one of claims 12 to 14,
the type of the first message header is a specific type, and the first message header is used for carrying the identified information.
16. The method of claim 15, wherein the first header is not a Segment Routing Header (SRH).
17. The method according to any one of claims 12 to 16,
the first network device is an operator boundary device, the second network device is a user access device, and the controller is a controller for managing the second network device.
18. A first network device, characterized in that the first network device comprises a transceiver module and a processing module,
the transceiver module is configured to receive a first packet from a second network device, where the first packet includes a first packet header, and the first packet header includes identification information;
the processing module is used for determining tunnel information according to the identification information;
the processing module is further configured to generate a second packet based on the first packet, where the second packet includes a second packet header, the second packet header includes the tunnel information, and a tunnel corresponding to the tunnel information is used to forward the second packet.
19. The first network device of claim 18,
the identification information is a binding segment identifier BSID; or,
the identification information is a tunnel identifier.
20. The first network device of claim 18 or 19,
the tunnel information comprises section identifier list information SID list of a tunnel corresponding to the tunnel information; or,
the tunnel information includes source node information of a tunnel corresponding to the tunnel information and destination node information of the tunnel corresponding to the tunnel information.
21. First network device according to any of claims 18 to 20,
the type of the first message header is a specific type, and the first message header is used for carrying the identification information.
22. The first network device of claim 21,
the type of the first header is different from the type of the second header.
23. The first network device of any of claims 18 to 22,
and the second message header is a Segment Routing Header (SRH).
24. First network device of any of claims 18 to 23,
the processing module is further configured to:
adding the second message header in front of the message header of the service message carried by the first message; or,
and adding the second message header before the first message header included in the first message.
25. The first network device of any of claims 18 to 24,
the first network device is an operator boundary device, and the second network device is a user access device.
26. A second network device, characterized in that the second network device comprises a transceiver module and a processing module,
the transceiver module is used for receiving the identification information from the controller;
the processing module is configured to generate a first packet based on identification information and send the first packet, where the first packet includes a first packet header, and the first packet header includes the identification information, and the identification information corresponds to tunnel information used for forwarding the first packet.
27. The second network device of claim 26,
the receiving and sending module is also used for receiving the service message;
the processing module is further configured to determine the identification information from one or more candidate identification information according to any one or more of the following information, where the any one or more of the following information at least includes:
one or more of quintuple information of the service packet, a Differentiated Services Code Point (DSCP) of the service packet, a stream identifier of the service packet, an EXP field of the service packet, a service class (CoS) of the service packet, or a TC field of the service packet.
28. A message forwarding system, characterized in that the system comprises a first network device according to any of claims 18 to 25 and a second network device according to claim 26 or 27.
29. A computer-readable storage medium, comprising a computer program which, when run on a computer, causes the computer to perform the method of any one of claims 1 to 17.
30. A system on chip comprising at least one processor and an interface, the at least one processor being configured to invoke and execute a computer program to cause the system on chip to perform the method of any of claims 1 to 17.
CN202110444013.8A 2021-04-23 2021-04-23 Method, equipment and system for forwarding message Pending CN115333896A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110444013.8A CN115333896A (en) 2021-04-23 2021-04-23 Method, equipment and system for forwarding message

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110444013.8A CN115333896A (en) 2021-04-23 2021-04-23 Method, equipment and system for forwarding message

Publications (1)

Publication Number Publication Date
CN115333896A true CN115333896A (en) 2022-11-11

Family

ID=83912694

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110444013.8A Pending CN115333896A (en) 2021-04-23 2021-04-23 Method, equipment and system for forwarding message

Country Status (1)

Country Link
CN (1) CN115333896A (en)

Similar Documents

Publication Publication Date Title
US10237177B2 (en) Transfer device and transfer system
EP3720066A1 (en) Packet sending and processing method and apparatus, pe node, and node
US8819267B2 (en) Network virtualization without gateway function
CN110138618B (en) Message processing method, device and system
US9774532B2 (en) Information processing system, information processing apparatus and control method of information processing system
EP4231597A1 (en) Method for forwarding bier message, and device and system
CN106878136B (en) Message forwarding method and device
US20230300070A1 (en) Packet Sending Method, Device, and System
CN113114576B (en) Method, equipment and system for sending message
CN112583711A (en) Message processing method and device
US20210359879A1 (en) Packet forwarding method and network device
US20230370899A1 (en) Packet forwarding method, packet processing method, and device
EP3920512A1 (en) Transmission method and device for message
CN113542111A (en) Message forwarding method and network equipment
EP4161002A1 (en) Message processing method and network device
CN108737239B (en) Message forwarding method and device
CN110022263B (en) Data transmission method and related device
CN111404797A (en) Control method, SDN controller, SDN access point, SDN gateway and CE
US20230421480A1 (en) Route Processing Method and Network Device
WO2021052381A1 (en) Message sending method and apparatus
US20230318974A1 (en) BIER Packet Forwarding Method, Device, and System
CN113765809A (en) BIER multicast traffic statistical method, device and system
US11611508B2 (en) Packet forwarding method and network device
CN115333896A (en) Method, equipment and system for forwarding message
WO2019056239A1 (en) Packet synchronization method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination