WO2018010560A1 - Method, apparatus, and system for detecting and processing multi-protocol label switching - Google Patents
Method, apparatus, and system for detecting and processing multi-protocol label switching Download PDFInfo
- Publication number
- WO2018010560A1 WO2018010560A1 PCT/CN2017/091477 CN2017091477W WO2018010560A1 WO 2018010560 A1 WO2018010560 A1 WO 2018010560A1 CN 2017091477 W CN2017091477 W CN 2017091477W WO 2018010560 A1 WO2018010560 A1 WO 2018010560A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- response
- request message
- node
- message
- downstream
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Ceased
Links
Images
Definitions
- the embodiments of the present invention relate to the field of communications, and in particular, to a method, a device, and a system for detecting and processing a multi-protocol exchange tag.
- P2P peer to peer
- P2MP peer to multiple peer
- MPLS Multi-protocol Label Switching
- the Administration and Maintenance (OAM) packet is transmitted on the same path as the MPLS data packet.
- the data plane does not recognize the MPLS OAM packet.
- the packet expires due to the time-to-live (Time To Live, TTL for short).
- TTL Time To Live
- Rfc4379 Label Switching Path (LSP) ping/trace
- MPLS BFD MPLS BFD
- IPv4 Label Switching Path
- IPv6 IPv6
- the data link layer defines whether the type field identifies whether it is an MPLS unicast packet or a multicast packet (rfc3032, rfc5332). However, there is no corresponding standard definition to identify whether it is an MPLS OAM packet or an MPLS data packet, except for the Ethernet link.
- the ethernet type is used for specific Ethernet OAM mechanisms (such as 802.1ag, 802.3ah, Y.1731), but these definitions cannot be applied to MPLS OAM.
- the data plane also needs to be perceived in advance in a quick way to be MPLS.
- OAM packets do some auxiliary processing that is independent of the forwarding path.
- the P2P LSP ping/trace standard in the related art has the following problems:
- the P2MP LSP ping/trace standard in the related art has the following problems of detecting inefficiency and insufficiency:
- the Initiator does not precisely control whether the echo reply message is received and then initiates the next echo request. That is to say, the timing of sending the next request is uncertain. If the Initiator sends the next echo request every time it receives an echo reply, it needs to cache a large number of historical echo requests in order to wait for those late echo requests.
- the received echo reply may burst and cause congestion.
- a solution has been proposed, it is not perfect. For example, a method that returns a random delay when echo reply will slow down the detection process; only a specific node will return echo. The reply method only supports specifying a single node or a route node assigned to a single egress.
- the embodiments of the present invention provide a method, a device, and a system for detecting and processing a multi-protocol exchange label, so as to solve the problem that the LSP detection distortion and the P2MP LSP detection are inefficient and insufficient in the related art.
- a method for detecting a multi-protocol switching label including: detecting an initiator sending an echo request packet, where the echo request packet includes an MPLS operation for identifying a multi-protocol switching label Maintaining the type field of the management OAM packet; receiving the response response message fed back by the transit node or the egress node according to the MPLS OAM packet, and detecting whether the response response packet matches the pre-stored information.
- the response request message further includes: downstream mapping information, where the downstream mapping information corresponds to one or more next hop routes of the response request message.
- the detecting the initiator sending the response request message further includes: detecting, by the initiator, whether the response request message is an initial response request message sent by the initial node; if the determination result is yes, detecting that the initiator is When the response request message is sent, the downstream mapping information in the response request message is locally saved in the initial node.
- the detecting initiator locally saves the downstream mapping information carried in the last round of the response response message in the initial node.
- the type field is encapsulated in a data link layer header of the response request message.
- detecting whether the response response message matches the pre-stored information includes: detecting whether a sender handle Sender's Handle in the response response message matches a first corresponding field in the response request message, and detecting Whether the sequence number in the response response message matches the second corresponding field in the response request message; the Sender's Handle matches the first corresponding field, and the serial number and the second
- the corresponding field matches it is determined whether the upstream interface information in the response response message matches the downstream mapping information saved locally by the initial node, and the upstream interface information in the response response message is locally saved with the initial node.
- the downstream mapping information matches, it is determined that the response response message matches the pre-stored information.
- the method further includes: determining, according to the detection result that the response response message matches the pre-stored information, whether to send the next response request message.
- determining, according to the detection result that the response response message matches the pre-stored information, whether to send the next response request message includes: detecting a transmission mode of the response request message; and searching for the Internet packet in the transmission mode When the ping (Packet Internet Groper) mode is used, the next response request message is discarded; and/or, according to whether the locally saved downstream mapping information satisfies the matching policy, whether to send the next response request message is determined.
- ping Packet Internet Groper
- a method for processing a multi-protocol exchange label including: receiving an echo request message, where the response request message includes an MPLS operation maintenance management for identifying a multi-protocol exchange label.
- the forwarding plane forwards the response request message according to the preset forwarding entry, and the forwarding plane forwards the response request message to the control according to the first preset forwarding entry.
- a plane and feedback the response response message of the response request message; the forwarding plane modifies the content of the MPLS OAM message, and forwards the response request message to the data plane according to the second preset forwarding entry Next hop node.
- modifying, by the forwarding plane, the content of the MPLS OAM packet includes: modifying downlink mapping information in the response request packet.
- a device for detecting a multi-protocol exchange label comprising: a sending module, configured to send an echo request message, wherein the response request message includes a multi-protocol exchange for identifying
- the labeling MPLS operation maintains and manages the type field of the OAM packet.
- the detecting module is configured to receive the response response message fed back by the transmitting node or the egress node according to the MPLS OAM packet, and detect whether the response response packet matches the pre-stored information. .
- the response request message further includes: downstream mapping information, where the downstream mapping information corresponds to one or more next hop routes of the response request message.
- a processing apparatus for a multi-protocol exchange label including: a receiving module, configured to receive an echo request message, where the response request message includes a multi-protocol exchange for identifying
- the tag MPLS operation maintains the type field of the OAM message;
- the identification module is configured to identify the MPLS OAM message by using the type field, and
- the forwarding module is configured to forward the response request message according to the preset forwarding entry.
- a detection system for a multi-protocol switching label including an initial node, a transit node, or an egress node, where the initial node further includes:
- the sending module is configured to send a response request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message; and the detecting module is configured to receive the transmission node or the egress node.
- the transmitting node or the egress node further includes: a receiving module, configured to receive the response request message, where The response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message; the identification module is configured to identify the MPLS OAM packet by using the type field; and the forwarding module is set to be based on the pre- Let the forwarding entry be the response request The packet is forwarded to the control plane, and the response response message of the response request message is fed back.
- a receiving module configured to receive the response request message, where The response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message; the identification module is configured to identify the MPLS OAM packet by using the type field; and the forwarding module is set to be based on the pre- Let the forwarding entry be the response request The packet is forwarded to the control plane, and the response response message of the response request message is fed back.
- a storage medium is also provided.
- the storage medium is arranged to store program code for performing the following steps:
- the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message;
- the receiving transmission node or the egress node responds to the response message sent by the MPLS OAM packet, and detects whether the response response message matches the pre-stored information.
- the response request message is sent, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message; the receiving transmission node or the egress node is according to the MPLS
- the OAM packet feedback response message is sent, and it is detected whether the response response message matches the pre-stored information.
- the response request message carries a type field for identifying the multi-protocol switching label MPLS operation and maintenance management OAM packet, so that the forwarding plane of the transport node modifies the packet according to the actual forwarding information, and a corresponding set of detection processing procedures. Therefore, the problem of LSP detection distortion and P2MP LSP detection inefficiency and insufficiency in the related art can be solved.
- FIG. 1 is a flowchart of a method for detecting a multi-protocol exchange tag according to an embodiment of the present invention
- FIG. 2 is a flowchart of a method for processing a multi-protocol exchange tag according to an embodiment of the present invention
- FIG. 3 is a structural block diagram of a multi-protocol exchange tag detecting apparatus according to an embodiment of the present invention.
- FIG. 4 is a structural block diagram of a processing apparatus for a multi-protocol exchange tag according to an embodiment of the present invention
- FIG. 5 is a structural block diagram of a detection system for a multi-protocol exchange tag according to an embodiment of the present invention
- FIG. 6 is a format diagram of an LSP ping echo request/reply message according to an embodiment of the present invention.
- FIG. 7 is a format diagram of a Downstream Mapping TLV according to an embodiment of the present invention.
- FIG. 8 is a format diagram of an Upstream Interface TLV according to an embodiment of the present invention.
- FIG. 9 is a format diagram of a Responder Egress TLV according to an embodiment of the present invention.
- FIG. 10 is a format diagram of a Responder Transit TLV according to an embodiment of the present invention.
- FIG. 11 is a flowchart of an Initiator node sending an echo request message according to an embodiment of the present invention
- FIG. 13 is a flowchart of a send reply message sent by a Responder node according to an embodiment of the present invention.
- Figure 15 is a network topology diagram according to Example 1 of the present invention.
- Example 16 is a network topology diagram according to Example 2 of the present invention.
- Figure 17 is a network topology diagram in accordance with Example 3 of the present invention.
- FIG. 1 is a flowchart of a method for detecting a multi-protocol exchange label according to an embodiment of the present invention. As shown in FIG. Including the following steps:
- Step S102 The initiating party sends an echo request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message.
- Step S104 Receive an echo response message fed back by the transit node or the egress node according to the MPLS OAM packet, and detect whether the response response packet matches the prestored information.
- the execution subject may be the detection initiator, or the detection party (same or different from the detection initiator).
- the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM packet, and the receiving transmission node or the egress node responds according to the MPLS OAM packet feedback.
- the response message is sent, and it is detected whether the response response message matches the pre-stored message.
- the type field of the MPLS operation and maintenance management OAM packet for the multi-protocol exchange label is carried in the response request packet, so that the forwarding plane of the transmission node modifies the packet according to the actual forwarding information, and a corresponding set of detection processing flows. Therefore, the problem of LSP detection distortion and P2MP LSP detection inefficiency and insufficiency in the related art can be solved.
- the response request message further includes: downstream mapping information, where the downstream mapping information corresponds to one or more next hop routes of the response request message.
- the detecting initiator sends the response request message, which further includes:
- the detecting initiator determines whether the response request message is an initial response request message sent by the initial node.
- the initiator detects that the initiator maps the downstream mapping information in the response request message locally. If the result of the determination is negative, the detecting initiator locally saves the downstream mapping information carried in the last round of response response packets at the initial node when sending the response request message.
- the type field is encapsulated in the data link layer header of the response request message.
- detecting whether the response response message matches the pre-stored information specifically includes:
- determining whether the upstream interface information in the response response packet matches the downstream mapping information includes the following two methods:
- the method further includes: determining, according to the detection result that the response response message matches the pre-stored information, whether to send the next response request message. Further, determining whether to send the next response request message according to the detection result that the response response message matches the pre-stored information includes: detecting a transmission mode of the response request message; and abandoning the transmission when the transmission mode is the Internet packet explorer ping mode The next response request message; and/or, determining whether to send the next response request message according to whether the locally saved downstream mapping information satisfies the matching policy.
- FIG. 2 is a multi-protocol exchange according to an embodiment of the present invention.
- Step S202 receiving a response request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message;
- Step S204 Identify an MPLS OAM packet by using a type field.
- Step S206 Forward the response request message according to the preset forwarding entry.
- the forwarding plane forwards the response request message according to the preset forwarding entry, including one of the following:
- the forwarding plane forwards the response request message to the control plane according to the first preset forwarding entry, and feeds back the response response message of the response request message;
- the forwarding plane modifies the content of the MPLS OAM packet, and forwards the response request packet to the next hop node of the data plane according to the second preset forwarding entry.
- the forwarding plane modifies the content of the MPLS OAM packet, including: the downstream mapping information in the forwarding plane modification response request packet.
- the method according to the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course, by hardware, but in many cases, the former is A better implementation.
- the technical solution of the present invention which is essential or contributes to the prior art, may be embodied in the form of a software product stored in a storage medium (such as ROM/RAM, disk,
- the optical disc includes a number of instructions for causing a terminal device (which may be a cell phone, a computer, a server, or a network device, etc.) to perform the methods of various embodiments of the present invention.
- a multi-protocol exchange label detecting apparatus a multi-protocol exchange label processing apparatus, and a multi-protocol exchange label detecting system are provided to implement the above embodiments and preferred embodiments, which have been described. No longer.
- the term "module” may implement a combination of software and/or hardware of a predetermined function.
- the apparatus described in the following embodiments is preferably implemented in software, hardware, or a combination of software and hardware, is also possible and contemplated.
- FIG. 3 is a structural block diagram of a multi-protocol exchange label detecting apparatus according to an embodiment of the present invention. As shown in FIG. 3, the apparatus includes:
- the sending module 30 is configured to send an echo request message, where the response request message includes a type field for identifying an OAM packet of the MPLS operation and maintenance management of the multi-protocol switching label;
- the detecting module 32 is configured to receive an echo response message fed back by the transit node or the egress node according to the MPLS OAM packet, and detect whether the response response packet matches the pre-stored information.
- the response request message further includes: downstream mapping information, where the downstream mapping information corresponds to one or more next hop routes of the response request message.
- FIG. 4 is a structural block diagram of a processing apparatus for a multi-protocol exchange tag according to an embodiment of the present invention. As shown in FIG. 4, the device includes:
- the receiving module 40 is configured to receive a response request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message;
- the identification module 42 is configured to identify the MPLS OAM message by using the type field;
- the forwarding module 44 is configured to forward the response request message according to the preset forwarding entry.
- FIG. 5 is a structural block diagram of a detection system for a multi-protocol exchange label according to an embodiment of the present invention. As shown in FIG. 5, the system includes: an Initiator initial node 50, a Transit transmission node 52, or an Egress exit node 52.
- the initial node 50 also includes:
- the sending module 502 is configured to send a response request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message;
- the detecting module 504 is configured to receive an echo response message fed back by the transit node or the egress node according to the MPLS OAM packet, and detect whether the response response packet matches the prestored information.
- Transfer node 52 or egress node 52 also includes:
- the receiving module 522 is configured to receive a response request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message;
- the identification module 524 is configured to identify the MPLS OAM message by using the type field;
- the forwarding module 526 is configured to forward the response request message to the control plane according to the preset forwarding entry, and feed back the response response message of the response request message.
- each of the above modules may be implemented by software or hardware.
- the foregoing may be implemented by, but not limited to, the foregoing modules are all located in the same processor; or, the above modules are in any combination.
- the forms are located in different processors.
- the Initiator node When sending an echo request message, the Initiator node sets a type field in the encapsulated data link layer header to indicate that it is an MPLS OAM packet.
- the Downstream Mapping TLV (Type Length Value) contained in the echo request always corresponds to the next hop to be sent.
- the initiator When the initiator sends the first echo request, it needs to save the corresponding next hop's Downstream Mapping information, so that it can be used to match the subsequent echo reply. In the case of a non-first echo request, the Initiator saves the Downstream Mapping information copied in the previous round of echo reply.
- the Downstream Mapping contained in the echo request sent by the Initiator always corresponds to the next hop to be sent, regardless of the subsequent echo reply.
- the data plane of the transit node or the egress node is forwarded through the data link layer header to identify the MPLS OAM packet (that is, the echo request packet), and then forwards the packet according to the forwarding entry consistent with the data packet forwarding. :1) If the control plane is sent, the control plane will process the echo reply to the Initiator node as a Responder node; 2) If the data plane continues to forward to the next hop, the data is directly in the data according to the MPLS OAM message. After the MPLS OAM packet is modified, the MPLS OAM packet is modified. If the Downstream Mapping TLV content is modified in the echo request, the Downstream Mapping TLV included in the echo request only corresponds to the next hop to be sent. Continue to set in the data link layer header. Type field to indicate as an MPLS OAM message. Note that if it is a normal data packet, there is no such step, which avoids affecting the forwarding efficiency of ordinary data packets.
- the Initiator node After receiving the echo reply of the Responde node, the Initiator node first matches the corresponding field in the Sequence Number and the echo request according to the Sender's Handle in the echo reply, and then matches the Upstream Interface TLV in the echo reply with the locally saved Downstream Mapping information to determine Whether all the locally saved Downstream mapping information has the corresponding echo reply matching, and the next echo request is sent.
- the default policy is that all locally saved Downstream mapping information has the corresponding echo reply matching before sending the next echo request.
- a policy can also be adopted to send the next echo request, or other policy, as long as the locally saved Downstream Mapping information matches the success ratio greater than a certain threshold.
- the Initiator obtains the Downstream Mapping information from the matched echo reply and saves it for matching with the next round of echo reply before sending the next round of the echo request.
- FIG. 6 is a format diagram of an LSP ping echo request/reply message according to an embodiment of the present invention, which is basically the same as rfc4379 except that a new flag is added to the Global Flags:
- C (Constant) flag used in the echo request message, set to 1 indicates that the target FEC stack remains unchanged during the detection process, and FEC change is not supported. For example, if a packet enters a tunnel that is outside, it is forced to process the outer tunnel according to the PIPE type. Otherwise, it is necessary to distinguish that the outer tunnel is UNIFORM or PIPE for differentiation. For example, if the packet enters another blocked LSP or the current tunnel is terminated, the target FEC stack is also not changed. The C flag defaults to 0. The LSP ping command design needs to introduce corresponding parameters for setting the C. Sign.
- FIG. 7 is a format diagram of a Downstream Mapping TLV according to an embodiment of the present invention, in which a field related to multipath information of a Downstream Mapping TLV in rfc4379 is deleted, and the reserved field is basically the same as rfc4379 except:
- E flag Set to 1 to indicate that the next hop corresponding to the Downstream Mapping TLV is an ECMP member. Used in echo reply.
- M flag Set to 1 to indicate that the next hop corresponding to the Downstream Mapping TLV is a multicast member. Used in echo reply.
- the R flag is set to 1 to indicate that the next hop corresponding to the Downstream Mapping TLV is indirectly connected. Used in echo request/reply.
- Downstream Labels refers only to the labels corresponding to each FEC in the target FEC stack, and does not include other outer labels.
- FIG. 8 is a format diagram of an Upstream Interface TLV according to an embodiment of the present invention, in which a field related to tag information in an Interface and Label Stack TLV in rfc4379 is deleted, and the reserved field has the same definition as rfc4379.
- FIG. 9 is a format diagram of a Responder Egress TLV according to an embodiment of the present invention
- FIG. 10 is a format diagram of a Responder Transit TLV according to an embodiment of the present invention.
- the Egress and Transit nodes may include their own address when replying to an Initiator node with an echo reply. Information so that the Initiator node evaluates whether an echo reply has been received from the desired node.
- This embodiment also uses the Target FEC Stack TLV defined in rfc4379, which has not been modified.
- FIG. 11 is a flowchart of an Initiator node sending an echo request message according to an embodiment of the present invention, including
- Step S601 the Initiator node initiates an LSP ping or LSP for a target FEC.
- the traceroute process constructs an echo request message.
- Step S602 the Initiator node constructs an echo request PDU (Protocol Data Unit) as follows:
- TimeStamp Sent field is set to the relative time of day, seconds and microseconds.
- the Reply Mode is set to the desired mode, indicating that the echo reply is expected to be returned to the Initiator node along IP or some other way. Return Code and Subcode are set to 0.
- the Downstream Mapping TLV is included, corresponding to the next hop to be sent.
- the DS Flags are marked with an I, indicating that the responder node wants to include the Upstream Interface TLV when replying to the echo reply.
- the next hop here refers to the next hop on the Initiator node to the top-level target FEC in the target FEC stack.
- the C flag is invalid, when the Initiator node finds that the forwarding entry to the top-level target FEC is to enter the outer PIPE tunnel, it refers to the far-end next hop before the iterative tunnel iteration.
- DS Flags The R flag is set to be valid; if it is to enter the outer UNIFORM type tunnel, it means the next hop after the iterative tunnel iteration. At this time, the R flag in the DS Flags is set to be invalid. In this case, the Initiator can be at the target FEC. The top layer of the stack continues to insert the FEC of the UNIFORM tunnel. When the C flag is valid, when the Initiator node finds that the forwarding entry to the top-level target FEC enters the outer-layer tunnel, it does not distinguish between PIPE or UNIFORM, which refers to the far-end next hop before the iterative tunnel iteration. The R flag in Flags is set to be valid.
- step S603 the Initiator node constructs an IP/UDP header as follows:
- the source IP is a routable IP address of the sender.
- the destination IP is randomly selected from 127/8, or randomly selected from 0:0:0:0:0:FFFF:127/104
- Source PORT is selected by the sender
- Step S604 the Initiator node encapsulates the label stack for the echo request message, and includes the label corresponding to the target FEC stack and any possible outer layer tunnel labels.
- the Initiator node encapsulates the data link layer for the echo request packet, and sets the type field (such as setting the ethernet type to a specific value when the Ethernet link is used) to indicate that it is an MPLS OAM packet.
- step S606 the Initiator node maintains the target responder identifiers, indicating which echo replys are expected to be received by the node, as one of the basis for determining whether the detection is completed.
- step S607 the Initiator node determines whether it is the first round of echo request.
- step S608 if it is the first round of the echo request, the Downstream Mapping information corresponding to the next hop to be sent by the first round of the echo request is saved, and is used to accurately match the next round of echo reply.
- the P2P LSP refers to the next hop of the top-level target FEC on the Initiator node to the target FEC stack. If multiple next hops form ECMP, the echo request will only be sent to one of the next hops, so the Initiator only needs to save. Downstream mapping information corresponding to this next hop, where DS Flags is marked with E. In step 602, the next hop here is determined based on the C flag and whether the PIPE/UNIFORM type of the outer tunnel is entered.
- the P2MP LSP is the Downstream mapping information corresponding to each multicast member in the multicast forwarding entry of the Initiator node to the target FEC.
- the Initiator needs to save multiple Downstream mapping information, in which DS Flags are marked with M.
- step S609 if it is not the first round of echo request, the Downstream Mapping information obtained from the previous round of matching echo replys is saved, and is used to accurately match the next round of echo reply.
- the last round of echo replys refers to the echo replys that match the echo request in the previous round of the echo request/reply process.
- the Upstream Interface TLVs contained in these echo replys indicate that they are the Downstream Mapping information saved by the Initiator node at the time. For the matching, see the process of receiving the echo reply message by the Initiator node below.
- the P2P LSP refers to the next hop corresponding to the target FEC (recorded as First Transit FEC) of the target FEC stack from the top to the bottom of the target FEC stack. If there are multiple ECMPs in the next hop, the echo reply There are multiple Downstream Mapping TLVs, and the DS Flags are marked with the E flag.
- the Initiator needs to save multiple Downstream Mapping information. In particular, when the Responder node finds that the forwarding entry to the First Transit FEC is to enter the outer tunnel, it also needs to determine the next hop along with the PI flag and the PIPE/UNIFORM type entering the outer tunnel, and step 602 above. The processing of the Initiator node is similar.
- the C flag in the DS Flags is set to be valid; if it is to enter the outer UNIFORM type tunnel, it means the next hop after the iterative tunnel iteration, and the R flag in the DS Flags is set to be invalid. .
- the C flag is valid, when the Initiator node finds that the forwarding entry to the top-level target FEC enters the outer-layer tunnel, it does not distinguish between PIPE or UNIFORM, which refers to the far-end next hop before the iterative tunnel iteration.
- the R flag in Flags is set to be valid. If the First Transit FEC does not exist, the echo reply does not need to include the Downstream Mapping TLV.
- the P2MP LSP is the Downstream Mapping information corresponding to each multicast member in the multicast forwarding entry of the destination FEC on the Responder node.
- the echo reply contains multiple Downstream Mapping TLVs, and the DS Flags are marked with the M flag.
- the Initiator needs to save multiple Downstream Mapping information.
- step S610 the Initiator starts a timer and waits for an echo reply.
- FIG. 12 is a flowchart of receiving an echo request message by a transit or egress node according to an embodiment of the present invention, including:
- step S701 the Transit or Egress node receives the echo request.
- step S702 the data plane first obtains an MPLS OAM packet according to the type field of the data link layer header for subsequent processing.
- the mpls echo request message is sent to the control plane:
- step S703 the data plane determines whether it needs to be sent to the control plane.
- Step S704 if the data plane needs to send the echo request message to the control plane.
- the Downstream Mapping TLV contains only the labels corresponding to the FEC in the target FEC stack. Therefore, the label layer corresponding to the FEC in the target FEC stack included in the Downstream Mapping TLV needs to be in the label stack from the bottom to the top. Get the label of the corresponding layer for consistency check with the target FEC stack.
- first check the top layer FEC if the top layer If the FEC indicates that the Egress node is reached, it will continue to check the next layer of FEC (forwarding equivalence class), otherwise the next layer of FEC will not be checked.
- step S705 it is determined whether the above check is successful.
- step S706 the check result is successful.
- the Responder node When the Responder node is Transit, it can also include Downstream Mapping TLVs in the ehco reply according to the echo request including the Downstream Mapping TLV, and put the E/M/R flag as needed.
- the P2P LSP refers to the next hop of the First Transit FEC on the Responder node to the target FEC stack.
- the next hop here is determined according to whether the C flag is entered into the PIPE/UNIFORM type of the outer tunnel. That is, when the C flag is invalid, when the Responder node finds that the forwarding entry to the First Transit FEC is to enter the outer PIPE tunnel, it refers to the far-end next hop before the iterative tunnel iteration, at this time in the DS Flags.
- the R flag is set to be valid; to enter the outer UNIFORM type tunnel, it means the next hop after the iterative tunnel iteration, and the R flag in DS Flags is set to invalid.
- the C flag is valid, when the Initiator node finds that the forwarding entry to the top-level target FEC enters the outer-layer tunnel, it does not distinguish between PIPE or UNIFORM, which refers to the far-end next hop before the iterative tunnel iteration.
- the R flag in Flags is set to be valid. If there are multiple ECMPs in the next hop, the echo reply will contain multiple Downstream Mapping TLVs, and the DS Flags will be marked with E.
- the P2MP LSP is the Downstream Mapping information corresponding to each multicast member in the multicast forwarding entry of the destination FEC on the Responder node.
- the echo reply contains multiple Downstream Mapping TLVs, and the DS Flags are marked with the M flag.
- step S707 the result of the check is a failure.
- Step S708 If the data plane does not need to send the echo request packet to the control plane, check whether the packet is quickly obtained as an MPLS OAM packet.
- step S709 if it is not an MPLS OAM packet, the data plane immediately forwards the packet according to the normal data packet.
- step S710 if it is an MPLS OAM packet, the data plane modifies the content of the packet before sending the packet.
- the level of support for the modification Generally, the simplest is to modify the field, that is, the size of the message is not changed, only the value of some of the fields is changed, and the more complicated modification is to change the size of the message.
- the simple modification may be to modify the Downstream Mapping TLV in the echo request according to the next hop to which the packet is sent.
- the complicated modification may be to modify the target FEC stack.
- the message can be modified according to the C flag carried in the echo request message.
- the target FEC stack TLV is not modified, and only the Downstream Mapping TLV is modified. Specifically, the P2P LSP is changed to the Downstream Mapping information corresponding to the next hop of the forwarding entry corresponding to the First Transit FEC. If the forwarding entry has multiple next hops to form ECMP, only one of them will be forwarded during actual forwarding.
- the Downstream Mapping TLV is modified based on the next hop in the pick. As the C flag is valid, when the next hop in the selection needs to continue to iterate over the outer layer tunnel, the outer tunnel is uniformly processed according to the PIPE type, that is, the next hop information in the modified Downstream Mapping TLV is the tunnel.
- the far-end next hop before iteration is actually the original next hop of the forwarding entry corresponding to the First Transit FEC, and the R flag in the DS Flags is set to 1. If it is not necessary to iterate over the outer tunnel, the R flag in DS Flags is set to zero.
- the P2MP LSP is changed to the Downstream mapping information corresponding to each multicast member in the multicast forwarding entry corresponding to the target FEC, that is, when each echo request is sent to each multicast member, the echo request is modified in each echo request.
- the next hop information in the Downstream Mapping TLV is the next hop of the corresponding multicast member.
- both the target FEC stack TLV and the Downstream Mapping TLV are modified. Specifically, in the case of a P2P LSP, if a target FEC stack occurs on the node Change, including FEC POP and PUSH, directly modify the target FEC stack TLV. In addition, the Downstream Mapping TLV is changed to the Downstream Mapping information of the next hop of the forwarding entry corresponding to the First Transit FEC. If the forwarding entry has multiple next hops to form ECMP, only one of them will be forwarded during the actual forwarding. Downstream Mapping The TLV is modified based on the next hop in the pick.
- the next hop information in the modified Downstream Mapping TLV is the far-end next hop before the tunnel iteration, because the C-flag is invalid, and the next hop in the selection needs to continue to iterate over the outer-layer PIPE tunnel.
- the R flag in the DS Flags is set to 1.
- the next hop information in the modified Downstream Mapping TLV is the next hop after the tunnel iteration, and the R flag in the DS Flags is set. 0. If it is not necessary to iterate over the outer tunnel, the R flag in DS Flags is set to zero.
- the P2MP LSP When the P2MP LSP is changed to the Downstream mapping information corresponding to each multicast member in the multicast forwarding entry corresponding to the target FEC, that is, when each echo request is sent to each multicast member, the echo request is modified in each echo request.
- the next hop information in the Downstream Mapping TLV is the next hop of the corresponding multicast member.
- the node finds that the R flag in the Downstream Mapping TLV is valid, it needs to compare whether the far-end next hop specified in the Downstream Mapping TLV is itself. Only you need to modify the Downstream according to the above process. Mapping TLV, otherwise it will not be modified.
- FIG. 13 is a flowchart of a send reply message sent by a Responder node according to an embodiment of the present invention, including:
- Step S801 The Transit or Egress node replies an echo reply as a responder node according to the processing result after the received echo request is sent to the control plane.
- Step S802 constructing an Echo reply PDU as follows:
- TimeStamp Received field is set to the relative time of day, seconds and microseconds.
- the target FEC Stack TLV can be copied from the request message.
- the Responder node When the Responder node is Transit, it can also include Downstream Mapping TLVs and mark the E/M/R as needed.
- the next hop of the Downstream Mapping TLVs is determined according to whether the C flag is entered into the PIPE/UNIFORM type of the outer tunnel, and is not described here.
- IP/UDP is constructed as follows:
- the source IP is a routable IP address on the Responder side.
- the destination IP copies the source IP from the request message or from the Reply-to TLV.
- Source PORT is 3503
- Router Alert option If the request indicates that the reply mode is "Reply via an IPv4 UDP packet with Router Alert", the Router Alert option must be included. If the LSP is returned, the top label is Router Alert label (1).
- Step S804 the corresponding data link layer is normally encapsulated and then forwarded.
- FIG. 14 is a flowchart of receiving an echo reply message by an Initiator node according to an embodiment of the present invention, including:
- step S901 the Initiator node receives the echo reply message.
- step S902 the Initiator obtains the Sender's Handle and the Sequence Number in the echo reply message, and matches the Sender's Handle and the Sequence Number corresponding to the locally saved echo request.
- step S903 it is checked whether the echo reply matches the echo request.
- step S904 if there is no match, the echo reply is discarded.
- step S905 if it matches, the Upstream Interface TLV in the echo reply message is continuously obtained in the traceroute mode, and the locally saved Downstream Mapping information is matched. Check whether all Downstream mapping information saved locally has a corresponding echo reply. Multiple Downstream Mappings with the E flag only need to match one of them; all those with the M flag need to match. When the mode is ping, no match is made, and the match is always considered successful.
- Step S906 waiting for the timer for waiting to receive the echo reply to time out.
- Step S907 after the timer expires, it is checked whether it is the ping mode.
- Step S908 if it is the ping mode, the entire detection process ends, and the detection result is reported, such as which nodes replied to the echo reply, whether the desired reply node has replied, and the like.
- the Initiator can turn on the next round of duplicate detection as needed.
- step S909 if it is in the traceroute mode, it continues to check whether the locally saved Downstream Mapping information is all matched, or only partially matched but meets the matching pass policy, for example, the matched Downstream Mapping ratio exceeds a certain threshold.
- the matched Downstream Mapping ratio exceeds a certain threshold.
- multiple Downstream Mapping entries marked with the E flag may be saved locally. If one of these entries matches the echo reply, they are considered to be matched.
- multiple Downstream Mapping entries marked with the M flag may be saved locally. These entries need to be matched separately and with different echo responses.
- step S910 if the locally saved Downstream Mapping matches, the node that wants to reply to the echo reply continues to check whether the echo reply is replied.
- Step S911 if some of the desired nodes do not reply to the echo reply, continue to check whether all the echo reply contains any Downstream Mapping TLV.
- Step S912 Delete all the Downstream mapping information that is saved locally, and obtain new Downstream Mapping information from all the echo replys, and save locally for matching with the next round of echo reply.
- Send the next round of echo request label TTL increased by 1.
- Sender's Handle is unchanged and the Sequence Number is incremented by 1.
- FIG. 15 is a network topology diagram according to the first embodiment of the present invention.
- A is established as an ingress node to an LDP LSP whose egress node is H, and on the transit node B.
- the LDP LSP has ECMP.
- One of the next hops is the remote next hop D and the LDP over TE is formed.
- the path from the tunnel head node to the tunnel destination node is BCD, and the next hop of the LDP LSP on the B node. Is E.
- the LSP traceroute LDP FEC H is initiated at the node A, and the parameter Constant is set to be valid.
- the detection process includes the following steps. For the sake of brevity, only the main processes related to this patent are described:
- the first round of echo request message is constructed on the A node, and the Echo request PDU is set:
- Target FEC stack TLV ⁇ LDP FEC H ⁇
- the label value is valid, the corresponding ILM exists, and the label operation is SWAP.
- the next hop information in the Donstream Mapping TLV matches the incoming interface of the packet; check the label of the packet.
- the stack is consistent with the target FEC stack.
- Node B replies with an echo reply message including:
- C flag is valid, the Downstream Mapping TLV is filled in according to the next hop before the tunnel iteration.
- Node A obtains the new Downstream Address information from the echo reply and saves it locally as:
- the included Downstream Mapping TLV is the same as in step S1001.
- the B node quickly determines that the MPLS OAM packet is based on the type field of the data link layer, and the C flag in the echo request is 1 and the next hop in the Downstream Mapping TLV before the modification in the echo request is B.
- the LDP Label TTL is decremented by 1, and the TE Label TTL is set to 255.
- the data link layer type field is set to indicate that it is an MPLS OAM packet. Forward the message.
- the C node quickly determines that it is an MPLS OAM packet according to the type field of the data link layer. However, if the next hop of the Downstream Mapping TLV before the modification in the echo request is not C, and the R flag is valid, C knows that it is somewhere else. In the layer tunnel, there is no modification to the Downstream Mapping TLV. Only the TE Label TTL is decremented by 1. The data link layer type field is set to indicate that it is an MPLS OAM packet. Forward the message.
- the check indicates that the tag value is valid, the corresponding ILM exists, and the tag operation is SWAP.
- the next hop information in the Donstream Mapping TLV is found to match the incoming interface of the packet. Check that the label stack of the packet is consistent with the target FEC stack.
- the D node replies with an echo reply message, including:
- the R flag is valid, it only matches the Router-id. Because the E flag of Downstream Mapping entry 2 is valid, it is considered to have passed the match.
- Node A obtains the new Downstream Address information from the echo reply and saves it locally as:
- the included Downstream Mapping TLV is the same as in step S1001.
- the B-node receives the echo request packet.
- step S1004 the Downstream Mapping TLV of the packet is modified and then forwarded.
- the control plane check that the label value is valid, the corresponding ILM exists, and the label operation is POP.
- the stack is consistent with the target FEC stack.
- the H node replies with an echo reply message, including:
- Node A cannot obtain new Downstream Address information from the echo reply. Detection After the test result is output, the echo reply of the Egress node H is received.
- Example 16 is a network topology diagram according to Example 2 of the present invention. This embodiment is basically the same as Example 1. The difference is that the parameter Constant is invalid when the A node initiates the LSP traceroute LDP FEC H.
- the detection process includes the following steps:
- the first round of echo request message is constructed on the A node, and the Echo request PDU is set:
- Target FEC stack TLV ⁇ LDP FEC H ⁇
- the label value is valid, the corresponding ILM exists, and the label operation is SWAP.
- the next hop information in the Donstream Mapping TLV matches the incoming interface of the packet; check the label of the packet.
- the stack is consistent with the target FEC stack.
- Node B replies with an echo reply message including:
- C flag is invalid, the Downstream Mapping TLV is filled in according to the next hop after the tunnel iteration.
- Node A obtains the new Downstream Address information from the echo reply and saves it locally as:
- the included Downstream Mapping TLV is the same as in step S1101.
- the B-node receives the echo request packet because the LDP Label TTL of the label on the top of the label stack is 2, and the transit node of the LDP LSP does not cause the control plane to be sent.
- the B node quickly determines that the MPLS OAM packet is based on the type field of the data link layer, and the C flag in the echo request is 0, and the next hop in the Downstream Mapping TLV before the modification in the echo request is B.
- the actual LDP over TE is sent to the remote next hop D.
- the next hop of the tunnel is the Downstream of the packet.
- the LDP Label TTL is decremented by 1, and the TE Label TTL is copied from the LDP Label TTL.
- the data link layer type field is set to indicate that it is an MPLS OAM packet. Forward the message.
- On the control plane check that the label value is valid, the corresponding ILM exists, and the label operation is SWAP.
- the stack is consistent with the target FEC stack.
- the C node replies with an echo reply message, including:
- Node A obtains the new Downstream Address information from the echo reply and saves it locally as:
- the included Downstream Mapping TLV is the same as in step S1101.
- the node B receives the echo request packet.
- step S1104 the target FEC stack TLV and the Downstream Mapping TLV of the packet are modified and then forwarded.
- the C node quickly determines that the MPLS OAM packet is based on the type field of the data link layer, and then the C flag in the echo request is 0, and the next hop in the Downstream Mapping TLV before the modification in the echo request is C.
- the D-node receives the echo request packet, and the TE label is ejected or terminated in advance.
- the TE Label TTL is inherited to the LDP Label TTL.
- the stack is consistent with the target FEC stack.
- the D node replies with an echo reply message, including:
- Node A obtains the new Downstream Address information from the echo reply and saves it locally as:
- the included Downstream Mapping TLV is the same as in step S1101.
- the B-node receives the echo request packet.
- the LDP Label TTL of the label on the top of the label stack is 4, and the transit node of the LDP LSP does not cause the control plane to be sent.
- step S1104 the target FEC stack TLV and the Downstream Mapping TLV of the packet are modified and then forwarded.
- the Downstream Mapping TLV of the packet is modified. If the penultimate hop popup occurs, you need to modify the target FEC stack TLV of the packet to be ⁇ LDP FEC H ⁇ , otherwise it will not be modified.
- the D-node receives the echo request packet, and the TE label is ejected or terminated in advance.
- the TE Label TTL is inherited to the LDP Label TTL.
- the D node quickly determines that the MPLS OAM packet is based on the type field of the data link layer, and then the C flag in the echo request is 0, and the next hop in the Downstream Mapping TLV before the modification in the echo request is D.
- the control plane check that the label value is valid, the corresponding ILM exists, and the label operation is POP.
- the stack is consistent with the target FEC stack.
- the H node replies with an echo reply message, including:
- Node A cannot obtain new Downstream Address information from the echo reply. After the detection is completed, the detection result is output, and the echo reply of the Egress node H is received.
- FIG. 17 is a network topology diagram of the example 3 according to the present invention. As shown in FIG. 17, the multicast distribution tree with the R node as the root node establishes an mLDP LSP whose FEC is opaqueX.
- the detection process includes the following steps. For the sake of brevity, only the main processes related to this patent are described:
- the first round of echo request packets is constructed on the R node, and the echo request is sent to the multicast member next hop A and the multicast member next hop B respectively.
- Target FEC stack TLV ⁇ mLDP FEC opaqueX ⁇
- Target FEC stack TLV ⁇ mLDP FEC opaqueX ⁇
- the label value is valid, the corresponding ILM exists, and the label operation is SWAP.
- the next hop information in the Donstream Mapping TLV matches the incoming interface of the packet; check the label of the packet.
- the stack is consistent with the target FEC stack.
- the A node replies with an echo reply message, including:
- the Node B receives the echo request packet and replies to the echo reply packet, including:
- the R node obtains the new Downstream Address information from the echo reply of A and saves it locally as:
- the R node obtains the new Downstream Address information from the echo reply of B and saves it locally as:
- the included Downstream Mapping TLV is the same as in step S1201.
- the A node quickly determines that the MPLS OAM packet is based on the type field of the data link layer. If the next hop in the Downstream Mapping TLV before the modification is A, the node sends an echo to the multicast member next hop C.
- the LDP Label TTL is decremented by 1, and the data link layer type field is set to indicate that it is an MPLS OAM packet. Forward the message.
- the label value is valid, the corresponding ILM exists, and the label operation is SWAP.
- the next hop information in the Donstream Mapping TLV matches the incoming interface of the packet; check the label of the packet.
- the stack is consistent with the target FEC stack.
- the C node replies with an echo reply message, including:
- the D node receives the echo request packet and replies to the echo reply packet, including:
- the E-node receives the echo request packet and replies to the echo reply packet, including:
- the F node receives the echo request packet and replies to the echo reply packet, including:
- the R node obtains the new Downstream Address information from the echo reply of C and saves it locally as:
- the R node obtains the new Downstream Address information from the echo reply of F and saves it locally as:
- the included Downstream Mapping TLV is the same as in step S1201.
- the A and B nodes respectively modify the Downstream Mapping TLV in the echo request packet sent to the next hop of the specific multicast member, and then forward the packet.
- the C and F nodes respectively modify the Downstream Mapping TLV in the echo request message sent to the next hop of the specific multicast member, and then forward the packet.
- the E node will reply the echo reply to the R node again, but the R node will not match its locally saved Downstream Mapping entry, and these echo reply will be discarded.
- the G node replies with an echo reply message, including:
- the H node receives the echo request message and replies to the echo reply message, including:
- the I node receives the echo request packet and replies to the echo reply packet, including:
- the J node receives the echo request message and replies to the echo reply message, including:
- the R node receives the echo reply from G, H, I, and J, respectively, and matches the locally saved Downstream Mapping entries 1 to 4.
- the R node cannot obtain new Downstream Address information from the echo reply. After the detection is completed, the detection result is output, and the echo reply of the Egress node D, E, G, H, I, J is received.
- Embodiments of the present invention also provide a storage medium.
- the foregoing storage medium may be configured to store program code for performing the following steps:
- the detecting initiator sends an echo request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message;
- the receiving transmission node or the egress node responds to the response message according to the MPLS OAM packet, and detects whether the response response message matches the pre-stored information.
- the foregoing storage medium may include, but not limited to, a USB flash drive, a Read-Only Memory (ROM), a Random Access Memory (RAM), a mobile hard disk, and a magnetic memory.
- ROM Read-Only Memory
- RAM Random Access Memory
- a mobile hard disk e.g., a hard disk
- magnetic memory e.g., a hard disk
- the processor executes according to the stored program code in the storage medium.
- the line detection initiator sends a response request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message;
- the processor performs, according to the stored program code in the storage medium, the response response message that is received by the transmitting node or the egress node according to the MPLS OAM packet, and detects whether the response response message and the pre-stored information are match.
- modules or steps of the present invention described above can be implemented by a general-purpose computing device that can be centralized on a single computing device or distributed across a network of multiple computing devices. Alternatively, they may be implemented by program code executable by the computing device such that they may be stored in the storage device by the computing device and, in some cases, may be different from the order herein.
- the steps shown or described are performed, or they are separately fabricated into individual integrated circuit modules, or a plurality of modules or steps thereof are fabricated as a single integrated circuit module.
- the invention is not limited to any specific combination of hardware and software.
- the method, device, and system for detecting and processing a multi-protocol exchange label provided by the embodiment have the following beneficial effects: the MPLS operation and maintenance management for identifying the multi-protocol exchange label is carried in the response request message.
- the type field of the OAM packet is such that the forwarding plane of the transmitting node modifies the packet according to the actual forwarding information and the corresponding set of detection processing flow. Therefore, the LSP detection distortion and the P2MP LSP detection inefficient and insufficient in the related art can be solved. problem.
Landscapes
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
Description
本发明实施例涉及通信领域,具体而言,涉及一种多协议交换标签的检测、处理方法、装置及系统。The embodiments of the present invention relate to the field of communications, and in particular, to a method, a device, and a system for detecting and processing a multi-protocol exchange tag.
相关技术中,P2P(peer to peer)LSP ping/trace与P2MP(peer to multiple peer)LSP ping/trace通过将多协议交换标签(Multi-protocol Label Switching,简称为MPLS)运行、管理和维护(Operation Administration and Maintenance,简称为OAM)报文按与MPLS数据报文转发一致的路径传输,数据平面不识别是MPLS OAM报文,当报文因标签生存时间(Time To Live,简称为TTL)超时或到达egress节点等原因从数据平面上送至控制平面时,才由控制平面识别是MPLS OAM报文并作后续处理。rfc4379(标记交换路径(Label Switching Path,简称为LSP)ping/trace)与rfc5884(MPLS BFD)都通过基于IP头的TTL=1与目的IP为127.0.0.0/8(IPv4)或0:0:0:0:0:FFFF:127.0.0.0/104(IPv6)这些标志来初步识别是MPLS OAM报文,以及rfc5586(MPLS g-ACH)通过GAL(特殊标签13)标志来识别是MPLS OAM报文,但是这些都不适合于不想对报文做深度解析来识别具体报文的数据平面,当这些标志在数据平面没有暴露,没有导致MPLS OAM报文从数据平面上送至控制平面时,则数据平面不知道它是一个MPLS OAM报文。In the related art, P2P (peer to peer) LSP ping/trace and P2MP (peer to multiple peer) LSP ping/trace are operated, managed, and maintained by using Multi-protocol Label Switching (MPLS). The Administration and Maintenance (OAM) packet is transmitted on the same path as the MPLS data packet. The data plane does not recognize the MPLS OAM packet. The packet expires due to the time-to-live (Time To Live, TTL for short). When the egress node is sent to the control plane from the data plane, the control plane identifies the MPLS OAM packet and performs subsequent processing. Rfc4379 (Label Switching Path (LSP) ping/trace) and rfc5884 (MPLS BFD) both pass the IP header based TTL=1 and the destination IP is 127.0.0.0/8 (IPv4) or 0:0: 0:0:0:FFFF:127.0.0.0/104 (IPv6) These flags are used to initially identify MPLS OAM packets, and rfc5586 (MPLS g-ACH) identifies MPLS OAM packets through the GAL (Special Label 13) flag. However, these are not suitable for the data plane that does not want to perform deep analysis on the packet to identify the specific packet. When these flags are not exposed on the data plane, and the MPLS OAM packet is not sent from the data plane to the control plane, the data is The plane does not know that it is an MPLS OAM message.
数据链路层虽然定义了类型字段识别是MPLS单播报文还是组播报文(rfc3032,rfc5332),但是并没有相应的标准定义识别是MPLS OAM报文还是MPLS数据报文,除了以太链路定义了ethernet type用于特定的以太OAM机制(如802.1ag,802.3ah,Y.1731)以外,但是这些定义不能适用于MPLS OAM。The data link layer defines whether the type field identifies whether it is an MPLS unicast packet or a multicast packet (rfc3032, rfc5332). However, there is no corresponding standard definition to identify whether it is an MPLS OAM packet or an MPLS data packet, except for the Ethernet link. The ethernet type is used for specific Ethernet OAM mechanisms (such as 802.1ag, 802.3ah, Y.1731), but these definitions cannot be applied to MPLS OAM.
一些场景下,数据平面也需要通过某种快捷的方式提前感知是MPLS OAM报文,在遵循与MPLS数据报文转发一致的前提下,做一些与转发路径无关的辅助处理。In some scenarios, the data plane also needs to be perceived in advance in a quick way to be MPLS. On the premise of consistent with the forwarding of MPLS data packets, OAM packets do some auxiliary processing that is independent of the forwarding path.
相关技术中的P2P LSP ping/trace标准存在如下问题:The P2P LSP ping/trace standard in the related art has the following problems:
1)按照rfc4379,检测的target FEC存在ECMP时,通过在控制平面模拟负荷分担划分multipath information为多个分片,然后基于划分结果发送多个echo request(分别包含不同的multipath information分片)以期望遍历出完整的路径。存在的关键问题是:a)控制平面的模拟负荷分担结果不一定与数据平面的实际负荷分担结果相同;b)原始的multipath information可能无法满足负荷分担的分片需求,即存在不够分的问题。这些都导致检测失真。实际上,LSP ping的本质需求是检测数据平面连通性以及保证数据平面与控制平面的转发表项一致,只要我们将MPLS OAM报文严格的按照数据平面的真实负荷分担转发即可。1) According to rfc4379, when there is ECMP in the detected target FEC, multipath information is divided into multiple fragments by simulating load sharing on the control plane, and then multiple echo requests (including different multipath information fragments respectively) are sent based on the division result to expect Traverse the complete path. The key problems are: a) the simulated load sharing result of the control plane is not necessarily the same as the actual load sharing result of the data plane; b) the original multipath information may not meet the fragmentation requirement of load sharing, that is, there is a problem of insufficient allocation. These all lead to detection distortion. In fact, the essential requirement of the LSP ping is to detect the data plane connectivity and ensure that the data plane is consistent with the forwarding entries of the control plane. As long as we MPLS OAM packets are strictly forwarded according to the real load of the data plane.
2)按照rfc6424,在检测过程中若发生FEC change,需要感知FEC change的节点向Initiator节点返回FEC change信息,以便Initiator在后续echo request中携带变化后的target FEC stack。但是该标准存在一个明显的缺陷是只适用于trace route模式,而ping模式时感知FEC change的节点是不会向Initiator节点返回FEC change信息,这意味着要只要发生了FEC change,执行LSP ping将会得到路径不通的结果。2) According to rfc6424, if an FEC change occurs during the detection process, the node that needs to perceive the FEC change returns the FEC change information to the Initiator node, so that the Initiator carries the changed target FEC stack in the subsequent echo request. However, there is an obvious flaw in the standard that is only applicable to the trace route mode. In the ping mode, the node that senses the FEC change will not return the FEC change information to the Initiator node, which means that as long as the FEC change occurs, the LSP ping will be performed. Will get the result of the path is not available.
相关技术中的P2MP LSP ping/trace标准存在如下检测低效与不充分的问题:The P2MP LSP ping/trace standard in the related art has the following problems of detecting inefficiency and insufficiency:
1)按照rfc6425,Initiator并没有精确控制echo reply报文是否收齐后发起下一次echo request,也就是说,发送下一次request的时机是不定的。如果Initiator每收到一个echo reply就发送下一个echo request,那么它需要缓存大量的历史echo request以便等待那些晚到的echo reply。1) According to rfc6425, the Initiator does not precisely control whether the echo reply message is received and then initiates the next echo request. That is to say, the timing of sending the next request is uncertain. If the Initiator sends the next echo request every time it receives an echo reply, it needs to cache a large number of historical echo requests in order to wait for those late echo requests.
2)由于echo request的发送没有严格控制,那么收到的echo reply可能会爆发而导致拥塞。虽然提出了解决方法,但是并不完美。比如,返回echo reply时随机延时的方法会拖慢检测过程;只让特定节点返回echo reply的方法则仅支持指定单个节点或指定至单个egress的沿路节点。2) Since the sending of the echo request is not strictly controlled, the received echo reply may burst and cause congestion. Although a solution has been proposed, it is not perfect. For example, a method that returns a random delay when echo reply will slow down the detection process; only a specific node will return echo. The reply method only supports specifying a single node or a route node assigned to a single egress.
3)由于echo request中包含的Downstream Detailed Mapping TLV中“Address Type”字段设置为IPv4Unnumbered或IPv6Unnumbered,“Downstream IP Address”字段设置为ALLROUTERS组播地址,则导致responder节点上无法做入接口一致性检查,无法严格检验控制平面与转发平面的转发信息是否一致。3) Because the "Address Type" field in the Downstream Detailed Mapping TLV included in the echo request is set to IPv4Unnumbered or IPv6Unnumbered, and the "Downstream IP Address" field is set to the ALLROUTERS multicast address, the interface consistency check cannot be performed on the responder node. It is impossible to strictly check whether the forwarding information of the control plane and the forwarding plane are consistent.
针对相关技术中存在的上述问题,目前尚未发现有效的解决方案。In view of the above problems in the related art, no effective solution has been found yet.
发明内容Summary of the invention
本发明实施例提供了一种多协议交换标签的检测、处理方法、装置及系统,以解决相关技术中LSP检测失真以及P2MP LSP检测低效与不充分的问题。The embodiments of the present invention provide a method, a device, and a system for detecting and processing a multi-protocol exchange label, so as to solve the problem that the LSP detection distortion and the P2MP LSP detection are inefficient and insufficient in the related art.
根据本发明的一个实施例,提供了一种多协议交换标签的检测方法,包括:检测发起方发送回应请求报文,其中,所述回应请求报文中包括用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;接收传输节点或出口节点根据所述MPLS OAM报文反馈的回应应答报文,并检测所述回应应答报文与预存信息是否匹配。According to an embodiment of the present invention, a method for detecting a multi-protocol switching label is provided, including: detecting an initiator sending an echo request packet, where the echo request packet includes an MPLS operation for identifying a multi-protocol switching label Maintaining the type field of the management OAM packet; receiving the response response message fed back by the transit node or the egress node according to the MPLS OAM packet, and detecting whether the response response packet matches the pre-stored information.
可选地,所述回应请求报文中还包括:下游映射信息,其中,所述下游映射信息对应于所述回应请求报文的一个或多个下一跳路由。Optionally, the response request message further includes: downstream mapping information, where the downstream mapping information corresponds to one or more next hop routes of the response request message.
可选地,检测发起方发送回应请求报文还包括:检测发起方判断所述回应请求报文是否为初始节点首次发送的回应请求报文;在判断结果为是的情况下,检测发起方在发送回应请求报文时,在所述初始节点本地保存所述回应请求报文中的下游映射信息。Optionally, the detecting the initiator sending the response request message further includes: detecting, by the initiator, whether the response request message is an initial response request message sent by the initial node; if the determination result is yes, detecting that the initiator is When the response request message is sent, the downstream mapping information in the response request message is locally saved in the initial node.
可选地,在判断结果为否的情况下,在发送回应请求报文时,检测发起方在所述初始节点本地保存上一轮回应应答报文中携带的下游映射信息。Optionally, in the case that the determination result is negative, when the response request message is sent, the detecting initiator locally saves the downstream mapping information carried in the last round of the response response message in the initial node.
可选地,所述类型字段封装在所述回应请求报文的数据链路层头中。 Optionally, the type field is encapsulated in a data link layer header of the response request message.
可选地,检测所述回应应答报文与预存信息是否匹配包括:检测所述回应应答报文中的发送方句柄Sender's Handle和所述回应请求报文中的第一相应字段是否匹配,以及检测所述回应应答报文中的序列号和所述回应请求报文中的第二相应字段是否匹配;在所述Sender's Handle与所述第一相应字段匹配,且所述序列号与所述第二相应字段匹配时,判断所述回应应答报文中的上游接口信息与所述初始节点本地保存的下游映射信息是否匹配,在所述回应应答报文中的上游接口信息与所述初始节点本地保存的下游映射信息匹配时,确定所述回应应答报文与预存信息匹配。Optionally, detecting whether the response response message matches the pre-stored information includes: detecting whether a sender handle Sender's Handle in the response response message matches a first corresponding field in the response request message, and detecting Whether the sequence number in the response response message matches the second corresponding field in the response request message; the Sender's Handle matches the first corresponding field, and the serial number and the second When the corresponding field matches, it is determined whether the upstream interface information in the response response message matches the downstream mapping information saved locally by the initial node, and the upstream interface information in the response response message is locally saved with the initial node. When the downstream mapping information matches, it is determined that the response response message matches the pre-stored information.
可选地,在本地保存多个下游映射信息时,判断所述回应应答报文中的上游接口信息与所述下游映射信息是否匹配包括:判断本地保存的所述多个下游映射信息是否都有对应的所述回应应答报文匹配;判断本地保存的所述多个下游映射信息与多个所述回应应答报文的匹配成功率是否大于预设阈值。Optionally, determining whether the upstream interface information in the response response packet matches the downstream mapping information, when determining that the plurality of downstream mapping information is locally saved, Corresponding to the response response message matching; determining whether the matching success rate of the plurality of downstream mapping information and the plurality of the response response messages saved locally is greater than a preset threshold.
可选地,在检测所述回应应答报文与预存信息是否匹配之后,所述方法还包括:根据所述回应应答报文与预存信息是否匹配的检测结果确定是否发送下一个回应请求报文。Optionally, after detecting whether the response response message matches the pre-stored information, the method further includes: determining, according to the detection result that the response response message matches the pre-stored information, whether to send the next response request message.
可选地,根据所述回应应答报文与预存信息是否匹配的检测结果确定是否发送下一个回应请求报文包括:检测所述回应请求报文的传输模式;在所述传输模式为因特网包探索器ping(Packet Internet Groper)模式时,放弃发送下一个回应请求报文;和/或,根据本地保存的下游映射信息是否满足匹配策略来确定是否发送下一个回应请求报文。Optionally, determining, according to the detection result that the response response message matches the pre-stored information, whether to send the next response request message includes: detecting a transmission mode of the response request message; and searching for the Internet packet in the transmission mode When the ping (Packet Internet Groper) mode is used, the next response request message is discarded; and/or, according to whether the locally saved downstream mapping information satisfies the matching policy, whether to send the next response request message is determined.
根据本发明的另一个实施例,提供了一种多协议交换标签的处理方法,包括:接收回应请求报文,其中,所述回应请求报文中包括用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;通过所述类型字段识别所述MPLS OAM报文;根据预设转发表项转发所述回应请求报文。According to another embodiment of the present invention, a method for processing a multi-protocol exchange label is provided, including: receiving an echo request message, where the response request message includes an MPLS operation maintenance management for identifying a multi-protocol exchange label. The type field of the OAM packet; the MPLS OAM packet is identified by the type field; and the response request packet is forwarded according to the preset forwarding entry.
可选地,由转发平面根据预设转发表项转发所述回应请求报文,包括以下之一:转发平面根据第一预设转发表项将所述回应请求报文转发至控 制平面,并反馈所述回应请求报文的回应应答报文;转发平面修改所述MPLS OAM报文的内容,并根据第二预设转发表项将所述回应请求报文转发至数据平面的下一跳节点。Optionally, the forwarding plane forwards the response request message according to the preset forwarding entry, and the forwarding plane forwards the response request message to the control according to the first preset forwarding entry. a plane, and feedback the response response message of the response request message; the forwarding plane modifies the content of the MPLS OAM message, and forwards the response request message to the data plane according to the second preset forwarding entry Next hop node.
可选地,转发平面修改所述MPLS OAM报文的内容包括:修改所述回应请求报文中的下游映射信息。Optionally, modifying, by the forwarding plane, the content of the MPLS OAM packet includes: modifying downlink mapping information in the response request packet.
根据本发明的另一个实施例,提供了一种多协议交换标签的检测装置,包括:发送模块,设置为发送回应请求报文,其中,所述回应请求报文中包括用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;检测模块,设置为接收传输节点或出口节点根据所述MPLS OAM报文反馈的回应应答报文,并检测所述回应应答报文与预存信息是否匹配。According to another embodiment of the present invention, a device for detecting a multi-protocol exchange label is provided, comprising: a sending module, configured to send an echo request message, wherein the response request message includes a multi-protocol exchange for identifying The labeling MPLS operation maintains and manages the type field of the OAM packet. The detecting module is configured to receive the response response message fed back by the transmitting node or the egress node according to the MPLS OAM packet, and detect whether the response response packet matches the pre-stored information. .
可选地,所述回应请求报文中还包括:下游映射信息,其中,所述下游映射信息对应于所述回应请求报文的一个或多个下一跳路由。Optionally, the response request message further includes: downstream mapping information, where the downstream mapping information corresponds to one or more next hop routes of the response request message.
根据本发明的另一个实施例,提供了一种多协议交换标签的处理装置,包括:接收模块,用于接收回应请求报文,其中,所述回应请求报文中包括用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;识别模块,设置为通过所述类型字段识别所述MPLS OAM报文;转发模块,设置为根据预设转发表项转发所述回应请求报文。According to another embodiment of the present invention, a processing apparatus for a multi-protocol exchange label is provided, including: a receiving module, configured to receive an echo request message, where the response request message includes a multi-protocol exchange for identifying The tag MPLS operation maintains the type field of the OAM message; the identification module is configured to identify the MPLS OAM message by using the type field, and the forwarding module is configured to forward the response request message according to the preset forwarding entry.
根据本发明的又一个实施例,提供了一种多协议交换标签的检测系统,包括初始节点、传输节点或出口节点,所述初始节点还包括:According to still another embodiment of the present invention, a detection system for a multi-protocol switching label is provided, including an initial node, a transit node, or an egress node, where the initial node further includes:
发送模块,设置为发送回应请求报文,其中,所述回应请求报文中包括用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;检测模块,设置为接收传输节点或出口节点根据所述MPLS OAM报文反馈的回应应答报文,并检测所述回应应答报文与预存信息是否匹配;传输节点或出口节点还包括:接收模块,设置为接收回应请求报文,其中,所述回应请求报文中包括用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;识别模块,设置为通过所述类型字段识别所述MPLS OAM报文;转发模块,设置为根据预设转发表项将所述回应请求 报文转发至控制平面,反馈所述回应请求报文的回应应答报文。The sending module is configured to send a response request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message; and the detecting module is configured to receive the transmission node or the egress node. And responding to the response message sent by the MPLS OAM packet, and detecting whether the response response message matches the pre-stored information; the transmitting node or the egress node further includes: a receiving module, configured to receive the response request message, where The response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message; the identification module is configured to identify the MPLS OAM packet by using the type field; and the forwarding module is set to be based on the pre- Let the forwarding entry be the response request The packet is forwarded to the control plane, and the response response message of the response request message is fed back.
根据本发明的又一个实施例,还提供了一种存储介质。该存储介质设置为存储用于执行以下步骤的程序代码:According to still another embodiment of the present invention, a storage medium is also provided. The storage medium is arranged to store program code for performing the following steps:
发送回应请求报文,其中,所述回应请求报文中包括用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;Sending a response request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message;
接收传输节点或出口节点根据所述MPLS OAM报文反馈的回应应答报文,并检测所述回应应答报文与预存信息是否匹配。The receiving transmission node or the egress node responds to the response message sent by the MPLS OAM packet, and detects whether the response response message matches the pre-stored information.
通过本发明实施例,发送回应请求报文,其中,所述回应请求报文中包括用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;接收传输节点或出口节点根据所述MPLS OAM报文反馈的回应应答报文,并检测所述回应应答报文与预存信息是否匹配。由于在回应请求报文中携带了用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段以便传输节点的转发平面根据实际转发信息自行修改报文,以及相应的一整套检测处理流程,因此,可以解决相关技术中LSP检测失真以及P2MP LSP检测低效与不充分的问题。According to the embodiment of the present invention, the response request message is sent, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message; the receiving transmission node or the egress node is according to the MPLS The OAM packet feedback response message is sent, and it is detected whether the response response message matches the pre-stored information. The response request message carries a type field for identifying the multi-protocol switching label MPLS operation and maintenance management OAM packet, so that the forwarding plane of the transport node modifies the packet according to the actual forwarding information, and a corresponding set of detection processing procedures. Therefore, the problem of LSP detection distortion and P2MP LSP detection inefficiency and insufficiency in the related art can be solved.
此处所说明的附图用来提供对本发明的进一步理解,构成本申请的一部分,本发明的示意性实施例及其说明用于解释本发明,并不构成对本发明的不当限定。在附图中:The drawings described herein are intended to provide a further understanding of the invention, and are intended to be a part of the invention. In the drawing:
图1是根据本发明实施例的多协议交换标签的检测方法的流程图;1 is a flowchart of a method for detecting a multi-protocol exchange tag according to an embodiment of the present invention;
图2是根据本发明实施例的多协议交换标签的处理方法的流程图;2 is a flowchart of a method for processing a multi-protocol exchange tag according to an embodiment of the present invention;
图3是根据本发明实施例的多协议交换标签的检测装置的结构框图;3 is a structural block diagram of a multi-protocol exchange tag detecting apparatus according to an embodiment of the present invention;
图4是根据本发明实施例的多协议交换标签的处理装置的结构框图;4 is a structural block diagram of a processing apparatus for a multi-protocol exchange tag according to an embodiment of the present invention;
图5是根据本发明实施例的多协议交换标签的检测系统的结构框图;5 is a structural block diagram of a detection system for a multi-protocol exchange tag according to an embodiment of the present invention;
图6是根据本发明具体实施方式的LSP ping echo request/reply消息格式图; 6 is a format diagram of an LSP ping echo request/reply message according to an embodiment of the present invention;
图7是根据本发明具体实施方式的Downstream Mapping TLV的格式图;7 is a format diagram of a Downstream Mapping TLV according to an embodiment of the present invention;
图8是根据本发明具体实施方式的Upstream Interface TLV的格式图;8 is a format diagram of an Upstream Interface TLV according to an embodiment of the present invention;
图9是根据本发明具体实施方式的Responder Egress TLV的格式图;9 is a format diagram of a Responder Egress TLV according to an embodiment of the present invention;
图10是根据本发明具体实施方式的Responder Transit TLV的格式图;10 is a format diagram of a Responder Transit TLV according to an embodiment of the present invention;
图11是根据本发明具体实施方式的Initiator节点发送echo request报文的流程图;11 is a flowchart of an Initiator node sending an echo request message according to an embodiment of the present invention;
图12是根据本发明具体实施方式的Transit或Egress节点接收echo request报文的流程图;12 is a flowchart of receiving an echo request message by a Transit or Egress node according to an embodiment of the present invention;
图13是根据本发明具体实施方式的Responder节点发送echo reply报文的流程图;13 is a flowchart of a send reply message sent by a Responder node according to an embodiment of the present invention;
图14是根据本发明具体实施方式的Initiator节点接收echo reply报文的流程图;14 is a flowchart of an Initiator node receiving an echo reply message according to an embodiment of the present invention;
图15是根据本发明示例1的网络拓扑图;Figure 15 is a network topology diagram according to Example 1 of the present invention;
图16是根据本发明示例2的网络拓扑图;16 is a network topology diagram according to Example 2 of the present invention;
图17是根据本发明示例3的网络拓扑图。Figure 17 is a network topology diagram in accordance with Example 3 of the present invention.
下文中将参考附图并结合实施例来详细说明本发明。需要说明的是,在不冲突的情况下,本申请中的实施例及实施例中的特征可以相互组合。The invention will be described in detail below with reference to the drawings in conjunction with the embodiments. It should be noted that the embodiments in the present application and the features in the embodiments may be combined with each other without conflict.
需要说明的是,本发明的说明书和权利要求书及上述附图中的术语“第一”、“第二”等是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。It is to be understood that the terms "first", "second" and the like in the specification and claims of the present invention are used to distinguish similar objects, and are not necessarily used to describe a particular order or order.
实施例1Example 1
在本实施例中提供了一种多协议交换标签的检测方法,图1是根据本发明实施例的多协议交换标签的检测方法的流程图,如图1所示,该流程 包括如下步骤:In this embodiment, a method for detecting a multi-protocol exchange label is provided. FIG. 1 is a flowchart of a method for detecting a multi-protocol exchange label according to an embodiment of the present invention. As shown in FIG. Including the following steps:
步骤S102,检测发起方发送回应请求报文,其中,回应请求报文中包括用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;Step S102: The initiating party sends an echo request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message.
步骤S104,接收传输节点或出口节点根据MPLS OAM报文反馈的回应应答报文,并检测回应应答报文与预存信息是否匹配。可选的,执行主体可以是检测发起方,或检测方(与检测发起方相同或不同)。Step S104: Receive an echo response message fed back by the transit node or the egress node according to the MPLS OAM packet, and detect whether the response response packet matches the prestored information. Optionally, the execution subject may be the detection initiator, or the detection party (same or different from the detection initiator).
通过上述步骤,发送回应请求报文,其中,回应请求报文中包括用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;接收传输节点或出口节点根据MPLS OAM报文反馈的回应应答报文,并检测回应应答报文与预存信息是否匹配。由于在回应请求报文中携带了用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段,以便传输节点的转发平面根据实际转发信息自行修改报文,以及相应的一整套检测处理流程,因此,可以解决相关技术中LSP检测失真以及P2MP LSP检测低效与不充分的问题。And the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM packet, and the receiving transmission node or the egress node responds according to the MPLS OAM packet feedback. The response message is sent, and it is detected whether the response response message matches the pre-stored message. The type field of the MPLS operation and maintenance management OAM packet for the multi-protocol exchange label is carried in the response request packet, so that the forwarding plane of the transmission node modifies the packet according to the actual forwarding information, and a corresponding set of detection processing flows. Therefore, the problem of LSP detection distortion and P2MP LSP detection inefficiency and insufficiency in the related art can be solved.
可选的,回应请求报文中还包括:下游映射信息,其中,下游映射信息对应于回应请求报文的一个或多个下一跳路由。Optionally, the response request message further includes: downstream mapping information, where the downstream mapping information corresponds to one or more next hop routes of the response request message.
具体的,检测发起方发送回应请求报文还包括:Specifically, the detecting initiator sends the response request message, which further includes:
S11,检测发起方判断回应请求报文是否为初始节点首次发送的回应请求报文;S11. The detecting initiator determines whether the response request message is an initial response request message sent by the initial node.
S12,在判断结果为是的情况下,在发送回应请求报文时,检测发起方在初始节点本地保存回应请求报文中的下游映射信息。在判断结果为否的情况下,检测发起方在发送回应请求报文时,在初始节点本地保存上一轮回应应答报文中携带的下游映射信息。S12. If the determination result is yes, when the response request message is sent, the initiator detects that the initiator maps the downstream mapping information in the response request message locally. If the result of the determination is negative, the detecting initiator locally saves the downstream mapping information carried in the last round of response response packets at the initial node when sending the response request message.
可选的,类型字段封装在回应请求报文的数据链路层头中。Optionally, the type field is encapsulated in the data link layer header of the response request message.
可选的,检测回应应答报文与预存信息是否匹配具体包括: Optionally, detecting whether the response response message matches the pre-stored information specifically includes:
S21,检测回应应答报文中的发送方句柄Sender's Handle和回应请求报文中的第一相应字段是否匹配,以及检测回应应答报文中的序列号和回应请求报文中的第二相应字段是否匹配;S21. Detect whether the sender corresponding handle Sender's Handle in the response response message matches the first corresponding field in the response request message, and detects whether the sequence number in the response response message and the second corresponding field in the response request message are match;
S22,在Sender's Handle与第一相应字段匹配,且序列号与第二相应字段匹配时,判断回应应答报文中的上游接口信息与初始节点本地保存的下游映射信息是否匹配,在回应应答报文中的上游接口信息与初始节点本地保存的下游映射信息匹配时,确定回应应答报文与预存信息匹配。S22: When the Sender's Handle matches the first corresponding field, and the sequence number matches the second corresponding field, determining whether the upstream interface information in the response response message matches the downstream mapping information saved locally by the initial node, and responding to the response message. When the upstream interface information matches the downstream mapping information saved locally by the initial node, it is determined that the response response message matches the pre-stored information.
可选的,在本地保存多个下游映射信息时,判断回应应答报文中的上游接口信息与下游映射信息是否匹配包括以下两种方式:Optionally, when the multiple downstream mapping information is saved locally, determining whether the upstream interface information in the response response packet matches the downstream mapping information includes the following two methods:
判断本地保存的多个下游映射信息是否都有对应的回应应答报文匹配;Determining whether multiple downstream mapping information saved locally has a corresponding response response message matching;
判断本地保存的多个下游映射信息与多个回应应答报文的匹配成功率是否大于预设阈值。It is determined whether the matching success rate of the multiple saved downstream mapping information and the multiple response response packets is greater than a preset threshold.
可选的,在检测回应应答报文与预存信息是否匹配之后,方法还包括:根据回应应答报文与预存信息是否匹配的检测结果确定是否发送下一个回应请求报文。进一步的,根据回应应答报文与预存信息是否匹配的检测结果确定是否发送下一个回应请求报文包括:检测回应请求报文的传输模式;在传输模式为因特网包探索器ping模式时,放弃发送下一个回应请求报文;和/或,根据本地保存的下游映射信息是否满足匹配策略来确定是否发送下一个回应请求报文。Optionally, after detecting whether the response response message matches the pre-stored information, the method further includes: determining, according to the detection result that the response response message matches the pre-stored information, whether to send the next response request message. Further, determining whether to send the next response request message according to the detection result that the response response message matches the pre-stored information includes: detecting a transmission mode of the response request message; and abandoning the transmission when the transmission mode is the Internet packet explorer ping mode The next response request message; and/or, determining whether to send the next response request message according to whether the locally saved downstream mapping information satisfies the matching policy.
在本实施例中提供了一种多协议交换标签的处理方法,与上述多协议交换标签的检测方法对应,可以应用在传输节点或出口节点中,图2是根据本发明实施例的多协议交换标签的处理方法的流程图,如图2所示,该流程包括如下步骤:In this embodiment, a method for processing a multi-protocol exchange label is provided, which is applicable to a transmission node or an egress node corresponding to the multi-protocol exchange label detection method, and FIG. 2 is a multi-protocol exchange according to an embodiment of the present invention. A flowchart of a method for processing a label, as shown in FIG. 2, the flow includes the following steps:
步骤S202,接收回应请求报文,其中,回应请求报文中包括用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;Step S202, receiving a response request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message;
步骤S204,通过类型字段识别MPLS OAM报文; Step S204: Identify an MPLS OAM packet by using a type field.
步骤S206,根据预设转发表项转发回应请求报文。Step S206: Forward the response request message according to the preset forwarding entry.
可选的,由转发平面根据预设转发表项转发回应请求报文,包括以下之一:Optionally, the forwarding plane forwards the response request message according to the preset forwarding entry, including one of the following:
转发平面根据第一预设转发表项将回应请求报文转发至控制平面,并反馈回应请求报文的回应应答报文;The forwarding plane forwards the response request message to the control plane according to the first preset forwarding entry, and feeds back the response response message of the response request message;
转发平面修改MPLS OAM报文的内容,并根据第二预设转发表项将回应请求报文转发至数据平面的下一跳节点。The forwarding plane modifies the content of the MPLS OAM packet, and forwards the response request packet to the next hop node of the data plane according to the second preset forwarding entry.
可选的,转发平面修改MPLS OAM报文的内容包括:转发平面修改回应请求报文中的下游映射信息。Optionally, the forwarding plane modifies the content of the MPLS OAM packet, including: the downstream mapping information in the forwarding plane modification response request packet.
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到根据上述实施例的方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端设备(可以是手机,计算机,服务器,或者网络设备等)执行本发明各个实施例的方法。Through the description of the above embodiments, those skilled in the art can clearly understand that the method according to the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course, by hardware, but in many cases, the former is A better implementation. Based on such understanding, the technical solution of the present invention, which is essential or contributes to the prior art, may be embodied in the form of a software product stored in a storage medium (such as ROM/RAM, disk, The optical disc includes a number of instructions for causing a terminal device (which may be a cell phone, a computer, a server, or a network device, etc.) to perform the methods of various embodiments of the present invention.
实施例2Example 2
在本实施例中还提供了一种多协议交换标签的检测装置,多协议交换标签的处理装置,多协议交换标签的检测系统,用于实现上述实施例及优选实施方式,已经进行过说明的不再赘述。如以下所使用的,术语“模块”可以实现预定功能的软件和/或硬件的组合。尽管以下实施例所描述的装置较佳地以软件来实现,但是硬件,或者软件和硬件的组合的实现也是可能并被构想的。In this embodiment, a multi-protocol exchange label detecting apparatus, a multi-protocol exchange label processing apparatus, and a multi-protocol exchange label detecting system are provided to implement the above embodiments and preferred embodiments, which have been described. No longer. As used below, the term "module" may implement a combination of software and/or hardware of a predetermined function. Although the apparatus described in the following embodiments is preferably implemented in software, hardware, or a combination of software and hardware, is also possible and contemplated.
图3是根据本发明实施例的多协议交换标签的检测装置的结构框图,如图3所示,该装置包括:FIG. 3 is a structural block diagram of a multi-protocol exchange label detecting apparatus according to an embodiment of the present invention. As shown in FIG. 3, the apparatus includes:
发送模块30,设置为发送回应请求报文,其中,回应请求报文中包括 用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;The sending module 30 is configured to send an echo request message, where the response request message includes a type field for identifying an OAM packet of the MPLS operation and maintenance management of the multi-protocol switching label;
检测模块32,设置为接收传输节点或出口节点根据MPLS OAM报文反馈的回应应答报文,并检测回应应答报文与预存信息是否匹配。The detecting module 32 is configured to receive an echo response message fed back by the transit node or the egress node according to the MPLS OAM packet, and detect whether the response response packet matches the pre-stored information.
可选的,回应请求报文中还包括:下游映射信息,其中,下游映射信息对应于回应请求报文的一个或多个下一跳路由。Optionally, the response request message further includes: downstream mapping information, where the downstream mapping information corresponds to one or more next hop routes of the response request message.
图4是根据本发明实施例的多协议交换标签的处理装置的结构框图,如图4所示,该装置包括:4 is a structural block diagram of a processing apparatus for a multi-protocol exchange tag according to an embodiment of the present invention. As shown in FIG. 4, the device includes:
接收模块40,设置为接收回应请求报文,其中,回应请求报文中包括用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;The receiving module 40 is configured to receive a response request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message;
识别模块42,设置为通过类型字段识别MPLS OAM报文;The identification module 42 is configured to identify the MPLS OAM message by using the type field;
转发模块44,设置为根据预设转发表项转发回应请求报文。The forwarding module 44 is configured to forward the response request message according to the preset forwarding entry.
图5是根据本发明实施例的多协议交换标签的检测系统的结构框图,如图5所示,该系统包括:包括Initiator初始节点50、Transit传输节点52或Egress出口节点52,FIG. 5 is a structural block diagram of a detection system for a multi-protocol exchange label according to an embodiment of the present invention. As shown in FIG. 5, the system includes: an Initiator initial node 50, a Transit transmission node 52, or an Egress exit node 52.
初始节点50还包括:The initial node 50 also includes:
发送模块502,设置为发送回应请求报文,其中,回应请求报文中包括用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;The sending module 502 is configured to send a response request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message;
检测模块504,设置为接收传输节点或出口节点根据MPLS OAM报文反馈的回应应答报文,并检测回应应答报文与预存信息是否匹配;The detecting module 504 is configured to receive an echo response message fed back by the transit node or the egress node according to the MPLS OAM packet, and detect whether the response response packet matches the prestored information.
传输节点52或出口节点52还包括:Transfer node 52 or egress node 52 also includes:
接收模块522,设置为接收回应请求报文,其中,回应请求报文中包括用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;The receiving module 522 is configured to receive a response request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message;
识别模块524,设置为通过类型字段识别MPLS OAM报文;The identification module 524 is configured to identify the MPLS OAM message by using the type field;
转发模块526,设置为根据预设转发表项将回应请求报文转发至控制平面,反馈回应请求报文的回应应答报文。 The forwarding module 526 is configured to forward the response request message to the control plane according to the preset forwarding entry, and feed back the response response message of the response request message.
需要说明的是,上述各个模块是可以通过软件或硬件来实现的,对于后者,可以通过以下方式实现,但不限于此:上述模块均位于同一处理器中;或者,上述各个模块以任意组合的形式分别位于不同的处理器中。It should be noted that each of the above modules may be implemented by software or hardware. For the latter, the foregoing may be implemented by, but not limited to, the foregoing modules are all located in the same processor; or, the above modules are in any combination. The forms are located in different processors.
实施例3Example 3
本实施时根据本发明的可选实施例,用于结合具体的场景对本申请进行具体详细的说明:In this implementation, according to an optional embodiment of the present invention, the present application is specifically described in detail in conjunction with a specific scenario:
本实施例的MPLS LSP检测的方法包括以下步骤:The method for detecting MPLS LSP in this embodiment includes the following steps:
第一步:first step:
Initiator节点在发送echo request(回应请求)报文时,在封装的数据链路层头中设置类型字段以表明为MPLS OAM报文。echo request中包含的Downstream Mapping TLV(Type Length Value,类型长度字符)始终只对应要发往的那个下一跳。When sending an echo request message, the Initiator node sets a type field in the encapsulated data link layer header to indicate that it is an MPLS OAM packet. The Downstream Mapping TLV (Type Length Value) contained in the echo request always corresponds to the next hop to be sent.
Initiator发送首个echo request时,需要保存相应的下一跳的Downstream Mapping信息,以便用于与后续的echo reply精确匹配。非首个echo request时,Initiator保存的是上一轮echo reply中拷贝的Downstream Mapping信息。When the initiator sends the first echo request, it needs to save the corresponding next hop's Downstream Mapping information, so that it can be used to match the subsequent echo reply. In the case of a non-first echo request, the Initiator saves the Downstream Mapping information copied in the previous round of echo reply.
Initiator发送的echo request中包含的Downstream Mapping始终只是对应要发往的下一跳,与后续收到的echo reply无关。The Downstream Mapping contained in the echo request sent by the Initiator always corresponds to the next hop to be sent, regardless of the subsequent echo reply.
第二步:The second step:
Transit节点或Egress节点的数据平面提前通过数据链路层头快速识别是MPLS OAM报文(即echo request报文),然后根据与数据报文转发一致的转发表项指导转发,转发结果有两种:1)如果发送控制平面,由控制平面处理后作为Responder节点向Initiator节点回复echo reply;2)如果数据平面继续向下一跳转发,则根据该报文是MPLS OAM报文而直接在数据平面修改MPLS OAM报文内容后发送,如修改echo request中的Downstream Mapping TLV内容,echo request中包含的Downstream Mapping TLV只对应要发往的那个下一跳的;继续在数据链路层头中设置 类型字段以表明为MPLS OAM报文。注意如果是普通数据报文则没有这一步,避免影响普通数据报文的转发效率。The data plane of the transit node or the egress node is forwarded through the data link layer header to identify the MPLS OAM packet (that is, the echo request packet), and then forwards the packet according to the forwarding entry consistent with the data packet forwarding. :1) If the control plane is sent, the control plane will process the echo reply to the Initiator node as a Responder node; 2) If the data plane continues to forward to the next hop, the data is directly in the data according to the MPLS OAM message. After the MPLS OAM packet is modified, the MPLS OAM packet is modified. If the Downstream Mapping TLV content is modified in the echo request, the Downstream Mapping TLV included in the echo request only corresponds to the next hop to be sent. Continue to set in the data link layer header. Type field to indicate as an MPLS OAM message. Note that if it is a normal data packet, there is no such step, which avoids affecting the forwarding efficiency of ordinary data packets.
第三步:third step:
Initiator节点收到Responde节点echo reply后,首先根据echo reply中的Sender's Handle与Sequence Number和echo request中的相应字段匹配,然后根据echo reply中的Upstream Interface TLV与本地保存的Downstream Mapping信息匹配,以确定是否所有本地保存的Downstream Mapping信息都有相应的echo reply匹配,决定是否可以发送下一个echo request,默认策略是所有本地保存的Downstream Mapping信息都有相应的echo reply匹配后才发送下一个echo request,也可采取策略为只要本地保存的Downstream Mapping信息匹配成功占比若大于一定的阀值即可发送下一个echo request,或者其它策略。Initiator在发送下一轮的echo request前,重新从这些匹配了的echo reply中获取Downstream Mapping信息并保存,用于和下一轮的echo reply匹配。After receiving the echo reply of the Responde node, the Initiator node first matches the corresponding field in the Sequence Number and the echo request according to the Sender's Handle in the echo reply, and then matches the Upstream Interface TLV in the echo reply with the locally saved Downstream Mapping information to determine Whether all the locally saved Downstream mapping information has the corresponding echo reply matching, and the next echo request is sent. The default policy is that all locally saved Downstream mapping information has the corresponding echo reply matching before sending the next echo request. A policy can also be adopted to send the next echo request, or other policy, as long as the locally saved Downstream Mapping information matches the success ratio greater than a certain threshold. The Initiator obtains the Downstream Mapping information from the matched echo reply and saves it for matching with the next round of echo reply before sending the next round of the echo request.
克服现有技术中存在的P2P LSP检测失真以及P2MP LSP检测低效与不充分的问题和缺陷,提供一种统一的MPLS LSP检测方法,采用本发明方法,与现有技术相比,统一了P2P LSP与P2MP LSP检测的流程,提升了检测效率,克服了检测失真以及检测不充分的问题。To overcome the problems of P2P LSP detection distortion and P2MP LSP detection inefficiency and insufficiency in the prior art, and provide a unified MPLS LSP detection method, which adopts the method of the present invention and unifies P2P compared with the prior art. The process of detecting LSP and P2MP LSP improves the detection efficiency and overcomes the problems of detection distortion and insufficient detection.
下面结合附图对技术方案的实施作进一步的详细描述:The implementation of the technical solution will be further described in detail below with reference to the accompanying drawings:
图6是根据本发明具体实施方式的LSP ping echo request/reply消息格式图,其定义与rfc4379基本相同,除了Global Flags新增一个标志:6 is a format diagram of an LSP ping echo request/reply message according to an embodiment of the present invention, which is basically the same as rfc4379 except that a new flag is added to the Global Flags:
C(Constant)标志:用于echo request报文中,设置为1表明在检测过程中target FEC stack始终保持不变,不支持FEC change。比如报文要进入更外层的隧道,都强制将更外层隧道按照PIPE类型处理,否则还要区分该外层隧道是UNIFORM或者PIPE做差异化处理。比如报文要进入另一段粘连的LSP或者当前隧道终结,也强制target FEC stack不变化。C标志默认为0。LSP ping的命令设计中需要引入相应的参数用于设置该C 标志。C (Constant) flag: used in the echo request message, set to 1 indicates that the target FEC stack remains unchanged during the detection process, and FEC change is not supported. For example, if a packet enters a tunnel that is outside, it is forced to process the outer tunnel according to the PIPE type. Otherwise, it is necessary to distinguish that the outer tunnel is UNIFORM or PIPE for differentiation. For example, if the packet enters another blocked LSP or the current tunnel is terminated, the target FEC stack is also not changed. The C flag defaults to 0. The LSP ping command design needs to introduce corresponding parameters for setting the C. Sign.
图7是根据本发明具体实施方式的Downstream Mapping TLV的格式图,其中删减了rfc4379中Downstream Mapping TLV关于multipath information相关的字段,保留下来的字段的定义与rfc4379基本相同,除了:7 is a format diagram of a Downstream Mapping TLV according to an embodiment of the present invention, in which a field related to multipath information of a Downstream Mapping TLV in rfc4379 is deleted, and the reserved field is basically the same as rfc4379 except:
1)DS Flags中新增三个标志:1) Three new flags are added to DS Flags:
E标志:设置为1表明该Downstream Mapping TLV对应的下一跳是ECMP成员。用于echo reply中。E flag: Set to 1 to indicate that the next hop corresponding to the Downstream Mapping TLV is an ECMP member. Used in echo reply.
M标志:设置为1表明该Downstream Mapping TLV对应的下一跳是组播成员。用于echo reply中。M flag: Set to 1 to indicate that the next hop corresponding to the Downstream Mapping TLV is a multicast member. Used in echo reply.
R标志:设置为1表明该Downstream Mapping TLV对应的下一跳是非直连的。用于echo request/reply中。The R flag is set to 1 to indicate that the next hop corresponding to the Downstream Mapping TLV is indirectly connected. Used in echo request/reply.
2)Downstream Labels仅指target FEC stack中各FEC对应的标签,不包含其它更外层标签。2) Downstream Labels refers only to the labels corresponding to each FEC in the target FEC stack, and does not include other outer labels.
图8是根据本发明具体实施方式的Upstream Interface TLV的格式图,其中删除了rfc4379中Interface and Label Stack TLV中标签信息相关的字段,保留下来的字段的定义与rfc4379基本相同。8 is a format diagram of an Upstream Interface TLV according to an embodiment of the present invention, in which a field related to tag information in an Interface and Label Stack TLV in rfc4379 is deleted, and the reserved field has the same definition as rfc4379.
图9是根据本发明具体实施方式的Responder Egress TLV的格式图,图10是根据本发明具体实施方式的Responder Transit TLV的格式图,Egress与Transit节点向Initiator节点回复echo reply时可以包含自身的地址信息,以便Initiator节点评估是否从期望的节点都收到了echo reply。9 is a format diagram of a Responder Egress TLV according to an embodiment of the present invention, and FIG. 10 is a format diagram of a Responder Transit TLV according to an embodiment of the present invention. The Egress and Transit nodes may include their own address when replying to an Initiator node with an echo reply. Information so that the Initiator node evaluates whether an echo reply has been received from the desired node.
本实施例还用到了rfc4379中定义的Target FEC Stack TLV,未作修改。This embodiment also uses the Target FEC Stack TLV defined in rfc4379, which has not been modified.
接下来我们介绍下echo request与echo reply报文的具体收发流程。Next, we will introduce the specific sending and receiving process of the echo request and the echo reply message.
图11是根据本发明具体实施方式的Initiator节点发送echo request报文的流程图,包括11 is a flowchart of an Initiator node sending an echo request message according to an embodiment of the present invention, including
步骤S601,Initiator节点发起针对某个target FEC的LSP ping或LSP traceroute流程,则构造echo request报文。Step S601, the Initiator node initiates an LSP ping or LSP for a target FEC. The traceroute process constructs an echo request message.
步骤S602,Initiator节点按照如下构造echo request PDU(Protocol Data Unit,协议数据单元):Step S602, the Initiator node constructs an echo request PDU (Protocol Data Unit) as follows:
1)选择一个Sender's Handle和一个Sequence Number,当连续发送echo request时,对Sequence Number按1递增。注意P2P LSP时若存在ECMP(Equal-Cost Multipath Routing,等价路由),则echo request只会向其中一个ECMP成员发送;而P2MP LSP时则会向每个组播成员发送,此种情况下任何一轮同时向各组播成员发送的echo request中的Sequence Number都是相同的。1) Select a Sender's Handle and a Sequence Number. When the echo request is sent continuously, increment the Sequence Number by 1. Note that if there is ECMP (Equal-Cost Multipath Routing) in the P2P LSP, the echo request will only be sent to one ECMP member; and the P2MP LSP will be sent to each multicast member. In this case, any The sequence number in the echo request sent to each multicast member at the same time is the same.
2)TimeStamp Sent字段设置为一天中的相对时间,秒和微秒。2) The TimeStamp Sent field is set to the relative time of day, seconds and microseconds.
3)TimeStamp Received字段设置为0。3) The TimeStamp Received field is set to 0.
4)Reply Mode设置为期望的模式,表明希望echo reply沿IP或其它某种方式返回至Initiator节点。Return Code与Subcode设置为0。4) The Reply Mode is set to the desired mode, indicating that the echo reply is expected to be returned to the Initiator node along IP or some other way. Return Code and Subcode are set to 0.
5)包含target FEC stack TLV,表示被检测的target FEC。5) Contains the target FEC stack TLV, indicating the detected target FEC.
6)根据LSP ping命令传入的参数设置Global Flags中的C标志。6) Set the C flag in Global Flags according to the parameters passed in the LSP ping command.
7)traceroute模式时,包含Downstream Mapping TLV,对应发往的下一跳。DS Flags打上I标志,表明希望responder节点在回复echo reply时包含Upstream Interface TLV。这里的下一跳是指Initiator节点上至target FEC stack中顶层target FEC的下一跳。特别是当C标志无效时,当Initiator节点发现至顶层target FEC的转发表项要进入更外层的PIPE类型隧道时,则是指迭代隧道迭代前的远端下一跳,此时DS Flags中的R标志设置为有效;若要进入更外层的UNIFORM类型隧道时,则是指迭代隧道迭代后的下一跳,此时DS Flags中的R标志设置为无效,此时Initiator可在target FEC stack顶层继续插入该UNIFORM隧道的FEC。当C标志有效时,当Initiator节点发现至顶层target FEC的转发表项要进入更外层的隧道时,不区分PIPE或UNIFORM,均是指迭代隧道迭代前的远端下一跳,此时DS Flags中的R标志设置为有效。 7) In the traceroute mode, the Downstream Mapping TLV is included, corresponding to the next hop to be sent. The DS Flags are marked with an I, indicating that the responder node wants to include the Upstream Interface TLV when replying to the echo reply. The next hop here refers to the next hop on the Initiator node to the top-level target FEC in the target FEC stack. In particular, when the C flag is invalid, when the Initiator node finds that the forwarding entry to the top-level target FEC is to enter the outer PIPE tunnel, it refers to the far-end next hop before the iterative tunnel iteration. In this case, DS Flags The R flag is set to be valid; if it is to enter the outer UNIFORM type tunnel, it means the next hop after the iterative tunnel iteration. At this time, the R flag in the DS Flags is set to be invalid. In this case, the Initiator can be at the target FEC. The top layer of the stack continues to insert the FEC of the UNIFORM tunnel. When the C flag is valid, when the Initiator node finds that the forwarding entry to the top-level target FEC enters the outer-layer tunnel, it does not distinguish between PIPE or UNIFORM, which refers to the far-end next hop before the iterative tunnel iteration. The R flag in Flags is set to be valid.
步骤S603,Initiator节点按照如下构造IP/UDP头:In step S603, the Initiator node constructs an IP/UDP header as follows:
1)源IP为发送端一个可路由的IP地址1) The source IP is a routable IP address of the sender.
2)目的IP从127/8中随机选择,或从0:0:0:0:0:FFFF:127/104中随机选择2) The destination IP is randomly selected from 127/8, or randomly selected from 0:0:0:0:0:FFFF:127/104
3)IP TTL=13) IP TTL=1
4)源PORT由发送端选择4) Source PORT is selected by the sender
5)目的PORT为35035) The destination PORT is 3503
6)Router Alert option必须设置6) Router Alert option must be set
步骤S604,Initiator节点为echo request报文封装标签栈,包含target FEC stack对应的标签以及任何可能的更外层隧道标签。Step S604, the Initiator node encapsulates the label stack for the echo request message, and includes the label corresponding to the target FEC stack and any possible outer layer tunnel labels.
步骤S605,Initiator节点为echo request报文封装数据链路层,设置类型字段(如以太链路时设置ethernet type为特定的值)表明为MPLS OAM报文。In the step S605, the Initiator node encapsulates the data link layer for the echo request packet, and sets the type field (such as setting the ethernet type to a specific value when the Ethernet link is used) to indicate that it is an MPLS OAM packet.
步骤S606,Initiator节点维护target responder identifiers,表示期望收到哪些节点回复的echo replys,作为后续判断检测是否完毕的依据之一。In step S606, the Initiator node maintains the target responder identifiers, indicating which echo replys are expected to be received by the node, as one of the basis for determining whether the detection is completed.
步骤S607,Initiator节点判断是否是首轮echo request。In step S607, the Initiator node determines whether it is the first round of echo request.
步骤S608,如果是首轮echo request,则保存首轮echo request要发往的下一跳对应的Downstream Mapping信息,用于精确匹配下一轮echo reply。In step S608, if it is the first round of the echo request, the Downstream Mapping information corresponding to the next hop to be sent by the first round of the echo request is saved, and is used to accurately match the next round of echo reply.
P2P LSP时,是指Initiator节点上至target FEC stack中顶层target FEC的下一跳,如果有多个下一跳形成ECMP,echo request也只会发往其中一个下一跳,所以Initiator只需保存这一个下一跳对应的Downstream Mapping信息,其中DS Flags打上E标志。如步骤602,这里的下一跳要根据C标志与是否进入更外层隧道的PIPE/UNIFORM类型一起确定。The P2P LSP refers to the next hop of the top-level target FEC on the Initiator node to the target FEC stack. If multiple next hops form ECMP, the echo request will only be sent to one of the next hops, so the Initiator only needs to save. Downstream mapping information corresponding to this next hop, where DS Flags is marked with E. In
P2MP LSP时,是指Initiator节点上至target FEC的组播转发表项中每个组播成员对应的Downstream Mapping信息,Initiator需要保存多个 Downstream Mapping信息,其中DS Flags都打上了M标志。The P2MP LSP is the Downstream mapping information corresponding to each multicast member in the multicast forwarding entry of the Initiator node to the target FEC. The Initiator needs to save multiple Downstream mapping information, in which DS Flags are marked with M.
步骤S609,如果不是首轮echo request,则保存从上一轮匹配的echo replys中获取的Downstream Mapping信息,用于精确匹配下一轮echo reply。上一轮匹配的echo replys是指那些在上一轮echo request/reply流程中匹配echo request的echo replys,特别是这些echo replys包含的Upstream Interface TLV表明了它们与当时Initiator节点保存的Downstream Mapping信息是匹配的,具体见下面的Initiator节点接收echo reply报文的流程。In step S609, if it is not the first round of echo request, the Downstream Mapping information obtained from the previous round of matching echo replys is saved, and is used to accurately match the next round of echo reply. The last round of echo replys refers to the echo replys that match the echo request in the previous round of the echo request/reply process. In particular, the Upstream Interface TLVs contained in these echo replys indicate that they are the Downstream Mapping information saved by the Initiator node at the time. For the matching, see the process of receiving the echo reply message by the Initiator node below.
P2P LSP时,是指Responder节点上对于target FEC stack从顶层至底层首先作为transit节点的target FEC(记为First Transit FEC)对应的下一跳,如果下一跳有多个形成ECMP,则echo reply中会包含多个Downstream Mapping TLVs,其中DS Flags都打上了E标志,Initiator需要保存多个Downstream Mapping信息。特别是当Responder节点发现至First Transit FEC的转发表项要进入更外层的隧道时,它也需要根据C标志与进入更外层隧道的PIPE/UNIFORM类型一起确定下一跳,与前面步骤602的Initiator节点的处理是类似的,即当C标志无效时,当Responder节点发现至First Transit FEC的转发表项要进入更外层的PIPE类型隧道时,则是指迭代隧道迭代前的远端下一跳,此时DS Flags中的R标志设置为有效;若要进入更外层的UNIFORM类型隧道时,则是指迭代隧道迭代后的下一跳,此时DS Flags中的R标志设置为无效。当C标志有效时,当Initiator节点发现至顶层target FEC的转发表项要进入更外层的隧道时,不区分PIPE或UNIFORM,均是指迭代隧道迭代前的远端下一跳,此时DS Flags中的R标志设置为有效。如果First Transit FEC不存在,则echo reply中无需包含Downstream Mapping TLV。The P2P LSP refers to the next hop corresponding to the target FEC (recorded as First Transit FEC) of the target FEC stack from the top to the bottom of the target FEC stack. If there are multiple ECMPs in the next hop, the echo reply There are multiple Downstream Mapping TLVs, and the DS Flags are marked with the E flag. The Initiator needs to save multiple Downstream Mapping information. In particular, when the Responder node finds that the forwarding entry to the First Transit FEC is to enter the outer tunnel, it also needs to determine the next hop along with the PI flag and the PIPE/UNIFORM type entering the outer tunnel, and step 602 above. The processing of the Initiator node is similar. When the C flag is invalid, when the Responder node finds that the forwarding entry to the First Transit FEC is to enter the outer PIPE type tunnel, it refers to the far end before the iterative tunnel iteration. One hop, at this time, the R flag in the DS Flags is set to be valid; if it is to enter the outer UNIFORM type tunnel, it means the next hop after the iterative tunnel iteration, and the R flag in the DS Flags is set to be invalid. . When the C flag is valid, when the Initiator node finds that the forwarding entry to the top-level target FEC enters the outer-layer tunnel, it does not distinguish between PIPE or UNIFORM, which refers to the far-end next hop before the iterative tunnel iteration. The R flag in Flags is set to be valid. If the First Transit FEC does not exist, the echo reply does not need to include the Downstream Mapping TLV.
P2MP LSP时,是指Responder节点上至target FEC的组播转发表项中每个组播成员对应的Downstream Mapping信息,echo reply中会包含多个Downstream Mapping TLVs,其中DS Flags都打上了M标志,Initiator需要保存多个Downstream Mapping信息。 The P2MP LSP is the Downstream Mapping information corresponding to each multicast member in the multicast forwarding entry of the destination FEC on the Responder node. The echo reply contains multiple Downstream Mapping TLVs, and the DS Flags are marked with the M flag. The Initiator needs to save multiple Downstream Mapping information.
步骤S610,Initiator启动定时器,等待echo reply。In step S610, the Initiator starts a timer and waits for an echo reply.
图12是根据本发明具体实施方式的Transit或Egress节点接收echo request报文的流程图,包括:FIG. 12 is a flowchart of receiving an echo request message by a transit or egress node according to an embodiment of the present invention, including:
步骤S701,Transit或Egress节点接收到echo request。In step S701, the Transit or Egress node receives the echo request.
步骤S702,数据平面首先根据数据链路层头的类型字段快速获取是否为MPLS OAM报文,用于后续处理。In step S702, the data plane first obtains an MPLS OAM packet according to the type field of the data link layer header for subsequent processing.
数据平面处理时若发现以下任一条件暴露,都将mpls echo request报文上送控制面:If any of the following conditions are exposed during data plane processing, the mpls echo request message is sent to the control plane:
a)Router Alert optiona) Router Alert option
b)IP TTL expirationb) IP TTL expiration
c)MPLS TTL expirationc) MPLS TTL expiration
d)MPLS Router Alert labeld) MPLS Router Alert label
e)127/8范围的目的IPe) Destination IP of 127/8 range
步骤S703,数据平面判断是否需要上送控制平面。In step S703, the data plane determines whether it needs to be sent to the control plane.
步骤S704,如果数据平面需要将echo request报文上送控制平面。Step S704, if the data plane needs to send the echo request message to the control plane.
控制平面处理:Control plane processing:
1)检查标签值是否有效,是否存在相应的ILM。Trace route时记下相应的标签操作,用于填写在后续的echo reply中。1) Check if the tag value is valid and whether there is a corresponding ILM. Trace route records the corresponding label operation, which is used to fill in the subsequent echo reply.
2)检查Downstream Mapping TLV中的下一跳信息是否与报文到达的入接口匹配。2) Check whether the next hop information in the Downstream Mapping TLV matches the incoming interface where the packet arrives.
3)检查报文的标签栈与target FEC stack是否一致。由于Downstream Mapping TLV中只包含了target FEC stack中FEC对应的标签,所以需要根据Downstream Mapping TLV中包含的target FEC stack中FEC对应的标签层数按照从底层至顶层的顺序从报文的标签栈中获取相应层数的标签,用于和target FEC stack做一致性检查。检查时,先检查顶层FEC,若顶层 FEC表明到达了Egress节点,则继续检查下一层FEC(转发等价类),否则不再检查下一层FEC。3) Check whether the label stack of the message is consistent with the target FEC stack. The Downstream Mapping TLV contains only the labels corresponding to the FEC in the target FEC stack. Therefore, the label layer corresponding to the FEC in the target FEC stack included in the Downstream Mapping TLV needs to be in the label stack from the bottom to the top. Get the label of the corresponding layer for consistency check with the target FEC stack. When checking, first check the top layer FEC, if the top layer If the FEC indicates that the Egress node is reached, it will continue to check the next layer of FEC (forwarding equivalence class), otherwise the next layer of FEC will not be checked.
步骤S705,判断上述检查是否都成功。In step S705, it is determined whether the above check is successful.
步骤S706,检查结果为成功。In step S706, the check result is successful.
1)向Initiator节点回复echo reply,Return Code与Return Subcode设置相应的成功返回码。包含Upstream Interface TLV,Responder Egress TLV或Responder Transit TLV。1) Reply to the Initiator node echo reply, Return Code and Return Subcode set the corresponding successful return code. Includes Upstream Interface TLV, Responder Egress TLV or Responder Transit TLV.
2)Responder节点为Transit时,还可以根据echo request中包含了Downstream Mapping TLV而在ehco reply中包含Downstream Mapping TLVs,根据需要打上E/M/R标志。P2P LSP时,是指Responder节点上至target FEC stack中First Transit FEC的下一跳,如步骤609,这里的下一跳要根据C标志与是否进入更外层隧道的PIPE/UNIFORM类型一起确定,即当C标志无效时,当Responder节点发现至First Transit FEC的转发表项要进入更外层的PIPE类型隧道时,则是指迭代隧道迭代前的远端下一跳,此时DS Flags中的R标志设置为有效;若要进入更外层的UNIFORM类型隧道时,则是指迭代隧道迭代后的下一跳,此时DS Flags中的R标志设置为无效。当C标志有效时,当Initiator节点发现至顶层target FEC的转发表项要进入更外层的隧道时,不区分PIPE或UNIFORM,均是指迭代隧道迭代前的远端下一跳,此时DS Flags中的R标志设置为有效。如果下一跳有多个形成ECMP,则echo reply中会包含多个Downstream Mapping TLVs,其中DS Flags都打上了E标志。P2MP LSP时,是指Responder节点上至target FEC的组播转发表项中每个组播成员对应的Downstream Mapping信息,echo reply中会包含多个Downstream Mapping TLVs,其中DS Flags都打上了M标志。2) When the Responder node is Transit, it can also include Downstream Mapping TLVs in the ehco reply according to the echo request including the Downstream Mapping TLV, and put the E/M/R flag as needed. The P2P LSP refers to the next hop of the First Transit FEC on the Responder node to the target FEC stack. In
步骤S707,检查结果为失败。In step S707, the result of the check is a failure.
向Initiator节点回复echo reply,Return Code与Return Subcode设置相应的失败返回码。包含Upstream Interface TLV。 Reply to the Initiator node echo reply, Return Code and Return Subcode set the corresponding failure return code. Contains the Upstream Interface TLV.
步骤S708,如果数据平面不需要将echo request报文上送控制平面,则检查之前快速获取是否为MPLS OAM报文的标志。Step S708: If the data plane does not need to send the echo request packet to the control plane, check whether the packet is quickly obtained as an MPLS OAM packet.
步骤S709,如果不是MPLS OAM报文,则数据平面立即将报文按正常数据报文转发。In step S709, if it is not an MPLS OAM packet, the data plane immediately forwards the packet according to the normal data packet.
步骤S710,如果是MPLS OAM报文,则数据平面在发送报文前将报文内容做修改后再发送。In step S710, if it is an MPLS OAM packet, the data plane modifies the content of the packet before sending the packet.
取决于硬件实现代价,选择支持修改的程度。一般最简单的是等字段修改,即不改变报文的大小,仅改变其中某些字段的取值,而更复杂的修改则是改变报文大小。本实施例中,简单的修改可以是将echo request中的Downstream Mapping TLV根据报文要发往的下一跳做修改,复杂的修改可以是修改target FEC stack。Depending on the hardware implementation cost, choose the level of support for the modification. Generally, the simplest is to modify the field, that is, the size of the message is not changed, only the value of some of the fields is changed, and the more complicated modification is to change the size of the message. In this embodiment, the simple modification may be to modify the Downstream Mapping TLV in the echo request according to the next hop to which the packet is sent. The complicated modification may be to modify the target FEC stack.
本实施例中,可根据echo request报文中携带的C标志来修改报文。In this embodiment, the message can be modified according to the C flag carried in the echo request message.
如果C标志有效,则不修改target FEC stack TLV,仅修改Downstream Mapping TLV。具体的,P2P LSP时,改成First Transit FEC对应的转发表项的下一跳对应的Downstream Mapping信息,如果转发表项有多个下一跳形成ECMP,实际转发时仅会挑选其中一个进行转发,Downstream Mapping TLV就根据该挑选中的下一跳进行修改。由于C标志有效,当该挑选中的下一跳需要继续迭代更外层的隧道时,都统一将外层隧道按照PIPE类型处理,即修改后的Downstream Mapping TLV中的下一跳信息为发生隧道迭代前的远端下一跳,实际上也就是First Transit FEC对应转发表项的原始下一跳,DS Flags中的R标志置1。如果不需要迭代外层隧道,则DS Flags中的R标志置0。P2MP LSP时,改成target FEC对应的组播转发表项中每个组播成员对应的Downstream Mapping信息,即向每个组播成员下一跳分别发送echo request时,各echo request中修改后的Downstream Mapping TLV中的下一跳信息分别为相应组播成员下一跳。If the C flag is valid, the target FEC stack TLV is not modified, and only the Downstream Mapping TLV is modified. Specifically, the P2P LSP is changed to the Downstream Mapping information corresponding to the next hop of the forwarding entry corresponding to the First Transit FEC. If the forwarding entry has multiple next hops to form ECMP, only one of them will be forwarded during actual forwarding. The Downstream Mapping TLV is modified based on the next hop in the pick. As the C flag is valid, when the next hop in the selection needs to continue to iterate over the outer layer tunnel, the outer tunnel is uniformly processed according to the PIPE type, that is, the next hop information in the modified Downstream Mapping TLV is the tunnel. The far-end next hop before iteration is actually the original next hop of the forwarding entry corresponding to the First Transit FEC, and the R flag in the DS Flags is set to 1. If it is not necessary to iterate over the outer tunnel, the R flag in DS Flags is set to zero. When the P2MP LSP is changed to the Downstream mapping information corresponding to each multicast member in the multicast forwarding entry corresponding to the target FEC, that is, when each echo request is sent to each multicast member, the echo request is modified in each echo request. The next hop information in the Downstream Mapping TLV is the next hop of the corresponding multicast member.
如果C标志无效,则既修改target FEC stack TLV,也修改Downstream Mapping TLV。具体的,P2P LSP时,如果节点上发生了target FEC stack change,包括FEC POP、PUSH,都直接修改target FEC stack TLV。另外Downstream Mapping TLV改成First Transit FEC对应的转发表项的下一跳对应的Downstream Mapping信息,如果转发表项有多个下一跳形成ECMP,实际转发时仅会挑选其中一个进行转发,Downstream Mapping TLV就根据该挑选中的下一跳进行修改。由于C标志无效,当该挑选中的下一跳需要继续迭代更外层的PIPE类型的隧道时,修改后的Downstream Mapping TLV中的下一跳信息为发生隧道迭代前的远端下一跳,实际上也就是First Transit FEC对应转发表项的原始下一跳,DS Flags中的R标志置1。当该挑选中的下一跳需要继续迭代更外层的UNIFORM类型的隧道时,修改后的Downstream Mapping TLV中的下一跳信息为发生隧道迭代后的下一跳,DS Flags中的R标志置0。如果不需要迭代外层隧道,则DS Flags中的R标志置0。P2MP LSP时,改成target FEC对应的组播转发表项中每个组播成员对应的Downstream Mapping信息,即向每个组播成员下一跳分别发送echo request时,各echo request中修改后的Downstream Mapping TLV中的下一跳信息分别为相应组播成员下一跳。If the C flag is invalid, both the target FEC stack TLV and the Downstream Mapping TLV are modified. Specifically, in the case of a P2P LSP, if a target FEC stack occurs on the node Change, including FEC POP and PUSH, directly modify the target FEC stack TLV. In addition, the Downstream Mapping TLV is changed to the Downstream Mapping information of the next hop of the forwarding entry corresponding to the First Transit FEC. If the forwarding entry has multiple next hops to form ECMP, only one of them will be forwarded during the actual forwarding. Downstream Mapping The TLV is modified based on the next hop in the pick. The next hop information in the modified Downstream Mapping TLV is the far-end next hop before the tunnel iteration, because the C-flag is invalid, and the next hop in the selection needs to continue to iterate over the outer-layer PIPE tunnel. In fact, the original next hop of the forwarding entry corresponding to the First Transit FEC, the R flag in the DS Flags is set to 1. When the next hop in the selection needs to continue to iterate over the outer UNIFORM tunnel, the next hop information in the modified Downstream Mapping TLV is the next hop after the tunnel iteration, and the R flag in the DS Flags is set. 0. If it is not necessary to iterate over the outer tunnel, the R flag in DS Flags is set to zero. When the P2MP LSP is changed to the Downstream mapping information corresponding to each multicast member in the multicast forwarding entry corresponding to the target FEC, that is, when each echo request is sent to each multicast member, the echo request is modified in each echo request. The next hop information in the Downstream Mapping TLV is the next hop of the corresponding multicast member.
另外,节点若发现修改前的Downstream Mapping TLV中的R标志是有效的,则它需要比较该Downstream Mapping TLV中指定的远端下一跳是否为自己,只有为自己才需要按照如上的流程修改Downstream Mapping TLV,否则不修改。In addition, if the node finds that the R flag in the Downstream Mapping TLV is valid, it needs to compare whether the far-end next hop specified in the Downstream Mapping TLV is itself. Only you need to modify the Downstream according to the above process. Mapping TLV, otherwise it will not be modified.
图13是根据本发明具体实施方式的Responder节点发送echo reply报文的流程图,包括:FIG. 13 is a flowchart of a send reply message sent by a Responder node according to an embodiment of the present invention, including:
步骤S801,Transit或Egress节点根据收到的echo request上送控制平面后的处理结果,作为responder节点回复echo reply。Step S801: The Transit or Egress node replies an echo reply as a responder node according to the processing result after the received echo request is sent to the control plane.
步骤S802,按照如下构造Echo reply PDU:Step S802, constructing an Echo reply PDU as follows:
1)Sender's Handle,Sequence Number,TimeStamp Sent从request报文中拷贝。1) Sender's Handle, Sequence Number, TimeStamp Sent is copied from the request message.
2)TimeStamp Received字段设置为一天中的相对时间,秒和微秒。 2) The TimeStamp Received field is set to the relative time of day, seconds and microseconds.
3)target FEC Stack TLV可从request报文中拷贝。3) The target FEC Stack TLV can be copied from the request message.
4)Return Code与Subcode必须根据接收request的处理结果设置。4) Return Code and Subcode must be set according to the processing result of receiving the request.
5)包含Upstream Interface TLV,Responder Egress TLV或Responder Transit TLV。5) Includes Upstream Interface TLV, Responder Egress TLV or Responder Transit TLV.
6)Responder节点为Transit时,还可以包含Downstream Mapping TLVs,根据需要打上E/M/R标志。如步骤706,这里Downstream Mapping TLVs的下一跳是根据C标志与是否进入更外层隧道的PIPE/UNIFORM类型一起确定的,此处不再赘述。6) When the Responder node is Transit, it can also include Downstream Mapping TLVs and mark the E/M/R as needed. In
步骤S803,按照如下构造IP/UDP:In step S803, IP/UDP is constructed as follows:
1)源IP为Responder端一个可路由的IP地址1) The source IP is a routable IP address on the Responder side.
2)目的IP从request报文中拷贝源IP或者从Reply-to TLV中拷贝。2) The destination IP copies the source IP from the request message or from the Reply-to TLV.
3)IP TTL=2553) IP TTL=255
4)源PORT为35034) Source PORT is 3503
5)目的PORT从request报文中拷贝源PORT5) Destination PORT copies source PORT from request message
6)Router Alert option:如果request中指明reply mode为"Reply via an IPv4UDP packet with Router Alert",则必须包含Router Alert option,此时如果返程走LSP,则顶层label为Router Alert label(1)6) Router Alert option: If the request indicates that the reply mode is "Reply via an IPv4 UDP packet with Router Alert", the Router Alert option must be included. If the LSP is returned, the top label is Router Alert label (1).
步骤S804,正常封装相应的数据链路层后转发。Step S804, the corresponding data link layer is normally encapsulated and then forwarded.
图14是根据本发明具体实施方式的Initiator节点接收echo reply报文的流程图,包括:FIG. 14 is a flowchart of receiving an echo reply message by an Initiator node according to an embodiment of the present invention, including:
步骤S901,Initiator节点接收到echo reply报文。In step S901, the Initiator node receives the echo reply message.
步骤S902,Initiator获取echo reply报文中的Sender's Handle与Sequence Number,与本地保存的echo request对应的Sender's Handle与Sequence Number做匹配。In step S902, the Initiator obtains the Sender's Handle and the Sequence Number in the echo reply message, and matches the Sender's Handle and the Sequence Number corresponding to the locally saved echo request.
步骤S903,检查echo reply是否与echo request匹配。 In step S903, it is checked whether the echo reply matches the echo request.
步骤S904,如果不匹配,则丢弃echo reply。In step S904, if there is no match, the echo reply is discarded.
步骤S905,如果匹配,则在traceroute模式时继续获取echo reply报文中的Upstream Interface TLV,与本地保存的Downstream Mapping信息做匹配。检查是否本地保存的所有Downstream Mapping信息都有相应的echo reply匹配。含有E标志的多个Downstream Mapping只需要匹配其中一个即可;含有M标志的都需要匹配。ping模式时,不做匹配,即总是认为匹配成功。In step S905, if it matches, the Upstream Interface TLV in the echo reply message is continuously obtained in the traceroute mode, and the locally saved Downstream Mapping information is matched. Check whether all Downstream mapping information saved locally has a corresponding echo reply. Multiple Downstream Mappings with the E flag only need to match one of them; all those with the M flag need to match. When the mode is ping, no match is made, and the match is always considered successful.
步骤S906,等待用于等待接收echo reply的定时器超时。Step S906, waiting for the timer for waiting to receive the echo reply to time out.
步骤S907,定时器超时后,检查是否为ping模式。Step S907, after the timer expires, it is checked whether it is the ping mode.
步骤S908,如果是ping模式,则整个检测过程结束,报告检测结果,比如哪些节点回复了echo reply,期望的回复节点是否都回复了等等。Initiator根据需要可开启下一轮重复检测。Step S908, if it is the ping mode, the entire detection process ends, and the detection result is reported, such as which nodes replied to the echo reply, whether the desired reply node has replied, and the like. The Initiator can turn on the next round of duplicate detection as needed.
步骤S909,如果是traceroute模式,则继续检查本地保存的Downstream Mapping信息是否全部匹配了,或者只有部分匹配但是否满足匹配通过策略,比如匹配的Downstream Mapping占比超过了一定的阀值。P2P LSP时,本地可能保存了多个打上了E标志的Downstream Mapping条目,这些条目中只要有一个能与echo reply匹配,则认为它们都通过匹配了。P2MP LSP时,本地可能保存了多个打上了M标志的Downstream Mapping条目,这些条目需要分别单独和不同的echo reply匹配。In step S909, if it is in the traceroute mode, it continues to check whether the locally saved Downstream Mapping information is all matched, or only partially matched but meets the matching pass policy, for example, the matched Downstream Mapping ratio exceeds a certain threshold. On a P2P LSP, multiple Downstream Mapping entries marked with the E flag may be saved locally. If one of these entries matches the echo reply, they are considered to be matched. When a P2MP LSP is used, multiple Downstream Mapping entries marked with the M flag may be saved locally. These entries need to be matched separately and with different echo responses.
如果本地保存的Downstream Mapping匹配没有通过,则整个检测过程结束,报告检测结果。If the locally saved Downstream Mapping match fails, the entire detection process ends and the detection result is reported.
步骤S910,如果本地保存的Downstream Mapping匹配通过了,则继续检查期望回复echo reply的节点是否都回复了echo reply。In step S910, if the locally saved Downstream Mapping matches, the node that wants to reply to the echo reply continues to check whether the echo reply is replied.
如果期望的节点都回复了echo reply,那么整个检测过程结束,报告检测结果。If the desired node replies with an echo reply, the entire detection process ends and the test results are reported.
步骤S911,如果还有些期望的节点没有回复echo reply,则继续检查所有echo reply中有没有包含任何Downstream Mapping TLV。 Step S911, if some of the desired nodes do not reply to the echo reply, continue to check whether all the echo reply contains any Downstream Mapping TLV.
如果所有echo reply中都没有包含任何Downstream Mapping TLV,那么整个检测过程结束,报告检测结果。If all the echo reply does not contain any Downstream Mapping TLV, the entire detection process ends and the detection result is reported.
步骤S912,将本地保存的所有Downstream Mapping信息删除,从所有echo reply中获取新的Downstream Mapping信息,本地保存用于和下一轮的echo reply匹配。发送下一轮echo request,label TTL增1。Sender's Handle不变,Sequence Number增1。其它参考Initiator节点发送echo request报文的流程。Step S912: Delete all the Downstream mapping information that is saved locally, and obtain new Downstream Mapping information from all the echo replys, and save locally for matching with the next round of echo reply. Send the next round of echo request, label TTL increased by 1. Sender's Handle is unchanged and the Sequence Number is incremented by 1. Other processes in which the Initiator node sends an echo request message.
下面结合以下示例介绍本实施例的MPLS LSP检测方法,包括:The following describes the MPLS LSP detection method in this embodiment, including:
示例1Example 1
本实施例将描述P2P LSP的检测流程,图15是根据本发明示例1的网络拓扑图,如图15所示,A作为ingress节点建立至egress节点为H的LDP LSP,在transit节点B上,LDP LSP存在ECMP,其中一个下一跳为远端下一跳D并且形成LDP over TE,TE-tunnel从隧道头节点至隧道目的节点的路径为B-C-D,B节点上LDP LSP的另一个下一跳为E。This embodiment will describe the detection flow of the P2P LSP. FIG. 15 is a network topology diagram according to the first embodiment of the present invention. As shown in FIG. 15, A is established as an ingress node to an LDP LSP whose egress node is H, and on the transit node B. The LDP LSP has ECMP. One of the next hops is the remote next hop D and the LDP over TE is formed. The path from the tunnel head node to the tunnel destination node is BCD, and the next hop of the LDP LSP on the B node. Is E.
此时在A节点发起LSP traceroute LDP FEC H,并且设置参数Constant为有效,该检测流程包含如下步骤,为简洁起见,仅描述与本专利相关的主要流程:At this time, the LSP traceroute LDP FEC H is initiated at the node A, and the parameter Constant is set to be valid. The detection process includes the following steps. For the sake of brevity, only the main processes related to this patent are described:
步骤S1001Step S1001
A节点上构造首轮echo request报文,设置Echo request PDU:The first round of echo request message is constructed on the A node, and the Echo request PDU is set:
Global Flags:C=1Global Flags: C=1
target FEC stack TLV:{LDP FEC H}Target FEC stack TLV: {LDP FEC H}
Downstream Mapping TLV:{DS Flags:I=1,E/M/R=0;Downstream Address=B&B.port1}。B表示Router-id,port1表示接口IP,下同。Downstream Mapping TLV: {DS Flags: I=1, E/M/R=0; Downstream Address=B&B.port1}. B indicates the router-id, and port1 indicates the IP address of the interface.
封装IP/UDP头以及标签栈,栈顶标签LDP Label TTL=1。Encapsulate the IP/UDP header and the label stack. The top label LDP Label TTL=1.
设置数据链路层类型字段(如ethernet type=0x88DF)表明为MPLS OAM报文。 Set the data link layer type field (such as ethernet type=0x88DF) to indicate that it is an MPLS OAM packet.
A节点上本地保存Downstream Mapping条目:{DS Flags:E/M=0;Downstream Address=B&B.port1}The Downstream Mapping entry is saved locally on node A: {DS Flags: E/M=0; Downstream Address=B&B.port1}
步骤S1002Step S1002
B节点收到echo request报文,因标签栈顶层标签TTL=1导致上送控制平面。在控制平面,检查发现标签值是有效的,存在相应的ILM并且标签操作为SWAP;检查发现Donstream Mapping TLV中的下一跳信息与报文到达的入接口是匹配的;检查发现报文的标签栈与target FEC stack是一致的。The node B receives the echo request packet and sends it to the control plane because the label TTL=1 on the top label of the label stack. On the control plane, check that the label value is valid, the corresponding ILM exists, and the label operation is SWAP. Check that the next hop information in the Donstream Mapping TLV matches the incoming interface of the packet; check the label of the packet. The stack is consistent with the target FEC stack.
B节点回复echo reply报文,包括:Node B replies with an echo reply message, including:
Upstream Interface TLV:{B&B.port1}Upstream Interface TLV: {B&B.port1}
Responder Transit TLV:{B}Responder Transit TLV: {B}
Downstream Mapping TLV1:{DS Flags:I=1,E=1,R=1;Downstream Address=D&D}。这里因为C标志有效,则按照隧道迭代之前的下一跳填写Downstream Mapping TLV。Downstream Mapping TLV1: {DS Flags: I=1, E=1, R=1; Downstream Address=D&D}. Here, because the C flag is valid, the Downstream Mapping TLV is filled in according to the next hop before the tunnel iteration.
Downstream Mapping TLV2:{DS Flags:I=1,E=1,R=0;Downstream Address=E&E.port1}。Downstream Mapping TLV2: {DS Flags: I=1, E=1, R=0; Downstream Address=E&E.port1}.
步骤S1003Step S1003
A节点收到B节点的ehco reply,检查发现与当前echo request是匹配的,并且echo reply中的Upstream Interface TLV:{B&B.port1}与本地保存的Downstream Mapping条目:{DS Flags:E/M=0;Downstream Address=B&B.port1}是匹配的。The A node receives the ehco reply of the Node B, checks that it matches the current echo request, and the Upstream Interface TLV in the echo reply: {B&B.port1} and the locally saved Downstream Mapping entry: {DS Flags: E/M= 0; Downstream Address=B&B.port1} is a match.
A节点从echo reply中获取新的Downstream Address信息并本地保存为:Node A obtains the new Downstream Address information from the echo reply and saves it locally as:
Downstream Mapping条目1:{DS Flags:E=1,R=1;Downstream Address=D&D}Downstream Mapping entry 1: {DS Flags: E=1, R=1; Downstream Address=D&D}
Downstream Mapping条目2:{DS Flags:E=1,R=0;Downstream Address=E&E.port1}Downstream Mapping entry 2: {DS Flags: E=1, R=0; Downstream Address=E&E.port1}
A发起下一轮echo request,类似步骤S1001,只不过栈顶标签LDP Label TTL=2。特别是包含的Downstream Mapping TLV与步骤S1001中是相同的。A initiates the next round of echo request, similar to step S1001, except that the top label LDP Label TTL=2. In particular, the included Downstream Mapping TLV is the same as in step S1001.
步骤S1004Step S1004
B节点收到echo request报文,因标签栈顶层标签TTL=2,且作为LDP LSP的transit节点,没有导致上送控制平面。The B-node receives the echo request packet because the label TTL=2 on the top of the label stack and the transit node of the LDP LSP does not cause the control plane to be sent.
B节点根据数据链路层的类型字段快速判断是MPLS OAM报文,则根据echo request中的C标志为1,以及echo request中修改前的Downstream Mapping TLV中的下一跳为B,则根据报文实际要通过LDP over TE发往远端下一跳D,而将报文的Downstream Mapping TLV修改为:{DS Flags:I=1,E=1,R=1;Downstream Address=D&D}。然后LDP Label TTL减1,TE Label TTL设置为255,继续设置数据链路层类型字段表明为MPLS OAM报文。转发报文。The B node quickly determines that the MPLS OAM packet is based on the type field of the data link layer, and the C flag in the echo request is 1 and the next hop in the Downstream Mapping TLV before the modification in the echo request is B. The text is actually sent to the remote next hop D through LDP over TE, and the Downstream Mapping TLV of the packet is modified to be: {DS Flags: I=1, E=1, R=1; Downstream Address=D&D}. Then the LDP Label TTL is decremented by 1, and the TE Label TTL is set to 255. The data link layer type field is set to indicate that it is an MPLS OAM packet. Forward the message.
步骤S1005Step S1005
C节点收到echo request报文,因标签栈顶层标签TTL=255,且作为TE LSP的transit节点,没有导致上送控制平面。The C-node receives the echo request packet because the label TTL=255 on the top of the label stack and the transit node of the TE LSP does not cause the control plane to be sent.
C节点根据数据链路层的类型字段快速判断是MPLS OAM报文,但是发现echo request中修改前的Downstream Mapping TLV的下一跳不为C,并且R标志有效,则C知道它处于某个外层隧道中,所以对Downstream Mapping TLV不作修改。仅将TE Label TTL减1,继续设置数据链路层类型字段表明为MPLS OAM报文。转发报文。The C node quickly determines that it is an MPLS OAM packet according to the type field of the data link layer. However, if the next hop of the Downstream Mapping TLV before the modification in the echo request is not C, and the R flag is valid, C knows that it is somewhere else. In the layer tunnel, there is no modification to the Downstream Mapping TLV. Only the TE Label TTL is decremented by 1. The data link layer type field is set to indicate that it is an MPLS OAM packet. Forward the message.
步骤S1006Step S1006
D节点收到echo request报文,TE Label或提前弹出或终结,使得标签栈顶层标签LDP Label TTL=1导致上送控制平面。在控制平面,检查发现标签值是有效的,存在相应的ILM并且标签操作为SWAP;检查发现Donstream Mapping TLV中的下一跳信息与报文到达的入接口是匹配的; 检查发现报文的标签栈与target FEC stack是一致的。The D-node receives the echo request packet, and the TE label is ejected or terminated in advance, so that the label LDP Label TTL=1 on the top label of the label stack is sent to the control plane. On the control plane, the check indicates that the tag value is valid, the corresponding ILM exists, and the tag operation is SWAP. The next hop information in the Donstream Mapping TLV is found to match the incoming interface of the packet. Check that the label stack of the packet is consistent with the target FEC stack.
D节点回复echo reply报文,包括:The D node replies with an echo reply message, including:
Upstream Interface TLV:{D&D.port1}Upstream Interface TLV: {D&D.port1}
Responder Transit TLV:{D}Responder Transit TLV: {D}
Downstream Mapping TLV1:{DS Flags:I=1,E=0,R=0;Downstream Address=H&H.port1}Downstream Mapping TLV1: {DS Flags: I=1, E=0, R=0; Downstream Address=H&H.port1}
步骤S1007Step S1007
A节点收到D节点的ehco reply,检查发现与当前echo request是匹配的,并且echo reply中的Upstream Interface TLV:{D&D.port1}与本地保存的Downstream Mapping条目1:{DS Flags:E=1,R=1;Downstream Address=D&D}是匹配的。这里因为R标志有效,只匹配Router-id即可。因为Downstream Mapping条目2的E标志有效,则认为它也通过了匹配。Node A receives the ehco reply of the D node, checks that it matches the current echo request, and the Upstream Interface TLV in the echo reply: {D&D.port1} and the locally saved Downstream Mapping entry 1: {DS Flags: E=1 , R=1; Downstream Address=D&D} is a match. Here, because the R flag is valid, it only matches the Router-id. Because the E flag of
A节点从echo reply中获取新的Downstream Address信息并本地保存为:Node A obtains the new Downstream Address information from the echo reply and saves it locally as:
Downstream Mapping条目:{DS Flags:E=0,R=0;Downstream Address=H&H.port1}Downstream Mapping entry: {DS Flags: E=0, R=0; Downstream Address=H&H.port1}
A发起下一轮echo request,类似步骤S1001,只不过栈顶标签LDP Label TTL=3。特别是包含的Downstream Mapping TLV与步骤S1001中是相同的。A initiates the next round of echo request, similar to step S1001, except that the top label LDP Label TTL=3. In particular, the included Downstream Mapping TLV is the same as in step S1001.
步骤S1008Step S1008
B节点收到echo request报文,因标签栈顶层标签TTL=3,且作为LDP LSP的transit节点,没有导致上送控制平面。The B-node receives the echo request packet. The TTL of the label stack is TTL=3, and the transit node of the LDP LSP does not cause the control plane to be sent.
其它类似步骤S1004,修改报文的Downstream Mapping TLV后转发。In the similar step S1004, the Downstream Mapping TLV of the packet is modified and then forwarded.
步骤S1009Step S1009
C节点收到echo request报文,因标签栈顶层标签TTL=255,且作为TE LSP的transit节点,没有导致上送控制平面。 The C-node receives the echo request packet because the label TTL=255 on the top of the label stack and the transit node of the TE LSP does not cause the control plane to be sent.
其它类似步骤S1005,不修改报文的Downstream Mapping TLV,转发。In other steps, S1005, the Downstream Mapping TLV of the packet is not modified and forwarded.
步骤S1010Step S1010
D节点收到echo request报文,因标签栈顶层标签TTL=2,且作为LDP LSP的transit节点,没有导致上送控制平面。The D-node receives the echo request packet because the label TTL=2 on the top of the label stack and the transit node of the LDP LSP does not cause the control plane to be sent.
D节点根据数据链路层的类型字段快速判断是MPLS OAM报文,则根据echo request中的C标志为1,以及echo request中修改前的Downstream Mapping TLV中的下一跳为D,以及R标志有效,则根据报文实际要发往下一跳H,而将报文的Downstream Mapping TLV修改为:{DS Flags:I=1,E/M/R=0;Downstream Address=H&H.port1}。然后LDP Label TTL减1,继续设置数据链路层类型字段表明为MPLS OAM报文。转发报文。The D node quickly determines that the MPLS OAM packet is based on the type field of the data link layer, and the C flag according to the echo request is 1, and the next hop in the Downstream Mapping TLV before the modification in the echo request is D, and the R flag. If the packet is valid, the packet is sent to the next hop H, and the Downstream Mapping TLV of the packet is modified to be: {DS Flags: I=1, E/M/R=0; Downstream Address=H&H.port1}. Then the LDP Label TTL is decremented by 1, and the data link layer type field is set to indicate that it is an MPLS OAM packet. Forward the message.
步骤S1011Step S1011
H节点收到echo request报文,标签栈顶层标签LDP Label TTL=1导致上送控制平面。在控制平面,检查发现标签值是有效的,存在相应的ILM并且标签操作为POP;检查发现Donstream Mapping TLV中的下一跳信息与报文到达的入接口是匹配的;检查发现报文的标签栈与target FEC stack是一致的。The H-node receives the echo request packet, and the label LDP Label TTL=1 on the top label of the label stack is sent to the control plane. On the control plane, check that the label value is valid, the corresponding ILM exists, and the label operation is POP. Check that the next hop information in the Donstream Mapping TLV matches the incoming interface of the packet; check the label of the packet. The stack is consistent with the target FEC stack.
H节点回复echo reply报文,包括:The H node replies with an echo reply message, including:
Upstream Interface TLV:{H&H.port1}Upstream Interface TLV: {H&H.port1}
Responder Egress TLV:{H}Responder Egress TLV: {H}
步骤S1012Step S1012
A节点收到H节点的ehco reply,检查发现与当前echo request是匹配的,并且echo reply中的Upstream Interface TLV:{H&H.port1}与本地保存的Downstream Mapping条目:{DS Flags:E/M=0;Downstream Address=H&H.port1}是匹配的。The A node receives the ehco reply of the H node, checks that it matches the current echo request, and the Upstream Interface TLV in the echo reply: {H&H.port1} and the locally saved Downstream Mapping entry: {DS Flags: E/M= 0; Downstream Address=H&H.port1} is a match.
A节点从echo reply中获取不到新的Downstream Address信息。检测 完毕,输出检测结果,收到了Egress节点H的echo reply。Node A cannot obtain new Downstream Address information from the echo reply. Detection After the test result is output, the echo reply of the Egress node H is received.
示例2Example 2
图16是根据本发明示例2的网络拓扑图,本实施例与示例1基本相同,区别是在A节点发起LSP traceroute LDP FEC H时设置参数Constant为无效。该检测流程包含如下步骤:16 is a network topology diagram according to Example 2 of the present invention. This embodiment is basically the same as Example 1. The difference is that the parameter Constant is invalid when the A node initiates the LSP traceroute LDP FEC H. The detection process includes the following steps:
步骤S1101Step S1101
A节点上构造首轮echo request报文,设置Echo request PDU:The first round of echo request message is constructed on the A node, and the Echo request PDU is set:
Global Flags:C=1Global Flags: C=1
target FEC stack TLV:{LDP FEC H}Target FEC stack TLV: {LDP FEC H}
Downstream Mapping TLV:{DS Flags:I=1,E/M/R=0;Downstream Address=B&B.port1}。B表示Router-id,port1表示接口IP,下同。Downstream Mapping TLV: {DS Flags: I=1, E/M/R=0; Downstream Address=B&B.port1}. B indicates the router-id, and port1 indicates the IP address of the interface.
封装IP/UDP头以及标签栈,栈顶标签LDP Label TTL=1。Encapsulate the IP/UDP header and the label stack. The top label LDP Label TTL=1.
设置数据链路层类型字段(如ethernet type=0x88DF)表明为MPLS OAM报文。Set the data link layer type field (such as ethernet type=0x88DF) to indicate that it is an MPLS OAM packet.
A节点上本地保存Downstream Mapping条目:{DS Flags:E/M=0;Downstream Address=B&B.port1}The Downstream Mapping entry is saved locally on node A: {DS Flags: E/M=0; Downstream Address=B&B.port1}
步骤S1102Step S1102
B节点收到echo request报文,因标签栈顶层标签LDP Label TTL=1导致上送控制平面。在控制平面,检查发现标签值是有效的,存在相应的ILM并且标签操作为SWAP;检查发现Donstream Mapping TLV中的下一跳信息与报文到达的入接口是匹配的;检查发现报文的标签栈与target FEC stack是一致的。The node B receives the echo request packet and sends it to the control plane because the label LDP Label TTL=1 on the top label of the label stack. On the control plane, check that the label value is valid, the corresponding ILM exists, and the label operation is SWAP. Check that the next hop information in the Donstream Mapping TLV matches the incoming interface of the packet; check the label of the packet. The stack is consistent with the target FEC stack.
B节点回复echo reply报文,包括:Node B replies with an echo reply message, including:
Upstream Interface TLV:{B&B.port1}Upstream Interface TLV: {B&B.port1}
Responder Transit TLV:{B} Responder Transit TLV: {B}
Downstream Mapping TLV1:{DS Flags:I=1,E=1,R=0;Downstream Address=C&C.port1}。这里因为C标志无效,则按照隧道迭代之后的下一跳填写Downstream Mapping TLV。Downstream Mapping TLV1: {DS Flags: I=1, E=1, R=0; Downstream Address=C&C.port1}. Here, because the C flag is invalid, the Downstream Mapping TLV is filled in according to the next hop after the tunnel iteration.
Downstream Mapping TLV2:{DS Flags:I=1,E=1,R=0;Downstream Address=E&E.port1}Downstream Mapping TLV2: {DS Flags: I=1, E=1, R=0; Downstream Address=E&E.port1}
步骤S1103Step S1103
A节点收到B节点的ehco reply,检查发现与当前echo request是匹配的,并且echo reply中的Upstream Interface TLV:{B&B.port1}与本地保存的Downstream Mapping条目:{DS Flags:E/M=0;Downstream Address=B&B.port1}是匹配的。The A node receives the ehco reply of the Node B, checks that it matches the current echo request, and the Upstream Interface TLV in the echo reply: {B&B.port1} and the locally saved Downstream Mapping entry: {DS Flags: E/M= 0; Downstream Address=B&B.port1} is a match.
A节点从echo reply中获取新的Downstream Address信息并本地保存为:Node A obtains the new Downstream Address information from the echo reply and saves it locally as:
Downstream Mapping条目1:{DS Flags:E=1,R=0;Downstream Address=C&C.port1}Downstream Mapping entry 1: {DS Flags: E=1, R=0; Downstream Address=C&C.port1}
Downstream Mapping条目2:{DS Flags:E=1,R=0;Downstream Address=E&E.port1}Downstream Mapping entry 2: {DS Flags: E=1, R=0; Downstream Address=E&E.port1}
A发起下一轮echo request,类似步骤S1101,只不过栈顶标签LDP Label TTL=2。特别是包含的Downstream Mapping TLV与步骤S1101中是相同的。A initiates the next round of echo request, similar to step S1101, except that the top label LDP Label TTL=2. In particular, the included Downstream Mapping TLV is the same as in step S1101.
步骤S1104Step S1104
B节点收到echo request报文,因标签栈顶层标签LDP Label TTL=2,且作为LDP LSP的transit节点,没有导致上送控制平面。The B-node receives the echo request packet because the LDP Label TTL of the label on the top of the label stack is 2, and the transit node of the LDP LSP does not cause the control plane to be sent.
B节点根据数据链路层的类型字段快速判断是MPLS OAM报文,则根据echo request中的C标志为0,以及echo request中修改前的Downstream Mapping TLV中的下一跳为B,则根据报文实际要通过LDP over TE发往远端下一跳D,按隧道迭代后的下一跳将报文的Downstream Mapping TLV修改为:{DS Flags:I=1,E=1,R=0;Downstream Address=C&C.port1}。以及将target FEC stack TLV修改为:{LDP FEC H,TE FEC D}。然后LDP Label TTL减1,TE Label TTL从LDP Label TTL拷贝,继续设置数据链路层类型字段表明为MPLS OAM报文。转发报文。The B node quickly determines that the MPLS OAM packet is based on the type field of the data link layer, and the C flag in the echo request is 0, and the next hop in the Downstream Mapping TLV before the modification in the echo request is B. The actual LDP over TE is sent to the remote next hop D. The next hop of the tunnel is the Downstream of the packet. The Mapping TLV is modified to: {DS Flags: I=1, E=1, R=0; Downstream Address=C&C.port1}. And modify the target FEC stack TLV to: {LDP FEC H, TE FEC D}. Then, the LDP Label TTL is decremented by 1, and the TE Label TTL is copied from the LDP Label TTL. The data link layer type field is set to indicate that it is an MPLS OAM packet. Forward the message.
步骤S1105Step S1105
C节点收到echo request报文,因标签栈顶层标签TE Label TTL=1导致上送控制平面。在控制平面,检查发现标签值是有效的,存在相应的ILM并且标签操作为SWAP;检查发现Donstream Mapping TLV中的下一跳信息与报文到达的入接口是匹配的;检查发现报文的标签栈与target FEC stack是一致的。The C-node receives the echo request packet and sends it to the control plane because the top label of the label stack, TE Label TTL=1. On the control plane, check that the label value is valid, the corresponding ILM exists, and the label operation is SWAP. Check that the next hop information in the Donstream Mapping TLV matches the incoming interface of the packet; check the label of the packet. The stack is consistent with the target FEC stack.
C节点回复echo reply报文,包括:The C node replies with an echo reply message, including:
Upstream Interface TLV:{C&C.port1}Upstream Interface TLV: {C&C.port1}
Responder Transit TLV:{C}Responder Transit TLV: {C}
Downstream Mapping TLV1:{DS Flags:I=1,E=0,R=0;Downstream Address=D&D.port1}。Downstream Mapping TLV1: {DS Flags: I=1, E=0, R=0; Downstream Address=D&D.port1}.
步骤S1106Step S1106
A节点收到C节点的ehco reply,检查发现与当前echo request是匹配的,并且echo reply中的Upstream Interface TLV:{C&C.port1}与本地保存的Downstream Mapping条目1:{DS Flags:E=1,R=0;Downstream Address=C&C.port1}是匹配的,由于Downstream Mapping条目2:{DS Flags:E=1,R=0;Downstream Address=E&E.port1}中的E标志有效,则它也认为是匹配的。The A node receives the ehco reply of the C node, checks that it matches the current echo request, and the Upstream Interface TLV in the echo reply: {C&C.port1} and the locally saved Downstream Mapping entry 1: {DS Flags: E=1 , R=0; Downstream Address=C&C.port1} is matched. Since the Downstream Mapping entry 2: {DS Flags: E=1, R=0; the E flag in Downstream Address=E&E.port1} is valid, then it also Think it is a match.
A节点从echo reply中获取新的Downstream Address信息并本地保存为:Node A obtains the new Downstream Address information from the echo reply and saves it locally as:
Downstream Mapping条目1:{DS Flags:E=0,R=0;Downstream Address=D&D.port1} Downstream Mapping entry 1: {DS Flags: E=0, R=0; Downstream Address=D&D.port1}
A发起下一轮echo request,类似步骤S1101,只不过栈顶标签LDP Label TTL=3。特别是包含的Downstream Mapping TLV与步骤S1101中是相同的。A initiates the next round of echo request, similar to step S1101, except that the top label LDP Label TTL=3. In particular, the included Downstream Mapping TLV is the same as in step S1101.
步骤S1107Step S1107
B节点收到echo request报文,因标签栈顶层标签LDP Label TTL=3,且作为LDP LSP的transit节点,没有导致上送控制平面。The node B receives the echo request packet. The label LDP Label TTL=3 on the top of the label stack is used as the transit node of the LDP LSP.
其它类似步骤S1104,修改报文的target FEC stack TLV与Downstream Mapping TLV后转发。In the similar step S1104, the target FEC stack TLV and the Downstream Mapping TLV of the packet are modified and then forwarded.
步骤S1108Step S1108
C节点收到echo request报文,因标签栈顶层标签TE Label TTL=2,且作为TE LSP的transit节点,没有导致上送控制平面。The C-node receives the echo request packet, because the top label of the label stack, TE Label TTL=2, and the transit node of the TE LSP does not cause the control plane to be sent.
C节点根据数据链路层的类型字段快速判断是MPLS OAM报文,则根据echo request中的C标志为0,以及echo request中修改前的Downstream Mapping TLV中的下一跳为C,则将报文的Downstream Mapping TLV修改为:{DS Flags:I=1,E=0,R=0;Downstream Address=D&D.port1}。然后TE Label TTL减1,继续设置数据链路层类型字段表明为MPLS OAM报文。转发报文。The C node quickly determines that the MPLS OAM packet is based on the type field of the data link layer, and then the C flag in the echo request is 0, and the next hop in the Downstream Mapping TLV before the modification in the echo request is C. The Downstream Mapping TLV of the text is modified as follows: {DS Flags: I=1, E=0, R=0; Downstream Address=D&D.port1}. Then the TE Label TTL is decremented by 1, and the data link layer type field is set to indicate that it is an MPLS OAM packet. Forward the message.
步骤S1109Step S1109
D节点收到echo request报文,TE Label或提前弹出或终结,TE Label TTL会继承给LDP Label TTL,由于LDP Label TTL=1导致上送控制平面。在控制平面,检查发现标签值是有效的,存在相应的ILM并且标签操作为SWAP;检查发现Donstream Mapping TLV中的下一跳信息与报文到达的入接口是匹配的;检查发现报文的标签栈与target FEC stack是一致的。The D-node receives the echo request packet, and the TE label is ejected or terminated in advance. The TE Label TTL is inherited to the LDP Label TTL. The LDP Label TTL=1 is sent to the control plane. On the control plane, check that the label value is valid, the corresponding ILM exists, and the label operation is SWAP. Check that the next hop information in the Donstream Mapping TLV matches the incoming interface of the packet; check the label of the packet. The stack is consistent with the target FEC stack.
D节点回复echo reply报文,包括:The D node replies with an echo reply message, including:
Upstream Interface TLV:{D&D.port1}Upstream Interface TLV: {D&D.port1}
Responder Transit TLV:{D} Responder Transit TLV: {D}
Downstream Mapping TLV1:{DS Flags:I=1,E=0,R=0;Downstream Address=H&H.port1}Downstream Mapping TLV1: {DS Flags: I=1, E=0, R=0; Downstream Address=H&H.port1}
步骤S1110Step S1110
A节点收到D节点的ehco reply,检查发现与当前echo request是匹配的,并且echo reply中的Upstream Interface TLV:{D&D.port1}与本地保存的Downstream Mapping条目:{DS Flags:E/M=0;Downstream Address=D&D.port1}是匹配的。Node A receives the ehco reply from the D node, checks that it matches the current echo request, and the Upstream Interface TLV in the echo reply: {D&D.port1} and the locally saved Downstream Mapping entry: {DS Flags: E/M= 0; Downstream Address=D&D.port1} is a match.
A节点从echo reply中获取新的Downstream Address信息并本地保存为:Node A obtains the new Downstream Address information from the echo reply and saves it locally as:
Downstream Mapping条目1:{DS Flags:E=0,R=0;Downstream Address=H&H.port1}Downstream Mapping entry 1: {DS Flags: E=0, R=0; Downstream Address=H&H.port1}
A发起下一轮echo request,类似步骤S1101,只不过栈顶标签LDP Label TTL=4。特别是包含的Downstream Mapping TLV与步骤S1101中是相同的。A initiates the next round of echo request, similar to step S1101, except that the top label LDP Label TTL=4. In particular, the included Downstream Mapping TLV is the same as in step S1101.
步骤S1111Step S1111
B节点收到echo request报文,因标签栈顶层标签LDP Label TTL=4,且作为LDP LSP的transit节点,没有导致上送控制平面。The B-node receives the echo request packet. The LDP Label TTL of the label on the top of the label stack is 4, and the transit node of the LDP LSP does not cause the control plane to be sent.
其它类似步骤S1104,修改报文的target FEC stack TLV与Downstream Mapping TLV后转发。In the similar step S1104, the target FEC stack TLV and the Downstream Mapping TLV of the packet are modified and then forwarded.
步骤S1112Step S1112
C节点收到echo request报文,因标签栈顶层标签TE Label TTL=3,且作为TE LSP的transit节点,没有导致上送控制平面。The C-node receives the echo request packet because the top label of the label stack, TE Label TTL=3, and the transit node of the TE LSP does not cause the control plane to be sent.
其它类似步骤S1108,修改报文的Downstream Mapping TLV。如果此时发生了倒数第二跳弹出,则还需修改报文的target FEC stack TLV为:{LDP FEC H},否则不修改。In other similar steps, S1108, the Downstream Mapping TLV of the packet is modified. If the penultimate hop popup occurs, you need to modify the target FEC stack TLV of the packet to be {LDP FEC H}, otherwise it will not be modified.
步骤S1113 Step S1113
D节点收到echo request报文,TE Label或提前弹出或终结,TE Label TTL会继承给LDP Label TTL,由于LDP Label TTL=2没有导致上送控制平面。The D-node receives the echo request packet, and the TE label is ejected or terminated in advance. The TE Label TTL is inherited to the LDP Label TTL. The LDP Label TTL=2 is not sent to the control plane.
D节点根据数据链路层的类型字段快速判断是MPLS OAM报文,则根据echo request中的C标志为0,以及echo request中修改前的Downstream Mapping TLV中的下一跳为D,则将报文的Downstream Mapping TLV修改为:{DS Flags:I=1,E=0,R=0;Downstream Address=H&H.port1}。如果之前C节点上没有发生倒数第二跳弹出,则此时D节点上需要根据TE Label POP也将target TE FEC POP,即修改target FEC stack TLV为:{LDP FEC H}。然后LDP Label TTL减1,继续设置数据链路层类型字段表明为MPLS OAM报文。转发报文。The D node quickly determines that the MPLS OAM packet is based on the type field of the data link layer, and then the C flag in the echo request is 0, and the next hop in the Downstream Mapping TLV before the modification in the echo request is D. The Downstream Mapping TLV of the text is modified as follows: {DS Flags: I=1, E=0, R=0; Downstream Address=H&H.port1}. If no penultimate hop popup occurs on the previous C node, then the target node FEC POP is also required according to the TE Label POP on the D node, that is, the target FEC stack TLV is modified: {LDP FEC H}. Then the LDP Label TTL is decremented by 1, and the data link layer type field is set to indicate that it is an MPLS OAM packet. Forward the message.
步骤S1114Step S1114
H节点收到echo request报文,标签栈顶层标签LDP Label TTL=1导致上送控制平面。在控制平面,检查发现标签值是有效的,存在相应的ILM并且标签操作为POP;检查发现Donstream Mapping TLV中的下一跳信息与报文到达的入接口是匹配的;检查发现报文的标签栈与target FEC stack是一致的。The H-node receives the echo request packet, and the label LDP Label TTL=1 on the top label of the label stack is sent to the control plane. On the control plane, check that the label value is valid, the corresponding ILM exists, and the label operation is POP. Check that the next hop information in the Donstream Mapping TLV matches the incoming interface of the packet; check the label of the packet. The stack is consistent with the target FEC stack.
H节点回复echo reply报文,包括:The H node replies with an echo reply message, including:
Upstream Interface TLV:{H&H.port1}Upstream Interface TLV: {H&H.port1}
Responder Egress TLV:{H}Responder Egress TLV: {H}
步骤S1115Step S1115
A节点收到H节点的ehco reply,检查发现与当前echo request是匹配的,并且echo reply中的Upstream Interface TLV:{H&H.port1}与本地保存的Downstream Mapping条目:{DS Flags:E/M=0;Downstream Address=H&H.port1}是匹配的。The A node receives the ehco reply of the H node, checks that it matches the current echo request, and the Upstream Interface TLV in the echo reply: {H&H.port1} and the locally saved Downstream Mapping entry: {DS Flags: E/M= 0; Downstream Address=H&H.port1} is a match.
A节点从echo reply中获取不到新的Downstream Address信息。检测完毕,输出检测结果,收到了Egress节点H的echo reply。 Node A cannot obtain new Downstream Address information from the echo reply. After the detection is completed, the detection result is output, and the echo reply of the Egress node H is received.
示例3Example 3
本实施例将描述P2MP LSP的检测流程,图17是根据本发明示例3网络拓扑图,如图17所示,是以R节点作为根节点的组播分发树,建立FEC为opaqueX的mLDP LSP。This embodiment will describe the detection flow of the P2MP LSP. FIG. 17 is a network topology diagram of the example 3 according to the present invention. As shown in FIG. 17, the multicast distribution tree with the R node as the root node establishes an mLDP LSP whose FEC is opaqueX.
此时在R节点发起LSP traceroute mLDP FEC opaqueX,该检测流程包含如下步骤,为简洁起见,仅描述与本专利相关的主要流程:At this point, the LSP traceroute mLDP FEC opaqueX is initiated at the R node. The detection process includes the following steps. For the sake of brevity, only the main processes related to this patent are described:
步骤S1201Step S1201
R节点上构造首轮echo request报文,分别向组播成员下一跳A和组播成员下一跳B发送echo request。The first round of echo request packets is constructed on the R node, and the echo request is sent to the multicast member next hop A and the multicast member next hop B respectively.
设置向组播成员下一跳A发送的Echo request PDU:Set the Echo request PDU sent to the multicast member next hop A:
target FEC stack TLV:{mLDP FEC opaqueX}Target FEC stack TLV: {mLDP FEC opaqueX}
Downstream Mapping TLV:{DS Flags:I=1,E/R=0,M=1;Downstream Address=A&A.port1}。A表示Router-id,port1表示接口IP,下同。Downstream Mapping TLV: {DS Flags: I=1, E/R=0, M=1; Downstream Address=A&A.port1}. A indicates the router-id, and port1 indicates the IP address of the interface.
封装IP/UDP头以及标签栈,栈顶标签LDP Label TTL=1。Encapsulate the IP/UDP header and the label stack. The top label LDP Label TTL=1.
设置数据链路层类型字段(如ethernet type=0x88DF)表明为MPLS OAM报文。Set the data link layer type field (such as ethernet type=0x88DF) to indicate that it is an MPLS OAM packet.
类似的设置向组播成员下一跳B发送的Echo request PDU:A similar setting to the Echo request PDU sent by the multicast member to the next hop B:
target FEC stack TLV:{mLDP FEC opaqueX}Target FEC stack TLV: {mLDP FEC opaqueX}
Downstream Mapping TLV:{DS Flags:I=1,E/R=0,M=1;Downstream Address=B&B.port1}。Downstream Mapping TLV: {DS Flags: I=1, E/R=0, M=1; Downstream Address=B&B.port1}.
封装IP/UDP头以及标签栈,栈顶标签LDP Label TTL=1。Encapsulate the IP/UDP header and the label stack. The top label LDP Label TTL=1.
设置数据链路层类型字段(如ethernet type=0x88DF)表明为MPLS OAM报文。Set the data link layer type field (such as ethernet type=0x88DF) to indicate that it is an MPLS OAM packet.
R节点上本地保存Downstream Mapping条目1:{DS Flags:E/R=0,M=1;Downstream Address=A&A.port1},Downstream Mapping条目2:{DS
Flags:E/R=0,M=1;Downstream Address=B&B.port1}The
步骤S1202Step S1202
A节点收到echo request报文,因标签栈顶层标签TTL=1导致上送控制平面。在控制平面,检查发现标签值是有效的,存在相应的ILM并且标签操作为SWAP;检查发现Donstream Mapping TLV中的下一跳信息与报文到达的入接口是匹配的;检查发现报文的标签栈与target FEC stack是一致的。The node A receives the echo request packet and sends it to the control plane because the label TTL=1 on the top label of the label stack. On the control plane, check that the label value is valid, the corresponding ILM exists, and the label operation is SWAP. Check that the next hop information in the Donstream Mapping TLV matches the incoming interface of the packet; check the label of the packet. The stack is consistent with the target FEC stack.
A节点回复echo reply报文,包括:The A node replies with an echo reply message, including:
Upstream Interface TLV:{A&A.port1}Upstream Interface TLV: {A&A.port1}
Responder Transit TLV:{A}Responder Transit TLV: {A}
Downstream Mapping TLV1:{DS Flags:I=1,E/R=0,M=1;Downstream Address=C&C.port1}。Downstream Mapping TLV1: {DS Flags: I=1, E/R=0, M=1; Downstream Address=C&C.port1}.
Downstream Mapping TLV2:{DS Flags:I=1,E/R=0,M=1;Downstream Address=D&D.port1}。Downstream Mapping TLV2: {DS Flags: I=1, E/R=0, M=1; Downstream Address=D&D.port1}.
类似的,B节点收到echo request报文,回复echo reply报文,包括:Similarly, the Node B receives the echo request packet and replies to the echo reply packet, including:
Upstream Interface TLV:{B&B.port1}Upstream Interface TLV: {B&B.port1}
Responder Transit TLV:{B}Responder Transit TLV: {B}
Downstream Mapping TLV1:{DS Flags:I=1,E/R=0,,M=1;Downstream Address=E&E.port1}。Downstream Mapping TLV1: {DS Flags: I=1, E/R=0,, M=1; Downstream Address=E&E.port1}.
Downstream Mapping TLV2:{DS Flags:I=1,E/R=0,,M=1;Downstream Address=F&F.port1}。Downstream Mapping TLV2: {DS Flags: I=1, E/R=0,, M=1; Downstream Address=F&F.port1}.
步骤S1203Step S1203
R节点收到A节点的ehco reply,检查发现与当前echo request是匹配的,并且echo reply中的Upstream Interface TLV:{A&A.port1}与本地保存的Downstream Mapping条目1:{DS Flags:E/R=0,M=1;Downstream Address=A&A.port1}是匹配的。 The R node receives the ehco reply of the A node, checks that it matches the current echo request, and the Upstream Interface TLV in the echo reply: {A&A.port1} and the locally saved Downstream Mapping entry 1: {DS Flags: E/R =0, M=1; Downstream Address=A&A.port1} is a match.
类似的,R节点收到B节点的echo reply,并且echo reply中的Upstream Interface TLV:{B&B.port1}与本地保存的Downstream Mapping条目2:{DS Flags:E/R=0,M=1;Downstream Address=B&B.port1}是匹配的。Similarly, the R node receives the echo reply of the Node B, and the Upstream Interface TLV in the echo reply: {B&B.port1} and the locally saved Downstream Mapping entry 2: {DS Flags: E/R=0, M=1; Downstream Address=B&B.port1} is a match.
R节点从A的echo reply中获取新的Downstream Address信息并本地保存为:The R node obtains the new Downstream Address information from the echo reply of A and saves it locally as:
Downstream Mapping条目1:{DS Flags:E/R=0,M=1;Downstream Address=C&C.port1}Downstream Mapping entry 1: {DS Flags: E/R=0, M=1; Downstream Address=C&C.port1}
Downstream Mapping条目2:{DS Flags:E/R=0,M=1;Downstream Address=D&D.port1}Downstream Mapping entry 2: {DS Flags: E/R=0, M=1; Downstream Address=D&D.port1}
R节点从B的echo reply中获取新的Downstream Address信息并本地保存为:The R node obtains the new Downstream Address information from the echo reply of B and saves it locally as:
Downstream Mapping条目3:{DS Flags:E/R=0,M=1;Downstream Address=E&E.port1}Downstream Mapping entry 3: {DS Flags: E/R=0, M=1; Downstream Address=E&E.port1}
Downstream Mapping条目4:{DS Flags:E/R=0,M=1;Downstream Address=F&F.port1}Downstream Mapping entry 4: {DS Flags: E/R=0, M=1; Downstream Address=F&F.port1}
R发起下一轮echo request,类似步骤S1201,只不过栈顶标签LDP Label TTL=2。特别是包含的Downstream Mapping TLV与步骤S1201中是相同的。R initiates the next round of echo request, similar to step S1201, except that the top label LDP Label TTL=2. In particular, the included Downstream Mapping TLV is the same as in step S1201.
步骤S1204Step S1204
A节点收到echo request报文,因标签栈顶层标签LDP Label TTL=2,且作为mLDP LSP的transit节点,没有导致上送控制平面。The node A received the echo request packet because the label LDP Label TTL=2 of the label stack and the transit node of the mLDP LSP did not cause the control plane to be sent.
A节点根据数据链路层的类型字段快速判断是MPLS OAM报文,则根据echo request中修改前的Downstream Mapping TLV中的下一跳为A,则将发给组播成员下一跳C的echo request报文的Downstream Mapping TLV修改为:{DS Flags:I=1,E/R=0,M=1;Downstream Address=C&C.port1}。将发给组播成员下一跳D的echo request报文的Downstream Mapping TLV修改为:{DS Flags:I=1,E/R=0,M=1;Downstream Address=D&D.port1}。然后LDP Label TTL减1,继续设置数据链路层类型字段表明为MPLS OAM报文。转发报文。The A node quickly determines that the MPLS OAM packet is based on the type field of the data link layer. If the next hop in the Downstream Mapping TLV before the modification is A, the node sends an echo to the multicast member next hop C. The Downstream Mapping TLV of the request packet is modified as follows: {DS Flags: I=1, E/R=0, M=1; Downstream Address=C&C.port1}. Downstream of the echo request message to be sent to the multicast member next hop D The Mapping TLV is modified to: {DS Flags: I=1, E/R=0, M=1; Downstream Address=D&D.port1}. Then the LDP Label TTL is decremented by 1, and the data link layer type field is set to indicate that it is an MPLS OAM packet. Forward the message.
类似的,B节点将发给组播成员下一跳E的echo request报文的Downstream Mapping TLV修改为:{DS Flags:I=1,E/R=0,M=1;Downstream Address=E&E.port1}。将发给组播成员下一跳F的echo request报文的Downstream Mapping TLV修改为:{DS Flags:I=1,E/R=0,M=1;Downstream Address=F&F.port1}。然后LDP Label TTL减1,继续设置数据链路层类型字段表明为MPLS OAM报文。转发报文。Similarly, the Node B changes the Downstream Mapping TLV of the echo request packet sent to the next hop of the multicast member to: {DS Flags: I=1, E/R=0, M=1; Downstream Address=E&E. Port1}. The Downstream Mapping TLV of the echo request packet sent to the next hop of the multicast member is modified as follows: {DS Flags: I=1, E/R=0, M=1; Downstream Address=F&F.port1}. Then the LDP Label TTL is decremented by 1, and the data link layer type field is set to indicate that it is an MPLS OAM packet. Forward the message.
步骤S1205Step S1205
C节点收到echo request报文,因标签栈顶层标签TTL=1导致上送控制平面。在控制平面,检查发现标签值是有效的,存在相应的ILM并且标签操作为SWAP;检查发现Donstream Mapping TLV中的下一跳信息与报文到达的入接口是匹配的;检查发现报文的标签栈与target FEC stack是一致的。The C-node receives the echo request packet and sends it to the control plane because the label TTL=1 on the top label of the label stack. On the control plane, check that the label value is valid, the corresponding ILM exists, and the label operation is SWAP. Check that the next hop information in the Donstream Mapping TLV matches the incoming interface of the packet; check the label of the packet. The stack is consistent with the target FEC stack.
C节点回复echo reply报文,包括:The C node replies with an echo reply message, including:
Upstream Interface TLV:{C&C.port1}Upstream Interface TLV: {C&C.port1}
Responder Transit TLV:{C}Responder Transit TLV: {C}
Downstream Mapping TLV1:{DS Flags:I=1,E/R=0,M=1;Downstream Address=G&G.port1}。Downstream Mapping TLV1: {DS Flags: I=1, E/R=0, M=1; Downstream Address=G&G.port1}.
Downstream Mapping TLV2:{DS Flags:I=1,E/R=0,M=1;Downstream Address=H&H.port1}。Downstream Mapping TLV2: {DS Flags: I=1, E/R=0, M=1; Downstream Address=H&H.port1}.
类似的,D节点收到echo request报文,回复echo reply报文,包括:Similarly, the D node receives the echo request packet and replies to the echo reply packet, including:
Upstream Interface TLV:{D&D.port1}Upstream Interface TLV: {D&D.port1}
Responder Egress TLV:{D}Responder Egress TLV: {D}
类似的,E节点收到echo request报文,回复echo reply报文,包括: Similarly, the E-node receives the echo request packet and replies to the echo reply packet, including:
Upstream Interface TLV:{E&E.port1}Upstream Interface TLV: {E&E.port1}
Responder Egress TLV:{E}Responder Egress TLV: {E}
类似的,F节点收到echo request报文,回复echo reply报文,包括:Similarly, the F node receives the echo request packet and replies to the echo reply packet, including:
Upstream Interface TLV:{F&F.port1}Upstream Interface TLV: {F&F.port1}
Responder Transit TLV:{F}Responder Transit TLV:{F}
Downstream Mapping TLV1:{DS Flags:I=1,E/R=0,M=1;Downstream Address=I&I.port1}。Downstream Mapping TLV1: {DS Flags: I=1, E/R=0, M=1; Downstream Address=I&I.port1}.
Downstream Mapping TLV2:{DS Flags:I=1,E/R=0,M=1;Downstream Address=J&J.port1}。Downstream Mapping TLV2: {DS Flags: I=1, E/R=0, M=1; Downstream Address=J&J.port1}.
步骤S1206Step S1206
R节点收到C节点的ehco reply,检查发现与当前echo request是匹配的,并且echo reply中的Upstream Interface TLV:{C&C.port1}与本地保存的Downstream Mapping条目1:{DS Flags:E/R=0,M=1;Downstream Address=C&C.port1}是匹配的。The R node receives the ehco reply of the C node, checks that it matches the current echo request, and the Upstream Interface TLV in the echo reply: {C&C.port1} and the locally saved Downstream Mapping entry 1: {DS Flags: E/R =0, M=1; Downstream Address=C&C.port1} is a match.
类似的,R节点收到D节点的echo reply,并且echo reply中的Upstream Interface TLV:{D&D.port1}与本地保存的Downstream Mapping条目2:{DS Flags:E/R=0,M=1;Downstream Address=D&D.port1}是匹配的。Similarly, the R node receives the echo reply of the D node, and the Upstream Interface TLV in the echo reply: {D&D.port1} and the locally saved Downstream Mapping entry 2: {DS Flags: E/R=0, M=1; Downstream Address=D&D.port1} is a match.
类似的,R节点收到E节点的echo reply,并且echo reply中的Upstream Interface TLV:{E&E.port1}与本地保存的Downstream Mapping条目3:{DS Flags:E/R=0,M=1;Downstream Address=E&E.port1}是匹配的。Similarly, the R node receives the echo reply of the E node, and the Upstream Interface TLV in the echo reply: {E&E.port1} and the locally saved Downstream Mapping entry 3: {DS Flags: E/R=0, M=1; Downstream Address=E&E.port1} is a match.
类似的,R节点收到F节点的echo reply,并且echo reply中的Upstream Interface TLV:{F&F.port1}与本地保存的Downstream Mapping条目4:{DS Flags:E/R=0,M=1;Downstream Address=F&F.port1}是匹配的。Similarly, the R node receives the echo reply of the F node, and the Upstream Interface TLV in the echo reply: {F&F.port1} and the locally saved Downstream Mapping entry 4: {DS Flags: E/R=0, M=1; Downstream Address=F&F.port1} is a match.
R节点从C的echo reply中获取新的Downstream Address信息并本地保存为:The R node obtains the new Downstream Address information from the echo reply of C and saves it locally as:
Downstream Mapping条目1:{DS Flags:E/R=0,M=1;Downstream Address=G&G.port1}Downstream Mapping entry 1: {DS Flags: E/R=0, M=1; Downstream Address=G&G.port1}
Downstream Mapping条目2:{DS Flags:E/R=0,M=1;Downstream Address=H&H.port1}Downstream Mapping entry 2: {DS Flags: E/R=0, M=1; Downstream Address=H&H.port1}
R节点从F的echo reply中获取新的Downstream Address信息并本地保存为:The R node obtains the new Downstream Address information from the echo reply of F and saves it locally as:
Downstream Mapping条目3:{DS Flags:E/R=0,M=1;Downstream Address=I&I.port1}Downstream Mapping entry 3: {DS Flags: E/R=0, M=1; Downstream Address=I&I.port1}
Downstream Mapping条目4:{DS Flags:E/R=0,M=1;Downstream Address=J&J.port1}Downstream Mapping entry 4: {DS Flags: E/R=0, M=1; Downstream Address=J&J.port1}
R发起下一轮echo request,类似步骤S1201,只不过栈顶标签LDP Label TTL=3。特别是包含的Downstream Mapping TLV与步骤S1201中是相同的。R initiates the next round of echo request, similar to step S1201, except that the top label LDP Label TTL=3. In particular, the included Downstream Mapping TLV is the same as in step S1201.
步骤S1207Step S1207
与步骤S1204是类似的,A,B节点分别修改发往特定组播成员下一跳的echo request报文中的Downstream Mapping TLV后转发报文。Similar to step S1204, the A and B nodes respectively modify the Downstream Mapping TLV in the echo request packet sent to the next hop of the specific multicast member, and then forward the packet.
步骤S1208Step S1208
与步骤S1204是类似的,C,F节点分别修改发往特定组播成员下一跳的echo request报文中的Downstream Mapping TLV后转发报文。Similar to step S1204, the C and F nodes respectively modify the Downstream Mapping TLV in the echo request message sent to the next hop of the specific multicast member, and then forward the packet.
D,E节点会再次向R节点回复echo reply,但是R节点上不会匹配到其本地保存的Downstream Mapping条目,这些echo reply会被丢弃。D, the E node will reply the echo reply to the R node again, but the R node will not match its locally saved Downstream Mapping entry, and these echo reply will be discarded.
步骤S1209Step S1209
与步骤S1205是类似的,G节点回复echo reply报文,包括:Similar to step S1205, the G node replies with an echo reply message, including:
Upstream Interface TLV:{G&G.port1}Upstream Interface TLV: {G&G.port1}
Responder Egress TLV:{G}Responder Egress TLV: {G}
类似的,H节点收到echo request报文,回复echo reply报文,包括: Similarly, the H node receives the echo request message and replies to the echo reply message, including:
Upstream Interface TLV:{H&H.port1}Upstream Interface TLV: {H&H.port1}
Responder Egress TLV:{H}Responder Egress TLV: {H}
类似的,I节点收到echo request报文,回复echo reply报文,包括:Similarly, the I node receives the echo request packet and replies to the echo reply packet, including:
Upstream Interface TLV:{I&I.port1}Upstream Interface TLV: {I&I.port1}
Responder Egress TLV:{I}Responder Egress TLV: {I}
类似的,J节点收到echo request报文,回复echo reply报文,包括:Similarly, the J node receives the echo request message and replies to the echo reply message, including:
Upstream Interface TLV:{J&J.port1}Upstream Interface TLV: {J&J.port1}
Responder Egress TLV:{J}Responder Egress TLV: {J}
步骤S1210Step S1210
与步骤S1203是类似的,R节点分别从G,H,I,J收到echo reply与本地保存的Downstream Mapping条目1~4进行匹配。Similar to step S1203, the R node receives the echo reply from G, H, I, and J, respectively, and matches the locally saved
R节点从echo reply中获取不到新的Downstream Address信息。检测完毕,输出检测结果,收到了Egress节点D,E,G,H,I,J的echo reply。The R node cannot obtain new Downstream Address information from the echo reply. After the detection is completed, the detection result is output, and the echo reply of the Egress node D, E, G, H, I, J is received.
实施例4Example 4
本发明的实施例还提供了一种存储介质。可选地,在本实施例中,上述存储介质可以被设置为存储用于执行以下步骤的程序代码:Embodiments of the present invention also provide a storage medium. Optionally, in the embodiment, the foregoing storage medium may be configured to store program code for performing the following steps:
S1,检测发起方发送回应请求报文,其中,回应请求报文中包括用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;S1, the detecting initiator sends an echo request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message;
S2,接收传输节点或出口节点根据MPLS OAM报文反馈的回应应答报文,并检测回应应答报文与预存信息是否匹配。S2: The receiving transmission node or the egress node responds to the response message according to the MPLS OAM packet, and detects whether the response response message matches the pre-stored information.
可选地,在本实施例中,上述存储介质可以包括但不限于:U盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、移动硬盘、磁碟或者光盘等各种可以存储程序代码的介质。Optionally, in this embodiment, the foregoing storage medium may include, but not limited to, a USB flash drive, a Read-Only Memory (ROM), a Random Access Memory (RAM), a mobile hard disk, and a magnetic memory. A variety of media that can store program code, such as a disc or a disc.
可选地,在本实施例中,处理器根据存储介质中已存储的程序代码执 行检测发起方发送回应请求报文,其中,回应请求报文中包括用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段;Optionally, in this embodiment, the processor executes according to the stored program code in the storage medium. The line detection initiator sends a response request message, where the response request message includes a type field for identifying a multi-protocol switching label MPLS operation and maintenance management OAM message;
可选地,在本实施例中,处理器根据存储介质中已存储的程序代码执行接收传输节点或出口节点根据MPLS OAM报文反馈的回应应答报文,并检测回应应答报文与预存信息是否匹配。Optionally, in this embodiment, the processor performs, according to the stored program code in the storage medium, the response response message that is received by the transmitting node or the egress node according to the MPLS OAM packet, and detects whether the response response message and the pre-stored information are match.
可选地,本实施例中的具体示例可以参考上述实施例及可选实施方式中所描述的示例,本实施例在此不再赘述。For example, the specific examples in this embodiment may refer to the examples described in the foregoing embodiments and the optional embodiments, and details are not described herein again.
显然,本领域的技术人员应该明白,上述的本发明的各模块或各步骤可以用通用的计算装置来实现,它们可以集中在单个的计算装置上,或者分布在多个计算装置所组成的网络上,可选地,它们可以用计算装置可执行的程序代码来实现,从而,可以将它们存储在存储装置中由计算装置来执行,并且在某些情况下,可以以不同于此处的顺序执行所示出或描述的步骤,或者将它们分别制作成各个集成电路模块,或者将它们中的多个模块或步骤制作成单个集成电路模块来实现。这样,本发明不限制于任何特定的硬件和软件结合。It will be apparent to those skilled in the art that the various modules or steps of the present invention described above can be implemented by a general-purpose computing device that can be centralized on a single computing device or distributed across a network of multiple computing devices. Alternatively, they may be implemented by program code executable by the computing device such that they may be stored in the storage device by the computing device and, in some cases, may be different from the order herein. The steps shown or described are performed, or they are separately fabricated into individual integrated circuit modules, or a plurality of modules or steps thereof are fabricated as a single integrated circuit module. Thus, the invention is not limited to any specific combination of hardware and software.
以上所述仅为本发明的优选实施例而已,并不用于限制本发明,对于本领域的技术人员来说,本发明可以有各种更改和变化。凡在本发明的精神和原则之内,所作的任何修改、等同替换、改进等,均应包含在本发明的保护范围之内。The above description is only the preferred embodiment of the present invention, and is not intended to limit the present invention, and various modifications and changes can be made to the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and scope of the present invention are intended to be included within the scope of the present invention.
如上所述,本实施例提供的一种多协议交换标签的检测、处理方法、装置及系统,具有以下有益效果:由于在回应请求报文中携带了用于标识多协议交换标签MPLS操作维护管理OAM报文的类型字段以便传输节点的转发平面根据实际转发信息自行修改报文,以及相应的一整套检测处理流程,因此,可以解决相关技术中LSP检测失真以及P2MP LSP检测低效与不充分的问题。 As described above, the method, device, and system for detecting and processing a multi-protocol exchange label provided by the embodiment have the following beneficial effects: the MPLS operation and maintenance management for identifying the multi-protocol exchange label is carried in the response request message. The type field of the OAM packet is such that the forwarding plane of the transmitting node modifies the packet according to the actual forwarding information and the corresponding set of detection processing flow. Therefore, the LSP detection distortion and the P2MP LSP detection inefficient and insufficient in the related art can be solved. problem.
Claims (16)
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201610567070.4A CN107623584A (en) | 2016-07-15 | 2016-07-15 | Detection and processing method, device and system of multi-protocol switching labels |
| CN201610567070.4 | 2016-07-15 |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2018010560A1 true WO2018010560A1 (en) | 2018-01-18 |
Family
ID=60952246
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2017/091477 Ceased WO2018010560A1 (en) | 2016-07-15 | 2017-07-03 | Method, apparatus, and system for detecting and processing multi-protocol label switching |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN107623584A (en) |
| WO (1) | WO2018010560A1 (en) |
Cited By (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2020125651A1 (en) * | 2018-12-17 | 2020-06-25 | 中兴通讯股份有限公司 | Label attribute identification method, apparatus and device, and storage medium |
| EP3937437A1 (en) * | 2020-06-30 | 2022-01-12 | Huawei Technologies Co., Ltd. | Packet loss processing method and network device |
| CN114500163A (en) * | 2020-10-23 | 2022-05-13 | 中国移动通信有限公司研究院 | Communication scheduling method, device and storage medium |
| CN116232996A (en) * | 2022-12-21 | 2023-06-06 | 中国人民解放军国防科技大学 | Label switching-based edge network data packet header compression transmission method and system |
Families Citing this family (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN110535771A (en) * | 2018-05-24 | 2019-12-03 | 中兴通讯股份有限公司 | A kind of data forwarding method, the network equipment and computer readable storage medium |
Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101325584A (en) * | 2007-06-15 | 2008-12-17 | 华为技术有限公司 | Route tracking method, MPLS network system and its entry node |
| CN101729391A (en) * | 2008-10-23 | 2010-06-09 | 华为技术有限公司 | Method, node and system for acquiring link aggregation group information |
| US20120176911A1 (en) * | 2010-06-10 | 2012-07-12 | Ping Pan | Supporting oam on protecting connections in shared mesh protection environment |
| US8472346B1 (en) * | 2007-06-08 | 2013-06-25 | Juniper Networks, Inc. | Failure detection for tunneled label-switched paths |
-
2016
- 2016-07-15 CN CN201610567070.4A patent/CN107623584A/en not_active Withdrawn
-
2017
- 2017-07-03 WO PCT/CN2017/091477 patent/WO2018010560A1/en not_active Ceased
Patent Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US8472346B1 (en) * | 2007-06-08 | 2013-06-25 | Juniper Networks, Inc. | Failure detection for tunneled label-switched paths |
| CN101325584A (en) * | 2007-06-15 | 2008-12-17 | 华为技术有限公司 | Route tracking method, MPLS network system and its entry node |
| CN101729391A (en) * | 2008-10-23 | 2010-06-09 | 华为技术有限公司 | Method, node and system for acquiring link aggregation group information |
| US20120176911A1 (en) * | 2010-06-10 | 2012-07-12 | Ping Pan | Supporting oam on protecting connections in shared mesh protection environment |
Cited By (6)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2020125651A1 (en) * | 2018-12-17 | 2020-06-25 | 中兴通讯股份有限公司 | Label attribute identification method, apparatus and device, and storage medium |
| EP3937437A1 (en) * | 2020-06-30 | 2022-01-12 | Huawei Technologies Co., Ltd. | Packet loss processing method and network device |
| US11570089B2 (en) | 2020-06-30 | 2023-01-31 | Huawei Technologies Co., Ltd. | Packet loss processing method and network device |
| CN114500163A (en) * | 2020-10-23 | 2022-05-13 | 中国移动通信有限公司研究院 | Communication scheduling method, device and storage medium |
| CN116232996A (en) * | 2022-12-21 | 2023-06-06 | 中国人民解放军国防科技大学 | Label switching-based edge network data packet header compression transmission method and system |
| CN116232996B (en) * | 2022-12-21 | 2024-05-28 | 中国人民解放军国防科技大学 | Label switching-based edge network data packet header compression transmission method and system |
Also Published As
| Publication number | Publication date |
|---|---|
| CN107623584A (en) | 2018-01-23 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US10581732B2 (en) | Target FEC (forwarding equivalence class) stack based FEC query in segment routing environments | |
| US11888726B2 (en) | Path establishment method and controller | |
| US9246799B2 (en) | Data plane learning of bi-directional service chains | |
| WO2017148139A1 (en) | Fault detection method and device | |
| US9350605B2 (en) | Method and apparatus for multi-instance control plane for dynamic MPLS-TP tunnel management via in-band communication channel (G-ACH) | |
| US11627070B2 (en) | Data packet processing method and apparatus, storage medium, and electronic device | |
| CN103004147B (en) | Message forwarding path determining method, network device and control device | |
| WO2019114437A1 (en) | Bier-te network detection method, device, and system | |
| WO2018010560A1 (en) | Method, apparatus, and system for detecting and processing multi-protocol label switching | |
| US11991066B2 (en) | Method of establishing bidirectional forwarding detection session based on BIER, and BFIR, BFER, system and storage medium | |
| EP4207685A1 (en) | Message header processing method and apparatus, storage medium and electronic device | |
| CN106375105B (en) | A method, controller, switch and system for determining path failure | |
| US11477114B2 (en) | Packet forwarding method and apparatus | |
| US11962491B2 (en) | Source routing tunnel ingress protection | |
| CN106789725B (en) | Method, device and system for realizing traffic redirection | |
| EP3361683B1 (en) | Path computation method and device | |
| US20240297841A1 (en) | Path computation method and apparatus, storage medium, and electronic device | |
| US11489768B2 (en) | Method for creating inter-domain bidirectional tunnel, communication method and device, and storage medium | |
| CN107645401A (en) | The detection of multiprotocol label switching, processing method, apparatus and system | |
| WO2020114083A1 (en) | Method and apparatus for processing ioam information | |
| CN106789705A (en) | The method and apparatus of transmission control message | |
| CN118869586A (en) | Label stack processing method, information processing method and message processing method | |
| CN117768063A (en) | Information notification method, network equipment and computer-readable storage medium | |
| CN110838965A (en) | Tunnel establishment method and receiving node |
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: 17826897 Country of ref document: EP Kind code of ref document: A1 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |
|
| 122 | Ep: pct application non-entry in european phase |
Ref document number: 17826897 Country of ref document: EP Kind code of ref document: A1 |