The disclosure relates to, but is not limited to, the technical field of communications.
The Service Function Chain (SFC) technology integrates all services and virtualizes a service overlay layer to form its own service topology for decoupling from an underlying network and breaking through restrictions of a structure of the underlying network.
An SFC architecture, as shown in
From the perspective of a control plane, an SFC classification rule, an SFC definition and an NSH are issued by an SFC controller or locally configured. From the perspective of data-plane encapsulation, the whole NSH, related to a service, of an SFC, as shown in
A Segment Routing (SR) technology is also a hot technology currently in the Internet Engineering Task Force (IETF). A main principle is that an ordered Segment Routing List (SR-List) is issued to a head node in an SR domain through a control plane, each piece of segment information identifies a segment a packet is to go through, and the SR-List identifies all the segments the packet is to go through. In such a manner, when the packet arrives at the head node of the SR domain, the packet may subsequently be forwarded according to the SR-List in an SR header only by adding the SR header to the packet. Furthermore, each segment may represent a segment of instructions, or a topology, or a service, and SR supports a segment with a global attribute, and also supports a segment with a local attribute of belonging to a certain node. Segments supported in a current SR technology include: an Interior Gateway Protocol (IGP) Segment Identifier (IGP-SID), a Prefix-SID, a Node-SID, an Anycast SID, an Adjacent SID (Adj-SID), a Border Gateway Protocol (BGP) Peer SID and the like. Existing SR technologies include Multiple Protocol Label Switching (MPLS)-SR, that is, during application in an IPv4 network, each segment is identified with a label, an SR-List is a stack of the labels, and is encapsulated outside an IPv4 packet header, and packet forwarding in an MPLS-SR domain is implemented according to label stack information.
As can be seen from the abovementioned technologies, from the perspective of a data layer, the SFC technology may specify an SFPID that a packet goes through according to a packet classification result, and then encapsulate an outer layer of an original packet with a layer of NSH for further forwarding to a next-hop SFF through an overlay technology, all a classifier(s), SFF(s), SF(s) and the like through which the packet passes have to support the NSH, and even for an SF not supporting the NSH, it needs to add an SSH proxy component for interworking between an SF supporting the NSH and the SF not supporting the NSH. From the perspective of a control layer, a controller is needed to additionally support management and control of an SFC domain. Therefore, deployment difficulties and deployment period of the SFC technology in an existing network are greatly increased, and a function set of the network devices is also greatly increased.
The below is a summary about the subject matter described in the disclosure in detail. The summary is not intended to limit the scope of protection of the claims.
The disclosure provides a method and device for implementing an SFC, which may simply deploy and rapidly implement an SFC technology in an Internet Protocol version 6 (IPv6) network.
A method for implementing an SFC may be applied to a node on the SFC, and the method may include that:
SFC information is encapsulated in an IPv6 header of an IPv6 packet; and
the IPv6 packet is sent according to the SFC information.
Alternatively, the method further includes the following characteristics:
the SFC information may include at least one of the following information: service forwarding path information or metadata information.
Alternatively, the method further includes the following characteristics:
the IPv6 header arranged to encapsulate the service forwarding path information may be an IPv6 routing header, or a newly defined IPv6 header.
Alternatively, the method further includes the following characteristics:
the service forwarding path information may include: SFP information and a service index,
wherein the service index may be arranged to identify position information of the current node in an SFP.
Alternatively, the method further includes the following characteristics:
the IPv6 header arranged to encapsulate the metadata information may be an IPv6 destination options header, or a newly defined IPv6 header.
Alternatively, the method further includes the following characteristics:
the operation that the IPv6 packet is sent according to the SFC information may include that:
an IPv6 address of a next-hop node is determined according to the acquired service forwarding path information, the IPv6 address of the next-hop node is determined as a destination address, and the IPv6 packet is sent to the destination address.
Alternatively, the method further includes the following characteristics:
before the operation that the SFC information is encapsulated in the IPv6 header of the IPv6 packet, the method may further include that: traffic is classified; and
the operation that the SFC information is encapsulated in the IPv6 header of the IPv6 packet may include that: the SFC information is encapsulated in the IPv6 header of the IPv6 packet according to a result of classification.
Alternatively, the method further includes the following characteristics:
before the operation that the SFC information is encapsulated in the IPv6 header of the IPv6 packet, the method may further include that: the SFC information is acquired.
Alternatively, the method further includes the following characteristics:
the SFC information may be acquired in at least one of the following manners:
acquiring the SFC information from local configuration information, and acquiring the SFC information from global configuration information issued by a controller.
Alternatively, the method further includes the following characteristics:
the SFP information may include any one of: an SFPID, an address list of nodes on the SFP, an SID list of the nodes on the SFP or a node ID list of the nodes on the SFP.
A method for implementing an SFC may be applied to a node on the SFC, and the method may include that:
after an IPv6 packet containing SFC information is received, the SFC information is parsed; and
an IPv6 address of a next-hop node of an SFP is acquired as a destination address, and the IPv6 packet is sent to the destination address.
Alternatively, the method further includes the following characteristics:
the SFC information may include at least one of the following information: service forwarding path information or metadata information.
Alternatively, the method further includes the following characteristics:
the service forwarding path information may be encapsulated in an IPv6 routing header of the IPv6 packet, or may be encapsulated in a newly defined IPv6 header of the IPv6 packet; and
the metadata information may be encapsulated in an IPv6 destination options header of the IPv6 packet, or may be encapsulated in a newly defined IPv6 header of the IPv6 packet.
Alternatively, the method further includes the following characteristics:
the operation that the IPv6 packet is sent to the destination packet may include that:
when a next hop of the node is a destination node of the SFP, the IPv6 header encapsulated with the SFC information is stripped from the IPv6 packet, and then the IPv6 packet is sent to the destination address.
Alternatively, the method further includes the following characteristics:
the operation that the IPv6 packet is sent to the destination address may include that:
when the next hop of the node is not the destination node of the SFP, whether to update the SFC information contained in the IPv6 packet or not is determined according to a deployment strategy, and then the IPv6 packet is sent to the destination address.
Alternatively, the method further includes the following characteristics:
the operation that whether to update the SFC information contained in the IPv6 packet or not is determined according to the deployment strategy and then the IPv6 packet is sent to the destination address may include that:
when the service forwarding path information contained in the IPv6 packet is updated according to the deployment strategy, the updated service forwarding path information is parsed, the IPv6 address of the next-hop node of the updated SFP is acquired as the destination address, and the IPv6 packet is sent to the destination address.
Alternatively, the method further includes the following characteristics:
the service forwarding path information may include: SFP information and a service index,
wherein the service index may be arranged to identify position information of the current node in the SFP.
Alternatively, the method further includes the following characteristics:
the operation that the IPv6 packet is sent to the destination address may include that:
when the next hop of the node is not the destination node of the SFP and the SFC information includes the service forwarding path information, the service index in the IPv6 packet is updated, and then the IPv6 packet is sent to the destination address.
Alternatively, the method further includes the following characteristics:
the operation that the service index in the IPv6 packet is updated may include that:
when the service index represents information about a hop number between the current node and the destination node of the SFP, the service index in the IPv6 packet is progressively decreased.
A device for implementing an SFC may be applied to a node on the SFC, and may include:
an encapsulation module, arranged to encapsulate SFC information in an IPv6 header of an IPv6 packet; and
a sending module, arranged to send the IPv6 packet according to the SFC information.
Alternatively, the device further includes the following characteristics:
the SFC information may include at least one of the following information: service forwarding path information and metadata information.
Alternatively, the device further includes the following characteristics:
the IPv6 header arranged to encapsulate the service forwarding path information may be an IPv6 routing header, or a newly defined IPv6 header.
Alternatively, the device further includes the following characteristics:
the service forwarding path information may include: SFP information and a service index,
wherein the service index may be arranged to identify position information of the current node in an SFP.
Alternatively, the device further includes the following characteristics:
the IPv6 header arranged to encapsulate the metadata information may be an IPv6 destination options header, or a newly defined IPv6 header.
Alternatively, the device further includes the following characteristics:
the sending module may be arranged to:
determine an IPv6 address of a next-hop node according to the acquired service forwarding path information, determine the IPv6 address of the next-hop node as a destination address, and send the IPv6 packet to the destination address.
Alternatively, the device further includes the following characteristics:
the encapsulation module may further be arranged to:
classify traffic, and encapsulate the SFC information in the IPv6 header of the IPv6 packet according to a result of the classification.
Alternatively, the device further includes the following characteristics:
the device may further include:
an information acquisition module, arranged to acquire the SFC information.
Alternatively, the device further includes the following characteristics:
the information acquisition module may be arranged to acquire the SFC information in at least one of the following manners:
acquiring the SFC information from local configuration information, and acquiring the SFC information from global configuration information issued by a controller.
Alternatively, the device further includes the following characteristics:
the SFC information may include any one of: an SFPID, an address list of nodes on the SFP, an SID list of the nodes on the SFP and a node ID list of the nodes on the SFP.
A device for implementing an SFC may be applied to a node on the SFC, and may include:
a packet receiving module, arranged to, after an IPv6 packet containing SFC information is received, parse the SFC information; and
a packet sending module, arranged to acquire an IPv6 address of a next-hop node of an SFP as a destination address, and send the IPv6 packet to the destination address.
Alternatively, the device further includes the following characteristics:
the SFC information may include at least one of the following information: service forwarding path information and metadata information.
Alternatively, the device further includes the following characteristics:
the service forwarding path information may be encapsulated in an IPv6 routing header of the IPv6 packet, or may be encapsulated in a newly defined IPv6 header of the IPv6 packet; and
the metadata information may be encapsulated in an IPv6 destination options header of the IPv6 packet, or may be encapsulated in a newly defined IPv6 header of the IPv6 packet.
Alternatively, the device further includes the following characteristics:
the packet sending module may be arranged to:
when a next hop of the node is a destination node of the SFP, strip the IPv6 header encapsulated with the SFC information from the IPv6 packet, and then send the IPv6 packet to the destination address.
Alternatively, the device further includes the following characteristics:
the packet sending module may be arranged to:
when the next hop of the node is not the destination node of the SFP, determine whether to update the SFC information contained in the IPv6 packet or not according to a deployment strategy, and then send the IPv6 packet to the destination address.
Alternatively, the device further includes the following characteristics:
the packet sending module may be arranged to:
when the service forwarding path information contained in the IPv6 packet is updated according to the deployment strategy, parse the updated service forwarding path information, acquire the IPv6 address of the next-hop node of the updated SFP as the destination address, and send the IPv6 packet to the destination address.
Alternatively, the device further includes the following characteristics:
the service forwarding path information may include: SFP information and a service index,
wherein the service index may be arranged to identify position information of the current node in the SFP.
Alternatively, the device further includes the following characteristics:
the packet sending module may be arranged to:
when the next hop of the node is not the destination node of the SFP and the SFC information includes the service forwarding path information, update the service index in the IPv6 packet, and then send the IPv6 packet to the destination address.
Alternatively, the device further includes the following characteristics:
the packet sending module may be arranged to:
when the service index represents information about a hop number between the current node and the destination node of the SFP, progressively decrease the service index in the IPv6 packet.
A computer-readable storage medium may store computer executable instructions, and the computer executable instructions may be arranged to execute any abovementioned method.
Compared with the related art, the method and device provided by embodiments of the disclosure for implementing the SFC have the advantage that the SFC information is encapsulated in the IPv6 header of the IPv6 packet and the IPv6 packet is forwarded along the SFC, so that the SFC technology may be simply deployed and rapidly implemented in an IPv6 network.
After the drawings and detailed descriptions are read and understood, the other aspects may be comprehended.
The embodiments of the disclosure will be described below in combination with the drawings in detail. It is to be noted that the embodiments in the disclosure and features in the embodiments may be freely combined without conflicts.
At present, in an IPv6 technology (RFC2460), multiple headers are defined for IPv6 headers, including a hop-by-hop options header, a routing header, a fragment header, a destination options header, an authentication header and the like.
Herein, the routing header is mainly arranged to display, at an IPv6 source node, information of intermediate nodes to be went through in a process for a specified packet to arrive at a destination node, and its format is shown in
Herein, the destination options header is mainly arranged to contain information to be processed by the destination node. An example of a header format is shown in
The embodiments of the disclosure are based on the IPv6 network, and are intended to extend an IPv6 header supported by all IPv6 network nodes by virtue of a principle of the IPv6 headers, to implement simple deployment and implementation of the SFC technology.
As shown in
In S10, SFC information is encapsulated in an IPv6 header of an IPv6 packet.
In S20, the IPv6 packet is sent according to the SFC information.
The method may further include the following characteristics.
Alternatively, before the operation that the SFC information is encapsulated in the IPv6 header of the IPv6 packet, the method may further include that:
the SFC information is acquired.
Alternatively, the SFC information may be acquired in at least one of the following manners: acquiring the SFC information from local configuration information, or acquiring the SFC information from global configuration information issued by a controller.
Alternatively, the SFC information may include at least one of the following information: service forwarding path information or metadata information.
Alternatively, the service forwarding path information may include: SFP information and a service index.
Alternatively, the SFP information may include any one of: an SFPID, an address list of nodes on an SFP, an SID list of the nodes on the SFP or a node ID list of the nodes on the SFP.
The service index is arranged to identify position information of the current node in the SFP.
The SFPID is arranged to uniquely identify the SFP.
Alternatively, before the operation that the SFC information is encapsulated in the IPv6 header of the IPv6 packet, the method may further include that: traffic is classified.
Accordingly, the operation that the SFC information is encapsulated in the IPv6 header of the IPv6 packet may include that: the SFC information is encapsulated in the IPv6 header of the IPv6 packet according to a result of the classification.
Alternatively, the operation that the IPv6 packet is sent according to the SFC information may include that:
an IPv6 address of a next-hop node is determined according to the acquired service forwarding path information, the IPv6 address of the next-hop node is determined as a destination address, and the IPv6 packet is sent to the destination address.
Alternatively, the IPv6 header arranged to encapsulate the service forwarding path information may be an IPv6 routing header, or a newly defined IPv6 header.
The metadata information may include at least one of the following information: mandatory context data information or optional context data information.
The mandatory context data information includes the following one or more types of data: network platform metadata, network service metadata, service platform metadata or service shared metadata.
The network platform metadata is arranged to identify network platform-level context information shared between network nodes, for example, incoming interface information and a forwarding environment. The network service metadata is arranged to identify network-layer information shared between the network nodes, for example, an ID, tenant information and the classification result. The service platform metadata is arranged to identify service platform-level context information shared between SF nodes, for example, a service strategy. The service shared metadata is arranged to identify service related context information shared between the SF nodes, for example, application information and a service processing result.
The optional context data information may be different according to different practical service scenarios.
Alternatively, the IPv6 header arranged to encapsulate the metadata information may be an IPv6 destination options header, or a newly defined IPv6 header.
As shown in
In S30, after an IPv6 packet containing SFC information is received, the SFC information is parsed.
In S40, an IPv6 address of a next-hop node of an SFP is acquired as a destination address, and the IPv6 packet is sent to the destination address.
The method may further include the following characteristics:
Nodes on the SFP include at least one of: an SF node(s) or an SFF node(s).
Alternatively, the SFC information may include at least one of the following information: service forwarding path information or metadata information.
Alternatively, the service forwarding path information may include: SFP information and a service index.
Alternatively, the SFP information may include any one of: an SFPID, an address list of the nodes on the SFP, an SID list of the nodes on the SFP or a node ID list of the nodes on the SFP.
The service index is arranged to identify position information of the current node in the SFP.
Alternatively, the service forwarding path information is encapsulated in an IPv6 routing header of the IPv6 packet, or is encapsulated in a newly defined IPv6 header of the IPv6 packet.
The metadata information is encapsulated in an IPv6 destination options header of the IPv6 packet, or is encapsulated in a newly defined IPv6 header of the IPv6 packet.
Alternatively, the operation that the IPv6 packet is sent to the destination packet may include that:
when a next hop of the node is a destination node of the SFP, the IPv6 header encapsulated with the SFC information is stripped from the IPv6 packet, and then the IPv6 packet is sent to the destination address.
Alternatively, the operation that the IPv6 packet is sent to the destination address may include that:
when the next hop of the node is not the destination node of the SFP and the SFC information includes the service forwarding path information, the service index in the IPv6 packet is updated, and then the IPv6 packet is sent to the destination address.
Alternatively, the operation that the service index in the IPv6 packet is updated may include that:
when the service index represents information about a number of hops between the current node and the destination node of the SFP, the service index in the IPv6 packet is progressively decreased.
Alternatively, the operation that the IPv6 packet is sent to the destination address may include that:
when the next hop of the node is not the destination node of the SFP, whether to update the SFC information contained in the IPv6 packet or not is determined according to a deployment strategy, and then the IPv6 packet is sent to the destination address.
Alternatively, the operation that whether to update the SFC information contained in the IPv6 packet or not is determined according to the deployment strategy and then the IPv6 packet is sent to the destination address may include that:
when the service forwarding path information contained in the IPv6 packet is updated according to the deployment strategy, the updated service forwarding path information is parsed, the IPv6 address of the next-hop node of the updated SFP is acquired as the destination address, and the IPv6 packet is sent to the destination address.
As shown in
The encapsulation module 21 is arranged to encapsulate SFC information in an IPv6 header of an IPv6 packet.
The sending module 22 is arranged to send the IPv6 packet according to the SFC information.
The device may further include the following characteristics.
Alternatively, the SFC information may include at least one of the following information: service forwarding path information or metadata information.
Alternatively, the IPv6 header arranged to encapsulate the service forwarding path information may be an IPv6 routing header, or a newly defined IPv6 header.
Alternatively, the service forwarding path information may include: SFP information and a service index.
Here, the service index is arranged to identify position information of the current node in an SFP.
Alternatively, the IPv6 header arranged to encapsulate the metadata information may be an IPv6 destination options header, or a newly defined IPv6 header.
Alternatively, the sending module 22 may be arranged to:
determine an IPv6 address of a next-hop node according to the acquired service forwarding path information, determine the IPv6 address of the next-hop node as a destination address, and send the IPv6 packet to the destination address.
Alternatively, the encapsulation module 21 may be further arranged to:
classify traffic, and encapsulate the SFC information in the IPv6 header of the IPv6 packet according to a result of the classification.
Alternatively, the device may further include an information acquisition module.
The information acquisition module may be arranged to acquire the SFC information.
Alternatively, the information acquisition module may be arranged to acquire the SFC information in at least one of the following manners:
acquiring the SFC information from local configuration information, and acquiring the SFC information from global configuration information issued by a controller.
Alternatively, the SFC information includes any one of: an SFPID, an address list of nodes on the SFP, an SID list of the nodes on the SFP or a node ID list of the nodes on the SFP.
Alternatively, the metadata information includes at least one of the following information: mandatory context data information or optional context data information.
As shown in
The packet receiving module 23 is arranged to, after an IPv6 packet containing SFC information is received, parse the SFC information.
The packet sending module 24 is arranged to acquire an IPv6 address of a next-hop node of an SFP as a destination address, and send the IPv6 packet to the destination address.
The device may further include the following characteristics.
Alternatively, the SFC information may include at least one of the following information: service forwarding path information or metadata information.
Alternatively, the service forwarding path information may be encapsulated in an IPv6 routing header of the IPv6 packet, or may be encapsulated in a newly defined IPv6 header of the IPv6 packet.
The metadata information may be encapsulated in an IPv6 destination options header of the IPv6 packet, or may be encapsulated in a newly defined IPv6 header of the IPv6 packet.
Alternatively, the packet sending module 24 may be arranged to, when a next hop of the current node is a destination node of the SFP, strip the IPv6 header encapsulated with the SFC information from the IPv6 packet, and then send the IPv6 packet to the destination address.
Alternatively, the packet sending module 24 may be arranged to, when the next hop of the node is not the destination node of the SFP, determine whether to update the SFC information contained in the IPv6 packet or not according to a deployment strategy, and then send the IPv6 packet to the destination address.
Alternatively, the packet sending module 24 may be arranged to, when the service forwarding path information contained in the IPv6 packet is updated according to the deployment strategy, parse the updated service forwarding path information, acquire the IPv6 address of the next-hop node of the updated SFP as the destination address, and send the IPv6 packet to the destination address.
Alternatively, the service forwarding path information includes: SFP information and a service index,
wherein the service index is arranged to identify position information of the current node in the SFP.
Alternatively, the packet sending module 24 may be arranged to, when the next hop of the node is not the destination node of the SFP and the SFC information includes the service forwarding path information, update the service index in the IPv6 packet, and then send the IPv6 packet to the destination address.
Alternatively, the packet sending module 24 may be arranged to, when the service index represents information of a number of hops between the current node and the destination node of the SFP, progressively decrease the service index in the IPv6 packet.
Implementations
As shown in
Routing Type: routing header type;
here, a routing header of a type 5 is extended in the embodiment of the disclosure;
Service Index: a service index, which is identical to Segments Left;
Identifier Type: mode for identifying service forwarding path information,
here, the identification manner for the service forwarding path information may be an SFPID, or may be an address list of each node, and
SFP information: being arranged to identify experienced path information for service forwarding.
As shown in
Here, the metadata option is arranged to identify a context header and/or variable length optional metadata information contained in an NSH in a current SFC technology, and a reference format of the metadata option is shown in
MD Option Type: identifying a metadata option type:
Opt Data Len: identifying a metadata length contained in the metadata option; and
Option Data: identifying metadata contained in the option.
Furthermore, a definition about an MD Sub-Opt is extended in the metadata option, and a reference format of the sub-option is shown in
MD Sub-Opt Type: identifying a metadata sub-option type:
MD Sub-Opt Length: identifying a metadata length contained in the metadata sub-option; and
Sub-Opt Data: identifying metadata contained in the metadata sub-option.
Furthermore, the currently defined metadata sub-option, as shown in
a network platform metadata sub-option: identifying network platform-level context information shared between network nodes, for example, incoming interface information and a forwarding environment;
a network service metadata sub-option: identifying network-layer information shared between the network nodes, for example, an ID, tenant information and a classification result;
a service platform metadata sub-option: identifying service platform-level context information shared between SF nodes, for example, a service strategy;
a service shared metadata sub-option: identifying service related context information shared between the SF nodes, for example, application information and a service processing result; and
other related metadata.
As shown in
where SF1 and SF2 are connected to SFF1, SF3 is connected to SFF2, SF4 and SF5 are connected to SFF3, and a classifier and each SFF and SF belong to nodes in an IPv6-SFC domain.
As shown in
In Step 1, the source node Source acquires information [SFF1,SF2,SFF3,SF5,Destination] about a service forwarding path to the destination node Destination and a corresponding SFPID SFPID1, totally 5 hops (Service Index), and meanwhile, acquires metadata related information to be transmitted and shared on the service forwarding path, where the path information and the metadata related information may be locally configured, or may be acquired from a controller, and here, the source node plays a role in encapsulating service forwarding path related information and the metadata related information.
In Step 2, the source node parses the SFPID1, acquires information of a first-hop node, further parses it as a routable IPv6 address, encapsulates it in a destination address field of an IPv6 header, encapsulates the SFPID1 corresponding to the information [SFF1,SF2,SFF3,SF5,Destination] about the service forwarding path in a routing header defined in the embodiment of the disclosure, that is, a packet format is shown in
In Step 3, the source node performs forwarding to the first-hop node SFF1 according to a destination IPv6 address in the IPv6 header. Of course, when looking up an IPv6 routing forwarding table, the source node may find that tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address, or may find that Virtual Local Area Network (VLAN) encapsulation, Virtual Extensible Local Area Network (VXLAN) encapsulation, tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address.
In Step 4, after SFF1 receives the packet, if finding that the destination is itself, the SFF1 parses the routing header in the packet, further parses the information of the SFPID1 and the Service Index to learn about that the current node is a first hop, further acquires information of a second-hop node SF2, parses the information of SF2 as a routable IPv6 address on the SFF1, replaces the destination address in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 3; meanwhile, the metadata related information in the packet is parsed to judge whether there is metadata information needed by the node SFF1 or not, and if YES, the metadata information is read and used, and after use, the metadata information is updated as needed; if NO, the metadata information is not updated; the SFF1 looks up the IPv6 routing table for forwarding according to the updated destination IPv6 address; and it may also be found that VLAN encapsulation, VXLAN encapsulation, tunnel encapsulation or MPLS forwarding is required for arrival at the destination node.
In Step 5, after SF2 receives the packet, if finding that the destination is itself, the SF2 parses the routing header in the packet, further parses the information of the SFPID1 and the Service Index to learn about that the current node is a second hop, further acquires information of a third-hop node SFF3, parses the information of SFF3 as a routable IPv6 address, replaces the destination address in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 2; meanwhile, the metadata information in the packet is parsed to judge whether there is metadata information needed by the node SF2 or not; if YES, the metadata information is read and used, and after use, the metadata information is updated as needed; if NO, the metadata information is not updated; the SF2 looks up the IPv6 routing table for forwarding according to the updated destination IPv6 address; and it may also be found that VLAN encapsulation, VXLAN encapsulation, tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address.
In Step 6, after SFF3 receives the packet, if finding that the destination is itself, the SFF3 parses the routing header in the packet, further parses the information of the SFPID1 and the Service Index to learn about that the current node is a third hop, further acquires information of a fourth-hop node SF5, parses the information of SF5 as a routable IPv6 address on the SFF3, replaces the destination address in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 1; meanwhile, the metadata information in the packet is parsed to judge whether there is metadata information needed by the node SFF3 or not; if YES, the metadata information is read and used, and after use, the metadata information is updated as needed; if NO, the metadata information is not updated; the SFF3 looks up the IPv6 routing table for forwarding according to the updated destination IPv6 address; and it may also be found that VLAN encapsulation. VXLAN encapsulation, tunnel encapsulation or MPLS forwarding is required for arrival at the destination address.
In Step 7, after SF5 receives the packet, if finding that the destination is itself, the SF5 parses the routing header in the packet, further parses the information of the SFPID1 and the Service Index to learn about that the current node is a fourth hop, further acquires information of a fifth-hop node Destination, parses information of the Destination as a routable IPv6 address, replaces the destination address in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 0; meanwhile, the metadata information in the packet is parsed to judge whether there is metadata information needed by the node SF5 or not; if YES, the metadata information is read and used, and after use, the metadata information is updated as needed; if NO, the metadata information is not updated; the SF5 finds that the Service Index field is 0, and strips the routing header containing the SFP related information and the destination routing header containing the metadata related information: then, the SF5 looks up the IPv6 routing table for forwarding according to the destination Destination-IPv6 address; and it may also be found that VLAN encapsulation, VXLAN encapsulation, tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address.
As shown in
In Step 1, the source node Source looks up an IPv6 routing table according to a destination address Destination, and finally forwards the packet to the inevitable node classifier.
In Step 2, the node classifier acquires information [SFF1. SF2. SFF3, SF5. Destination] about a service forwarding path to the destination node Destination and corresponding identifiers SFPID2, totally 5 hops, and meanwhile, does not acquire the metadata related information to be transmitted and shared on the service forwarding path; the path information may be locally configured, or may be acquired from a controller, and here, the node classifier plays a role in encapsulating the SFP related information.
In Step 3, the node classifier parses the SFPID2, acquires information of a first-hop node, further parses the information of the first-hop node as a routable IPv6 address, encapsulates it in a destination address field of an IPv6 header, encapsulates the SFPID2 corresponding to the information [SFF1, SF2, SFF3, SF5, Destination] about the service forwarding path in a routing header defined in the embodiment of the disclosure, and subtracts 1 from the Service Index field to obtain 4.
In Step 4, the node classifier performs forwarding to to the first-hop node SFF1 according to a destination IPv6 address in the IPv6 header. Of course, when looking up an IPv6 routing forwarding table, the node classifier may find that tunnel encapsulation or MPLS forwarding is needed for arrival at the destination IPv6 address, or may find that VLAN encapsulation, VXLAN encapsulation, tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address.
In Step 5, after SFF1 receives the packet, if finding that the destination is itself, the SFF1 parses the routing header in the packet, further parses the information of the SFPID2 and the Service Index to learn about that the current node is a first hop, further acquires information of a second-hop node SF2, parses the information of SF2 as a routable IPv6 address on the SFF1, replaces the destination address in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 3; meanwhile, the other part of the IPv6 header is parsed, and no metadata related information is parsed; the SFF1 looks up the IPv6 routing table for forwarding according to the parsed IPv6 address; and it may also be found that VLAN encapsulation, VXLAN encapsulation, tunnel encapsulation or MPLS forwarding is required for arrival at the SF2.
In Step 6, after SF2 receives the packet, if finding that the destination is itself, the SF2 parses the routing header in the packet, further parses the information of the SFPID2 and the Service Index to learn about that the current node is a second hop, further acquires information of a third-hop node SFF3, parses the information of SFF3 as a routable IPv6 address, replaces the destination address in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 2; meanwhile, the other part of the IPv6 header is parsed, and no metadata related information is parsed; the SF2 looks up the IPv6 routing table for forwarding according to the parsed IPv6 address; and it may also be found that VLAN encapsulation, VXLAN encapsulation, tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address.
In Step 7, after SFF3 receives the packet, if finding that the destination is itself and meanwhile, finding that reclassification is required on the SFF3, the SFF3 reacquires information [SF4, Destination] about a service forwarding path to the destination node Destination and corresponding identifiers SFPID3, totally 2 hops; meanwhile, the metadata related information to be transmitted and shared on the forwarding path is acquired; the path information and the metadata related information may be locally configured, or may be acquired from the controller; here, the node SFF3 forwards the path related information SFPID3 and a service index 2 according to the new service forwarding path, parses information about the first-hop node SF4 as a routable IPv6 address on the SFF3, replaces the destination in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 1; in addition, the original service forwarding path related information contained in the routing header is updated with the new service forwarding path related information, and the metadata related information is encapsulated in an IPv6 destination options headers; the SFF3 looks up the IPv6 routing table for forwarding according to the parsed IPv6 address; and it may also be found that VLAN encapsulation, VXLAN encapsulation, tunnel encapsulation or MPLS forwarding is required for arrival at the SF4.
In Step 8, after SF4 receives the packet, if finding that the destination is itself, the SF4 parses the routing header in the packet, further parses the information of the SFPID3 and the Service Index to learn about that the current node is a first hop, further acquires information of a second-hop node Destination, parses the information of the Destination as a routable IPv6 address, replaces the destination address in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 0; meanwhile, the metadata information in the packet is parsed to judge whether there is metadata information needed by the node SF4 or not; if YES, the metadata information is read and used, and after use, the metadata information is updated as needed; if NO, the metadata information is not updated; the SF4 finds that the Service Index field is 0, and strips the routing header containing the SFP related information and the destination routing header containing the metadata related information; then, the SF4 looks up the IPv6 routing table for forwarding according to the destination Destination-IPv6 address; and it may also be found that VLAN encapsulation, VXLAN encapsulation, tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address.
As shown in
In Step 1, the source node Source acquires information [SFF1, SF2, SFF3, SF5, Destination] about a service forwarding path to the destination node Destination and the corresponding global IPv6 addresses, totally 5 hops, and meanwhile, acquires metadata related information to be transmitted and shared on the service forwarding path. The path information and the metadata related information may be locally configured, or may be acquired from a controller.
In Step 2, the source node acquires IPv6 address information of a first-hop node SFF1, encapsulates it in a destination address field of an IPv6 header, encapsulates the IPv6 addresses corresponding to the information [SFF1, SF2, SFF3, SF5, Destination] about the service forwarding path in a newly extended routing header defined in the embodiment of the disclosure in an inverted sequence, that is, a packet format is shown in
In Step 3, the source node performs forwarding to implement forwarding to the first-hop node SFF1 according to a destination IPv6 address in the IPv6 header. Of course, when looking up an IPv6 routing forwarding table, the source node may find that tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address.
In Step 4, after SFF1 receives the packet, if finding that the destination is itself, the SFF1 parses the routing header in the packet, further parses the information of the service forwarding path and the Service Index to learn about that the current node is a first hop, further acquires the IPv6 address of a second-hop node SF2, replaces the destination address in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 3; meanwhile, the metadata related information in the packet is parsed to judge whether there is metadata information needed by the node SFF1 or not, and if YES, the metadata information is read and used, and after use, the metadata information is updated as needed; if NO, the metadata information is not updated; the SFF1 looks up the IPv6 routing table for forwarding according to the destination SF2-IPv6 address; and it may also be found that tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address.
In Step 5, after SF2 receives the packet, if finding that the destination is itself, the SF2 parses the routing header in the packet, further parses the information of the service forwarding path and the Service Index to learn about that the current node is a second hop, further acquires the IPv6 address of a third-hop node SFF3, replaces the destination address in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 2; meanwhile, the metadata information in the packet is parsed to judge whether there is metadata information needed by the node SF2 or not; if YES, the metadata information is read and used, and after use, the metadata information is updated as needed; if NO, the metadata information is not updated; the SF2 looks up the IPv6 routing table for forwarding according to the destination SFF3-IPv6 address; and it may also be found that tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address.
In Step 6, after SFF3 receives the packet, if finding that the destination is itself, the SFF3 parses the routing header in the packet, further parses the information of the service forwarding path and the Service Index to learn about that the current node is a third hop, further acquires the IPv6 address of a fourth-hop node SF5, replaces the destination address in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 1; meanwhile, the metadata information in the packet is parsed to judge whether there is metadata information needed by the node SFF3 or not; if YES, the metadata information is read and used, and after use, the metadata information is updated as needed; if NO, the metadata information is not updated; the SFF3 looks up the IPv6 routing table for forwarding according to the destination SF5-IPv6 address; and it may also be found that tunnel encapsulation or MPLS forwarding is required for arrival at the destination address.
In Step 7, after SF5 receives the packet, if finding that the destination is itself, the SF5 parses the routing header in the packet, further parses the information of the service forwarding path and the Service Index to learn about that the current node is a fourth hop, further acquires the IPv6 address of a fifth-hop node Destination, replaces the destination address in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 0; meanwhile, the metadata information in the packet is parsed to judge whether there is metadata information needed by the node SF5 or not; if YES, the metadata information is read and used, and after use, the metadata information is updated as needed; if NO, the metadata information is not updated; the SF5 finds that the Service Index field is 0, and strips the routing header containing the SFP related information and the destination routing header containing the metadata related information; then, the SF5 looks up the IPv6 routing table for forwarding according to the destination Destination-IPv6 address; and it may also be found that tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address.
As shown in
In Step 1, the source node Source looks up an IPv6 routing table according to a destination address Destination, and finally forwards the packet to the inevitable node Classifier.
In Step 2, the node Classifier acquires information [SFF1, SF2, SFF3, SF5, Destination] about a service forwarding path to the destination node Destination and the corresponding global IPv6 addresses, totally 5 hops, and meanwhile, acquires metadata related information to be transmitted and shared on the service forwarding path. The path information and the metadata related information may be locally configured, and may also be acquired from a controller.
In Step 3, the node Classifier acquires information of a first-hop node, encapsulates it in a destination address field of an IPv6 header, encapsulates the IPv6 addresses corresponding to the information [SFF1, SF2, SFF3. SF5, Destination] about the service forwarding path in a routing header newly extended in the embodiment of the disclosure, of which a packet format is shown in
In Step 4, the node Classifier performs forwarding to the first-hop node SFF according to a destination IPv6 address in the IPv6 header. Of course, when looking up an IPv6 routing forwarding table, the node Classifier may find that tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address.
Step 5 is the same as Step 4 in example 3.
In Step 7, after SFF3 receives the packet, if finding that the destination is itself, the SFF3 parses the routing header in the packet, if finding that the next hop is the SF5 and meanwhile, finding that the traffic on the SF5 is almost saturated by various means, reselects the next-hop SF as the SF4, updates the destination address in the IPv6 header to be SF4-IPv6, and subtracts 1 from the Service Index field to obtain 1; at this moment, the SFF3 may select to update an SFP address list, or may select not to update it; meanwhile, the metadata related information in the packet is parsed to judge whether there is metadata information needed by the node SFF3 or not; if YES, the metadata information is read and used, and after use, the metadata information is updated as needed; if NO, the metadata information is not updated; the SFF3 looks up the IPv6 routing table for forwarding according to the destination SF4-IPv6 address; and it may also be found that tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address.
In Step 8, after SF4 receives the packet, if finding that the destination is itself, the SF4 parses the routing header in the packet, further parses the information of the service forwarding path and the Service Index to learn about that the current node is a fourth hop, further acquires the IPv6 address of a fifth-hop node Destination, replaces the destination address in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 0; meanwhile, the metadata information in the packet is parsed to judge whether there is metadata information needed by the node SF4 or not; if YES, the metadata information is read and used, and after use, the metadata information is updated as needed; if NO, the metadata information is not updated; furthermore, the SF4 finds that the Service Index field is 0, and strips the routing header containing the SFP related information and the destination routing header containing the metadata related information; then, the SF4 looks up the IPv6 routing table for forwarding according to the destination Destination-IPv6 address; and it may also be found that tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address.
As shown in
In Step 1, the source node Source acquires information [SFF1, SF2, SFF3, SF5, Destination] about a service forwarding path to the destination node Destination and the corresponding SIDs, totally 5 hops, and meanwhile, does not acquire metadata related information corresponding to the service forwarding path. The path information and the metadata related information may be locally configured, or may be acquired from a controller, and here, the source node plays a role in encapsulating a routing header.
In Step 2, the source node acquires information of a first-hop node, i.e. SFF1-SID information, further parses the SFF1-SID information as a routable IPv6 address, encapsulates the address in a destination address field of an IPv6 header, encapsulates the SIDs corresponding to the information [SFF1, SF2, SFF3, SF5, Destination] about the service forwarding path in a routing header defined in the embodiment of the disclosure in an inverted sequence, that is, a packet format is shown in
In Step 3, the source node performs forwarding to to the first-hop node SFF1 according to a destination IPv6 address in the IPv6 header. Of course, when looking up an IPv6 routing forwarding table, the source node may find that tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address, or may find that VLAN encapsulation, VXLAN encapsulation, tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address.
In Step 4, after receiving the packet, if finding that the destination is itself, the SFF1 parses the routing header in the packet, further parses corresponding SF2-SID information, if finding that it is a local service SID, parses it as a routable IPv6 address on the SFF1, replaces the destination address in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 3; the SFF1 looks up the IPv6 routing table for forwarding according to the parsed IPv6 address of the SF2-SID; and it may also be found that VLAN encapsulation, VXLAN encapsulation, tunnel encapsulation or MPLS forwarding is required for arrival at the SF2-SID.
In Step 5, after SF2 receives the packet, if finding that the destination is itself, the SF2 parses the routing header in the packet, further parses corresponding SFF3-SID information as a routable IPv6 address, replaces the destination address in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 2; the SF2 looks up the IPv6 routing table for forwarding according to the parsed IPv6 address of the SFF3-SID; and it may also be found that VLAN encapsulation, VXLAN encapsulation, tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address.
In Step 6, after SFF3 receives the packet, if finding that the destination is itself the SFF3 parses the routing header in the packet, further parses corresponding SF5-SID information, if finding that it is a local service SID, parses the SF5-SID information as a routable IPv6 address on the SFF3, replaces the destination address in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 3; the SFF3 looks up the IPv6 routing table for forwarding according to the parsed IPv6 address of the SF5-SID; and it may also be found that VLAN encapsulation, VXLAN encapsulation, tunnel encapsulation or MPLS forwarding is required for arrival at the SF5-SID.
In Step 7, after SF5 receives the packet, if finding that the destination is itself, the SF5 parses the routing header in the packet, further parses corresponding Destination-SID information, parses the Destination-SID information as a routable IPv6 address, replaces the destination address in the IPv6 header with the address, and subtracts 1 from the Service Index field to obtain 0; the SF5 finds that the Service Index field is 0, and strips the routing header; then, the SF5 looks up the IPv6 routing table for forwarding according to the destination Destination-IPv6 address; and it may also be found that VLAN encapsulation, VXLAN encapsulation, tunnel encapsulation or MPLS forwarding is required for arrival at the destination IPv6 address.
As shown in
When highest two bits in an MD Option Type field of a metadata option are 00, the option is ignored:
when the highest two bits in the MD Option Type field of the metadata option are 01, the packet is discarded:
when the highest two bits in the MD Option Type field of the metadata option are 10, the packet is discarded, and no matter whether a destination address of the packet is a multicast address or not, an Internet Control Packet Protocol (ICMP) parameter error packet is sent to the source node to indicate that there is an unrecognized option type; and
when the highest two bits in the MD Option Type field of the metadata option are 11, the packet is discarded, and only when the destination address of the packet is not a multicast address, the ICMP parameter error packet is sent to the source node to indicate that there is an unrecognized option type.
According to the methods and devices provided by the abovementioned embodiments for implementing the SFC, the SFC information is encapsulated in the IPv6 header of the IPv6 and the IPv6 packet is forwarded along the SFC, so that the SFC technology may be simply deployed and rapidly implemented in an IPv6 network.
Those skilled in the art should know that all or part of the steps of the abovementioned embodiments may be implemented by virtue of a flow of a computer program, the computer program may be stored in a computer-readable storage medium, the computer program is executed on a corresponding hardware platform (for example, a system, equipment, a device and an apparatus), and during execution, one or combination of the steps of the method embodiments is included.
Alternatively, all or part of the steps of the abovementioned embodiments may also be implemented by virtue of an integrated circuit, these steps may form multiple integrated circuit modules respectively, or multiple modules or steps therein form a single integrated circuit module for implementation.
The devices/function modules/function units in the abovementioned embodiments may be implemented by adopting a universal computing device, and they may be concentrated on a single computing device, and may also be distributed on a network formed by multiple computing devices.
When being implemented in form of software function module and sold or used as independent products, the devices/function modules/function units in the abovementioned embodiments may be stored in a computer-readable storage medium. The abovementioned computer-readable storage medium may be a read-only memory, a magnetic disk, an optical disk or the like.
Disclosed are a method and apparatus for implementing a service function chain. The method is applied to a node on a service function chain. The method comprises: packaging service function chain information in an IPv6 extension header of an IPv6 message; transmitting the IPv6 message according to the service function chain information; after the IPv6 message carrying the service function chain information is received, parsing the service function chain information; and acquiring an IPv6 address of a next hop node on a service function path as a destination address, and transmitting the IPv6 message to the destination address.
Number | Date | Country | Kind |
---|---|---|---|
201510383483.2 | Jul 2015 | CN | national |
Filing Document | Filing Date | Country | Kind |
---|---|---|---|
PCT/CN2016/074458 | 2/24/2016 | WO | 00 |