WO2023029871A1 - 发送报文的方法、发送报文的控制方法及装置 - Google Patents

发送报文的方法、发送报文的控制方法及装置 Download PDF

Info

Publication number
WO2023029871A1
WO2023029871A1 PCT/CN2022/110185 CN2022110185W WO2023029871A1 WO 2023029871 A1 WO2023029871 A1 WO 2023029871A1 CN 2022110185 W CN2022110185 W CN 2022110185W WO 2023029871 A1 WO2023029871 A1 WO 2023029871A1
Authority
WO
WIPO (PCT)
Prior art keywords
message
sub
network device
node
segment
Prior art date
Application number
PCT/CN2022/110185
Other languages
English (en)
French (fr)
Inventor
王贵
沙李
耿雪松
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Publication of WO2023029871A1 publication Critical patent/WO2023029871A1/zh

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
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0894Policy-based network configuration management
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/50Routing or path finding of packets in data switching networks using label swapping, e.g. multi-protocol label switch [MPLS]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1001Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers

Definitions

  • the present application relates to the field of network technology, and in particular to a method for sending a message, a method and a device for controlling the sending of a message.
  • Redundancy protection is a general protection mechanism used to achieve high reliability of node-to-point service transmission in the network.
  • the two nodes involved in the redundancy protection are referred to as a redundancy node and a merge node, respectively.
  • the redundant node copies the message into multiple messages, and then forwards the multiple messages to the merging node through multiple different paths. After the merging node receives multiple messages, it can continue to forward one of the messages and discard other messages. In this way, even if a path between the redundant node and the merging node fails, the merging node can receive packets forwarded through other paths, thereby improving the reliability of service transmission from the redundant node to the merging node.
  • segment routing segment routing
  • SR segment routing
  • the redundant node After the redundant node receives the message, it needs to match the SR policy to realize the redundant protection of the message between the redundant node and the merging node, which is not conducive to improving the forwarding efficiency of the message by the redundant node.
  • the embodiment of the present application provides a method for sending a message, a method and a device for controlling the sending of a message, which are beneficial to improving the efficiency of sending a message by a redundant node.
  • the embodiment of the present application provides a method for sending a packet, and the method may be applied to, for example, an SR network.
  • the method in this embodiment of the present application includes: the first network device receives a first packet, the first packet includes a plurality of subpath information and first indication information, and the plurality of subpath information respectively correspond to the first network device and multiple sub-paths between second network devices, and each sub-path in the multiple sub-paths starts from the first network device, and each sub-path in the multiple sub-paths starts from the second network device End point; based on the first message including the first indication information, the first network device reports to the second network device respectively through the multiple sub-paths according to the multiple sub-path information in the first message Forwarding a plurality of second messages, where the second messages are obtained by duplicating the first message, and the second messages include the payload data of the first message.
  • the first network device After the first network device receives the first message, if the first network device parses the first indication information from the first message, the first network device can obtain multiple sub-paths corresponding to the multiple sub-paths from the first message information, and based on copying the first message to generate multiple second messages, the second message includes the payload data in the first message, and then according to the multiple sub-path information to the second network device through multiple sub-paths Forwarding a plurality of second messages is beneficial to realizing redundant protection of the first message between the first network device and the second network device, improving the reliability of message transmission, and improving the first network device's sensitivity to the first message. The forwarding efficiency of the text.
  • the second packet includes second indication information, and the second indication information instructs the second network device to forward the received target packet, where the target packet is included in the among the plurality of second packets, and discarding other packets in the plurality of received second packets except the target second packet.
  • Encapsulating the second indication information corresponding to the merge node function in the second message facilitates the second network device to recognize the second indication information and execute the merge node operation, that is, the function of deleting redundant messages to improve operation efficiency.
  • the first message is a segment routing message
  • the multiple subpath information is carried in a segment identification list field of the first message.
  • Carrying multiple subpath information in the segment identification list field of the segment routing message is beneficial to using the above message sending method in the SR network, improving the reliability and efficiency of message forwarding, and saving the overhead of the message header.
  • the first message is a segment routing message
  • the multiple subpath information is carried in the optional type length value field of the segment routing header SRH of the first message, and has It is beneficial to use the above message sending method in the SR network, improves the reliability and efficiency of message forwarding, and saves the overhead of the SRH mid-range identification list.
  • the plurality of sub-path information in the first message is an ordered list, and the ordered list includes the first sub-path information, ..., i-th sub-path information arranged in sequence Path information, ..., and nth subpath information, n is the number of subpaths in the plurality of subpaths, i is any positive integer less than or equal to n, and the ith subpath information corresponds to the plurality of subpaths
  • the i-th sub-path in the i-th sub-path, the i-th sub-path information includes a segment identification list corresponding to the i-th sub-path.
  • Carrying a plurality of sub-path information in the form of an ordered list is beneficial to improving the accuracy of identifying each sub-path information by the first network device, and improving the reliability and efficiency of message forwarding.
  • the multiple second packets are segment routing packets
  • the multiple subpath information is carried in the segment identification list field of the second packet
  • the multiple second Each message includes a segment remaining field
  • the value of the segment remaining field of each second message in the plurality of second messages is different, so that each second message in the plurality of second messages
  • the value of the segment remaining field of the text respectively points to each sub-path information in the plurality of sub-path information.
  • Carrying multiple sub-path information in the segment identification list field of the second message is beneficial to retaining more information in the first message in the second message, which in turn facilitates path backtracking at the network egress device, that is, from Multiple sub-path information is determined in the message received by the network egress device, and then the redundant path that the message passes through is determined.
  • the multiple second packets are segment routing packets, and each second packet in the multiple second packets respectively includes each of the multiple subpath information.
  • sub-path information, and each sub-path information is carried in the segment identification list field of each second message.
  • each second message only includes sub-path information of the corresponding sub-path, which is beneficial to saving message overhead and further saving network resources.
  • the first indication information is carried in the first segment identifier SID of the first network device, and the first SID is carried in the segment identifier list field of the first packet .
  • the first SID is an SRv6 SID
  • the first indication information is included in a FUNCT field and/or an ARG field of the first SID.
  • the first SID can not only identify the network segment of the network device, but also serve as the first indication information, which is beneficial to reduce message overhead.
  • the embodiment of the present application provides a method for sending a message, the method includes: a network ingress device encapsulates a plurality of sub-path information in a data message to obtain a first message, and the multiple sub-path information respectively correspond to Multiple sub-paths between the first network device and the second network device, and each sub-path in the multiple sub-paths starts from the first network device, and each sub-path in the multiple sub-paths starts from the The second network device is the end point; the network ingress device sends the first message to the first network device, and the first message also includes first indication information, and the first indication information indicates the The first network device forwards a plurality of second packets to the second network device through the plurality of subpaths according to the plurality of subpath information in the first packet, and the second packets are for all the subpaths. obtained by copying the first message, and the second message includes the payload data of the first message.
  • the network ingress device may encapsulate multiple subpath information in the data packet to obtain and send the first packet to the first network device, so that the first network device obtains multiple subpaths corresponding to the multiple subpaths from the first packet information, and based on copying the first message to generate multiple second messages, the second message includes the payload data in the first message, and then according to the multiple sub-path information to the second network device through multiple sub-paths Forwarding a plurality of second messages is beneficial to realizing redundant protection of the first message between the first network device and the second network device, improving the reliability of message transmission, and improving the first network device's sensitivity to the first message. The forwarding efficiency of the text.
  • the first message is a segment routing message
  • the multiple subpath information is carried in a segment identification list field of the first message.
  • Carrying multiple subpath information in the segment identification list field of the segment routing message is beneficial to using the above message sending method in the SR network, improving the reliability and efficiency of message forwarding, and saving the overhead of the message header.
  • the first packet is a segment routing packet
  • the multiple subpath information is carried in an optional type length value field of a segment routing header SRH of the first packet. It is beneficial to use the above message sending method in the SR network, improves the reliability and efficiency of message forwarding, and saves the overhead of the SRH mid-range identification list.
  • the encapsulating a plurality of subpath information in the data message by the network ingress device includes: encapsulating a segment identifier list in the data message by the network ingress device according to a segment routing policy, and the segment routing policy
  • the candidate path information includes the segment identification list, and the segment identification list includes the plurality of sub-path information.
  • the network ingress device can push multiple sub-path information into the data message by matching a segment routing policy, which is beneficial to improve the transmission efficiency of the data message in multiple sub-paths.
  • the embodiment of the present application provides a control method for sending messages, including: the controller sends a segment routing policy to the network ingress device, the candidate path information of the segment routing policy includes a segment identification list, and the segment identification The list includes a plurality of sub-path information, the plurality of sub-path information respectively corresponding to a plurality of sub-paths between the first network device and the second network device, and each sub-path in the plurality of sub-paths starts with the first
  • the network device is the starting point, and each sub-path in the plurality of sub-paths ends with the second network device, and the segment routing policy is used to instruct the network ingress device to encapsulate the segment identification list in a data packet to Obtaining the first message sent to the first network device, so that the first network device transmits to the second network device through the multiple sub-paths according to the multiple sub-path information in the first message
  • the network device forwards multiple second packets, where the second packets are obtained based on duplicating the first packet, and the second packet
  • a segment identification list carries multiple sub-path information, which is beneficial to enable the network ingress device to push multiple sub-path information into the data packet by matching a segment routing policy , which is conducive to improving the transmission efficiency of data packets in multiple sub-paths.
  • the embodiment of the present application provides a method for sending a message, including: the second network device receives a plurality of second messages, and the plurality of second messages include a plurality of sub-path information and segment remaining fields ;
  • the plurality of sub-path information is an ordered list, and the ordered list includes the first sub-path information, ..., the i-th sub-path information, ..., and the n-th sub-path information from front to back, and n is The number of paths in multiple sub-paths between the first network device and the second network device, each of the multiple sub-paths starts from the first network device, and each of the multiple sub-paths A sub-path ends with the second network device, i is any positive integer less than or equal to n, the i-th sub-path information corresponds to the i-th path in the plurality of sub-paths, and the i-th sub-path
  • the information includes a list of segment identifiers corresponding to the i-th subpath; the value of the
  • the second network device performs the operation of merging nodes, that is, deleting redundant messages, which is beneficial to improving the reliability of message transmission.
  • Carrying multiple sub-path information in the segment identification list field of the second message is beneficial to retaining more information in the first message in the second message, which in turn facilitates path backtracking at the network egress device, that is, from Multiple sub-path information is determined in the message received by the network egress device, and then the redundant path that the message passes through is determined.
  • the second network device forwarding the target second message in the plurality of second messages includes: the second network device modifying the target second message in the target second message The value of the segment remaining field, so that the value of the segment remaining field in the target second message corresponds to the target SID in the segment identification list of the target second message, and the target SID corresponds to the target second message
  • the next-hop network device or link in the message forwarding path is beneficial to ensure that the target second message continues to be transmitted according to the forwarding path, and is conducive to improving the reliability of message transmission.
  • the embodiment of the present application provides a method for sending a message, including: the first network device obtains a segment routing policy, and the segment routing policy includes a list of segment identifications and a binding segment identification corresponding to the list of segment identifications BSID, the segment identification list includes a plurality of sub-path information, the plurality of sub-path information respectively corresponds to a plurality of sub-paths between the first network device and the second network device, and each sub-path in the plurality of sub-paths The path starts and ends with the first network device and the second network device respectively; the first network device receives a first message, and the destination address field of the first message includes the BSID; the The first network device obtains the segment identification list according to the BSID and the SR policy, and forwards multiple second packets to the second network device respectively through the multiple subpaths, and the second packets are The first message is copied, and the second message includes payload data of the first message.
  • the first network device binds the segment identification list containing multiple sub-path information with the BSID, so that the first message only needs to carry the BSID, and the above-mentioned multiple sub-path information is carried in the segment routing policy at the same time.
  • a segment identifier list that is, the segment routing policy carries sub-path information corresponding to multiple sub-paths through a segment identifier list.
  • the first network device finds the segment identification list through the BSID, so as to obtain information about multiple subpaths.
  • the existing segment routing policy protocol if the candidate path bound by the BSID corresponds to multiple segment identifier lists, the traffic directed to the candidate path will be load balanced among the multiple paths corresponding to the multiple segment identifier lists. Therefore, it is necessary to extend the existing segment routing policy protocol by carrying multiple subpath information in multiple segment identification lists of the segment routing policy to realize redundancy protection. However, the embodiment of the present application does not need to extend the existing segment routing policy protocol, so that the first message can be redundantly protected among the multiple sub-paths corresponding to the multiple sub-path information.
  • the embodiment of the present application provides a control method for sending messages, including: the controller sends a segment routing policy to the first network device, the segment routing policy includes a segment identifier list and a segment identifier corresponding to the segment identifier list.
  • Binding segment identification BSID the segment identification list includes a plurality of sub-path information, the plurality of sub-path information respectively corresponds to a plurality of sub-paths between the first network device and the second network device, and the plurality of sub-paths
  • Each subpath in the SR policy starts from the first network device, and each subpath in the plurality of subpaths ends with the second network device, and the SR policy is used to indicate that the first network device is receiving
  • obtain the segment identification list according to the BSID and the SR policy and forward multiple second packets to the second network device through the multiple sub-paths respectively.
  • a message, the second message is obtained by duplicating the first message, and the second message includes the payload data of the first message.
  • the controller carries a segment identification list including multiple subpath information and corresponding BSIDs in the SR policy sent to the first network device, which is beneficial for the first network device to map the BSID in the first message to to multiple sub-path information, thereby effectively reducing the length of the first packet.
  • the embodiment of the present application provides a network device.
  • the network device may be a physical network device, or a device in the physical network device, or a device that can be matched with the physical network device.
  • the network device may be a virtual network device, such as a virtual switch or a virtual router.
  • the embodiment of the present application provides a network device, the network device includes a processor and a memory, the memory is used to store instructions, the memory is coupled to the processor, and the processor executes the instructions stored in the memory. Instructing, the method described in the first aspect or the second aspect or the third aspect or the fourth aspect or the fifth aspect or the sixth aspect may be implemented.
  • the communication device may also include a communication interface, which is used for the device to communicate with other devices.
  • the communication interface may be a transceiver, a circuit, a bus, a module, a pin or other types of communication interfaces, Other devices may be terminal devices.
  • the embodiment of the present application provides a chip system
  • the chip system includes: a processor, and may also include a memory, for implementing the first aspect or the second aspect or the third aspect or the fourth aspect or the first aspect The method described in the fifth aspect or the sixth aspect.
  • the system-on-a-chip may consist of chips, or may include chips and other discrete devices.
  • the embodiments of the present application provide a computer-readable storage medium, the computer-readable storage medium includes instructions, and when the instructions are run on the computer, the computer executes the above-mentioned first aspect or the second aspect according to the embodiments of the present application.
  • the embodiments of the present application provide a computer program product, the computer program product includes instructions, and when the instructions are run on the computer, the computer executes the above-mentioned first aspect or the second aspect or the third aspect according to the embodiments of the present application.
  • this embodiment of the present application provides a network (or communication system).
  • the network may include a first network device for performing the method introduced in the first aspect, and /or a network access device for executing the method introduced in the second aspect, and/or a controller for implementing the method introduced in the third aspect, and/or a second device for implementing the method introduced in the fourth aspect Internet equipment.
  • the network may include a first network device configured to execute the method introduced in the fifth aspect and a controller configured to execute the method introduced in the sixth aspect.
  • each device provided in this application can be used to execute the above-mentioned corresponding method
  • the technical effect obtained by each device of this application can refer to the technical effect obtained by the above-mentioned corresponding method, and will not be repeated here.
  • Figure 1A shows a possible application scenario to which this embodiment of the present application applies
  • FIG. 1B and FIG. 1C show a possible form of an SR policy for instructing the SR network to load balance traffic
  • Figure 1D and Figure 1E show a possible form of the SR policy used to instruct the SR network to perform redundancy protection on the message
  • Figure 2 shows a possible flow of the method of the embodiment of the present application
  • FIG. 3A shows another possible form of an SR policy used to instruct the SR network to perform redundancy protection on packets
  • FIG. 3B and FIG. 3C respectively show a possible form of the SID list R in FIG. 3A;
  • FIG. 4A, FIG. 4B and FIG. 4C respectively show another possible form of the SID list R in FIG. 3A;
  • FIG. 5A, FIG. 5B and FIG. 5C respectively illustrate the structure of the message involved in the method provided by the embodiment of the present application
  • Figure 6A and Figure 6B show a possible structure of SID (A) respectively;
  • FIG. 7A, FIG. 7B and FIG. 7C respectively show another possible flow of the method of the embodiment of the present application.
  • Fig. 8 shows another possible form of the SR policy used to instruct the SR network to perform redundancy protection on the message
  • FIG. 9A shows another possible flow of the method of the embodiment of the present application.
  • FIG. 9B shows a possible structure of the first message involved in the embodiment corresponding to FIG. 9A;
  • FIG. 10 to FIG. 13 respectively show possible structural diagrams of network devices provided by the embodiments of the present application.
  • FIG. 14 shows a schematic structural diagram of a possible chip provided by the embodiment of the present application.
  • Embodiments of the present application provide a method for sending packets and a network device based on the method.
  • the embodiments of the present application will be described below with reference to the accompanying drawings.
  • Fig. 1A shows a possible application scenario of the embodiment of the present application.
  • the traffic generated by the node CE1 can be forwarded to the node CE2 through the forwarding path between the node PE1 and the node PE2.
  • the forwarding path between the node PE1 and the node PE2 includes the node A
  • Two forwarding paths starting from node F and ending at node F (referred to as sub-path 1 and sub-path 2 respectively).
  • Traffic directed to sub-path 1 will pass through node A, node B, and node D to reach node F in sequence
  • traffic directed to sub-path 2 will pass through node A, node C, and node E to reach node F in sequence.
  • Figure 1A only exemplarily shows two forwarding paths between node A and node A. It should be noted that there may be other forwarding paths between node A and node F.
  • the sub-path 1 and the sub-path 2 shown are taken as examples for description.
  • the node CE1, the node CE2, the node PE1, the node A, the node B, the node C, the node D, the node E, the node F and the node PE2 may be the same or different types of network devices.
  • it may be a router or a switch or a forwarding device under the network architecture of a software defined network (software defined network, SDN).
  • the nodes CE1 and CE2 may be client routers, and the nodes PE1, node A, node B, node C, node D, node E, node F and node PE2 may be operator routers.
  • Node PE1 node A, node B, node C, node D, node E, node F, and node PE2 correspond to one physical network.
  • the embodiment of the present application does not limit the form of the physical network.
  • the physical network may be a segment routing (segment routing, SR) network.
  • SR is a protocol designed based on the concept of source routing to forward data packets on the network.
  • the network ingress device of the SR network can obtain the SR policy.
  • the SR policy describes a candidate path for transmitting traffic from a network ingress device (or head end) of the SR policy to a network egress device (or end point).
  • the SR policy may include path information of the candidate path.
  • the path information may be, for example, a segment (segment) or an ordered list of segment identifiers (segment identifier, SID) of each node in the candidate path, hereinafter referred to as the SID list.
  • SID segment identifier
  • the SID of a node can represent the function that the node needs to perform. After receiving the message carrying the SID list, the node in the SR network can process the message according to the function indicated by the SID matching the node in the SID list.
  • the network ingress device After the network ingress device receives a data packet matching the SR policy, it can encapsulate the path information of the active candidate path in the SR policy in the data packet, so as to instruct the network device that receives the encapsulated data packet to forward it through the candidate path the datagram.
  • the SR technology can simplify the network and have good scalability.
  • the following describes the process of the SR network forwarding data packets according to the SR policy in combination with the application scenario shown in FIG. 1A .
  • the forwarding of data packets in the SR network can be realized by issuing SR policies to node PE1 and node A respectively .
  • FIG. 1B shows a possible structure of an SR policy delivered to a network ingress device, where the SR policy may include path information of at least one candidate path.
  • FIG. 1B exemplarily shows one of the candidate paths (referred to as candidate path B), and the SR policy may also include other candidate paths.
  • the network ingress device of the SR policy shown in Figure 1B is the node PE1 shown in Figure 1A
  • the network egress device is the node PE2 shown in Figure 1A
  • the traffic forwarded through candidate path B is forwarded by node PE1 to node A , and then load-balanced between sub-path 1 and sub-path 2 and forwarded to node F, and then forwarded to node PE2.
  • the SR policy shown in FIG. 1B is called SR policy ⁇ PE1, B, PE2>.
  • node PE1 If the traffic received by node PE1 (for example, from node CE1) matches the SR policy ⁇ PE1, B, PE2>, then node PE1 can encapsulate the path information of candidate path B into a data packet, and then forward the encapsulated path information to node A datagrams.
  • the path information of the candidate path may be, for example, a SID list: ⁇ BSID(A), SID(PE2)>.
  • SID(i) is used to represent the SID of node i
  • node i may be, for example, any node in the SR network shown in FIG. 1B .
  • Figure 1C shows the SR policy delivered to node A, assuming that candidate path b shown in Figure 1C starts and ends at node A and node F respectively, as shown in Figure 1A, candidate path b may include sub-path 1 and sub-path Path 2.
  • the traffic forwarded through the candidate path b can be forwarded to node F in a load-balanced manner between sub-path 1 and sub-path 2 .
  • the SR policy shown in FIG. 1C is called SR policy ⁇ A, b, F>.
  • the candidate path b of the SR policy ⁇ A, b, F> is associated with a binding SID (banding SID, BSID), such as BSID (A) shown in FIG. 1C .
  • BSID binding SID
  • the path information of the candidate path b may include path information of sub-path 1 and path information of sub-path 2 .
  • the path information of sub-path 1 and the path information of sub-path 2 are respectively carried in different SID lists.
  • the SID list corresponding to subpath 1 is ⁇ SID(A), SID(B), SID(D), SID(F)>
  • the SID list corresponding to subpath 2 is ⁇ SID(A), SID(C) , SID(E), SID(F)>.
  • node A After node A receives traffic encapsulated with ⁇ BSID(A), SID(PE2)>, it can match SR policy ⁇ A, b, F> according to BSID(A), and according to ⁇ SID(A), SID(B), SID(D), SID(F)> and ⁇ SID(A), SID(C), SID(E), SID(F)> guide traffic forwarding to node F in a load-balanced manner between subpath 1 and subpath 2 , and then node F continues to forward the traffic to node PE2 according to the SID (PE2) in the traffic, so that the SR network forwards traffic according to SR policy ⁇ PE1, B, PE2> and SR policy ⁇ A, b, F>.
  • the SR network implements load balancing of traffic on sub-path 1 and sub-path 2.
  • the following describes how the SR network implements redundancy protection for packets on sub-path 1 and sub-path 2 according to the SR policy.
  • Redundancy protection is a general protection mechanism used to achieve high reliability of node-to-point service transmission in the network.
  • the redundant node is used to copy the message into multiple messages, and then forward the multiple messages to the merging node through multiple different paths.
  • the merging node is used to continue forwarding one message after receiving multiple messages, and discard other messages. In this way, even if a path between the redundant node and the merging node fails, the merging node can receive packets forwarded through other paths, thereby improving the reliability of service transmission from the redundant node to the merging node.
  • FIG. 1A continue to combine with the application scenario shown in FIG. 1A , to introduce how the SR network implements redundancy protection for messages on node A (redundant node) and node F (merging node) according to the SR strategy.
  • node PE1 can obtain the SR policy as shown in Figure 1D, and call the SR policy SR policy ⁇ PE1, R1, PE2>, and the SR policy ⁇ PE1, R1, PE2> includes candidate paths R.
  • the candidate path R starts and ends at node PE1 and node PE2 respectively, and node A and node F in the candidate path R respectively perform functions of a redundant node and a merge node.
  • node PE1 forwards it to node A
  • node A copies the message into two messages, and then forwards the two messages to node F through sub-path 1 and sub-path 2 respectively.
  • the path information of the candidate path R can be, for example, a SID list: ⁇ BSID(A), SID(PE2)>, only the SR policy ⁇ PE1, B, PE2> and the SR policy
  • the specific content of BSID (A) in ⁇ PE1, R1, PE2> may be different.
  • node PE1 matches the received message (for example, from node CE1) to SR policy ⁇ PE1, R, PE2>, then node PE1 can encapsulate the path information of the candidate path R into the data message, and then forward it to node A Encapsulated data packets.
  • Node A may acquire the SR policy as shown in FIG. 1E , and call the SR policy ⁇ A, r1, F>, and the SR policy ⁇ A, r1, F> includes the candidate path r.
  • the SR policy ⁇ A, r1, F> can be obtained by extending the SR policy ⁇ A, b, F> shown in FIG. 1C .
  • the SR policy ⁇ A, r1, F> delivered to node A can be additionally associated with a redundancy identifier, and the redundancy identifier can be used to indicate that the SR policy is used to implement redundancy. Yu protection.
  • the path information of the candidate path r may include a SID list corresponding to subpath 1 and a SID list corresponding to subpath 2.
  • node A After node A receives the message encapsulating ⁇ BSID(A), SID(PE2)> sent by node PE1, it can match SR policy ⁇ A, r1, F> according to BSID (A), and execute the function of redundant node. Specifically, for example, copy the message to obtain two messages, and then forward them to the merging node (that is, node F) through subpath 1 according to ⁇ SID(A), SID(B), SID(D), and SID(F)> The message forwards the message to the merging node (that is, node F) through sub-path 2 according to ⁇ SID(A), SID(C), SID(E), and SID(F)>.
  • node F After node F receives the two messages arriving through sub-path 1 and sub-path 2, it can continue to forward one of the messages and discard the other message. In this way, even if a path between node A and node F fails, node F can receive packets forwarded through other paths, thereby improving the reliability of service transmission from node A to node F, and realizing the Redundant protection between A and node F.
  • Solution 2 Carry sub-path 1 and the path information of the sub-path in the SR policy delivered to the network ingress device
  • the above-mentioned SR network forwarding process involves at least two SR policy matching processes.
  • it is also necessary to match the SR policy at node F ⁇ A, b, F> or SR policy ⁇ A, r1, F> is not conducive to improving the packet forwarding efficiency of the SR network.
  • the technical solution introduced in Solution 2 aims to reduce the number of SR policy matching involved in the process of realizing the redundant protection of messages in the SR network, thereby improving the forwarding efficiency of messages by redundant nodes.
  • FIG. 2 shows a possible flow of the method of the present application.
  • a possible flow of the method for sending an application message includes step S201 to step S211 .
  • the controller sends the SR policy ⁇ PE1, R2, PE2> to PE1;
  • the application scenario shown in FIG. 1A further includes a controller, and the controller may send the SR policy to the network ingress device.
  • the network ingress device corresponding to the SR policy is node PE1
  • the network egress device corresponding to the SR policy ⁇ PE1, R2, PE2> is node PE2.
  • the SR policy acquired in S201 is called SR policy ⁇ PE1, R2, PE2>.
  • the candidate paths of the SR policy ⁇ PE1, R2, PE2> include the candidate path R, which can be interpreted as the candidate path R in the above scheme 1, that is, the node PE1 and the node PE2 are the starting point and the end point of the candidate path R respectively , and node A and node F in the candidate path R are respectively used as a redundant node and a merge node, so that messages forwarded through the candidate path R can be redundantly protected between node A and node F.
  • the SR policy ⁇ PE1, R2, PE2> may also include candidate paths other than the candidate path R, for example, the SR policy ⁇ PE1, R2, PE2> may also include the candidate paths shown in Figure 1B b.
  • the SR policy ⁇ PE1, R2, PE2> may describe the candidate path R through a SID list, and the SID list is referred to as the SID list R for convenience of description.
  • SID(i) represents the SID of node i, and node i is any node in the candidate path R.
  • SID(B) and SID(D) correspond to the SID list corresponding to subpath 1
  • SID(C) and SID(E) correspond to the SID list corresponding to subpath 2.
  • the SID lists corresponding to sub-path 1 and sub-path 2 are called SID list r1, list r1, and SID list r2, respectively.
  • Fig. 3C shows another possible form of the SID list R.
  • SID(i) is still used to represent the SID of node i, and node i is any node in the candidate path R.
  • SID (B), SID (D) and SID (F) are equivalent to the SID list corresponding to subpath 1
  • SID (C), SID (E) and SID (F) are equivalent to SID list corresponding to subpath 2.
  • the SID lists corresponding to sub-path 1 and sub-path 2 are respectively called SID list r1 list r1 and SID list r2.
  • FIG. 3B and FIG. 3C only exemplarily show possible forms of the SID list R, and this embodiment of the present application does not limit the specific form of the SID list R.
  • the SR network shown in FIG. 1A may be an SR (SR over MPLS, SR-MPLS) network using multi-protocol label switching (multi-protocol label switching, MPLS).
  • the SID(i) in the SID list R can be encoded as an MPLS label (label).
  • the MPLS label may include a label value field, and the label value field is used to identify a forwarding equivalence class (forwarding equivalence class, FEC).
  • the SID list R shown in FIG. 4A as an example, the SID list R in the SR policy ⁇ PE1, R2, PE2> may be, for example, the label stack shown in FIG. 5A .
  • an MPLS label (node i) is used to represent the MPLS label of node i, and node i is still any node in the candidate path R.
  • the SR network shown in FIG. 1A may be a segment routing (SR using IPv6 data plane, SRv6) network using an Internet protocol version 6 (internet protocol version 6, Ipv6) data plane.
  • the SID(i) in the SID list R may be encoded as an Ipv6 address.
  • the SID(i) under the SRv6 technology is called SRv6SID(i).
  • the SRv6SID(i) may include a local (locator, LOC) field and a function (function, FUNC) field, and optionally, the SRv6SID(i) may also include an argument (argument, ARG) field.
  • the LOC field can be a network segment address that can be routed to node i.
  • the LOC field can be expressed in the form of "B field: N field", where "B field” is the IPv6 address allocated by the operator for SRv6SID(i). Subnet, "N field” is the identifier of the parent node of the instantiated SID(i).
  • the FUNCT field may indicate a certain function corresponding to SRv6 SID(i).
  • the ARG field can be used for FUNCT field parameters, such as defining message flow and service information.
  • the FUNCT field of the node in the SID list R will be introduced later and will not be expanded here.
  • the SID list R in the SR policy ⁇ PE1, R2, PE2> may be, for example, the SRv6 SID ordered list shown in FIG. 4B .
  • the SID list R in the SR policy ⁇ PE1, R2, PE2> may be, for example, the SRv6 SID ordered list shown in FIG. 4C .
  • SRv6SID(i) is used to represent the SRv6SID of node i, and node i is still any node in the candidate path R.
  • Node CE1 sends message 0 to node PE1;
  • the application scenario shown in FIG. 1A also includes nodes CE1 and CE2.
  • Node CE1 and node CE2 may be routers or switches or forwarding devices under the network architecture of software defined network (software defined network, SDN).
  • node CE1 and node CE2 may be client routers.
  • Node CE1 may send message 0 to node PE1, so as to forward the payload data in message 0 to node CE2.
  • the node PE1 encapsulates the SID list R in the message 0 to obtain the message 1;
  • node PE1 may receive SR policy ⁇ PE1, R2, PE2> and message 0 respectively. Assuming that packet 0 matches the SR policy ⁇ PE1, R2, PE2>, and the candidate path R is an active candidate path of the SR policy ⁇ PE1, R2, PE2>, node PE1 can encapsulate the SID list R in packet 0 to obtain Message 1.
  • the payload data (payload) in message 1 is the same as the payload data in message 0.
  • Packet 1 may be an SR packet.
  • packet 1 may be an SR-MPLS packet or an SRv6 packet.
  • the possible structures of the two types of message 1 are respectively introduced below.
  • FIG. 5A shows a possible structure of message 1 .
  • the SID list R may be carried in the label stack of the packet 1 .
  • node PE1 may push the SID list R shown in FIG. 4A into packet 0 to obtain, for example, packet 1 shown in FIG. 5A .
  • the MPLS label to be enforced eg, MPLS label (A)
  • MPLS label (A) is at the top of the label stack.
  • the MPLS label at the top of the label stack may be called an active (active) MPLS label.
  • FIG. 5B shows another possible structure of message 1 .
  • the SID list R may be carried in the SID list field of the message 1, and the SID list field is located in the SR Header (SR Header, SRH) of the message 1.
  • node PE1 may push the SID list R shown in FIG. 4B into packet 0 in reverse order to obtain, for example, packet 1 shown in FIG. 5B .
  • FIG. 5C shows another possible structure of message 1 .
  • the SID list R may be carried in the SID list field of the message 1, and the SID list field is located in the SR Header (SR Header, SRH) of the message 1.
  • node PE1 may push the SID list R shown in FIG. 4C into packet 0 in reverse order to obtain, for example, packet 1 shown in FIG. 5C .
  • the SRv6 SID to be executed may be called an active SRv6 SID.
  • the SRH of message 1 includes a segment left (SegmentLeft, SL) field, and the SL field indicates the active SRv6 SID in the SR list field.
  • the number in “[]” represents the serial number of the corresponding SID in the SR list field. Since the sequence number of SRv6SID(A) is the SRv6SID with the largest sequence number in the SR list field, SRv6SID(A) is the first executed SRv6SID in the SR list field.
  • the value of SL may be the serial number of SRv6 SID(A) (namely 6).
  • the value of SL may be the serial number (namely 7) of SRv6 SID(A).
  • the active SRv6SID is also carried in the destination address (Destination Address, DA) field of the Ipv6 header of the message 1, for example, the DA field of the message 1 includes SRv6SID (A).
  • the SL field indicates the next SRv6SID of the active SRv6SID in the SR list field. Taking packet 1 shown in FIG. (A) pop-up, which is beneficial to save the length of message 1.
  • packet 1 is an SRv6 packet, or, optionally, the SID list R may be carried in the optional Type Length Value (TLV) field of packet 1 (such as the optional TLV shown in Figure-7B).
  • TLV Type Length Value
  • message 1 must be the structure shown in FIG. 5A, FIG. 5B or FIG. 5C.
  • a layer-3 protocol header such as a user datagram protocol (UDP) header
  • UDP user datagram protocol
  • FIG. 5B or FIG. 5C only shows the DA field of the Ipv6 header in the message, and does not show other fields in the Ipv6 header for the purpose of simplification.
  • Node PE1 sends message 1 to node A;
  • the node PE1 After the node PE1 obtains the message 1, it can search the forwarding information of the node A, and send the message 1 to the node A according to the forwarding information of the node A.
  • the message 1 sent by node PE1 to node A may refer to the structure of message 1 in FIG. 5A or FIG. 5B or FIG. 5C.
  • the embodiment of this application does not limit the direct connection between node PE1 and node A.
  • node PE1 can forward message 1 to node A through other network devices.
  • the embodiment of this application does not limit the connection between message 1 sent by node PE1 and node A.
  • Received message 1 is the same.
  • the message 1 sent by node PE1 and the message 1 received by node A both include the SID list R introduced above, and include the same payload data, etc.
  • the position of the SID list R in message 1 can refer to Figure 5A Or the form of Figure 5B or Figure 5C. Therefore, for ease of description, in this embodiment of the present application, the message sent by node PE1 and the message received by node A in step S204 are collectively referred to as message 1.
  • Node A generates message 2 according to SID list r1 and list r1 in message 1, and generates message 2' according to SID list r2 in message 1';
  • Node A forwards message 2 to node F through subpath 1;
  • Node A forwards message 2' to node F through sub-path 2;
  • node A can receive message 1. After receiving the message 1, the node A can analyze the message 1, and then execute steps S205 to S208.
  • Step S205 to step S208 will be described below using message 1 shown in FIG. 5A or FIG. 5B or FIG. 5C respectively.
  • Node A can parse the packet 1 to obtain the MPLS label (A).
  • Figure 6A shows a possible structure of the MPLS label (A).
  • the packet 1 can be copied under the instruction of the first function to obtain two packets 1 .
  • the message 1 may also obtain the SID list r1 list r1 and the SID list r2 from the message 1 under the instruction of the first function.
  • the message 1 copied from the above two messages 1 is referred to as message 1' in the following.
  • message 1 can also generate message 2 forwarded to node F through sub-path 1 according to SID list r1 list r1 and message 1, and generate message 2 according to SID list r2 and message 1' through Message 2' forwarded by sub-path 2 to node F.
  • the payload data of message 2 and message 1 are the same, and the payload data of message 2' and message 1 are the same.
  • FIG. 5A shows a possible structure of message 2 .
  • the label stack of message 2 carries SID list r1 and list r1, but does not carry SID list r2. Therefore, message 2 sent by node A will reach node F through subpath 1, that is, node A passes subpath 1 to Node F forwards message 2.
  • FIG. 5B shows a possible structure of message 2'. Referring to Figure 5B, it can be seen that the label stack of message 2' carries the SID list r2, but does not carry the SID list r1 list r1, therefore, the message 2' sent by node A will reach node F through subpath 2, that is, node A passes through subpath 2 forwards message 2' to node F.
  • the MPLS label (A) can be extended, and the primary SID list (abbreviated as Pri-SIDs) field and the standby SID list (abbreviated as Back-SIDs) field can be added at the end of the original MPLS label (A) .
  • the Pri-SIDs field and the Back-SIDs field are used to determine the SID list r1 list r1 and the SID list r2 in the message 1 respectively.
  • the Pri-SIDs field and the Back-SIDs field respectively indicate the number of SIDs in the SID list r1 (for example, 2) and the number of SIDs in the SID list r2 (for example, 2).
  • node A When node A determines that the label field in the MPLS label (A) corresponds to the first function, node A can obtain the Pri-SIDs field and the Back-SIDs field from the MPLS label (A) respectively, and then according to the Pri-SIDs field and the Back-SIDs field, - The SIDs field obtains the SID list r1 list r1 and the SID list r2 from the message 1 respectively, and then executes step S206.
  • Figure 6A shows a possible structure of an MPLS label (A) including two subpaths between node A and node F. If there are more subpaths between node A and node F, the MPLS label (A) can further expand the description field of the corresponding subpath on the basis of FIG.
  • the MPLS label (A) may also include a description field of the number of subpaths to describe the number of subpaths between node A and node F. number. For example, after the node (A) determines that the label field in the MPLS label (A) matches the first function (i.e.
  • the redundant node it can parse the description field of the number of subpaths from the TTL field of the MPLS label (A), According to the number of sub-paths (assumed to be 3) indicated by the value of the description field, continue to parse the description fields of the three sub-paths to determine the number of SIDs in the SID list of each sub-path, thereby facilitating accurate slave message 1 to obtain the list of SIDs.
  • Node A can parse the IPv6 header of message 1 to obtain the SRv6 SID(A) carried in the DA field.
  • Figure 6B shows a possible structure of SRv6SID(A).
  • the LOC field of SRv6SID(A) is the network segment address of node A, and node A can follow the indication of the FUNCT field of SRv6SID(A) Process message 1.
  • the FUNCT field indicates the first function (corresponding to the function of the redundant node)
  • node A can perform steps S205 to S208 under the instruction of the first function.
  • steps S205 to S208 are executed under the instructions, which will not be repeated here.
  • FIG. 5B shows another possible structure of message 2 .
  • the SID list field of message 2 carries the SID list R1, but does not carry the SID list r2. Therefore, the message 2 sent by node A will reach node F through subpath 1, that is, node A sends node A to node F through subpath 1. F forwards packet 2.
  • FIG. 5B shows another possible structure of the message 2'.
  • the SID list field of message 2' carries SID list r2, but does not carry SID list r1, therefore, message 2' sent by node A will reach node F through subpath 2, that is, node A passes through subpath 2 Forward message 2' to node F.
  • the ARG field may include a primary SID list (abbreviated as Pri-SIDs) field and a standby SID list (abbreviated as Back-SIDs) field.
  • Pri-SIDs field and the Back-SIDs field are used to determine the SID list r1 and the SID list r2 in the message 1 respectively.
  • the Pri-SIDs field and the Back-SIDs field respectively indicate the number of SIDs in the SID list r1 (for example, 2) and the number of SIDs in the SID list r2 (for example, 2).
  • node A When node A determines that the FUNCT field of SRv6SID(A) indicates the first function, node A can obtain the Pri-SIDs field and Back-SIDs field from SRv6SID(A) respectively, and then according to the Pri-SIDs field and Back-SIDs field respectively Obtain the SID list r1 and the SID list r2 from the message 1, and then execute step S206 to step S208.
  • FIG. 6B shows a possible structure of SRv6 SID(A) including two subpaths between node A and node F. If there are more subpaths between node A and node F, SRv6SID(A) can further expand the description field of the corresponding subpath on the basis of FIG. 6B . For example, if subpath 3 is also included between node A and node F, then the ARG field of SRv6SID(A) shown in FIG. 6B may also add a standby SID list field, which indicates the SID list of subpath 3 The number of SIDs in (13).
  • SRv6SID(A) may also include a description field of the number of subpaths to describe the number of subpaths between node A and node F.
  • the node (A) determines that the FUNCT field in the SRv6SID(A) indicates the first function (that is, the function of the redundant node), it can analyze the description field of the number of subpaths from the TTL field of the SRv6SID(A), according to the The number of sub-paths indicated by the value of the description field (assumed to be 3), continue to parse the description fields of the 3 sub-paths to determine the number of SIDs in the SID list of each sub-path, so as to facilitate accurate information from message 1 Obtain a list of SIDs.
  • the SL field indicates the next SRv6SID of the active SRv6SID in the SR list field, taking message 2 shown in Figure 5B as an example, the SL field
  • the value of is 2, and packet 2 may not include SRv6SID(A) and SRv6SID(B), which is beneficial to save the length of packet 2.
  • Node A can parse the IPv6 header of message 1 to obtain the SRv6 SID(A) carried in the DA field.
  • a possible structure of SRv6SID(A) can continue to refer to FIG. 6B .
  • the LOC field of SRv6SID(A) is the network segment address of node A, and node A can follow the indication of the FUNCT field of SRv6SID(A) Process message 1. Assuming that the FUNCT field indicates the first function, node A can perform steps S205 to S208 under the instruction of the first function. For details, you can refer to the correlation between node A performing steps S205 to S208 under the instruction of the first function corresponding to the label described above. content, which will not be repeated here.
  • FIG. 5C shows another possible structure of message 2 .
  • the SL field in the SRH of message 2 points to SRv6SID(B), therefore, message 2 sent by node A will reach node F through subpath 1, that is, node A forwards the message to node F through subpath 1 Text 2.
  • FIG. 5C shows another possible structure of the message 2'.
  • the SL field in the SRH of message 2 points to SRv6SID(C), therefore, message 2' sent by node A will reach node F through subpath 2, that is, node A forwards to node F through subpath 2 Message 2'.
  • the ARG field may include a primary SID list (abbreviated as Pri-SIDs) field and a standby SID list (abbreviated as Back-SIDs) field.
  • Pri-SIDs primary SID list
  • Back-SIDs standby SID list
  • the Pri-SIDs field and the Back-SIDs field are used to determine the SID list r1 list r1 and the SID list r2 in the message 1 respectively.
  • the Pri-SIDs field and the Back-SIDs field respectively indicate the number of SIDs in the SID list r1 (for example, 2) and the number of SIDs in the SID list r2 (for example, 2).
  • node A When node A determines that the FUNCT field of SRv6SID(A) indicates the first function, node A can obtain the Pri-SIDs field and Back-SIDs field from SRv6SID(A) respectively, and then according to the Pri-SIDs field and Back-SIDs field respectively Obtain the SID list r1 and the SID list r2 from the message 1, and then execute steps S206 to S208.
  • the embodiment of the present application does not limit the execution of steps S206 to S208 in the order of serial numbers. For example, after node A generates message 2, it can send message 2 without waiting for message 2' to be generated. Then send message 2.
  • Node F generates message 3 according to message 2;
  • Message 2 sent by node A passes through node B and node D in turn, and then reaches node F.
  • the message generated and forwarded by node B and node D according to message 2 is called message 2.
  • Node B can pop out the MPLS label (B) after receiving message 2, and then continue to forward message 2 to node D.
  • node D receives message 2, it can pop out the MPLS label (D), and then continue to forward message 2 to node F.
  • node F After receiving message 2, node F can generate message 3 according to message 2. For example, it can pop the MPLS label (F) in message 2 to obtain message 3 as shown in FIG. 5A.
  • the payload data of message 3 and message 2 are the same.
  • Node B After Node B receives message 2, it can decrement the value of the SL field in the SRH of message 2 by one according to the indication of the FUNCT field in SRv6SID(B), and the SL field points to the next SRv6SID(D), and points to Copy the SRv6SID(D) of the DA field to the DA field, and then continue to forward message 2 to node D.
  • node D After receiving message 2, node D can decrease the value of SL field in SRH of message 2 by one according to the instruction of FUNCT field in SRv6SID(D), and the SL field points to the next SRv6SID(F), and points to Copy the SRv6SID(F) of the DA field to the DA field, and then continue to forward message 2 to node F.
  • the function indicated by the FUNCT field in SRv6SID(B) and SRv6SID(D) may be an Endpoint function.
  • node F After receiving message 2, node F can generate message 3 according to message 2. For example, according to the indication of the FUNCT field in SRv6SID(F), the value of the SL field in the SRH of message 2 can be reduced by one, and the SL field Point to the next SRv6SID (PE2), to obtain, for example, packet 3 as shown in FIG. 5B.
  • PE2 next SRv6SID
  • Node B After Node B receives message 2, it can decrement the value of the SL field in the SRH of message 2 by one according to the indication of the FUNCT field in SRv6SID(B), and the SL field points to the next SRv6SID(D), and points to Copy the SRv6SID(D) of the DA field to the DA field, and then continue to forward message 2 to node D.
  • node D After receiving message 2, node D can decrease the value of SL field in SRH of message 2 by one according to the instruction of FUNCT field in SRv6SID(D), and the SL field points to the next SRv6SID(F), and points to Copy the SRv6SID(F) of the DA field to the DA field, and then continue to forward message 2 to node F.
  • the function indicated by the FUNCT field in SRv6SID(B) and SRv6SID(D) may be an Endpoint function.
  • node F may generate message 3 according to message 2 according to the function indicated by the FUNCT field in SRv6SID(F) (called the second function).
  • the second function may correspond to the function of the merging node, and the embodiment of the present application may extend the second function, for example, instead of decrementing the value of the SL field in the SRH of message 2 by one, the SL field points to the next SRv6SID(PE2), but point the value of the SL field to the next-hop network device (that is, node PE2) of the second packet, so as to obtain, for example, packet 3 shown in FIG. 5C.
  • the payload data of message 3 and message 2 are the same.
  • the node F forwards the message 3 to the node PE2;
  • node F After node F obtains message 3 according to message 2, it can send message 3 to node PE2.
  • the node F discards the packet 2'.
  • the message 2' sent by node A passes through node C and node E in turn, and then reaches node F.
  • node F After node F receives message 2', it can process message 2' according to the indication of the FUNCT field in SRv6SID(F).
  • the function indicated by the FUNCT field in SRv6SID(F) can be extended.
  • the function indicated by the FUNCT field in SRv6SID(F) instructs node F to discard messages other than the first one arriving at the node F. Assuming that message 2 arrives at node F before message 2', node F may discard message 2' according to the indication of the FUNCT field in SRv6 SID(F).
  • node PE1 After node PE1 receives packet 0 matching SR policy ⁇ PE1, R2, PE2>, it can encapsulate the SID list R into packet 0 according to the instruction of SR policy ⁇ PE1, R2, PE2>, and obtain packet 1.
  • node A After receiving message 1, node A can forward message 2 carrying the payload data in message 1 to node F through sub-path 1 and sub-path 2 respectively according to the carried SID list r1 and SID list r2, without the need of solution 1
  • the introduced re-matching SR policy ⁇ A, r1, F> is therefore beneficial to realize the redundancy protection of message 2 between node A and node F, and improve the forwarding of message by node A through subpath 1 and subpath 2 respectively. 1 efficiency.
  • the candidate path R applicable to this application may include more or less network devices, and correspondingly, the SID list R may include more or less SIDs.
  • the SID list R in the SR policy ⁇ PE1, R2, PE2> may also include the SID of the corresponding intermediate network device, and the report sent by node PE1 Document 1 can also include the corresponding intermediate network device SID.
  • the intermediate network device can re-encapsulate the received message (such as popping up the corresponding MPLS label or modifying the value of SL in SRH) , and then forward the re-encapsulated message.
  • step S205 node A copies message 1 to obtain more message 2.
  • the number of obtained message 2 is equal to the difference between A and F in candidate subpath 1.
  • the number of subpaths is the same.
  • the candidate path R also includes a sub-path 3 with A as the starting point and F as the end point, then in step S205, node A can obtain three messages 1 by copying message 1 (such as message message 1, message Message 1' and Message 1"), correspondingly, node F will receive more Message 2 (for example, Message 2, Message 2' and Message 2").
  • message 1 such as message message 1, message Message 1' and Message 1
  • Message 2 for example, Message 2, Message 2' and Message 2"
  • Another possible flow of the method for sending an application message may include step S701.
  • the controller sends the SR policy to the network ingress device.
  • the controller can generate an SR policy, and send the SR policy to a network ingress device corresponding to the SR policy.
  • the controller may be the controller shown in FIG. 1A
  • the SR policy may be the SR policy ⁇ PE1, R2, PE2> mentioned in the embodiment corresponding to FIG. 2, or, for example, the SR policy shown in FIG. 3A ⁇ PE1, R2, PE2>.
  • the candidate path information of the SR policy may include a SID list.
  • the SID list may be understood with reference to the SID list R corresponding to FIG. 3B or FIG. 3C or FIG. 4A or FIG. 4B or FIG. 4C.
  • the SID list may include a plurality of subpath information, and the plurality of subpath information respectively correspond to a plurality of subpaths between the first network device and the second network device, and each subpath in the plurality of subpaths starts from the first network device, and the plurality of Each of the sub-paths terminates at the second network device.
  • the multiple subpath information may be understood with reference to the SID list r1 and the SID list r2 corresponding to FIG. 3B or FIG. 3C or FIG. 4A or FIG. 4B or FIG. 4C.
  • the first network device and the second network device may be understood with reference to node A and node F corresponding to FIG. 1A and FIG. 2 .
  • multiple subpaths can be understood with reference to the corresponding subpath 1 and subpath 2 in FIG. 1A or FIG. 2 .
  • FIG. 7A shows another possible flow of the method in the embodiment of the present application.
  • the method in this embodiment of the present application may include step S701A to step S702A.
  • the network ingress device encapsulates multiple subpath information in the data packet to obtain the first packet;
  • the network ingress device may receive the SR policy issued by the controller, and then encapsulate multiple subpath information in the data message according to the SR policy, so as to obtain the first message.
  • the second packet includes payload data of the first packet.
  • the SR policy and multiple sub-path information can be understood by referring to the corresponding content in step S701.
  • the embodiment of the present application does not limit the network ingress device to obtain the SR policy from the controller, for example, the network ingress device may locally generate the SR policy.
  • the controller can be understood with reference to the controller mentioned in step S701.
  • the first packet may be an SR packet.
  • multiple subpath information may be carried in the TLV field of the segment routing header SRH of the first packet.
  • a plurality of subpath information (such as SID list r1 and SID list r2) may be carried in the SID list field of the first message.
  • the plurality of sub-path information in the first message is an ordered list, and the ordered list includes the first sub-path information, ..., the i-th sub-path information, ..., and the n-th sub-path in sequence information, n is the number of sub-paths in multiple sub-paths, i is any positive integer less than or equal to n, the i-th sub-path information corresponds to the i-th sub-path among the multiple sub-paths, and the i-th sub-path information includes the i-th sub-path A list of SIDs corresponding to subpaths.
  • multiple subpaths can be understood with reference to the corresponding subpath 1 and subpath 2 in FIG. 1A or FIG. 2 .
  • the network ingress device sends the first packet to the first network device.
  • the network ingress device may send the first packet to the first network device.
  • the network entrance device can be understood with reference to the node PE1 corresponding to FIG. 1A or FIG. 2
  • the first network device can be understood with reference to the node A corresponding to FIG. 1A or FIG. 2 .
  • FIG. 7B shows another possible flow of the method in the embodiment of the present application.
  • the method in this embodiment of the present application may include step S701B and step S702B.
  • the first network device receives the first packet
  • the first packet may come from, for example, the network entry device in the embodiment corresponding to FIG. 7A .
  • the first packet may include multiple pieces of subpath information and first indication information.
  • the plurality of sub-path information respectively correspond to a plurality of sub-paths between the first network device and the second network device, and each sub-path in the plurality of sub-paths starts from the first network device, and each sub-path in the plurality of sub-paths starts from the first network device
  • the second network device is the end point.
  • the first packet, the multiple subpath information, and the multiple subpaths may be understood with reference to corresponding content in the embodiment corresponding to FIG. 7A .
  • the first network device Based on the fact that the first packet includes the first indication information, the first network device respectively forwards the multiple second packets to the second network device through the multiple subpaths according to the multiple subpath information in the first packet.
  • the first network device may parse the first packet.
  • the first packet may carry the first indication information, and the first network device may parse the first indication information.
  • the first indication information may be carried in the first SID of the first network device, and the first SID is carried in the SID list field of the first packet.
  • the first SID may be, for example, the MPLS label (A) in packet 1 shown in FIG. 5A or FIG. 6A .
  • the first indication information may be carried in a label field in the MPLS label (A).
  • the first SID may be, for example, the SRv6 SID (A) in packet 1 shown in FIG. 5B or FIG. 5C .
  • the first indication information may be carried in the FUNCT field and/or the ARG field in the SRv6 SID(A).
  • the first network device After the first network device parses the first indication information from the first message, it may, under the instruction of the first indication information, forward the message to the second network device through multiple sub-paths according to the multiple sub-path information in the first message. Multiple second messages.
  • the second packet may be obtained by duplicating the first packet, and the second packet includes payload data of the first packet.
  • the process of the first network device forwarding multiple second packets to the second network device through multiple subpaths according to the multiple subpath information in the first packet can refer to steps S205 to S208 Comprehend.
  • the multiple second packets may be segment routing packets.
  • multiple subpath information may be carried in the SID list field of the second packet.
  • each second message in the plurality of second messages respectively includes each sub-path information in the plurality of sub-path information,
  • Each subpath information is carried in the SID list field of each second packet.
  • each of the multiple second packets includes an SL field and multiple subpath information.
  • the value of the SL field of each second message in the multiple second messages is different, so that the value of the SL field of each second message in the multiple second messages points to multiple sub-path information respectively Each subpath information in .
  • the values of the SL fields of message 2 and message 2' are 6 and 3 respectively, so that the values of the SL fields of message 2 and message 2' point to the SID list r1 and the SID list respectively r2.
  • FIG. 7C shows another possible flow of the method in the embodiment of the present application.
  • the method in this embodiment of the present application may include step S701C and step S702C.
  • the second network device receives multiple second packets
  • the multiple second packets may come from the first network device in the embodiment corresponding to FIG. 7B .
  • the multiple second packets can be understood with reference to the multiple second packets in step S702B.
  • the second network device forwards the target second packet in the multiple second packets, and discards other packets in the multiple second packets except the target second packet.
  • the second packet may include second indication information, and the second network device may, under the indication of the second indication information, forward target second packets among the multiple second packets, and discard the multiple second packets other packets except the target second packet.
  • the target second packet may be a second packet that first arrives at the second network device among the multiple second packets.
  • each of the multiple second packets including each subpath information in the multiple subpath information as an example, after the second network device receives the target second packet, it may Under the instruction of the second instruction information of the target, modify the value of the SL field in the target second message, so that the value of the SL field in the target second message corresponds to the target SID in the SL list of the target second message, wherein , the target SID corresponds to the next-hop network device or link in the target second packet forwarding path.
  • the target SID may be SRv6SID(PE2), and after receiving packet 2, the second network device may change the value of SL in packet 2 from 6 to It is changed to 0, that is, the value of the SL field of the second packet points to the node PE2.
  • the first network device After the first network device receives the first message, if the first network device parses the first indication information from the first message, the first network device can obtain multiple sub-paths corresponding to the multiple sub-paths from the first message information, and based on copying the first message to generate multiple second messages, the second message includes the payload data in the first message, and then according to the multiple sub-path information to the second network device through multiple sub-paths Forwarding multiple second packets is beneficial to realizing redundancy protection of the first packet between the first network device and the second network device, and improving the forwarding efficiency of the first network device for the first packet.
  • the above schemes 1 and 2 respectively introduce the alternative schemes for the SR network to implement redundancy protection for packets on sub-path 1 and sub-path 2 according to the SR policy.
  • the following supplements the introduction of another scheme for SR network redundancy protection in combination with scheme 3. option.
  • Solution 3 follows the mechanism of SR policy ⁇ A, b, F> to issue SR policy to redundant nodes
  • the SR policy ⁇ A, b, F> needs to be extended. If node A saves SR policy ⁇ A, b, F> and SR policy ⁇ A, r1, F>, when node A receives the BSID (A) packets, after node A matches the SR policy corresponding to BSID (A), it needs to continue to analyze whether the SR policy includes redundant identifiers, so as to determine how to process the packet according to the multiple SID lists corresponding to the candidate path. arts. Not only does it need to extend the SR policy, but it also reduces the efficiency of node A in processing packets according to the SR policy.
  • scheme three proposes to use the mechanism of SR policy ⁇ A, b, F> to issue SR policy to redundant nodes.
  • the optional solutions provided by the third solution are introduced below.
  • the controller sends the SR policy to the first network device
  • the controller may send an SR policy to the first network device, and the section routing policy may include an SR list and a BSID corresponding to the SID list.
  • the SR list can be understood with reference to SID(A) to SID(F) shown in FIG. 3B or FIG. 4A or FIG. 4B.
  • the controller and the first network device can be understood with reference to the controller and node A shown in FIG. 1A , respectively.
  • the SR list may include a plurality of subpath information, and the plurality of subpath information respectively correspond to a plurality of subpaths between the first network device and the second network device, and each subpath in the plurality of subpaths starts from the first network device, and the plurality of subpaths Each of the sub-paths terminates at the second network device.
  • multiple subpaths can be understood with reference to the corresponding subpath 1 and subpath 2 in FIG. 1A or FIG. 2 .
  • the multiple subpath information may be understood with reference to the SID list r1 list r1 and the SID list r2 corresponding to FIG. 3B or FIG. 4A or FIG. 4B.
  • the SR strategy can be, for example, the SR strategy ⁇ A, r3, F> in FIG. SID list r).
  • the candidate path r may be, for example, the candidate path r shown in FIG. 1E , which includes subpath 1 and subpath 2, and node A and node F are redundant nodes and merge nodes respectively.
  • the SID list r may include, for example, SID(A), SID list r1 , SID list r2 and SID(F) shown in FIG. 3B .
  • the BSID can be understood with reference to the BSID (A) shown in FIG. 1E .
  • another possible embodiment of the method for sending an application message may include steps S901 to S903.
  • the first network device acquires an SR policy
  • the SR policy may come from the controller in the aforementioned step S801.
  • the SR policy can be understood with reference to the SR policy introduced in step S801.
  • the first network device receives the first packet
  • FIG. 9B shows another possible structure of the first packet.
  • the SID list field of the first packet does not include multiple sub-path information, which is beneficial to save the length of the first packet, and further helps to save network resources.
  • "NH” represents the next header type field
  • "HEL” represents the header length field
  • "RT” represents the route type field
  • "LE” represents the previous entry field
  • "F” represents the flag field.
  • the embodiment of the present application does not limit that the first message in the embodiment corresponding to FIG. 8 must have the structure shown in FIG. 9B.
  • FIG. 9B only shows the DA field of the Ipv6 header in the message. Other fields in the Ipv6 header are not shown.
  • the SL field indicates the next SRv6SID of the active SRv6SID in the SR list field, and the value of the SL field is 0, and the first packet may not include the BSID , which is beneficial to save the length of message 2.
  • the SID list and BSID can be understood with reference to related content in step S801.
  • the first network device obtains the SID list according to the BSID and the SR policy in the first packet, and forwards multiple second packets to the second network device through multiple subpaths respectively.
  • the first network device After the first network device parses the BSID from the first message, it can match the SR policy corresponding to the BSID, and then obtain the SR list bound to the BSID under the instruction of the SR policy, and pass through multiple sub-paths according to the SR list Forward multiple second packets to the second network device.
  • the second network device can be understood with reference to the node F shown in FIG. 1A .
  • the multiple second packets forwarded by the first network device to the second network device through multiple sub-paths according to the SR list can refer to the packet 2 and the packet 2' shown in FIG. 5A or FIG. 5B. understand.
  • the second message is obtained by duplicating the first message, and the second message includes payload data of the first message.
  • the method for sending a message in the embodiment of the present application is introduced above, and the structure of the network device of the present application is introduced below.
  • the network device may be node PE1 or node A or node F in FIG. 1A or FIG. 2 or FIG. 5A or FIG. 5B or FIG. 5C, or the controller in step S701, or the network entrance device in the method of the corresponding embodiment in FIG. 7A , or Fig. 7B corresponds to the first network device in the embodiment method, or Fig. 7C corresponds to the second network device in the embodiment method, or is the controller in step S801, or Fig. 9A corresponds to the first network device in the embodiment method Internet equipment.
  • the network device may be installed in a corresponding device, for example, the network device may be a chip system. In the embodiment of the present application, the system-on-a-chip may be composed of chips, or may include chips and other discrete devices.
  • FIG. 10 is a schematic structural diagram of a network device according to an embodiment of the present application.
  • the network device 10 includes a processor 1001 and a memory 1002 .
  • the processor 1001 may be one or more CPUs, and the CPUs may be single-core CPUs or multi-core CPUs.
  • Memory 1002 includes, but is not limited to, random access memory (random access memory, RAM), read-only memory (Read only Memory, ROM), erasable programmable read-only memory (erasable programmable read-only memory, EPROM or flash memory), flash memory, or optical memory, etc.
  • RAM random access memory
  • ROM read-only memory
  • EPROM erasable programmable read-only memory
  • flash memory or optical memory, etc.
  • the code of the operating system and program instructions are stored in the memory 1002 .
  • the network device 10 further includes a communication interface 1003 .
  • the communication interface 1003 may be a wired interface, such as a Fiber Distributed Data Interface (Fiber Distributed Data Interface, FDDI), Gigabit Ethernet (Gigabit Ethernet, GE) interface; the communication interface 1003 may also be a wireless interface.
  • the communication interface 1003 is used to receive routing information sent from BGP neighbors.
  • the network device 10 further includes a bus 1004, and the processor 1001 and the memory 1002 are usually connected to each other through the bus 1004, and may also be connected to each other in other ways.
  • the processor 1001 implements the method for sending a message in the embodiment of the present application by reading the program instructions stored in the memory 1002, or, the processor 1001 may also implement the method of sending a message in the embodiment of the present application through an internally stored program instruction. method.
  • the processor 1001 executes the steps performed by the controller or node PE1 or node A or node F in the method of the embodiment shown in FIG. 2 according to the instructions stored in the memory 1002, or executes step S701, or executes the corresponding embodiment in FIG. 7A
  • the steps executed by the network entry device in the method or execute the steps executed by the first network device in the embodiment corresponding to FIG. 7B , or execute the steps executed by the second network device in the embodiment corresponding to FIG.
  • step S801 or Execute the steps performed by the first network device in the embodiment corresponding to FIG. 9A .
  • the processor 1001 implements the above steps, please refer to the descriptions in the methods of the foregoing embodiments, and will not be repeated here.
  • FIG. 11 is a schematic structural diagram of a network device according to an embodiment of the present application.
  • the network device 11 includes a receiving module 1101 and a sending module 1102 .
  • the receiving module 1101 is used to perform step S204 or S207 or S208 or S701B or S701C or S901 or S902
  • the sending module 1102 is used to perform step S205 or S206 or S207 or S208 or S702B or S702C or S209 or S210 or S211 or S705 or S903.
  • the specific execution process please refer to the detailed description of the corresponding steps in the foregoing method embodiments, and details are not repeated here.
  • FIG. 12 is a schematic structural diagram of a network device according to an embodiment of the present application.
  • the network device 12 includes an encapsulation module 1201 and a sending module 1202 .
  • the encapsulation module 1201 is configured to execute step S203 or S701A
  • the sending module 1202 is configured to execute step S204 or S702A.
  • the specific execution process please refer to the detailed description of the corresponding steps in the foregoing method embodiments, and details are not repeated here.
  • FIG. 13 is a schematic structural diagram of a network device according to an embodiment of the present application.
  • the network device 13 includes a sending module 1301 .
  • the sending module 1301 is configured to execute step S201 shown in FIG. 2 or S701 or S801 described above.
  • step S201 shown in FIG. 2 or S701 or S801 described above.
  • the coupling in the embodiments of the present application is an indirect coupling or a communication connection between devices, units or modules, which may be in electrical, mechanical or other forms, and is used for information exchange between devices, units or modules.
  • the apparatus embodiments depicted in Figures 11 to 13 are merely illustrative.
  • the modules in Fig. 11 to Fig. 13 can be implemented in the form of hardware or in the form of software functional units.
  • the sending module 1102 in the network device shown in FIG. 11 can be one or more generated after the processor 1001 reads the program instructions stored in the memory 1002 realized by software function modules.
  • the division of modules in this embodiment of the present application is schematic, and is only a logical function division, and there may be other division methods in actual implementation.
  • the modules in Figure 11 to Figure 13 can also be realized by different hardware in the network equipment, for example, taking the network equipment 11 shown in Figure 11 as an example, the receiving module 1101 is realized by the communication interface 1003 in Figure 10, and the sending module 1102 is realized by The processors 1001 in FIG. 10 are implemented together.
  • the above functional modules can also be realized by a combination of software and hardware, for example, the receiving module 1101 is realized by the communication interface 1003 .
  • the embodiment of the present application also provides a chip 14, the chip 14 includes a processor 1401 and a communication interface 1402, the communication interface 1402 is coupled to the processor 1401, and the processor 1401 is used to run computer programs or instructions, thereby realizing the present invention. Apply the method provided by any one of the above method embodiments.
  • the communication interface 1402 may be, for example, an input/output interface, a pin or a circuit on the chip 14 .
  • the processor 1401 can execute computer instructions stored in the memory, so that the chip 14 executes any one of the above method embodiments.
  • the memory can be a storage unit in the chip 14, such as a register, a cache, etc., or, the memory can be a memory outside the chip 14 in a computer device, such as a read-only memory (read-only memory). , ROM) or other types of static storage devices that can store static information and instructions, random access memory (random access memory, RAM), etc.
  • the processor 1401 can be a general-purpose central processing unit (CPU), a microprocessor, an application-specific integrated circuit (application-specific integrated circuit, ASIC), or one or more An integrated circuit for program execution of an embodiment.
  • the computer program product includes one or more computer instructions.
  • the computer can be a general purpose computer, a special purpose computer, a computer network, or other programmable devices.
  • the computer instructions may be stored in or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions may be transmitted from a website, computer, server, or data center Transmission to another website site, computer, server, or data center by wired (eg, coaxial cable, fiber optic, digital subscriber line (DSL)) or wireless (eg, infrared, wireless, microwave, etc.).
  • wired eg, coaxial cable, fiber optic, digital subscriber line (DSL)
  • wireless eg, infrared, wireless, microwave, etc.
  • the computer-readable storage medium may be any available medium that can be stored by a computer, or a data storage device such as a server or a data center integrated with one or more available media.
  • the available medium may be a magnetic medium (such as a floppy disk, a hard disk, or a magnetic tape), an optical medium (such as a DVD), or a semiconductor medium (such as a solid state disk (solid state disk, SSD)), etc.
  • the embodiment of the present application also provides a network system (or communication system).
  • the network system may include at least two network devices in the embodiment corresponding to FIG. The steps performed by the corresponding network equipment in the example method.
  • the network system may include the controller in step S701 and/or the network entry device in the embodiment corresponding to FIG. 7A and/or the first network device in the embodiment corresponding to FIG. 7B and/or the first network device in the embodiment corresponding to FIG. 7C Second network device.
  • the network system may include the controller in step S801 and the first network device in the embodiment corresponding to FIG. 9A .
  • At least one refers to one or more, and multiple refers to two or more, which are not limited in the present application.
  • "/" can indicate that the objects associated before and after are in an "or" relationship, for example, A/B can indicate A or B; “and/or” can be used to describe that there are three types of associated objects A relationship, for example, A and/or B, may mean: A exists alone, A and B exist simultaneously, and B exists independently, where A and B may be singular or plural.
  • words such as “first” and “second” may be used to distinguish technical features with the same or similar functions.
  • words “first” and “second” do not limit the number and execution order, and the words “first” and “second” do not necessarily mean that they must be different.
  • words such as “exemplary” or “for example” are used to represent examples, illustrations or illustrations, and any embodiment or design described as “exemplary” or “for example” should not be interpreted It is more preferred or more advantageous than other embodiments or design solutions.
  • the use of words such as “exemplary” or “for example” is intended to present related concepts in a specific manner for easy understanding.
  • a computer program product refers to computer readable instructions stored on a computer readable medium.
  • the computer readable medium may be a computer readable signal medium or a computer readable storage medium.
  • Computer readable storage media include, but are not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or devices, or any suitable combination of the foregoing.
  • the computer readable storage medium is random access memory (Random Access Memory, RAM), read only memory (read only memory, ROM), erasable programmable read only memory (Erasable Programmable Read Only Memory, EPROM) or portable only memory Read memory (Compact Disc Read-Only Memory, CD-ROM).

Landscapes

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

Abstract

本申请实施例公开了一种发送报文的方法、发送报文的控制方法及装置,可以用于SR网络,用于实现高效率的冗余保护。该方法可以包括:第一网络设备接收到第一报文后,根据第一报文中的第一指示信息,从第一报文中获得多个子路径对应的多个子路径信息,并且基于对第一报文进行复制生成多个第二报文,根据多个子路径信息分别通过多个子路径向第二网络设备转发多个第二报文,有利于实现第一报文在第一网络设备和第二网络设备之间的冗余保护,提高报文传输的可靠性,并且提高第一网络设备对第一报文的转发效率。

Description

发送报文的方法、发送报文的控制方法及装置
本申请要求于2021年8月30日提交中国国家知识产权局、申请号为202111007552.1、发明名称为“发送报文的方法、发送报文的控制方法及装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及网络技术领域,尤其涉及一种发送报文的方法、发送报文的控制方法及装置。
背景技术
冗余保护是一种通用的保护机制,用于实现网络中节点到节点(point-to-point)业务传输的高可靠性。为了便于描述,将冗余保护涉及的两个节点分别称作冗余节点和合并节点。具体的,冗余节点将报文复制为多个报文,之后分别通过多个不同路径向合并节点转发多个报文。合并节点接收到多个报文后,可以继续转发其中的一个报文,并丢弃其他报文。这样,即使冗余节点和合并节点之间的一个路径出现故障,合并节点可以接收到通过其他路径转发的报文,从而有利于提高冗余节点至合并节点的业务传输的可靠性。
为了在段路由(segment routing,SR)网络中支持冗余保护,在冗余节点处需要将接收到的报文匹配至具体的SR策略,通过该SR策略获取多个不同路径对应的路径信息,进而分别将复制的多个报文通过多个不同路径向合并节点转发。
冗余节点接收到报文后,需要匹配SR策略后才能实现报文在冗余节点和合并节点间的冗余保护,不利于提高冗余节点对报文的转发效率。
发明内容
本申请实施例提供一种发送报文的方法、发送报文的控制方法及装置,有利于提高冗余节点对报文的发送效率。
第一方面,本申请实施例提供一种发送报文的方法,该方法可以例如应用于SR网络。本申请实施例方法包括:第一网络设备接收第一报文,所述第一报文包括多个子路径信息和第一指示信息,所述多个子路径信息分别对应于所述第一网络设备和第二网络设备之间的多个子路径,并且所述多个子路径中的每个子路径以所述第一网络设备为起点,所述多个子路径中的每个子路径以所述第二网络设备为终点;基于所述第一报文包括第一指示信息,所述第一网络设备根据所述第一报文中的所述多个子路径信息分别通过所述多个子路径向所述第二网络设备转发多个第二报文,所述第二报文为对所述第一报文进行复制得到的,所述第二报文包括所述第一报文的净荷数据。
第一网络设备接收到第一报文后,若第一网络设备从第一报文中解析到第一指示信息,第一网络设备可以从第一报文中获得多个子路径对应的多个子路径信息,并且基于对第一报文进行复制生成多个第二报文,第二报文包括第一报文中的净荷数据,之后根据多个子路径信息分别通过多个子路径向第二网络设备转发多个第二报文,有利于实现第一报文在第一网络设备和第二网络设备之间的冗余保护,提高报文传输的可靠性,并且提高第一网络设备对 第一报文的转发效率。
在一种可能的实现方式中,所述第二报文包括第二指示信息,所述第二指示信息指示所述第二网络设备转发接收到的目标报文,所述目标报文包括在所述多个第二报文中,并且丢弃接收到的所述多个第二报文中除所述目标第二报文以外的其他报文。
在第二报文中封装与合并节点功能对应的第二指示信息,便于第二网络设备识别该第二指示信息,执行合并节点的操作,即删除冗余报文的功能,提高操作效率。
在一种可能的实现方式中,所述第一报文为段路由报文,所述多个子路径信息携带在所述第一报文的段标识列表字段中。
在段路由报文的段标识列表字段中携带多个子路径信息,有利于在SR网络中使用上述报文发送方法,提高报文转发的可靠性和效率,并且节省报文头部的开销。
在一种可能的实现方式中,所述第一报文为段路由报文,所述多个子路径信息携带在所述第一报文的段路由头SRH的可选类型长度值字段中,有利于在SR网络中使用上述报文发送方法,提高报文转发的可靠性和效率,并且节省SRH中段标识列表的开销。
在一种可能的实现方式中,所述第一报文中的所述多个子路径信息为一个有序列表,所述有序列表包括依次排列的第1子路径信息、……、第i子路径信息、……、和第n子路径信息,n为所述多个子路径中子路径的数目,i为小于或等于n的任意一个正整数,所述第i子路径信息对应于所述多个子路径中的第i子路径,所述第i子路径信息包括所述第i子路径对应的段标识列表。
通过有序列表的形式携带多个子路径信息,有利于提高第一网络设备识别出各个子路径信息的准确性,提高报文转发的可靠性和效率。
在一种可能的实现方式中,所述多个第二报文为段路由报文,所述多个子路径信息携带在所述第二报文的段标识列表字段中,所述多个第二报文均包括段剩余字段,所述多个第二报文中的每个第二报文的段剩余字段的取值不同,以使得所述多个第二报文中的每个第二报文的段剩余字段的取值分别指向所述多个子路径信息中的每个子路径信息。
在第二报文的段标识列表字段中携带多个子路径信息,有利于在第二报文中更多的保留第一报文中的信息,进而有利于在网络出口设备做路径回溯,即从网络出口设备接收到的报文中确定多个子路径信息,进而确定报文所经过的冗余路径。
在一种可能的实现方式中,所述多个第二报文为段路由报文,所述多个第二报文中的每个第二报文分别包括所述多个子路径信息中的每个子路径信息,所述每个子路径信息携带在所述每个第二报文的段标识列表字段中。
对于多个子路径信息,每个第二报文仅包括相应子路径的子路径信息,有利于节约报文开销,进而节约网络资源。
在一种可能的实现方式中,所述第一指示信息携带在所述第一网络设备的第一段标识SID中,所述第一SID携带在所述第一报文的段标识列表字段中。
在一种可能的实现方式中,所述第一SID为SRv6SID,所述第一指示信息包括在所述第一SID的FUNCT字段和/或ARG字段中。
第一SID不仅可以标识网络设备的网段,还可以充当第一指示信息,有利于减小报文开销。
第二方面,本申请实施例提供一种发送报文的方法,该方法包括:网络入口设备在数据报文中封装多个子路径信息,以获得第一报文,所述多个子路径信息分别对应于第一网络设备和第二网络设备之间的多个子路径,并且所述多个子路径中的每个子路径以所述第一网络设备为起点,所述多个子路径中的每个子路径以所述第二网络设备为终点;所述网络入口设备向所述第一网络设备发送所述第一报文,所述第一报文还包括第一指示信息,所述第一指示信息指示所述第一网络设备根据所述第一报文中的所述多个子路径信息分别通过所述多个子路径向所述第二网络设备转发多个第二报文,所述第二报文为对所述第一报文进行复制得到的,所述第二报文包括所述第一报文的净荷数据。
网络入口设备可以在数据报文中封装多个子路径信息,以获得并向第一网络设备发送第一报文,以使得第一网络设备从第一报文中获得多个子路径对应的多个子路径信息,并且基于对第一报文进行复制生成多个第二报文,第二报文包括第一报文中的净荷数据,之后根据多个子路径信息分别通过多个子路径向第二网络设备转发多个第二报文,有利于实现第一报文在第一网络设备和第二网络设备之间的冗余保护,提高报文传输的可靠性,并且提高第一网络设备对第一报文的转发效率。
在一种可能的实现方式中,所述第一报文为段路由报文,所述多个子路径信息携带在所述第一报文的段标识列表字段中。
在段路由报文的段标识列表字段中携带多个子路径信息,有利于在SR网络中使用上述报文发送方法,提高报文转发的可靠性和效率,并且节省报文头部的开销。
在一种可能的实现方式中,所述第一报文为段路由报文,所述多个子路径信息携带在所述第一报文的段路由头SRH的可选类型长度值字段中。有利于在SR网络中使用上述报文发送方法,提高报文转发的可靠性和效率,并且节省SRH中段标识列表的开销。
在一种可能的实现方式中,所述网络入口设备在数据报文中封装多个子路径信息包括:所述网络入口设备根据段路由策略在数据报文中封装段标识列表,所述段路由策略的候选路径信息包括所述段标识列表,所述段标识列表包括所述多个子路径信息。
网络入口设备可以通过匹配一个段路由策略便可以在数据报文中压入多个子路径信息,有利于提高数据报文在多个子路径中的传输效率。
第三方面,本申请实施例提供了一种发送报文的控制方法,包括:控制器向网络入口设备发送段路由策略,所述段路由策略的候选路径信息包括段标识列表,所述段标识列表包括多个子路径信息,所述多个子路径信息分别对应于所述第一网络设备和第二网络设备之间的多个子路径,并且所述多个子路径中的每个子路径以所述第一网络设备为起点,所述多个子路径中的每个子路径以所述第二网络设备为终点,所述段路由策略用于指示所述网络入口设备在数据报文中封装所述段标识列表以获得向所述第一网络设备发送的第一报文,以使得所述第一网络设备根据所述第一报文中的所述多个子路径信息分别通过所述多个子路径向所述第二网络设备转发多个第二报文,所述第二报文为基于对所述第一报文进行复制得到的,所述第二报文包括所述第一报文的净荷数据。
控制器在向网络入口设备发送的段路由策略中,通过一个段标识列表携带多个子路径信息,有利于使得网络入口设备通过匹配一个段路由策略便可以在数据报文中压入多个子路径信息,有利于提高数据报文在多个子路径中的传输效率。
第四方面,本申请实施例提供了一种发送报文的方法,包括:第二网络设备接收多个第二报文,所述多个第二报文均包括多个子路径信息及段剩余字段;所述多个子路径信息为一个有序列表,所述有序列表从前至后依次包括第1子路径信息、……、第i子路径信息、……、和第n子路径信息,n为第一网络设备和所述第二网络设备之间的多个子路径中的路径数目,所述多个子路径中的每个子路径以所述第一网络设备为起点,所述多个子路径中的每个子路径以所述第二网络设备为终点,i为小于或等于n的任意一个正整数,所述第i子路径信息对应于所述多个子路径中的第i路径,所述第i子路径信息包括所述第i子路径对应的段标识列表;所述多个第二报文中的每个第二报文的段剩余字段的取值不同,以使得所述多个第二报文中的每个第二报文的段剩余字段的取值分别指向所述多个子路径信息中的每个子路径信息;所述第二网络设备转发所述多个第二报文中的目标第二报文,并且丢弃所述多个第二报文中除所述目标第二报文外的其他报文。
第二网络设备执行合并节点的操作,即删除冗余报文,有利于提高报文传输的可靠性。在第二报文的段标识列表字段中携带多个子路径信息,有利于在第二报文中更多的保留第一报文中的信息,进而有利于在网络出口设备做路径回溯,即从网络出口设备接收到的报文中确定多个子路径信息,进而确定报文所经过的冗余路径。
在一种可能的实现方式中,所述第二网络设备转发所述多个第二报文中的目标第二报文,包括:所述第二网络设备修改所述目标第二报文中的段剩余字段的值,以使得所述目标第二报文中的段剩余字段的值对应所述目标第二报文的段标识列表中的目标SID,所述目标SID对应所述目标第二报文转发路径中的下一跳网络设备或链路,有利于保证目标第二报文继续按照转发路径传输,有利于提高报文传输的可靠性。
第五方面,本申请实施例提供一种发送报文的方法,包括:第一网络设备获取段路由策略,所述段路由策略包括段标识列表和对应于所述段标识列表的绑定段标识BSID,所述段标识列表包括多个子路径信息,所述多个子路径信息分别对应于所述第一网络设备和第二网络设备之间的多个子路径,并且所述多个子路径中的每个子路径分别以所述第一网络设备和所述第二网络设备为起点和终点;所述第一网络设备接收第一报文,所述第一报文的目的地址字段包括所述BSID;所述第一网络设备根据所述BSID和所述SR策略获得所述段标识列表,分别通过所述多个子路径向所述第二网络设备转发多个第二报文,所述第二报文为对所述第一报文进行复制得到的,所述第二报文包括所述第一报文的净荷数据。
本申请实施例中,第一网络设备通过将包含多个子路径信息的段标识列表与BSID进行绑定,这样第一报文只需携带BSID,上述多个子路径信息均携带在段路由策略的同一个段标识列表中,即段路由策略通过一个段标识列表携带多个子路径对应的子路径信息。第一网络设备接收到携带BSID的第一报文后,通过BSID找到该段标识列表,以获取多个子路径信息。由于现有段路由策略协议中,若BSID绑定的候选路径对应于多个段标识列表,那么引导至该候选路径的流量将在多个段标识列表对应的多条路径之间进行负载均衡。因此通过在段路由策略的多个段标识列表中携带多个子路径信息以实现冗余保护,需要对现有段路由策略协议进行扩展。而通过本申请实施例无需对现有段路由策略协议进行扩展,便可以对第一报文在多个子路径信息对应的多个子路径之间进行冗余保护。
第六方面,本申请实施例提供一种发送报文的控制方法,包括:控制器向第一网络设备 发送段路由策略,所述段路由策略包括段标识列表和对应于所述段标识列表的绑定段标识BSID,所述段标识列表包括多个子路径信息,所述多个子路径信息分别对应于所述第一网络设备和第二网络设备之间的多个子路径,并且所述多个子路径中的每个子路径以所述第一网络设备为起点,所述多个子路径中的每个子路径以所述第二网络设备为终点,所述SR策略用于指示所述第一网络设备在接收到目的地址字段包括所述BSID的第一报文后,根据所述BSID和所述SR策略获得所述段标识列表,分别通过所述多个子路径向所述第二网络设备转发多个第二报文,所述第二报文为对所述第一报文进行复制得到的,所述第二报文包括所述第一报文的净荷数据。
本申请实施例中,控制器通过在向第一网络设备发送的SR策略中携带包括多个子路径信息的段标识列表和相应的BSID,有利于第一网络设备将第一报文中的BSID映射到多个子路径信息,从而有效减少第一报文长度。
第七方面,本申请实施例提供了一种网络设备。该网络设备可以是实体网络设备,也可以是实体网络设备中的装置,或者是能够与实体网络设备匹配使用的装置。或者,该网络设备可以是虚拟网络设备,例如虚拟交换机或虚拟路由器等。
第八方面,本申请实施例提供一种网络设备,该网络设备包括处理器和存储器,存储器用于存储指令,所述存储器与所述处理器耦合,所述处理器执行所述存储器中存储的指令时,可以实现上述第一方面或第二方面或第三方面或第四方面或第五方面或第六方面所描述的方法。所述通信装置还可以包括通信接口,所述通信接口用于该装置与其它设备进行通信,示例性的,通信接口可以是收发器、电路、总线、模块、管脚或其它类型的通信接口,其它设备可以为终端设备。
第九方面,本申请实施例提供提供了一种芯片系统,该芯片系统包括:处理器,还可以包括存储器,用于实现上述第一方面或第二方面或第三方面或第四方面或第五方面或第六方面所描述的方法。该芯片系统可以由芯片构成,也可以包含芯片和其他分立器件。
第十方面,本申请实施例提供一种计算机可读存储介质,该计算机可读存储介质中包括指令,当指令在计算机上运行时,使得计算机执行如本申请实施例上述第一方面或第二方面或第三方面或第四方面或第五方面或第六方面的任意一种可能的实现方式中的方法。
第十一方面,本申请实施例提供一种计算机程序产品,该计算机程序产品包括指令,当指令在计算机上运行时,使得计算机执行如本申请实施例上述第一方面或第二方面或第三方面或第四方面或第五方面或第六方面的任意一种可能的实现方式中的方法。
第十二方面,本申请实施例提供一种网络(或称通信系统),在一种可能的实现方式中,该网络可以包括用于执行第一方面所介绍的方法的第一网络设备,和/或用于执行第二方面所介绍的方法的网络入口设备,和/或用于执行第三方面所介绍的方法的控制器,和/或用于执行第四方面所介绍的方法的第二网络设备。或者,在一种可能的实现方式中,该网络可以包括用于执行第五方面所介绍的方法的第一网络设备和用于执行第六方面所介绍的方法的控制器。
由于本申请提供的各装置可用于执行前述对应的方法,因此本申请各装置所能获得到的技术效果可参考前述对应的方法所获得的技术效果,此处不再赘述。
附图说明
图1A示出了本申请实施例适用的一种可能的应用场景;
图1B和图1C示出了用于指示SR网络对流量进行负载均衡的SR策略一种可能的形式;
图1D和图1E示出了用于指示SR网络对报文进行冗余保护的SR策略一种可能的形式;
图2示出了本申请实施例方法一种可能的流程;
图3A示出了用于指示SR网络对报文进行冗余保护的SR策略另一种可能的形式;
图3B和图3C分别示出了图3A中SID列表R一种可能的形式;
图4A、图4B和图4C分别示出了图3A中SID列表R另一种可能的形式;
图5A、图5B和图5C分别示例性示出了本申请实施例提供的方法所涉及的报文的结构;
图6A和图6B分别示出了SID(A)一种可能的结构;
图7A、图7B和图7C分别示出了本申请实施例方法另一种可能的流程;
图8示出了用于指示SR网络对报文进行冗余保护的SR策略另一种可能的形式;
图9A示出了本申请实施例方法另一种可能的流程;
图9B示出了图9A对应的实施例中涉及的第一报文一种可能的结构;
图10至图13分别示出了本申请实施例提供的网络设备可能的结构示意图;
图14示出了本申请实施例提供的芯片的一种可能的结构示意图。
具体实施方式
本申请实施例提供一种发送报文的方法及基于该方法的网络设备,下面结合附图对本申请实施例进行描述。
图1A示出了本申请实施例一种可能的应用场景。在该应用场景中,如图1A中带有箭头的线段所示,节点CE1产生的流量可以通过节点PE1和节点PE2之间的转发路径转发至节点CE2。
如图1A中标识有“子路径1”的带有箭头的虚线段和标识有“子路径2”的带有箭头的虚线段所示,节点PE1和节点PE2之间的转发路径包括以节点A为起点、以节点F为终点的两个转发路径(分别称作子路径1和子路径2)。引导至子路径1的流量将依次通过节点A、节点B和节点D到达节点F,引导至子路径2的流量将依次通过节点A、节点C和节点E到达节点F。图1A仅示例性示出了节点A与节点A之间的两个转发路径,需要说明的是,节点A和节点F之间还可以存在其他转发路径,以下本申请实施例仅以图1A所示的子路径1和子路径2为例进行说明。
其中,节点CE1、节点CE2、节点PE1、节点A、节点B、节点C、节点D、节点E、节点F和节点PE2可以为相同或不同类型的网络设备。可选的,对于图1A所示的任意一个节点,其可以是路由器或交换机或软件定义网络(software defined network,SDN)的网络架构下的转发设备。作为举例,节点CE1和节点CE2可以为客户端路由器,节点PE1、节点A、节点B、节点C、节点D、节点E、节点F和节点PE2可以为运营商路由器。节点PE1、节点A、节点B、节点C、节点D、节点E、节点F和节点PE2对应于一个物理网络。本申请实施例对该物理网络的形式不作限定。可选的,该物理网络可以是段路由(segment routing,SR)网络。
SR是基于源路由理念而设计的在网络上转发数据包的一种协议。具体的,SR网络的网络 入口设备可以获取SR策略。SR策略描述将流量从SR策略的网络入口设备(或称头端)传送到网络出口设备(或称端点)的候选路径,具体的,SR策略可以包括候选路径的路径信息。
路径信息可以例如候选路径中各节点的段(segment)或段标识(segment identifier,SID)的有序列表,以下简称为SID列表。节点的SID可以代表节点所需执行的功能,SR网络中的节点接收到携带SID列表的报文后,可以根据SID列表中匹配本节点的SID所指示的功能对报文进行相应处理。
网络入口设备接收到匹配该SR策略的数据报文后,可以在数据报文中封装SR策略中活动候选路径的路径信息,以指示收到封装后的数据报文的网络设备通过该候选路径转发该数据报文。SR技术能够使网络更加简化,并具有良好的可扩展能力。
下面结合图1A所示的应用场景介绍SR网络根据SR策略转发数据报文的过程。
由于图1A所示的SR网络中的节点A和节点F之间存在至少两个转发路径,因此,可以通过分别向节点PE1和节点A下发SR策略来实现数据报文在SR网络中的转发。
图1B示出了下发到网络入口设备的SR策略一种可能的结构,该SR策略可以包括至少一个候选路径的路径信息。图1B示例性示出了其中的一个候选路径(称作候选路径B),该SR策略还可以包括其他候选路径。假设图1B所示的SR策略的网络入口设备为图1A所示的节点PE1,网络出口设备为图1A所示的节点PE2,并且,通过候选路径B转发的流量,由节点PE1转发到节点A,之后在子路径1和子路径2之间负载均衡的转发至节点F,之后转发到节点PE2。以下将图1B所示的SR策略称作SR策略<PE1,B,PE2>。
若节点PE1接收到的流量(例如来自节点CE1)匹配到SR策略<PE1,B,PE2>,那么节点PE1可以将候选路径B的路径信息封装到数据报文中,之后向节点A转发封装后的数据报文。作为举例,该候选路径的路径信息可以例如SID列表:<BSID(A)、SID(PE2)>。
以下用SID(i)代表节点i的SID,节点i可以为例如图1B所示的SR网络中的任意一个节点。
图1C示出了下发到节点A的SR策略,假设图1C所示的候选路径b分别以节点A和节点F为起点和终点,如图1A所示,候选路径b可以包括子路径1和子路径2。通过候选路径b转发的流量可以在子路径1和子路径2之间负载均衡的转发至节点F。以下将图1C所示的SR策略称作SR策略<A,b,F>。如图1C所示,该SR策略<A,b,F>的候选路径b关联于绑定SID(banding SID,BSID),例如图1C所示的BSID(A)。
该候选路径b的路径信息可以包括子路径1的路径信息和子路径2的路径信息。子路径1的路径信息和子路径2的路径信息分别携带在不同的SID列表中。例如,子路径1对应的SID列表为<SID(A)、SID(B)、SID(D)、SID(F)>,子路径2对应的SID列表为<SID(A)、SID(C)、SID(E)、SID(F)>。
节点A接收到封装<BSID(A)、SID(PE2)>的流量后,可以根据BSID(A)匹配到SR策略<A,b,F>,根据<SID(A)、SID(B)、SID(D)、SID(F)>和<SID(A)、SID(C)、SID(E)、SID(F)>引导流量在子路径1和子路径2之间负载均衡的转发到节点F,之后节点F根据流量中的SID(PE2)将流量继续转发至节点PE2,以实现SR网络根据SR策略<PE1,B,PE2>和SR策略<A,b,F>转发流量。
以上,通过SR策略<PE1,B,PE2>和SR策略<A,b,F>实现了SR网络将流量在子路径1和子路径2上进行负载均衡。下面,介绍SR网络如何根据SR策略在子路径1和子路径2上对报文进行冗余保护。
冗余保护是一种通用的保护机制,用于实现网络中节点到节点(point-to-point)业务传输的高可靠性。冗余节点用于将报文复制为多个报文,之后分别通过多个不同路径向合并节点转发多个报文。合并节点用于在接收到多个报文后,继续转发其中的一个报文,并丢弃其他报文。这样,即使冗余节点和合并节点之间的一个路径出现故障,合并节点可以接收到通过其他路径转发的报文,从而有利于提高冗余节点至合并节点的业务传输的可靠性。下面,继续结合图1A所示的应用场景,介绍SR网络如何根据SR策略在节点A(冗余节点)和节点F(合并节点)上对报文进行冗余保护。
方案一、对SR策略<A,b,F>进行扩展
在一种可能的技术方案中,节点PE1可以获取如图1D所示的SR策略,将该SR策略称作SR策略<PE1,R1,PE2>,SR策略<PE1,R1,PE2>包括候选路径R。参考图1A,候选路径R分别以节点PE1和节点PE2为起点和终点,并且,候选路径R中的节点A和节点F分别执行冗余节点和合并节点的功能。具体的,报文通过候选路径R转发的过程中,由节点PE1转发到节点A后,节点A将报文复制为两个报文,之后分别通过子路径1和子路径2向节点F转发这两个报文,节点F在接收到两个报文后,继续转发其中的一个报文,并丢弃另一个报文。与SR策略<PE1,B,PE2>类似的,候选路径R的路径信息可以例如为SID列表:<BSID(A)、SID(PE2)>,只是SR策略<PE1,B,PE2>和SR策略<PE1,R1,PE2>中的BSID(A)的具体内容可以不同。
若节点PE1为接收到的报文(例如来自节点CE1)匹配到SR策略<PE1,R,PE2>,那么节点PE1可以将候选路径R的路径信息封装到数据报文中,之后向节点A转发封装后的数据报文。
节点A可以获取如图1E所示的SR策略,将该SR策略称作SR策略<A,r1,F>,SR策略<A,r1,F>包括候选路径r。本申请实施例可以通过对图1C所示的SR策略<A,b,F>进行扩展得到SR策略<A,r1,F>。具体的,如图1E所示,本申请实施例可以将下发到节点A的SR策略<A,r1,F>额外关联冗余标识,冗余标识可以用于表示该SR策略用于实现冗余保护。与SR策略<PE1,B,PE2>类似的,候选路径r的路径信息可以包括子路径1对应的SID列表和子路径2对应的SID列表。
节点A接收到节点PE1发送的封装<BSID(A)、SID(PE2)>的报文后,可以根据BSID(A)匹配到SR策略<A,r1,F>,执行冗余节点的功能,具体的,例如复制报文以获得两个报文,之后根据<SID(A)、SID(B)、SID(D)、SID(F)>通过子路径1向合并节点(即节点F)转发报文,根据<SID(A)、SID(C)、SID(E)、SID(F)>通过子路径2向合并节点(即节点F)转发报文。节点F接收到通过子路径1和子路径2到达的两个报文后,可以继续转发其中的一个报文,并丢弃另一个报文。这样,即使节点A和节点F之间的一个路径出现故障,节点F可以接收到通过其他路径转发的报文,从而有利于提高节点A至节点F的业务传输的可靠性,实现报文在节点A和节点F之间的冗余保护。
方案二、在下发到网络入口设备的SR策略中携带子路径1和子路径的路径信息
上述SR网络转发报文的过程至少涉及两次SR策略的匹配过程,除了在网络入口设备处需要匹配SR策略以外,如图1C或图1D对应的技术方案,还需要在节点F处匹配SR策略<A,b,F>或SR策略<A,r1,F>,不利于提高SR网络对报文的转发效率。方案二介绍的技术方案旨在减少SR网络在实现对报文的冗余保护的过程中所涉及的SR策略匹配次数,进而提高冗余节点对报文的转发效率。
结合图1A所示的应用场景,图2示出了本申请方法一种可能的流程。参考图2,本申请报文发送的方法一种可能的流程包括步骤S201至步骤S211。
S201、控制器向PE1发送SR策略<PE1,R2,PE2>;
可选的,图1A所示的应用场景还包括控制器,控制器可以向网络入口设备发送SR策略。参考图1A,假设该SR策略对应的网络入口设备为节点PE1,该SR策略<PE1,R2,PE2>对应的网络出口设备为节点PE2。以下将S201获取的SR策略称作SR策略<PE1,R2,PE2>。
示例性的,SR策略<PE1,R2,PE2>所描述的内容可以参考图3A进行理解。具体的,SR策略<PE1,R2,PE2>的候选路径包括候选路径R,候选路径R可以解释为上述方案一中的候选路径R,即节点PE1和节点PE2分别为候选路径R的起点和终点,并且,候选路径R中的节点A和节点F分别作为冗余节点和合并节点,以实现通过候选路径R转发的报文在节点A和节点F之间得到冗余保护。
可选的,该SR策略<PE1,R2,PE2>还可以包括除候选路径R以外的其他候选路径,例如,该SR策略<PE1,R2,PE2>还可以包括如图1B所示的候选路径B。
本申请实施例中,SR策略<PE1,R2,PE2>可以通过一个SID列表来描述候选路径R,为了便于描述,将该SID列表称作SID列表R。
图3B示出了SID列表R的一种可能的形式。图3B中,用SID(i)代表节点i的SID,节点i为候选路径R中任意一个节点。图3B所示的SID列表R中,SID(B)、SID(D)相当于子路径1对应的SID列表,SID(C)、SID(E)相当于子路径2对应的SID列表。为了便于区分,本申请实施例将子路径1和子路径2对应的SID列表分别称作SID列表r1列表r1和SID列表r2。
图3C示出了SID列表R的另一种可能的形式。图3C中,仍然用SID(i)代表节点i的SID,节点i为候选路径R中任意一个节点。图3C所示的SID列表R中,SID(B)、SID(D)和SID(F)相当于子路径1对应的SID列表,SID(C)、SID(E)和SID(F)相当于子路径2对应的SID列表。与前文类似的,将子路径1和子路径2对应的SID列表分别称作SID列表r1列表r1和SID列表r2。
图3B和图3C仅示例性示出SID列表R的可能形式,本申请实施例不限定SID列表R的具体形式。
可选的,图1A所示的SR网络可以为使用多协议标签交换(multi-protocol label switching,MPLS)的SR(SR over MPLS,SR-MPLS)网络。SID列表R中的SID(i)可以编码为MPLS标签(label)。MPLS标签可以包括标签值字段,标签值字段用于标识一个转发等价类(forwarding equivalence class,FEC)。可选的,以图4A所示的SID列表R为例,SR 策略<PE1,R2,PE2>中的SID列表R可以例如为图5A所示的标签栈。图5A中,用MPLS标签(节点i)代表节点i的MPLS标签,节点i仍为候选路径R中任意一个节点。
可选的,图1A所示的SR网络可以为使用因特网协议第6版(internet protocol version 6,Ipv6)数据面的段路由(SR using IPv6data plane,SRv6)网络。SID列表R中的SID(i)可以编码为Ipv6地址,本申请实施例将SRv6技术下的SID(i)称作SRv6SID(i)。在一种可能的实现方式中,SRv6SID(i)可以包括本地(locator,LOC)字段和功能(function,FUNC)字段,可选的,SRv6SID(i)还可以包括参数(argument,ARG)字段。其中,LOC字段可以是可以路由到节点i的网段地址,例如,LOC字段可以表示为“B字段:N字段”的形式,其中,“B字段”为运营商为SRv6SID(i)分配的Ipv6子网,“N字段”是实例化SID(i)父节点的标识符。FUNCT字段可以指示对应于SRv6SID(i)的某种功能。ARG字段可以用于FUNCT字段参数,例如定义报文流和服务等信息。SID列表R中节点的FUNCT字段将在后文进行介绍,此处暂不展开。
可选的,以图3B所示的SID列表R为例,SR策略<PE1,R2,PE2>中的SID列表R可以例如为图4B所示的SRv6SID有序列表。或者,可选的,以3C所示的SID列表R为例,SR策略<PE1,R2,PE2>中的SID列表R可以例如为图4C所示的SRv6SID有序列表。图4B和图4C中,用SRv6SID(i)代表节点i的SRv6SID,节点i仍为候选路径R中任意一个节点。
S202、节点CE1向节点PE1发送报文0;
可选的,图1A所示的应用场景还包括节点CE1和节点CE2。节点CE1和节点CE2可以为路由器或交换机或软件定义网络(software defined network,SDN)的网络架构下的转发设备。例如,节点CE1和节点CE2可以为客户端路由器。
节点CE1可以向节点PE1发送报文0,以将报文0中的净荷数据转发至节点CE2。
S203、节点PE1在报文0中封装SID列表R,以获得报文1;
步骤S201和步骤S202之后,节点PE1可以分别接收到SR策略<PE1,R2,PE2>和报文0。假设报文0匹配该SR策略<PE1,R2,PE2>,并且候选路径R为SR策略<PE1,R2,PE2>的活动候选路径,节点PE1可以在报文0中封装SID列表R,以获得报文1。报文1中的净荷数据(payload)与报文0中的净荷数据相同。
报文1可以为SR报文。可选的,报文1可以为SR-MPLS报文或SRv6报文。下面分别介绍这两种类型的报文1可能的结构。
图5A示出了报文1一种可能的结构。参考图5A,可选的,SID列表R可以携带在报文1的标签栈中。参考图5A,节点PE1可以将图4A所示的SID列表R压入报文0,得到例如图5A所示的报文1。参考图5A,待被执行的MPLS标签(例如MPLS标签(A))位于标签栈顶部。本申请实施例中,可以将标签栈顶部的MPLS标签称作活动(active)MPLS标签。
图5B示出了报文1另一种可能的结构。参考图5B,可选的,SID列表R可以携带在报文1的SID列表字段中,SID列表字段位于报文1的SR头(SR Header,SRH)中。参考图5B,节点PE1可以将图4B所示的SID列表R逆序压入报文0,得到例如图5B所示的报文1。
图5C示出了报文1另一种可能的结构。参考图5C,可选的,SID列表R可以携带在报文1的SID列表字段中,SID列表字段位于报文1的SR头(SR Header,SRH)中。参考图5C,节点PE1可以将图4C所示的SID列表R逆序压入报文0,得到例如图5C所示的报文1。
图5B和图5C所示报文的SRH头中,“NH”代表下一个头部类型字段,“HEL”代表头部长度字段,“RT”代表路由类型字段,“LE”代表上一个入口字段,“F”代表标志位字段。
本申请实施例中,可以将待被执行的SRv6SID称作活动SRv6SID。参考图5B或图5C,报文1的SRH包括段剩余(SegmentLeft,SL)字段,SL字段指示SR列表字段中的活动SRv6SID。图5B和图5C中,“[]”中的数字代表相应SID在SR列表字段中的序号。由于SRv6SID(A)的序号为SR列表字段中序号最大的SRv6SID,因此SRv6SID(A)为SR列表字段中最先被执行的SRv6SID。相应的,在图5B中,SL的取值可以为SRv6SID(A)的序号(即6)。在图5C中,SL的取值可以为SRv6SID(A)的序号(即7)。活动SRv6SID还携带在报文1的Ipv6头的目的地址(Destination Address,DA)字段中,例如,报文1的DA字段包括SRv6SID(A)。
或者,可选的,SL字段指示SR列表字段中的活动SRv6SID的下一个SRv6SID,以图5B所示的报文1为例,SL字段的取值为5,并且,PE1可以将SRH中的SRv6SID(A)弹出,有利于节省报文1的长度。
假设报文1为SRv6报文,或者,可选的,SID列表R可以携带在报文1的可选类型长度值(TLV)字段(例如图-7B所示的可选TLV)中。
本申请实施例不限定报文1一定为图5A、图5B或图5C所示的结构,例如,和图5A、图5B或图5C所示的报文结构相比,报文1可以包括更多或更少的字段。以图5A所示的报文1为例,标签栈和净荷数据之间还可以封装有三层协议头,例如用户数据报协议(user datagram protocol,UDP)头。图5B或图5C仅示出报文中Ipv6头的DA字段,出于简化的目的,并未示出Ipv6头中的其他字段。
S204、节点PE1向节点A发送报文1;
节点PE1获得报文1之后,可以查找节点A的转发信息,根据节点A的转发信息向节点A发送报文1。参考步骤S203中的内容,作为举例,节点PE1向节点A发送的报文1可以参考图5A或图5B或图5C中报文1的结构。
本申请实施例不限定节点PE1与节点A直连,例如,节点PE1可以通过其他网络设备向节点A转发报文1,相应的,本申请实施例不限定节点PE1发送的报文1和节点A接收到的报文1相同。例如,节点PE1和节点A之间的转发路径上还存在至少一个中间网络设备,节点PE1发送报文1后,该中间网络设备可以对接收到的报文进行重新封装(例如弹出相应的MPLS标签或修改SRH中SL的取值),进而将重新封装的报文进行转发,以到达节点A。但是节点PE1发送的报文1和节点A接收到的报文1均包括前文介绍的SID列表R,并且包括相同的净荷数据等,SID列表R在报文1中的位置均可以参考图5A或图5B或图5C的形式。因此,为了便于描述,本申请实施例将步骤S204中节点PE1发送的报文和节点A接收到的报文统称为报文1。
S205、节点A对报文1进行复制,以获得报文1′;
S206、节点A根据报文1中的SID列表r1列表r1生成报文2,根据报文1′中的SID列表r2生成报文2′;
S207、节点A通过子路径1向节点F转发报文2;
S208、节点A通过子路径2向节点F转发报文2′;
步骤S204后,节点A可以接收报文1。节点A接收到报文1后,可以对报文1进行解析,进而执行步骤S205至S208。
下面分别以图5A或图5B或图5C所示的报文1介绍步骤S205至步骤S208。
一、以报文1为图-7A所示的MPLS报文为例。
节点A可以从报文1中解析得到MPLS标签(A)。图6A示出了MPLS标签(A)一种可能的结构。
假设MPLS标签(A)中的标签字段与第一功能对应,报文1可以在第一功能的指示下,对报文1进行复制,以获得两个报文1。报文1还可以在第一功能的指示下,从报文1中获取SID列表r1列表r1和SID列表r2。为了便于描述,后文将上述两个报文1中复制得到的报文1称作报文1′。之后,报文1还可以在第一功能的指示下,根据SID列表r1列表r1和报文1生成通过子路径1向节点F转发的报文2,根据SID列表r2和报文1′生成通过子路径2向节点F转发的报文2′。报文2和报文1的净荷数据相同,并且,报文2′和报文1的净荷数据相同。
节点A获取到报文2后,可以发送报文2。图5A示出了报文2一种可能的结构。参考图5A可知,报文2的标签栈携带SID列表r1列表r1,未携带SID列表r2,因此,节点A发送的报文2将通过子路径1到达节点F,即节点A通过子路径1向节点F转发报文2。
节点A获取到报文2后,可以发送报文2。图5B示出了报文2′一种可能的结构。参考图5B可知,报文2′的标签栈携带SID列表r2,未携带SID列表r1列表r1,因此,节点A发送的报文2′将通过子路径2到达节点F,即节点A通过子路径2向节点F转发报文2′。
参考图6A,可选的,可以对MPLS标签(A)进行扩展,在原MPLS标签(A)的尾部增加主SID列表(简称为Pri-SIDs)字段和备SID列表(简称为Back-SIDs)字段。其中,Pri-SIDs字段和Back-SIDs字段分别用于在报文1中确定SID列表r1列表r1和SID列表r2。可选的,Pri-SIDs字段和Back-SIDs字段分别指示SID列表r1列表r1中SID的数目(例如2)和SID列表r2中SID的数目(例如2)。当节点A确定MPLS标签(A)中的标签字段对应于第一功能时,节点A可以从MPLS标签(A)中分别获取Pri-SIDs字段和Back-SIDs字段,之后根据Pri-SIDs字段和Back-SIDs字段分别从报文1中获取SID列表r1列表r1和SID列表r2,进而执行步骤S206。图6A示出了在节点A和节点F之间包括两个子路径的情况下MPLS标签(A)的可能结构。若节点A和节点F之间包括更多子路径,MPLS标签(A)可以在图6A的基础上进一步扩展相应子路径的描述字段。例如,节点A和节点F之间还包括子路径3,那么图6A所示的MPLS标签(A)的尾部还可以增加备SID列表字段,该备SID列表字段指示子路径3的SID列表(13)中SID的数目。可选的,为了便于节点A准确获取MPLS标签(A)中各子路径的描述字段,MPLS标签(A)还可以包括子路径数目的描述字段,以描述节点A和节点F之间子路径的数目。例如,节点(A)在确定MPLS标签(A)中的标签字段匹配第一功能(即冗余节点的功能)后,可以从MPLS标签(A)的TTL字段后解析子路径数目的描述字段,根据该描述字段的取值所指示的子路径的数目(假设为3),继续解析3个子路径的描述字段,以确定各个子路径的SID列表中SID的数目,从而有利于准确的从报文1中获取各SID列表。
二、以报文1为图5B所示的SRv6报文为例。
节点A可以从报文1的IPv6头中解析得到DA字段携带的SRv6SID(A)。图6B示出了SRv6SID(A)一种可能的结构。
基于节点A从报文1中解析得到的SRv6SID(A)与节点A匹配,例如,SRv6SID(A)的LOC字段为节点A的网段地址,节点A可以根据SRv6SID(A)的FUNCT字段的指示对报文1进行处理。假设FUNCT字段指示第一功能(对应于冗余节点的功能),节点A可以在第一功能的指示下执行步骤S205至S208,具体可以参考前文介绍的节点A在标签所对应的第一功能的指示下执行步骤S205至S208的相关内容,此处不再赘述。
图5B示出了报文2另一种可能的结构。参考图5B可知,报文2的SID列表字段携带SID列表R1,未携带SID列表r2,因此,节点A发送的报文2将通过子路径1到达节点F,即节点A通过子路径1向节点F转发报文2。
图5B示出了报文2′另一种可能的结构。参考图5B可知,报文2′的SID列表字段携带SID列表r2,未携带SID列表r1,因此,节点A发送的报文2′将通过子路径2到达节点F,即节点A通过子路径2向节点F转发报文2′。
参考图6B,可选的,ARG字段可以包括主SID列表(简称为Pri-SIDs)字段和备SID列表(简称为Back-SIDs)字段。其中,Pri-SIDs字段和Back-SIDs字段分别用于在报文1中确定SID列表r1和SID列表r2。可选的,Pri-SIDs字段和Back-SIDs字段分别指示SID列表r1中SID的数目(例如2)和SID列表r2中SID的数目(例如2)。
当节点A确定SRv6SID(A)的FUNCT字段指示第一功能时,节点A可以从SRv6SID(A)中分别获取Pri-SIDs字段和Back-SIDs字段,之后根据Pri-SIDs字段和Back-SIDs字段分别从报文1中获取SID列表r1和SID列表r2,进而执行步骤S206至步骤S208。
图6B示出了在节点A和节点F之间包括两个子路径的情况下SRv6SID(A)的可能结构。若节点A和节点F之间包括更多子路径,SRv6SID(A)可以在图6B的基础上进一步扩展相应子路径的描述字段。例如,节点A和节点F之间还包括子路径3,那么图6B所示的SRv6SID(A)的ARG字段还可以新增一个备SID列表字段,该备SID列表字段指示子路径3的SID列表(13)中SID的数目。可选的,为了便于节点A准确获取SRv6SID(A)中各子路径的描述字段,SRv6SID(A)还可以包括子路径数目的描述字段,以描述节点A和节点F之间子路径的数目。例如,节点(A)在确定SRv6SID(A)中的FUNCT字段指示第一功能(即冗余节点的功能)后,可以从SRv6SID(A)的TTL字段后解析子路径数目的描述字段,根据该描述字段的取值所指示的子路径的数目(假设为3),继续解析3个子路径的描述字段,以确定各个子路径的SID列表中SID的数目,从而有利于准确的从报文1中获取各SID列表。
可选的,和图5B所示的报文2和报文2′不同的,SL字段指示SR列表字段中的活动SRv6SID的下一个SRv6SID,以图5B所示的报文2为例,SL字段的取值为2,并且,报文2可以不包括SRv6SID(A)和SRv6SID(B),有利于节省报文2的长度。
三、以报文1为图5C所示的SRv6报文为例。
节点A可以从报文1的IPv6头中解析得到DA字段携带的SRv6SID(A)。SRv6SID(A)一种可能的结构可以继续参考图6B所示。
基于节点A从报文1中解析得到的SRv6SID(A)与节点A匹配,例如,SRv6SID(A)的LOC字段为节点A的网段地址,节点A可以根据SRv6SID(A)的FUNCT字段的指示对报 文1进行处理。假设FUNCT字段指示第一功能,节点A可以在第一功能的指示下执行步骤S205至S208,具体可以参考前文介绍的节点A在标签所对应的第一功能的指示下执行步骤S205至S208的相关内容,此处不再赘述。
图5C示出了报文2另一种可能的结构。参考图5C可知,报文2的SRH中的SL字段指向SRv6SID(B),因此,节点A发送的报文2将通过子路径1到达节点F,即节点A通过子路径1向节点F转发报文2。
图5C示出了报文2′另一种可能的结构。参考图5C可知,报文2的SRH中的SL字段指向SRv6SID(C),因此,节点A发送的报文2′将通过子路径2到达节点F,即节点A通过子路径2向节点F转发报文2′。参考图6B,可选的,ARG字段可以包括主SID列表(简称为Pri-SIDs)字段和备SID列表(简称为Back-SIDs)字段。其中,Pri-SIDs字段和Back-SIDs字段分别用于在报文1中确定SID列表r1列表r1和SID列表r2。可选的,Pri-SIDs字段和Back-SIDs字段分别指示SID列表r1中SID的数目(例如2)和SID列表r2中SID的数目(例如2)。
当节点A确定SRv6SID(A)的FUNCT字段指示第一功能时,节点A可以从SRv6SID(A)中分别获取Pri-SIDs字段和Back-SIDs字段,之后根据Pri-SIDs字段和Back-SIDs字段分别从报文1中获取SID列表r1和SID列表r2,进而执行步骤S206至S208。
需要说明的是,本申请实施例不限定步骤S206至S208按照序号的先后顺序执行,例如,节点A在生成报文2后,便可以发送报文2,而无需等待生成报文报文2′后再发送报文2。
S209、节点F根据报文2生成报文3;
节点A发出的报文2依次经过节点B和节点D,之后到达节点F。
由于本申请实施例重点关注节点PE1、节点A和节点F对报文的处理过程,并且节点B和节点D根据报文2生成并转发的报文均携带相同的净荷数据,因此,为了简化描述,本申请实施例将节点B和节点D根据报文2生成并转发的报文称作报文2。
下面分别结合图5A、图5B和图5C介绍报文2依次经过节点B和节点D到达F的过程。
一、以图5A所示的报文2为例。
节点B接收到报文2之后可以将MPLS标签(B)弹出,之后继续向节点D转发报文2。节点D接收到报文2后,可以将MPLS标签(D)弹出,之后继续向节点F转发报文2。
节点F接收到报文2后,可以根据报文2生成报文3,例如,可以将报文2中的MPLS标签(F)弹出,以获得例如图5A所示的报文3。报文3和报文2的净荷数据相同。
二、以图5B所示的报文2为例。
节点B接收到报文2之后,可以根据SRv6SID(B)中FUNCT字段的指示,将报文2的SRH中SL字段的取值减一,SL字段指向下一个SRv6SID(D),并且,将指向的SRv6SID(D)复制到DA字段中,之后继续向节点D转发报文2。节点D接收到报文2后,可以根据SRv6SID(D)中FUNCT字段的指示,将报文2的SRH中SL字段的取值减一,SL字段指向下一个SRv6SID(F),并且,将指向的SRv6SID(F)复制到DA字段中,之后继续向节点F转发报文2。
作为举例,SRv6SID(B)和SRv6SID(D)中的FUNCT字段指示的功能可以为终点(Endpoint)功能。
节点F接收到报文2后,可以根据报文2生成报文3,例如,可以根据SRv6SID(F)中FUNCT字段的指示,将报文2的SRH中SL字段的取值减一,SL字段指向下一个SRv6SID(PE2),以获得例如图5B所示的报文3。报文3和报文2的净荷数据相同。
三、以图5C所示的报文2为例。
节点B接收到报文2之后,可以根据SRv6SID(B)中FUNCT字段的指示,将报文2的SRH中SL字段的取值减一,SL字段指向下一个SRv6SID(D),并且,将指向的SRv6SID(D)复制到DA字段中,之后继续向节点D转发报文2。节点D接收到报文2后,可以根据SRv6SID(D)中FUNCT字段的指示,将报文2的SRH中SL字段的取值减一,SL字段指向下一个SRv6SID(F),并且,将指向的SRv6SID(F)复制到DA字段中,之后继续向节点F转发报文2。
作为举例,SRv6SID(B)和SRv6SID(D)中的FUNCT字段指示的功能可以为终点(Endpoint)功能。
节点F接收到报文2后,可以根据SRv6SID(F)中FUNCT字段指示的功能(称作第二功能),根据报文2生成报文3。第二功能可以对应于合并节点的功能,并且,本申请实施例可以对第二功能进行扩展,例如,节点F不是将报文2的SRH中SL字段的取值减一,SL字段指向下一个SRv6SID(PE2),而是将SL字段的取值指向第二报文的下一跳网络设备(即节点PE2),以获得例如图5C所示的报文3。报文3和报文2的净荷数据相同。
S210、节点F向节点PE2转发报文3;
节点F根据报文2获得报文3之后,可以向节点PE2发送报文3。
S211、节点F丢弃报文2′。
节点A发出的报文2′依次经过节点C和节点E,之后到达节点F。
由于本申请实施例重点关注节点PE1、节点A和节点F对报文的处理过程,并且节点C和节点E根据报文2′生成并转发的报文均携带相同的净荷数据,因此,为了简化描述,本申请实施例将节点C和节点E根据报文2′生成并转发的报文称作报文2′。
图5A、图5B或图5C所示的报文2′依次经过节点C和节点E到达F的过程可以参考步骤S209中描述的相关内容进行理解,此处不再赘述。
节点F接收到报文2′后,可以根据SRv6SID(F)中FUNCT字段的指示处理报文2′。本申请实施例可以对SRv6SID(F)中FUNCT字段指示的功能进行扩展,例如,SRv6SID(F)中FUNCT字段指示的功能指示节点F丢弃除第一个到达该节点F外的报文。假设,报文2先于报文2′到达节点F,节点F可以根据SRv6SID(F)中FUNCT字段的指示丢弃报文2′。
节点PE1接收到匹配SR策略<PE1,R2,PE2>的报文0后,可以根据SR策略<PE1,R2,PE2>的指示将SID列表R封装到报文0中,得到报文1。节点A接收到报文1后,可以根据携带的SID列表r1和SID列表r2分别通过子路径1和子路径2向节点F转发携带报文1中净荷数据的报文2,而无需如方案一所介绍的再次匹配SR策略<A,r1,F>,因此有利于实现报文2在节点A和节点F之间的冗余保护,并且提高节点A分别通过子路径1和子路径2转发报文1的效率。
本申请适用的候选路径R可以包括更多或更少的网络设备,相应的,SID列表R可以包括更多或更少的SID。例如,节点PE1和节点A之间的转发路径上还存在至少一个中间网络 设备,SR策略<PE1,R2,PE2>中的SID列表R还可以包括相应中间网络设备的SID,节点PE1发送的报文1中还可以包括相应中间网络设备SID,节点PE1发送报文1后,该中间网络设备可以对接收到的报文进行重新封装(例如弹出相应的MPLS标签或修改SRH中SL的取值),进而将重新封装的报文进行转发。
和/或,本申请实施例适用的候选路径中,节点A和节点F之间可以包括更多的子路径,相应的,SR策略<PE1,R2,PE2>中的SID列表R可以包括更多子路径对应的SID列表,步骤S205中,节点A对报文1进行复制,以获得更多的报文2,可选的,获得的报文2的数目与候选子路径1中A和F之间子路径的数目相同。例如,候选路径R还包括以A为起点、以F为终点的子路径3,那么步骤S205中,节点A可以通过复制报文1,得到三个报文1(例如报文报文1、报文1′和报文1"),相应的,节点F将接收到更多报文2(例如报文报文2、报文2′和报文2")。
本申请报文发送的方法另一种可能的流程可以包括步骤S701。
S701、控制器向网络入口设备发送SR策略。
控制器可以生成SR策略,并向SR策略对应的网络入口设备发送SR策略。可选的,控制器可以为图1A所示的控制器,SR策略可以为图2对应的实施例中提到的SR策略<PE1,R2,PE2>,或者例如为图3A所示的SR策略<PE1,R2,PE2>。
SR策略的候选路径信息可以包括SID列表,可选的,该SID列表可以参考图3B或图3C或图4A或图4B或图4C对应的SID列表R进行理解。
SID列表可以包括多个子路径信息,多个子路径信息分别对应于第一网络设备和第二网络设备之间的多个子路径,并且多个子路径中的每个子路径以第一网络设备为起点,多个子路径中的每个子路径以第二网络设备为终点。可选的,多个子路径信息可以参考图3B或图3C或图4A或图4B或图4C对应的SID列表r1和SID列表r2进行理解。
可选的,第一网络设备和第二网络设备可以参考图1A和图2对应的节点A和节点F进行理解。可选的,多个子路径可以参考图1A或图2对应的子路径1和子路径2进行理解。
图7A示出了本申请实施例方法另一种可能的流程。参考图7A,本申请实施例方法可以包括步骤S701A至步骤S702A。
S701A、网络入口设备在数据报文中封装多个子路径信息,以获得第一报文;
网络入口设备可以接收控制器下发的SR策略,之后可以根据SR策略在数据报文中封装多个子路径信息,以获得第一报文。第二报文包括第一报文的净荷数据。该SR策略和多个子路径信息可以步骤S701中提到相应内容进行理解。本申请实施例不限定网络入口设备从控制器获取该SR策略,例如,网络入口设备可以本地生成SR策略。该控制器可以参考步骤S701所提到的控制器进行理解。
可选的,第一报文可以为SR报文。
在一种可能的实现方式中,多个子路径信息可以携带在第一报文的段路由头SRH的TLV字段中。
或者,可选的,参考图5A或图5B或图5C所示的报文1,多个子路径信息(例如SID列 表r1和SID列表r2)可以携带在第一报文的SID列表字段中。可选的,第一报文中的多个子路径信息为一个有序列表,有序列表包括依次排列的第1子路径信息、……、第i子路径信息、……、和第n子路径信息,n为多个子路径中子路径的数目,i为小于或等于n的任意一个正整数,第i子路径信息对应于多个子路径中的第i子路径,第i子路径信息包括第i子路径对应的SID列表。可选的,多个子路径可以参考图1A或图2对应的子路径1和子路径2进行理解。
S702A、网络入口设备向第一网络设备发送第一报文。
网络入口设备得到第一报文后,可以向第一网络设备发送第一报文。
可选的,网络入口设备可以参考图1A或图2对应的节点PE1进行理解,第一网络设备可以参考图1A或图2对应的节点A进行理解。
图7B示出了本申请实施例方法另一种可能的流程。参考图7B,本申请实施例方法可以包括步骤S701B和步骤S702B。
S701B、第一网络设备接收第一报文;
可选的,第一报文可以来自例如图7A对应的实施例中的网络入口设备。
第一报文可以包括多个子路径信息和第一指示信息。多个子路径信息分别对应于第一网络设备和第二网络设备之间的多个子路径,并且多个子路径中的每个子路径以第一网络设备为起点,多个子路径中的每个子路径以第二网络设备为终点。
可选的,第一报文、多个子路径信息和多个子路径可以分别参考图7A对应的实施例中的相应内容进行理解。
S702B、基于第一报文包括第一指示信息,第一网络设备根据第一报文中的多个子路径信息分别通过多个子路径向第二网络设备转发多个第二报文。
第一网络设备接收到第一报文,可以对第一报文进行解析。本申请实施例中,第一报文可以携带第一指示信息,第一网络设备可以解析到第一指示信息。
可选的,第一指示信息可以携带在第一网络设备的第一SID中,第一SID携带在第一报文的SID列表字段中。
可选的,第一SID可以例如为图5A或图6A所示的报文1中的MPLS标签(A)。作为举例,第一指示信息可以携带在MPLS标签(A)中的标签字段中。
或者,可选的,第一SID可以例如为图5B或图5C所示的报文1中的SRv6SID(A)。作为举例,第一指示信息可以携带在SRv6SID(A)中的FUNCT字段和/或ARG字段中。
第一网络设备从第一报文中解析到第一指示信息后,可以在第一指示信息的指示下,根据第一报文中的多个子路径信息分别通过多个子路径向第二网络设备转发多个第二报文。在一种可能的实现方式中,第二报文可以为对第一报文进行复制得到的,第二报文包括第一报文的净荷数据。
可选的,第一网络设备根据第一报文中的多个子路径信息分别通过多个子路径向第二网络设备转发多个第二报文的过程可以参考图2对应的实施例中步骤S205至S208进行理解。
可选的,多个第二报文可以为段路由报文。可选的,例如参考图5A或图5B或图5C所示的报文2和报文2′,多个子路径信息可以携带在第二报文的SID列表字段中。
可选的,例如参考图5A或图5B所示的报文2和报文2′,多个第二报文中的每个第二报文分别包括多个子路径信息中的每个子路径信息,每个子路径信息携带在每个第二报文的SID列表字段中。
可选的,例如参考图5C所示的报文2和报文2′,多个第二报文中的每个第二报文均包括SL字段和多个子路径信息。多个第二报文中的每个第二报文的SL字段的取值不同,以使得多个第二报文中的每个第二报文的SL字段的取值分别指向多个子路径信息中的每个子路径信息。如图5C所示,报文2和报文2′的SL字段的取值分别为6和3,以使得报文2和报文2′的SL字段的取值分别指向SID列表r1和SID列表r2。
图7C示出了本申请实施例方法另一种可能的流程。参考图7C,本申请实施例方法可以包括步骤S701C和步骤S702C。
S701C、第二网络设备接收多个第二报文;
可选的,多个第二报文可以来自图7B对应实施例中的第一网络设备。可选的,该多个第二报文可以参考步骤S702B中的多个第二报文进行理解。
S702C、第二网络设备转发多个第二报文中的目标第二报文,并且丢弃多个第二报文中除目标第二报文外的其他报文。
第二报文可以包括第二指示信息,第二网络设备可以在第二指示信息的指示下,对多个第二报文中的目标第二报文进行转发,并且丢弃多个第二报文中除目标第二报文以外的其他报文。作为举例,目标第二报文可以为多个第二报文中最先到达第二网络设备的第二报文。
以多个第二报文中的每个第二报文包括多个子路径信息中的每个子路径信息为例,第二网络设备接收到目标第二报文后,可以在目标第二报文中的第二指示信息的指示下,修改目标第二报文中的SL字段的值,以使得目标第二报文中的SL字段的值对应目标第二报文的SL列表中的目标SID,其中,目标SID对应目标第二报文转发路径中的下一跳网络设备或链路。
以目标第二报文如图5C所示的报文2为例,目标SID可以为SRv6SID(PE2),第二网络设备接收到报文2后,可以将报文2中SL的取值由6修改为0,即第二报文的SL字段的取值指向节点PE2。
第一网络设备接收到第一报文后,若第一网络设备从第一报文中解析到第一指示信息,第一网络设备可以从第一报文中获得多个子路径对应的多个子路径信息,并且基于对第一报文进行复制生成多个第二报文,第二报文包括第一报文中的净荷数据,之后根据多个子路径信息分别通过多个子路径向第二网络设备转发多个第二报文,有利于实现第一报文在第一网络设备和第二网络设备之间的冗余保护,并且提高第一网络设备对第一报文的转发效率。
以上通过方案一和方案二分别介绍了SR网络根据SR策略在子路径1和子路径2上对报文进行冗余保护的可选方案,下面结合方案三补充介绍SR网络实现冗余保护的另一种可选方案。
方案三、沿用SR策略<A,b,F>的机制来向冗余节点下发SR策略
在方案一中,需要对SR策略<A,b,F>进行扩展,若节点A保存有SR策略<A,b,F>和SR策略<A,r1,F>,当节点A接收到携带BSID(A)的报文时,节点A在匹配BSID(A)所 对应的SR策略后,需要继续解析SR策略中是否包括冗余标识,才能确定如何根据候选路径对应的多个SID列表处理报文。不仅需要对SR策略进行扩展,还会降低节点A根据SR策略处理报文的效率。
为此,方案三提出沿用SR策略<A,b,F>的机制来向冗余节点下发SR策略。下面介绍方案三提供的可选方案。
可选的,本申请实施例方法另一种可能的流程可以包括步骤S801。
S801、控制器向第一网络设备发送SR策略;
控制器可以向第一网络设备发送SR策略,该段路由策略可以包括SR列表和对应于SID列表的BSID。可选的,该SR列表可以参考图3B或图4A或图4B所示的SID(A)至SID(F)进行理解。该控制器和第一网络设备可以分别参考图1A所示的控制器和节点A进行理解。
SR列表可以包括多个子路径信息,多个子路径信息分别对应于第一网络设备和第二网络设备之间的多个子路径,并且多个子路径中的每个子路径以第一网络设备为起点,多个子路径中的每个子路径以第二网络设备为终点。可选的,多个子路径可以参考图1A或图2对应的子路径1和子路径2进行理解。可选的,多个子路径信息可以参考图3B或图4A或图4B对应的SID列表r1列表r1和SID列表r2进行理解。
可选的,该SR策略可以例如图8中的SR策略<A,r3,F>,该SR策略中的SR路径为候选路径r,候选路径r的路径信息可以携带在一个SID列表(称作SID列表r)中。示例性的,该候选路径r可以例如为图1E所示的候选路径r,即包括子路径1和子路径2,并且,节点A和节点F分别冗余节点和合并节点。例如,该SID列表r可以例如包括图3B所示的SID(A)、SID列表r1、SID列表r2和SID(F)。可选的,该BSID可以参考图1E所示的BSID(A)进行理解。
参考图9A,本申请报文发送的方法另一种可能的实施例可以可以包括步骤S901至步骤S903。
S901、第一网络设备获取SR策略;
可选的,该SR策略可以来自前述步骤S801中的控制器。可选的,该SR策略可以参考步骤S801中介绍的SR策略进行理解。
S902、第一网络设备接收第一报文;
第一网络设备获取段路由策略后,可以接收第一报文,其中,第一报文的目的地址字段包括BSID。图9B示出了第一报文另一种可能的结构,第一报文的SID列表字段不包括多个子路径信息,有利于节约第一报文的长度,进而有利于节约网络资源。图9B所示报文的SRH头中,“NH”代表下一个头部类型字段,“HEL”代表头部长度字段,“RT”代表路由类型字段,“LE”代表上一个入口字段,“F”代表标志位字段。本申请实施例不限定图8对应的实施例中的第一报文一定为图9B所示的结构,例如,出于简化描述的目的,图9B仅示出报文中Ipv6头的DA字段,并未示出Ipv6头中的其他字段。
可选的,和图9B所示的第一报文不同的,SL字段指示SR列表字段中的活动SRv6SID的下一个SRv6SID,SL字段的取值为0,并且,第一报文可以不包括BSID,有利于节省报文2的长度。
该SID列表和BSID可以参考步骤S801中的相关内容进行理解。
S903、第一网络设备根据第一报文中的BSID和SR策略获得SID列表,分别通过多个子路径向第二网络设备转发多个第二报文。
第一网络设备从第一报文中解析到BSID后,可以匹配到BSID对应的SR策略,之后可以在SR策略的指示下,获取绑定该BSID的SR列表,根据SR列表分别通过多个子路径向第二网络设备转发多个第二报文。第二网络设备可以参考图1A所示的节点F进行理解。例如,可选的,第一网络设备根据SR列表分别通过多个子路径向第二网络设备转发的多个第二报文可以参考图5A或图5B所示的报文2和报文2′进行理解。第二报文为对第一报文进行复制得到的,第二报文包括第一报文的净荷数据。
上面介绍了本申请实施例发送报文的方法,下面介绍本申请网络设备的结构。该网络设备可以为图1A或图2或图5A或图5B或图5C中的节点PE1或节点A或节点F,或步骤S701中的控制器,或图7A对应实施例方法中的网络入口设备,或图7B对应实施例方法中的第一网络设备,或图7C对应实施例方法中的第二网络设备,或者为步骤S801中的控制器,或者为图9A对应实施例方法中的第一网络设备。该网络设备可以安装在相应设备中,示例性的,该网络设备可以为芯片系统。本申请实施例中,芯片系统可以由芯片构成,也可以包含芯片和其他分立器件。
图10是本申请实施例网络设备的一个结构示意图。参阅图10,该网络设备10包括处理器1001、存储器1002。
处理器1001可以是一个或多个CPU,该CPU可以是单核CPU,也可以是多核CPU。
存储器1002包括但不限于是随机存取存储器(random access memory,RAM)、只读存储器(Read only Memory,ROM)、可擦除可编程只读存储器(erasable programmable read-only memory,EPROM或者快闪存储器)、快闪存储器、或光存储器等。存储器1002中保存有操作系统和程序指令的代码。
可选的,该网络设备10还包括通信接口1003。通信接口1003可以是有线接口,例如光纤分布式数据接口(Fiber Distributed Data Interface,FDDI)、千兆以太网(Gigabit Ethernet,GE)接口;通信接口1003也可以是无线接口。通信接口1003用于接收来自于BGP邻居发送的路由信息。
可选地,网络设备10还包括总线1004,上述处理器1001、存储器1002通常通过总线1004相互连接,也可以采用其他方式相互连接。
可选地,处理器1001通过读取存储器1002中保存的程序指令实现本申请实施例发送报文的方法,或者,处理器1001也可以通过内部存储的程序指令实现本申请实施例发送报文的方法。例如,处理器1001根据存储器1002保存的指令来执行图2所示实施例方法中控制器或节点PE1或节点A或节点F执行的步骤,或者,执行步骤S701,或者,执行图7A对应实施例方法中网络入口设备执行的步骤,或者执行图7B对应的实施例中第一网络设备执行的步骤,或者执行图7C对应的实施例中第二网络设备执行的步骤,或者,执行步骤S801,或者执行图9A对应的实施例中第一网络设备执行的步骤。处理器1001实现上述步骤的更多细节请参阅前面各个实施例方法中的描述,在这里不再重复。
本申请实施例还提供一种网络设备。图11为本申请实施例网络设备的结构示意图。参阅图11,该网络设备11包括接收模块1101和发送模块1102。示例性的,该接收模块1101用于执行步骤S204或S207或S208或S701B或S701C或S901或S902,该发送模块1102用于执行步骤S205或S206或S207或S208或S702B或S702C或S209或S210或S211或S705或S903。具体执行过程请参考上述方法实施例中相应步骤的详细描述,这里不再赘述。
本申请实施例还提供一种网络设备。图12为本申请实施例网络设备的结构示意图。参阅图12,该网络设备12包括封装模块1201和发送模块1202。示例性的,该封装模块1201用于执行步骤S203或S701A,该发送模块1202用于执行步骤S204或S702A。具体执行过程请参考上述方法实施例中相应步骤的详细描述,这里不再赘述。
本申请实施例还提供一种网络设备。图13为本申请实施例网络设备的结构示意图。参阅图13,该网络设备13包括发送模块1301。示例性的,该发送模块1301用于执行图2所示的步骤S201或前文介绍的S701或S801。具体执行过程请参考上述方法实施例中相应步骤的详细描述,这里不再赘述。
本申请实施例中的耦合是装置、单元或模块之间的间接耦合或通信连接,可以是电性,机械或其它的形式,用于装置、单元或模块之间的信息交互。
图11至图13所描述的装置实施例仅仅是示意性的。图11至图13中的模块既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。以图11所示的网络设备11为例,采用软件实现时,图11所示网络设备中的发送模块1102可以由处理器1001读取存储器1002中存储的程序指令后,生成的一个或多个软件功能模块来实现。本申请实施例对模块的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。图11至图13中的模块也可以由网络设备中的不同硬件分别实现,例如,以图11所示网络设备11为例,接收模块1101由图10中的通信接口1003实现,发送模块1102由图10中处理器1001共同实现。显然上述功能模块也可以采用软件硬件相结合的方式来实现,例如接收模块1101由通信接口1003实现。
图11至图13所示的网络设备能够实现的技术效果、各个模块实现上述功能的更多细节请参阅前面各个方法实施例中的相应描述,在这里不再赘述。
参考图14,本申请实施例还提供一种芯片14,该芯片14包括处理器1401和通信接口1402,通信接口1402和处理器1401耦合,处理器1401用于运行计算机程序或指令,从而实现本申请上述任意一个方法实施例提供的方法。
一个示例中,该通信接口1402(或称接口电路)例如可以是该芯片14上的输入/输出接口、管脚或电路等。该处理器1401可执行存储器存储的计算机指令,以使该芯片14执行上述任一方法实施例。可选地,该存储器可以为该芯片14内的存储单元,如寄存器、缓存等,或者,该存储器可以是计算机设备内的位于所述芯片14外部的存储器,如只读存储器(read-only memory,ROM)或可存储静态信息和指令的其他类型的静态存储设备,随机存取存储器(random access memory,RAM)等。可选的,该处理器1401,可以是一个通用中央处理器(CPU),微处理器,特定应用集成电路(application-specific integrated circuit,ASIC),或一个或多个用于控制上述任一方法实施例的程序执行的集成电路。
上述实施例,可以全部或部分地通过软件、硬件、固件或者其任意组合来实现,当使用 软件实现时,可以全部或部分地以计算机程序产品的形式实现。
所述计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行所述计算机执行指令时,全部或部分地产生按照本申请实施例所述的流程或功能。所述计算机可以是通用计算机、专用计算机、计算机网络、或者其他可编程装置。所述计算机指令可以存储在计算机可读存储介质中,或者从一个计算机可读存储介质向另一计算机可读存储介质传输,例如,所述计算机指令可以从一个网站站点、计算机、服务器或数据中心通过有线(例如同轴电缆、光纤、数字用户线(DSL))或无线(例如红外、无线、微波等)方式向另一个网站站点、计算机、服务器或数据中心进行传输。所述计算机可读存储介质可以是计算机能够存储的任何可用介质或者是包含一个或多个可用介质集成的服务器、数据中心等数据存储设备。所述可用介质可以是磁性介质,(例如,软盘、硬盘、磁带)、光介质(例如,DVD)、或者半导体介质(例如固态硬盘(solid state disk,SSD))等。
本申请实施例还提供一种网络系统(或称通信系统),该网络系统可以包括图2对应的实施例中的至少两个网络设备,该至少两个网络设备分别用于执行图2对应实施例方法中相应网络设备所执行的步骤。或者,该网络系统可以包括步骤S701中的控制器和/或图7A对应实施例中的网络入口设备和/或图7B对应实施例中的第一网络设备和/或图7C对应实施例中的第二网络设备。或者,该网络系统可以包括步骤S801中的控制器和图9A对应实施例中的第一网络设备。
本申请实施例中,至少一个是指一个或多个,多个是指两个或两个以上,本申请不做限制。在本申请实施例中,“/”可以表示前后关联的对象是一种“或”的关系,例如,A/B可以表示A或B;“和/或”可以用于描述关联对象存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况,其中A,B可以是单数或者复数。为了便于描述本申请实施例的技术方案,在本申请实施例中,可以采用“第一”、“第二”等字样对功能相同或相似的技术特征进行区分。该“第一”、“第二”等字样并不对数量和执行次序进行限定,并且“第一”、“第二”等字样也并不限定一定不同。在本申请实施例中,“示例性的”或者“例如”等词用于表示例子、例证或说明,被描述为“示例性的”或者“例如”的任何实施例或设计方案不应被解释为比其它实施例或设计方案更优选或更具优势。使用“示例性的”或者“例如”等词旨在以具体方式呈现相关概念,便于理解。
本说明书中的各个实施例均采用递进的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同之处。尤其,对于系统实施例而言,由于其基本相似于方法实施例,所以描述的比较简单,相关之处参见方法实施例的部分说明即可。
本领域普通技术人员将会理解,当使用软件实现本申请实施例的各个方面、或各个方面的可能实现方式时,上述各个方面、或各个方面的可能实现方式可以全部或部分地以计算机程序产品的形式实现。计算机程序产品是指存储在计算机可读介质中的计算机可读指令。在计算机上加载和执行所述计算机指令时,全部或部分地产生按照本申请实施例所述的流程或功能。
计算机可读介质可以是计算机可读信号介质或者计算机可读存储介质。计算机可读存储介质包括但不限于电子、磁性、光学、电磁、红外或半导体系统、设备或者装置,或者前述 的任意适当组合。如计算机可读存储介质为随机存取存储器(Random Access Memory,RAM)、只读存储器(read only memory,ROM)、可擦除可编程只读存储器(Erasable Programmable Read Only Memory,EPROM)或便携式只读存储器(Compact Disc Read-Only Memory,CD-ROM)。
显然,本领域的技术人员可以对本发明进行各种改动和变型而不脱离本发明的范围。这样,倘若本申请的这些修改和变型属于本发明权利要求的范围之内,则本发明也意图包括这些改动和变型在内。

Claims (20)

  1. 一种发送报文的方法,其特征在于,包括:
    第一网络设备接收第一报文,所述第一报文包括多个子路径信息和第一指示信息,所述多个子路径信息分别对应于所述第一网络设备和第二网络设备之间的多个子路径,并且所述多个子路径中的每个子路径以所述第一网络设备为起点,所述多个子路径中的每个子路径以所述第二网络设备为终点;
    基于所述第一报文包括第一指示信息,所述第一网络设备根据所述第一报文中的所述多个子路径信息分别通过所述多个子路径向所述第二网络设备转发多个第二报文,所述第二报文为对所述第一报文进行复制得到的,所述第二报文包括所述第一报文的净荷数据。
  2. 根据权利要求1所述的方法,其特征在于,所述第二报文包括第二指示信息,所述第二指示信息指示所述第二网络设备转发接收到的目标报文,所述目标报文包括在所述多个第二报文中,并且丢弃接收到的所述多个第二报文中除所述目标第二报文以外的其他报文。
  3. 根据权利要求1或2所述的方法,其特征在于,所述第一报文为段路由报文,所述多个子路径信息携带在所述第一报文的段标识列表字段中。
  4. 根据权利要求1或2所述的方法,其特征在于,所述第一报文为段路由报文,所述多个子路径信息携带在所述第一报文的段路由头SRH的可选类型长度值字段中。
  5. 根据权利要求3或4所述的方法,其特征在于,所述第一报文中的所述多个子路径信息为一个有序列表,所述有序列表包括依次排列的第1子路径信息、……、第i子路径信息、……、和第n子路径信息,n为所述多个子路径中子路径的数目,i为小于或等于n的任意一个正整数,所述第i子路径信息对应于所述多个子路径中的第i子路径,所述第i子路径信息包括所述第i子路径对应的段标识列表。
  6. 根据权利要求5所述的方法,其特征在于,所述多个第二报文为段路由报文,所述多个子路径信息携带在所述第二报文的段标识列表字段中,所述多个第二报文均包括段剩余字段,所述多个第二报文中的每个第二报文的段剩余字段的取值不同,以使得所述多个第二报文中的每个第二报文的段剩余字段的取值分别指向所述多个子路径信息中的每个子路径信息。
  7. 根据权利要求5所述的方法,其特征在于,所述多个第二报文为段路由报文,所述多个第二报文中的每个第二报文分别包括所述多个子路径信息中的每个子路径信息,所述每个子路径信息携带在所述每个第二报文的段标识列表字段中。
  8. 根据权利要求1至7中任一项所述的方法,其特征在于,所述第一指示信息携带在所述第一网络设备的第一段标识SID中,所述第一SID携带在所述第一报文的段标识列表字段中。
  9. 根据权利要求8所述的方法,其特征在于,所述第一SID为SRv6SID,所述第一指示信息包括在所述第一SID的FUNCT字段和/或ARG字段中。
  10. 一种发送报文的方法,其特征在于,包括:
    网络入口设备在数据报文中封装多个子路径信息,以获得第一报文,所述多个子路径信息分别对应于第一网络设备和第二网络设备之间的多个子路径,并且所述多个子路径中的每个子路径以所述第一网络设备为起点,所述多个子路径中的每个子路径以所述第二网络设备为终点;
    所述网络入口设备向所述第一网络设备发送所述第一报文,所述第一报文还包括第一指示信息,所述第一指示信息指示所述第一网络设备根据所述第一报文中的所述多个子路径信息分别通过所述多个子路径向所述第二网络设备转发多个第二报文,所述第二报文为对所述第一报文进行复制得到的,所述第二报文包括所述第一报文的净荷数据。
  11. 根据权利要求10所述的方法,其特征在于,所述第一报文为段路由报文,所述多个子路径信息携带在所述第一报文的段标识列表字段中。
  12. 根据权利要求10所述的方法,其特征在于,所述第一报文为段路由报文,所述多个子路径信息携带在所述第一报文的段路由头SRH的可选类型长度值字段中。
  13. 根据权利要求10至12中任一项所述的方法,其特征在于,所述网络入口设备在数据报文中封装多个子路径信息包括:
    所述网络入口设备根据段路由策略在数据报文中封装段标识列表,所述段路由策略的候选路径信息包括所述段标识列表,所述段标识列表包括所述多个子路径信息。
  14. 一种发送报文的控制方法,其特征在于,包括:
    控制器向网络入口设备发送段路由策略,所述段路由策略的候选路径信息包括段标识列表,所述段标识列表包括多个子路径信息,所述多个子路径信息分别对应于所述第一网络设备和第二网络设备之间的多个子路径,并且所述多个子路径中的每个子路径以所述第一网络设备为起点,所述多个子路径中的每个子路径以所述第二网络设备为终点,所述段路由策略用于指示所述网络入口设备在数据报文中封装所述段标识列表以获得向所述第一网络设备发送的第一报文,以使得所述第一网络设备根据所述第一报文中的所述多个子路径信息分别通过所述多个子路径向所述第二网络设备转发多个第二报文,所述第二报文为基于对所述第一报文进行复制得到的,所述第二报文包括所述第一报文的净荷数据。
  15. 一种发送报文的方法,其特征在于,包括:
    第二网络设备接收多个第二报文,所述多个第二报文均包括多个子路径信息及段剩余字段;所述多个子路径信息为一个有序列表,所述有序列表从前至后依次包括第1子路径信息、……、第i子路径信息、……、和第n子路径信息,n为第一网络设备和所述第二网络设备之间的多个子路径中的路径数目,所述多个子路径中的每个子路径以所述第一网络设备为起点,所述多个子路径中的每个子路径以所述第二网络设备为终点,i为小于或等于n的任意一个正整数,所述第i子路径信息对应于所述多个子路径中的第i路径,所述第i子路径信息包括所述第i子路径对应的段标识列表;所述多个第二报文中的每个第二报文的段剩余字段的取值不同,以使得所述多个第二报文中的每个第二报文的段剩余字段的取值分别指向所述多个子路径信息中的每个子路径信息;
    所述第二网络设备转发所述多个第二报文中的目标第二报文,并且丢弃所述多个第二报文中除所述目标第二报文外的其他报文。
  16. 根据权利要求15所述的方法,其特征在于,所述第二网络设备转发所述多个第二报文中的目标第二报文,包括:
    所述第二网络设备修改所述目标第二报文中的段剩余字段的值,以使得所述目标第二报文中的段剩余字段的值对应所述目标第二报文的段标识列表中的目标SID,所述目标SID对应所述目标第二报文转发路径中的下一跳网络设备或链路。
  17. 一种发送报文的方法,其特征在于,包括:
    第一网络设备获取段路由策略,所述段路由策略包括段标识列表和对应于所述段标识列表的绑定段标识BSID,所述段标识列表包括多个子路径信息,所述多个子路径信息分别对应于所述第一网络设备和第二网络设备之间的多个子路径,并且所述多个子路径中的每个子路径分别以所述第一网络设备和所述第二网络设备为起点和终点;
    所述第一网络设备接收第一报文,所述第一报文的目的地址字段包括所述BSID;
    所述第一网络设备根据所述BSID和所述SR策略获得所述段标识列表,分别通过所述多个子路径向所述第二网络设备转发多个第二报文,所述第二报文为对所述第一报文进行复制得到的,所述第二报文包括所述第一报文的净荷数据。
  18. 一种发送报文的控制方法,其特征在于,包括:
    控制器向第一网络设备发送段路由策略,所述段路由策略包括段标识列表和对应于所述段标识列表的绑定段标识BSID,所述段标识列表包括多个子路径信息,所述多个子路径信息分别对应于所述第一网络设备和第二网络设备之间的多个子路径,并且所述多个子路径中的每个子路径以所述第一网络设备为起点,所述多个子路径中的每个子路径以所述第二网络设备为终点,所述SR策略用于指示所述第一网络设备在接收到目的地址字段包括所述BSID的第一报文后,根据所述BSID和所述SR策略获得所述段标识列表,分别通过所述多个子路径向所述第二网络设备转发多个第二报文,所述第二报文为对所述第一报文进行复制得到的,所述第二报文包括所述第一报文的净荷数据。
  19. 一种网络设备,其特征在于,包括:处理器和存储器,所述存储器和所述处理器耦合,所述存储器用于存储程序代码,所述处理器用于调用所述程序代码以执行权利要求1至18中任一项所述的方法。
  20. 一种网络系统,其特征在于,包括第一网络设备、网络入口设备、控制器和第二网络设备中的至少一种设备,其中,所述第一网络设备用于执行权利要求1至9中任一项所述的方法或权利要求17所述的方法,所述网络入口设备用于执行权利要求10至13中任一项所述的方法,所述控制器用于执行权利要求14或18所述的方法,所述第二网络设备用于执行权利要求15或16所述的方法。
PCT/CN2022/110185 2021-08-30 2022-08-04 发送报文的方法、发送报文的控制方法及装置 WO2023029871A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202111007552.1A CN115733840A (zh) 2021-08-30 2021-08-30 发送报文的方法、发送报文的控制方法及装置
CN202111007552.1 2021-08-30

Publications (1)

Publication Number Publication Date
WO2023029871A1 true WO2023029871A1 (zh) 2023-03-09

Family

ID=85291089

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/110185 WO2023029871A1 (zh) 2021-08-30 2022-08-04 发送报文的方法、发送报文的控制方法及装置

Country Status (2)

Country Link
CN (1) CN115733840A (zh)
WO (1) WO2023029871A1 (zh)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116938807A (zh) * 2023-09-14 2023-10-24 新华三技术有限公司 数据报文传输方法、装置、设备及存储介质
CN117439898A (zh) * 2023-12-22 2024-01-23 深圳万物安全科技有限公司 网络设备识别方法、网络设备识别设备和存储介质

Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6751746B1 (en) * 2000-07-31 2004-06-15 Cisco Technology, Inc. Method and apparatus for uninterrupted packet transfer using replication over disjoint paths
US20100235593A1 (en) * 2009-03-13 2010-09-16 Navindra Yadav Flow resiliency
CN109309623A (zh) * 2017-07-28 2019-02-05 瞻博网络公司 用于多播保护的到冗余多播源节点的最大冗余树
CN110535782A (zh) * 2019-06-15 2019-12-03 华为技术有限公司 一种实现QoS保障的报文处理方法、设备和系统
US20200145321A1 (en) * 2018-11-02 2020-05-07 Cisco Technology, Inc., A California Corporation Operations Processing of Multiple-Protocol Packets by Packet Switching Devices in a Network
CN112217724A (zh) * 2019-07-11 2021-01-12 中兴通讯股份有限公司 路由管理方法、装置、网络设备和可读存储介质
EP3764606A1 (en) * 2019-07-08 2021-01-13 Juniper Networks, Inc. Resilient multiprotocol label switching (mpls) rings using segment routing
CN112448888A (zh) * 2019-08-31 2021-03-05 华为技术有限公司 一种在sr网络中转发报文的方法、设备和系统
CN112751763A (zh) * 2019-10-30 2021-05-04 北京华为数字技术有限公司 一种报文转发方法、设备、存储介质及系统
CN113114566A (zh) * 2017-09-25 2021-07-13 华为技术有限公司 一种报文转发的方法及网络设备
CN113364680A (zh) * 2020-03-06 2021-09-07 华为技术有限公司 一种sr策略的发布、接收方法及装置

Patent Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6751746B1 (en) * 2000-07-31 2004-06-15 Cisco Technology, Inc. Method and apparatus for uninterrupted packet transfer using replication over disjoint paths
US20100235593A1 (en) * 2009-03-13 2010-09-16 Navindra Yadav Flow resiliency
CN109309623A (zh) * 2017-07-28 2019-02-05 瞻博网络公司 用于多播保护的到冗余多播源节点的最大冗余树
CN113114566A (zh) * 2017-09-25 2021-07-13 华为技术有限公司 一种报文转发的方法及网络设备
US20200145321A1 (en) * 2018-11-02 2020-05-07 Cisco Technology, Inc., A California Corporation Operations Processing of Multiple-Protocol Packets by Packet Switching Devices in a Network
CN110535782A (zh) * 2019-06-15 2019-12-03 华为技术有限公司 一种实现QoS保障的报文处理方法、设备和系统
EP3764606A1 (en) * 2019-07-08 2021-01-13 Juniper Networks, Inc. Resilient multiprotocol label switching (mpls) rings using segment routing
CN112217724A (zh) * 2019-07-11 2021-01-12 中兴通讯股份有限公司 路由管理方法、装置、网络设备和可读存储介质
CN112448888A (zh) * 2019-08-31 2021-03-05 华为技术有限公司 一种在sr网络中转发报文的方法、设备和系统
CN112751763A (zh) * 2019-10-30 2021-05-04 北京华为数字技术有限公司 一种报文转发方法、设备、存储介质及系统
CN113364680A (zh) * 2020-03-06 2021-09-07 华为技术有限公司 一种sr策略的发布、接收方法及装置

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116938807A (zh) * 2023-09-14 2023-10-24 新华三技术有限公司 数据报文传输方法、装置、设备及存储介质
CN116938807B (zh) * 2023-09-14 2023-12-22 新华三技术有限公司 数据报文传输方法、装置、设备及存储介质
CN117439898A (zh) * 2023-12-22 2024-01-23 深圳万物安全科技有限公司 网络设备识别方法、网络设备识别设备和存储介质
CN117439898B (zh) * 2023-12-22 2024-03-12 深圳万物安全科技有限公司 网络设备识别方法、网络设备识别设备和存储介质

Also Published As

Publication number Publication date
CN115733840A (zh) 2023-03-03

Similar Documents

Publication Publication Date Title
US11979322B2 (en) Method and apparatus for providing service for traffic flow
WO2023029871A1 (zh) 发送报文的方法、发送报文的控制方法及装置
JP7327876B2 (ja) パケット転送経路を決定するための方法及びシステム、並びに、ネットワークノード
US9699105B2 (en) Self-routing multicast in a software defined network fabric
JP6144834B2 (ja) Sdnスイッチにより正確なフロー・エントリを獲得するための方法、およびsdnスイッチ、コントローラ、およびシステム
KR102239717B1 (ko) 패킷 처리 방법 및 장치
KR20210092304A (ko) 패킷 처리 방법 및 장치, 기기, 그리고 시스템
Li et al. Improving SDN scalability with protocol-oblivious source routing: A system-level study
US20220124025A1 (en) Method for forwarding packet in data center network and related apparatus
WO2022001835A1 (zh) 发送报文的方法、装置、网络设备、系统及存储介质
CN113056891B (zh) 源路由隧道入节点保护
WO2019165900A1 (zh) 一种处理组播数据报文的方法及装置
WO2021083332A1 (zh) 发送报文的方法、装置及系统
WO2020173198A1 (zh) 一种报文的处理方法、报文转发装置以及报文处理装置
WO2022117018A1 (zh) 报文传输的方法和装置
US7742471B2 (en) Methods and systems for routing packets with a hardware forwarding engine and a software forwarding engine
CN113950811B (zh) 扩展bgp保护以用于sr路径入口保护
US20230254246A1 (en) Mechanisms for packet path tracing and per-hop delay measurement in segment routing with multiprotocol label switching (sr-mpls) networks
CN116094987A (zh) 转发路径的确定方法及装置
CN113055268A (zh) 隧道流量负载均衡的方法、装置、设备及介质
WO2024001701A1 (zh) 数据处理方法、装置及系统
WO2022194193A1 (zh) 用于获取路径的方法和装置
WO2023078031A1 (zh) 一种报文发送方法及装置
WO2023216622A1 (zh) 报文处理方法、设备、系统及计算机可读存储介质
WO2022257773A1 (zh) 路由检测方法、设备、系统及存储介质

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22863012

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE