Path exploration method, apparatus, network device, and program product

By carrying probe request messages containing the IP address of the escape link interface in the MLAG network and checking the probe response messages hop by hop, the problem of path information detection failure and missing information in the MLAG network environment is solved, and successful and accurate path detection is achieved.

CN121193629BActive Publication Date: 2026-06-19MAIPU COMM TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
MAIPU COMM TECH CO LTD
Filing Date
2025-09-28
Publication Date
2026-06-19

AI Technical Summary

Technical Problem

In an MLAG networking environment, traditional path information detection methods are prone to detection failures or missing path information, making it impossible to accurately determine the reliability and fault status of network links.

Method used

The probe request message carries the IP address of the escape link interface of the MLAG device. By probing the path hop by hop, the probe response message receives and checks whether the IP address of the escape link interface in the probe response message is the same as the IP address of the escape link interface of this MLAG device, and determines that the path is reachable.

Benefits of technology

Successful path detection was achieved in an MLAG networking environment, ensuring the accuracy and reliability of path information and avoiding problems such as detection failure and missing path information.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121193629B_ABST
    Figure CN121193629B_ABST
Patent Text Reader

Abstract

This invention relates to the field of communication technology, providing a path detection method, apparatus, network device, and program product. It is applied to MLAG devices in a cross-device link aggregation (MLAG) network, where MLAG member devices are configured with Peer-Link links and escape links. The method includes: sending a probe request message to a target host, the probe request message carrying the IP address of the escape link interface of the MLAG device; receiving a probe response message sent by a network device; if the IP address of the escape link interface carried in the probe response message is the same as the IP address of the escape link interface of the MLAG device, then it is determined that the path between the MLAG device and the network device is reachable. This invention can successfully detect the path.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of communication technology, and more specifically, to a path detection method, apparatus, network equipment, and program product. Background Technology

[0002] MLAG (Multi-Chassis Link Aggregation Group) networking technology is a cross-device link aggregation technology. MLAG networking technology aggregates two or more independent physical devices into a single logical device, achieving both load balancing and improving link reliability to the device level.

[0003] In an MLAG networking environment, to better aggregate member devices into logically unified devices and enhance link reliability, access-side services are typically deployed using anycast (i.e., within the same MLAG domain, the Layer 3 interface IP addresses and MAC addresses of services in the same MLAG group are identical on all member devices); while network-side services are deployed using ECMP to ensure that traffic from the network side can be distributed across all MLAG member devices. Furthermore, to ensure that access-side traffic can still be forwarded normally when the network-side link of any MLAG member device fails, escape links for network-side services must be deployed between MLAG member devices.

[0004] When maintaining a network environment, path information probing is typically used. This involves sending probe request messages and receiving probe response messages to obtain the actual forwarding path of the corresponding service, thereby determining whether a link in the network has failed. In an MLAG networking environment, due to the characteristics of MLAG networking, MLAG member devices within the same MLAG domain and the same MLAG service group have identical Layer 3 interface IP addresses and MAC addresses. Using traditional path information probing methods can lead to probing failures or missing path information. Summary of the Invention

[0005] The purpose of this invention is to provide a path detection method, device, network equipment, and program product that can successfully detect paths.

[0006] The embodiments of the present invention can be implemented as follows:

[0007] In a first aspect, the present invention provides a path detection method applied to MLAG devices in a cross-device link aggregation (MLAG) network, wherein the MLAG member devices in the MLAG network are configured with Peer-Link links and escape links, the method comprising:

[0008] Send a probe request message to the target host to perform path probing. The probe request message carries the IP address of the escape link interface of this MLAG device.

[0009] Receive probe response messages sent by network devices;

[0010] If the escape link interface IP address carried in the probe response message is the same as the escape link interface IP address of this MLAG device, then it is determined that the path between this MLAG device and the network device is reachable.

[0011] In an optional implementation, the method further includes:

[0012] If the escape link interface IP address carried in the probe response message is different from the escape link interface IP address of this MLAG device, and the source IP address of the probe response message is the Layer 3 interface IP address of this MLAG device, then the probe response message is sent through the Peer-Link link or the escape link.

[0013] In an optional implementation, the probe request message is pre-set with a Time-to-Live (TTL) during generation, and after the step of determining the path reachability between the MLAG device and the network device, it includes:

[0014] If the network device is not the target host, a new probe request message is generated and sent. The TTL carried in the new probe request message is obtained by adding 1 to the TTL of the previously generated probe request message.

[0015] Secondly, the present invention provides a path detection method applied to network devices, the method comprising:

[0016] Receive a probe request message, which is sent by any MLAG device in the cross-device link aggregation group (MLAG) network when probing a target host. The probe request message carries the escape link interface IP address of any MLAG device.

[0017] If the conditions for responding to the probe request message are met, a probe response message is generated, which includes the IP address of the escape link interface.

[0018] Send the probe response message so that when any MLAG device determines that the escape link interface IP address carried in the probe response message is the same as the escape link interface IP address of this MLAG device, it can determine that the path between any MLAG device and this network device is reachable.

[0019] In an optional implementation, if the network device is an MLAG device, the step of sending the probe response message includes:

[0020] If the link receiving the probe request message is a Peer-Link link or an escape link, and the source IP address in the probe request message is the same as the Layer 3 interface IP address of this MLAG device, and the escape link interface IP address in the probe request message is different from the escape link interface IP address of this network device, then the escape link interface IP address in the probe request message is used as the destination IP address of the probe response message, and the escape link interface IP address of this network device is used as the source IP address of the probe response message, and the probe response message is sent.

[0021] If the link receiving the probe request message is a Peer-Link link or an escape link, and the source IP address in the probe request message is different from the Layer 3 interface IP address of this network device, then the source IP address in the probe request message is used as the destination IP address of the probe response message, and the escape link interface IP address of this network device is used as the source IP address of the probe response message, and the probe response message is sent.

[0022] In an optional implementation, if the network device is an RR device, the step of sending the probe response message includes:

[0023] The probe response message is sent by using the source IP address in the probe request message as the destination IP address of the probe response message and the IP address of the Layer 3 interface that receives the probe request message as the source IP address of the probe response message.

[0024] Thirdly, the present invention provides a path detection device applied to MLAG devices in a cross-device link aggregation (MLAG) network, wherein the MLAG member devices in the MLAG network are configured with Peer-Link links and escape links, and the device includes:

[0025] The request sending module is used to send a probe request message for path probing of the target host. The probe request message carries the IP address of the escape link interface of this MLAG device.

[0026] The response receiving module is used to receive probe response messages sent by network devices;

[0027] The determination module is used to determine that the path between the MLAG device and the network device is reachable if the escape link interface IP address carried in the probe response message is the same as the escape link interface IP address of the MLAG device.

[0028] Fourthly, the present invention provides a path detection device applied to network equipment, the device comprising:

[0029] The request receiving module is used to receive probe request messages, which are sent by any MLAG device in the cross-device link aggregation group (MLAG) network when probing the target host. The probe request message carries the escape link interface IP address of any MLAG device.

[0030] The generation module is used to generate a probe response message if the conditions for responding to the probe request message are met. The probe response message includes the IP address of the escape link interface.

[0031] The response sending module is used to send the probe response message so that when any MLAG device determines that the escape link interface IP address carried in the probe response message is the same as the escape link interface IP address of this MLAG device, it can determine that the path between any MLAG device and this network device is reachable.

[0032] Fifthly, the present invention provides a network device including a processor and a memory, the memory being used to store a program, and the processor being used to implement the path detection method described in the first aspect and / or the path detection method described in the second aspect when executing the program.

[0033] In a sixth aspect, the present invention provides a program product that, when executed by a processor, implements the path detection method described in the first aspect and / or the path detection method described in the second aspect.

[0034] Compared with the prior art, the present invention has the following beneficial effects:

[0035] By including the escape link interface IP address of this MLAG device in the probe request message, since the escape link interface IP address of the MLAG device is unique within the same MLAG domain, the MLAG device that sends the probe request message can receive the corresponding probe response message, and thus the probe path is successfully detected based on the probe response message. Attached Figure Description

[0036] To more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of the present invention and should not be regarded as a limitation on the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.

[0037] Figure 1 This is an example diagram illustrating an application scenario provided in this embodiment.

[0038] Figure 2 This is a block diagram of a network device provided in this embodiment.

[0039] Figure 3 This is a flowchart illustrating the path detection method for MLAG devices provided in this embodiment.

[0040] Figure 4 This is an example diagram of hop-by-hop path detection provided in this embodiment.

[0041] Figure 5 This is a flowchart illustrating the path detection method for network devices provided in this embodiment.

[0042] Figure 6 This is a block diagram of a path detection device applied to MLAG equipment provided in this embodiment.

[0043] Figure 7 This is a block diagram of a path detection device applied to a network device provided in this embodiment.

[0044] Icons: 10-Network device; 11-Processor; 12-Memory; 13-Bus; 100-Path detection device for MLAG devices; 110-Request sending module; 120-Response receiving module; 130-Determination module; 200-Path detection device for network devices; 210-Request receiving module; 220-Generation module; 230-Response sending module. Detailed Implementation

[0045] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. The components of the embodiments of the present invention described and shown in the accompanying drawings can generally be arranged and designed in various different configurations.

[0046] Therefore, the following detailed description of the embodiments of the invention provided in the accompanying drawings is not intended to limit the scope of the claimed invention, but merely to illustrate selected embodiments of the invention. All other embodiments obtained by those skilled in the art based on the embodiments of the invention without inventive effort are within the scope of protection of the invention.

[0047] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.

[0048] In the description of this invention, it should be noted that if terms such as "upper," "lower," "inner," or "outer" are used to indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings, or the orientation or positional relationship in which the product of this invention is usually placed, they are only for the convenience of describing this invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of this invention.

[0049] Furthermore, the terms "first" and "second" are used only to distinguish descriptions and should not be interpreted as indicating or implying relative importance.

[0050] It should be noted that, where there is no conflict, the features in the embodiments of the present invention can be combined with each other.

[0051] Please refer to Figure 1 , Figure 1 This is an example diagram illustrating an application scenario provided in this embodiment. Figure 1 In this context, MLAG domain 1 includes two MLAG devices, MLAG1-1 and MLAG1-2, with two links between them: a Peer-Link link and an escape link. MLAG domain 2 includes two MLAG devices, MLAG2-1 and MLAG2-2, with two links between them: a Peer-Link link and an escape link. A Peer-Link link is one or more high-speed, highly reliable, and low-latency standard interconnection links between two MLAG devices. An escape link is a backup of the Peer-Link link, used to maintain communication in the event of a complete Peer-Link failure between the two MLAG devices.

[0052] MLAG domain 1 and MLAG domain 2 communicate through RR (Route Reflector) devices. MLAG1-1 and MLAG1-2 in MLAG domain 1 are connected to the access host 1 through the link aggregation port of LACP (Link Aggregation Control Protocol). MLAG2-1 and MLAG2-2 in MLAG domain 2 are connected to the access host 2 through the link aggregation port of LACP.

[0053] To more clearly describe the problems existing in traditional path detection methods, this embodiment combines... Figure 1 The application scenario will be explained in detail by taking the path detection from MLAG 1-1 node to host 2 as an example.

[0054] Question 1: If the probe response message from the RR device or the MLAG device in MLAG domain 2 is forwarded to the MLAG1-2 device, the message will be terminated by the MLAG1-2 device because the destination IP address of the probe response message also exists on the MLAG1-2 device. As a result, the MLAG1-1 device will not receive the probe response message, leading to the situation where the target host being probed is unreachable or the path information is missing.

[0055] Question 2: If the uplink of MLAG1-1 fails, the probe request message will be forwarded to the MLAG1-2 device. However, when the MLAG1-2 device responds to the probe reply message, it finds that the destination IP address of the probe reply message (i.e. the source IP address of the probe request message) is itself, so it cannot reply. As a result, the probe path information does not contain the path information corresponding to the first hop.

[0056] Question 3: If the uplink of MLAG2-1 and the downlink of MLAG2-2 fail simultaneously, when a probe request packet arrives at MLAG2-2, MLAG2-2 will use the IP address of its own Layer 3 interface as the source IP address of the probe response packet to respond. However, when the next probe request packet arrives at MLAG2-1, it will use the exact same source IP address as MLAG2-2 to respond to the probe response packet. This will eventually lead to two identical probe messages on the MLAG1-1 device, making it impossible to determine the correctness of the path information and the actual forwarding path of the packet.

[0057] To address the above issues, the following two solutions are some of the solutions that can be considered:

[0058] Option 1:

[0059] An independent controller is deployed to manage all devices in the network, sending path information, probe control information, and capturing probe request messages to all devices along the path. Once a device along the path captures the corresponding probe request message, each device reports its node information to the controller. However, this solution suffers from high deployment costs, poor compatibility, and the inability to guarantee the order of path information.

[0060] Option 2:

[0061] This method synchronizes connectivity probe requests among MLAG member devices within the same MLAG domain. When a probe response message is sent to another MLAG member device, the response message is forwarded to that device. However, this method only works within the current MLAG domain and cannot be synchronously applied to other MLAG domains on the network side. Most importantly, this method only addresses connectivity issues and cannot obtain path information to the target host.

[0062] In view of this, this embodiment provides a path detection method, apparatus, network device, and program product, which can successfully detect the path. It will be described in detail below.

[0063] Please refer to Figure 2 , Figure 2 This is a block diagram of a network device 10 provided in this embodiment. The network device 10 includes a processor 11, a memory 12, and a bus 13. The processor 11 and the memory 12 are connected through the bus 13.

[0064] The processor 11 can be an integrated circuit chip with signal processing capabilities. In implementation, each step of the path detection method in this embodiment can be completed by the integrated logic circuitry in the processor 11 or by software instructions. The processor 11 can be a general-purpose processor, including a CPU (Central Processing Unit), an NP (Network Processor), etc.; it can also be a DSP (Digital Signal Processor), an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Logic Gate Array), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.

[0065] The memory 12 is used to store the program that implements the path detection method. The program can be a software function module stored in the memory 12 in the form of software or firmware or embedded in the OS (Operating System) of the network device 10.

[0066] After receiving the execution instruction, the processor 11 executes the program to implement the path detection method of this embodiment.

[0067] Network device 10 can be Figure 1 The MLAG device or RR device in this embodiment is used to perform the path detection method on the corresponding device.

[0068] based on Figure 1 and Figure 2 This embodiment first describes the MLAG device side that sends the probe request message. Please refer to [link / reference]. Figure 3 , Figure 3 This is a flowchart illustrating the path detection method for MLAG equipment provided in this embodiment. The method includes the following steps:

[0069] Step S101: Send a probe request message to the target host to perform path probing. The probe request message carries the IP address of the escape link interface of this MLAG device.

[0070] In this embodiment, path probing of the target host can be performed by sending a probe request message to the target host hop by hop. Each probe request message is sent to probe the hop information, including reachable devices and reachable paths. As the number of hops obtained increases, the path from this MLAG device to the target host is eventually detected.

[0071] In this embodiment, the escape link interface IP address is the Layer 3 interface IP address of the escape link configured on this MLAG device. To facilitate the return of the escape link interface IP address from the probe request message when devices on the probe path respond to the probe request message, the probe request message can be an IP packet. The escape link interface IP address of this MLAG device can be set in the option field of the IP header of the probe request message. According to the IP protocol standard, network devices on the path will return the escape link interface IP address from the probe request message when responding to the probe response message. It is understood that the probe request message can be a UDP packet, and the probe response message from network devices on the probe path is generally an ICMP error message indicating a TTL (Time To Live) timeout; the probe response message from the target host is generally an ICMP error message indicating that the port is unreachable.

[0072] In this embodiment, the target host can be any host connected to the MLAG network. The MLAG device and the target host can communicate via the LACP protocol, for example, Figure 1 In the MLAG1-1 and Host 1 configuration, the MLAG device and the target host can also communicate across MLAG domains, for example, Figure 1 MLAG1-1 and host 2 in the middle.

[0073] Step S102: Receive the probe response message sent by the network device.

[0074] In this embodiment, since path probing is performed hop-by-hop, the network device sending the probe response message can be either an MLAG device or an RR device, depending on the number of hops.

[0075] Step S103: If the escape link interface IP address carried in the probe response message is the same as the escape link interface IP address of this MLAG device, then it is determined that the path between this MLAG device and the network device is reachable.

[0076] In this embodiment, the escape link interface IP address carried in the probe response message is the same as the escape link interface IP address of this MLAG device. This means that the probe response message received by this MLAG device is a probe request message sent by this MLAG device, i.e., it obtains a path from this MLAG device to the network device corresponding to the source IP address in the probe response message. For example, Figure 1 In the probe response message returned by MLAG1-1 to detect the path to host 1, the source IP address of MLAG1-2 is found in the first hop probe. This indicates that the first hop probe obtained the path from MLAG1-1 to MLAG1-2, suggesting a possible failure in the uplink of MLAG1-1. The source IP address of RR is found in the probe response message returned by the second hop probe. This means that the second hop probe obtained the path from MLAG1-1 to MLAG1-2, and then from MLAG1-2 to the RR device, indicating that the path between MLAG1-1 and the RR device is reachable.

[0077] The method provided in this embodiment carries the escape link interface IP address of the MLAG device in the probe request message. Since the escape link interface IP address of the MLAG device is unique in the same MLAG domain, the MLAG device that sends the probe request message can receive the corresponding probe response message carrying the same escape link interface IP address, and thus successfully detect the probe path based on the probe response message.

[0078] In this embodiment, if the escape link interface IP address carried in the probe response message is different from the escape link interface IP address of the MLAG device that sent the probe request message, it is determined that the probe response message was not sent to this MLAG device. In this case, the MLAG device needs to forward the received probe response message. This embodiment also provides the following processing method:

[0079] If the escape link interface IP address carried in the probe response message is different from the escape link interface IP address of this MLAG device, and the source IP address of the probe response message is the Layer 3 interface IP address of this MLAG device, then the probe response message is sent through the Peer-Link link or the escape link.

[0080] In this embodiment, if the escape link interface IP address carried in the probe response message is different from the escape link interface IP address of this MLAG device, and the source IP address of the probe response message is the Layer 3 interface IP address of this MLAG device, it means that the MLAG member device in the same MLAG domain as this MLAG device is the real receiver of the probe response message. At this time, the probe response message can be forwarded directly to the MLAG member device through the Peer-Link link, or it can be forwarded to the MLAG member device through the escape link.

[0081] It should be noted that in this case, if the probe response message is forwarded via the escape link, the destination IP address in the probe response message needs to be modified to the escape link interface IP address carried in the probe response message (i.e., the escape link interface IP address of this MLAG member device).

[0082] It should also be noted that, in addition to the above situations and the situation in step S103, there may also be cases where the probe response message is neither sent to this MLAG device nor to MLAG member devices. In this case, the message is processed according to the traditional logic. One specific processing method is: if the escape link interface IP address carried in the probe response message is different from the escape link interface IP address of this MLAG device, and the source IP address of the probe response message is not the Layer 3 interface IP address of this MLAG device, then the probe response message is forwarded directly.

[0083] In this embodiment, since path probing is performed hop-by-hop, if a path to the target host has not yet been detected after the current hop probing is completed, probing needs to continue. Therefore, this embodiment distinguishes between different hop counts in the TTL of the probe request message. Thus, after determining the path reachability between this MLAG device and the network device, the following processing can also be performed:

[0084] If the network device sending the probe response message is not the target host, a new probe request message is generated and sent. The TTL carried in the regenerated probe request message is obtained by adding 1 to the TTL of the previously generated probe request message.

[0085] In this embodiment, during hop-by-hop probing, each hop is incremented based on the TTL set in the previous hop probe request message, ultimately achieving path probing from the MLAG device to the target host. As one implementation, when the probe request message uses an IP packet, the TTL field in the IP packet header can be set. For example, the TTL is set to 1 for the first hop, 2 for the second hop, and so on, until the target host is reached.

[0086] To more intuitively demonstrate the hop-by-hop detection process, this embodiment combines... Figure 1 The detection process from MLAG1-1 to host 2 will be used as an example for explanation. Please refer to [link / reference]. Figure 4 , Figure 4 This is an example diagram of hop-by-hop path detection provided in this embodiment. Figure 4 In the process, MLAG1-1 sends the first probe request message with TTL set to 1, and then receives a probe response message from RR device, thus obtaining path information 1: MLAG1-1→RR, the path between MLAG1-1 and RR device is reachable. Since MLAG1-1 does not know the path to host 2, MLAG1-1 sends a second probe request message with TTL set to 2, and then receives a probe response message from MLAG2-1, thus obtaining path information 2: RR→MLAG2-1, that is, the path between MLAG1-1 and MLAG2-1 is reachable. At this time, MLAG1-1 still does not know the path to host 2, so MLAG1-1 sends a third probe request message with TTL set to 3, and then receives a probe response message from host 2, thus obtaining path information 3: MLAG2-1→host 2. Thus, MLAG1-1 knows that the complete path to host 2 is: MLAG1-1→RR→MLAG2-1→host 2, completing the path detection.

[0087] The above description is from the perspective of the MLAG device sending the probe request message. This embodiment will now describe the process from the perspective of the network device receiving the probe request message. Please refer to [link / reference]. Figure 5 , Figure 5 This is a flowchart illustrating the path detection method for network devices provided in this embodiment. The method includes the following steps:

[0088] Step S201: Receive a probe request message. The probe request message is sent by any MLAG device in the cross-device link aggregation group (MLAG) network when it performs path probing on the target host. The probe request message carries the IP address of the escape link interface of any MLAG device.

[0089] Step S202: If the conditions for responding to the probe request message are met, a probe response message is generated, which includes the IP address of the escape link interface.

[0090] In this embodiment, the conditions for satisfying the response probe request message can be that the TTL in the probe request message decreases to 0 on the network device, or that the destination IP address in the probe request message is the IP address of the network device. If the conditions for satisfying the response probe request message are not met, the received probe request message can be forwarded directly according to the existing processing logic.

[0091] Step S203: Send a probe response message so that if any MLAG device determines that the escape link interface IP address carried in the probe response message is the same as the escape link interface IP address of this MLAG device, it can determine that the path between any MLAG device and this network device is reachable.

[0092] In this embodiment, the way the network device sends probe response messages varies depending on the situation, including at least the following situations:

[0093] Scenario 1:

[0094] If the link receiving the probe request message is a Peer-Link link or an escape link, and the source IP address in the probe request message is the same as the Layer 3 interface IP address of this network device, and the escape link interface IP address in the probe request message is different from the escape link interface IP address of this network device, then the escape link interface IP address in the probe request message will be used as the destination IP address of the probe response message, and the escape link interface IP address of this network device will be used as the source IP address of the probe response message, and a probe response message will be sent.

[0095] In scenario one above, the network device could be one MLAG device within the same MLAG domain sending a probe request message to another MLAG device, and the MLAG device receiving the probe request message needing to return a probe response message. For example, Figure 1 In this process, MLAG1-1 sends a probe request message to MLAG1-2, and MLAG1-2 needs to return a probe response message. In this embodiment, the probe response message is returned via the escape link. Therefore, the IP address of the escape link interface in the probe request message is used as the destination IP address of the probe response message, and the IP address of the escape link interface of this MLAG device is used as the source IP address of the probe response message. Thus, the probe response message can be sent normally through the escape link.

[0096] Scenario 2:

[0097] If the link receiving the probe request message is a Peer-Link or an escape link, and the source IP address in the probe request message is different from the Layer 3 interface IP address of this network device, then the source IP address in the probe request message will be used as the destination IP address of the probe response message, and the escape link interface IP address of this network device will be used as the source IP address of the probe response message, and a probe response message will be sent.

[0098] The second scenario described above corresponds to a network device receiving a probe request message that is an MLAG device. The probe request message is sent from another MLAG member device, but these two MLAG devices and the MLAG device that initiated the probe request message do not belong to the same MLAG domain. The MLAG device receiving the probe request message needs to return a probe response message. For example, MLAG1-1 sends a probe request message, which is then sent to MLAG2-1 and from MLAG2-1 to MLAG2-2. In this embodiment, the source IP address in the probe request message is used as the destination IP address of the probe response message, and the escape link interface IP address of this MLAG device is used as the source IP address of the probe response message.

[0099] Both scenarios 1 and 2 described above involve MLAG devices receiving probe request packets. However, there are also scenarios where the receiving probe request packets are not from MLAG devices. For example, the network device receiving the probe request packets might be... Figure 1 Therefore, given the RR condition, scenario three also exists:

[0100] The probe response message is sent by using the source IP address in the probe request message as the destination IP address of the probe response message and the IP address of the Layer 3 interface that receives the probe request message as the source IP address of the probe response message.

[0101] The above situation three falls under the category of general message forwarding processing.

[0102] To more intuitively illustrate the path detection method provided in this embodiment, this embodiment will combine... Figure 1 The application scenarios are illustrated with examples of the following typical scenarios.

[0103] Scene 1:

[0104] Figure 1 When all links are functioning normally, and the MLAG1-1 device detects the path information to host 2, the MLAG1-1 first constructs a probe request message. The key information in the probe request message includes: the destination IP address is the IP address of host 2, the source IP address is the IP address of the Layer 3 interface on the MLAG1-1, the message TTL, and the IP address of the escape link interface on the MLAG1-1 device.

[0105] When the probe request message arrives at the RR device, since the TTL is about to reach 0, the RR device will send a TTL timeout error message (i.e., a probe response message) to the MLAG1-1 device. This probe response message will carry the escape link interface IP address of the MLAG1-1 device. Because the route to MLAG1-1 on the RR device is an ECMP route, when the RR device responds to the probe response message, there is a 50% probability that the probe response message will be sent directly to MLAG1-1 and a 50% probability that it will be sent directly to MLAG1-2.

[0106] When the probe response message from the RR device is directly sent to MLAG1-2, MLAG1-2 needs to parse the message to obtain and check the escape link interface IP address. Since the escape link interface IP address is not on MLAG1-2, it needs to forward the message to MLAG1-1. This can be done via a Peer-Link or an escape link. After the message is forwarded to MLAG1-1, it also needs to check the escape link interface IP address. Since this IP address is on MLAG1-1, it can receive the message and obtain the first-hop probe information for the entire path information probe based on the source IP address.

[0107] When the probe response message recovered by the RR device is directly sent to the MLAG1-1 device, it is also necessary to check the escape link interface IP address information in the probe response message to confirm that the escape link interface IP address information is on this device before further processing can be performed, and the first hop probe information of the entire path information probe can be obtained.

[0108] After the first-hop path information probe is completed, since no probe response message is received from host 2, the MLAG1-1 device will continue to initiate the next round of path probe requests. Similar to the above process, the MLAG1-1 device will receive probe response messages from the MLAG-1 device (or MLAG2-2 device) and host 2 in sequence, and finally collect the complete path information from the MLAG1-1 device to the host 2 device.

[0109] Scene 2:

[0110] when Figure 1When the uplink of MLAG1-1 device fails, it will also construct a probe request message first when probing for path information to host 2. Because the uplink of MLAG1-1 fails, the probe request message will first be sent from MLAG1-1 device to MLAG1-2 device.

[0111] When the probe request message arrives at the MLAG1-2 device, since the TTL is about to decrease to 0, the MLAG1-2 device also needs to send a probe response message to the device at the source IP address of the probe request message. Simultaneously, the MLAG1-2 device needs to parse and check the escape link interface IP address carried in the probe request message. If the receiving link of the probe request message is a Peer-Link link or an escape link, and the source IP address of the probe request message is on the MLAG1-2 device, but the escape link interface IP address carried in the message is not on the MLAG1-2 device, then when the MLAG1-2 responds to the probe request message with a probe response message, the source IP address of the probe response message needs to be specified as the escape link interface IP address on the MLAG1-2 device, and the destination IP address needs to be specified as the escape link interface IP address carried in the probe request message (i.e., the MLAG1-1 escape link interface IP address). When the MLAG1-1 device receives the probe response message from the MLAG1-2 device, it can obtain the first hop of the path information to host 2 as the MLAG1-2 device, and can also determine that the uplink from the MLAG1-1 device to host 2 has failed based on this path information.

[0112] After the first-hop path information probe is completed, since no probe response message is received from Host 2, the MLAG1-1 device will continue to initiate the next round of path probe requests. At this time, with the uplink of the MLAG1-1 device failing, the probe response messages from the RR device and the MLAG devices in MLAG domain 2 will be sent to the MLAG1-2 device. When the MLAG1-2 device receives the probe response message, it needs to obtain and check the escape link interface IP address in the probe response message. Since the escape link interface IP address in the probe response message is not on the MLAG1-2 device, the MLAG1-2 device needs to forward the probe response message to the MLAG1-1 device. Finally, the MLAG1-1 device can collect the complete path information to Host 2 device.

[0113] Scene 3

[0114] Figure 1When both the uplink of MLAG2-1 and the downlink of MLAG2-2 fail simultaneously, MLAG1-1 probes for path information to host 2. When the probe request message arrives at RR and MLAG2-2, the probe response messages from RR and MLAG2-2, as described above, can be normally sent to MLAG1-1, enabling MLAG1-1 to obtain this part of the path information.

[0115] When the probe request message reaches the MLAG2-1 device via the MLAG2-2 device, the TTL is about to decrease to 0. Therefore, the MLAG2-1 device needs to send a probe response message to the device at the source IP address of the probe request message. At this time, the MLAG2-1 device needs to obtain the source IP address information and receiving link information of the probe request message. If the receiving link of the probe request message is a Peer-Link link or an escape link, and the source IP address of the probe request message is not on the MLAG2-1 device, then when the MLAG2-1 device responds to the probe request message with a probe response message, the source IP address of the probe response message needs to be specified as the escape link interface IP address on the MLAG2-1 device. Similarly, when the MLAG1-1 device receives the probe response message from the MLAG2-1 device, it can obtain that the penultimate hop of the path information to host 2 is the MLAG2-1 device. It can also determine based on this path information that the uplink of MLAG2-1 and the uplink of MLAG2-2 in MLAG domain 2 have failed on the path to host 2.

[0116] To perform the corresponding steps in the above embodiments and various possible implementations, an implementation of a path detection device 100 applied to an MLAG device is given below. Please refer to... Figure 6 , Figure 6 This is a block diagram of the path detection device for MLAG equipment provided in this embodiment. It should be noted that the basic principle and technical effects of the path detection device 100 for MLAG equipment provided by the present invention are the same as those of the corresponding embodiments described above. For the sake of brevity, some parts of this embodiment are not mentioned.

[0117] The path detection device 100 applied to MLAG equipment includes a request sending module 110, a response receiving module 120, and a determination module 130.

[0118] The request sending module 110 is used to send a probe request message for path probing of the target host. The probe request message carries the IP address of the escape link interface of this MLAG device.

[0119] The response receiving module 120 is used to receive probe response messages sent by network devices;

[0120] The determination module 130 is used to determine that the path between the MLAG device and the network device is reachable if the escape link interface IP address carried in the probe response message is the same as the escape link interface IP address of the MLAG device.

[0121] In an optional implementation, the determining module 130 is further configured to:

[0122] If the escape link interface IP address carried in the probe response message is different from the escape link interface IP address of this MLAG device, and the source IP address of the probe response message is the Layer 3 interface IP address of the MLAG device, then the probe response message is sent through the Peer-Link link or the escape link.

[0123] In an optional implementation, the probe request message is pre-set with a Time-to-Live (TTL) during generation, and the determination module 130 is further configured to:

[0124] If the network device is not the target host, a new probe request message is generated and sent. The TTL carried in the regenerated probe request message is obtained by adding 1 to the TTL of the previously generated probe request message.

[0125] To perform the corresponding steps in the above embodiments and various possible implementations, an implementation of a path detection device 200 applied to a network device is given below. Please refer to... Figure 7 , Figure 7 This is a block diagram of the path detection device 200 for network devices provided in this embodiment. It should be noted that the basic principle and technical effects of the path detection device 200 for network devices provided by the present invention are the same as those of the corresponding embodiments described above. For the sake of brevity, some parts of this embodiment are not mentioned.

[0126] The path detection device 200 applied to network devices includes a request receiving module 210, a generation module 220, and a response sending module 230.

[0127] The request receiving module 210 is used to receive probe request messages. The probe request message is sent by any MLAG device in the cross-device link aggregation group (MLAG) network when it performs path probing on the target host. The probe request message carries the escape link interface IP address of any MLAG device.

[0128] The generation module 220 is used to generate a probe response message if the conditions for responding to the probe request message are met. The probe response message includes the IP address of the escape link interface.

[0129] The response sending module 230 is used to send a probe response message so that if any MLAG device determines that the escape link interface IP address carried in the probe response message is the same as the escape link interface IP address of this MLAG device, then the path between any MLAG device and this network device is reachable.

[0130] In an optional implementation, the response sending module 230 is specifically used for:

[0131] If the link receiving the probe request message is a Peer-Link link or an escape link, and the source IP address in the probe request message is the same as the Layer 3 interface IP address of this MLAG device, and the escape link interface IP address in the probe request message is different from the escape link interface IP address of this network device, then the escape link interface IP address in the probe request message will be used as the destination IP address of the probe response message, and the escape link interface IP address of this network device will be used as the source IP address of the probe response message, and the probe response message will be sent.

[0132] If the link receiving the probe request message is a Peer-Link or an escape link, and the source IP address in the probe request message is different from the Layer 3 interface IP address of this network device, then the source IP address in the probe request message will be used as the destination IP address of the probe response message, and the escape link interface IP address of this network device will be used as the source IP address of the probe response message, and a probe response message will be sent.

[0133] In an optional implementation, the response sending module 230 is further configured to:

[0134] The probe response message is sent by using the source IP address in the probe request message as the destination IP address of the probe response message and the IP address of the Layer 3 interface that receives the probe request message as the source IP address of the probe response message.

[0135] This invention also provides a program product, which, when executed by a processor, implements the path detection method applied to MLAG devices and / or the path detection method applied to network devices.

[0136] In summary, this invention provides a path detection method, apparatus, network device, and program product, applied to MLAG devices in a cross-device link aggregation (MLAG) network. The MLAG member devices in the MLAG network are configured with Peer-Link links and escape links. The method includes: sending a detection request message to a target host for path detection, the detection request message carrying the IP address of the escape link interface of the MLAG device; receiving a detection response message sent by a network device; if the IP address of the escape link interface carried in the detection response message is the same as the IP address of the escape link interface of the MLAG device, then it is determined that the path between the MLAG device and the network device is reachable. Compared with the prior art, this embodiment has at least the following advantages: (1) By carrying the escape link interface IP address of the MLAG device in the probe request message, since the escape link interface IP address of the MLAG device is unique in the same MLAG domain, the MLAG device that sends the probe request message can receive the corresponding probe response message through the escape link interface IP address of the MLAG device, and thus the probe path is successfully probed according to the probe response message; (2) Both the probe request message and the probe response message carry the escape link information of the MLAG member device, thereby solving the problem of opaque forwarding paths between MLAG member devices. The problems are: (3) Different network path devices perform differentiated processing based on the escape link information carried in the probe request message and probe response message, so as to obtain the real forwarding path information in the state of link failure; (4) In the scenario without relying on additional controller devices, the complete path information to the target device can be obtained directly on the MLAG member device in the MLAG network; (5) Based on traditional path detection, the devices in the network path can be well compatible except for MLAG member devices; (6) Based on the obtained path information, it can be quickly analyzed whether a fault has occurred on the path to the target device, which can effectively improve the network operation and maintenance efficiency.

[0137] The above descriptions are merely various embodiments of the present invention, but the scope of protection of the present invention is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in the present invention should be included within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.

Claims

1. A path detection method, characterized in that, The method, applied to MLAG devices in a cross-device link aggregation (MLAG) network, wherein MLAG member devices in the MLAG network are configured with Peer-Link links and escape links, includes: Send a probe request message to the target host to perform path probing. The probe request message carries the IP address of the escape link interface of this MLAG device. Receive probe response messages sent by network devices; If the escape link interface IP address carried in the probe response message is the same as the escape link interface IP address of this MLAG device, then it is determined that the path between this MLAG device and the network device is reachable.

2. The method according to claim 1, characterized in that, The method further includes: If the escape link interface IP address carried in the probe response message is different from the escape link interface IP address of this MLAG device, and the source IP address of the probe response message is the Layer 3 interface IP address of this MLAG device, then the probe response message is forwarded through the Peer-Link link or the escape link.

3. The method according to claim 1, characterized in that, The probe request message is pre-set with a Time-to-Live (TTL) during generation. After the step of determining the path reachability between this MLAG device and the network device, the method further includes: If the network device is not the target host, a new probe request message is generated and sent. The TTL carried in the new probe request message is obtained by adding 1 to the TTL of the previously generated probe request message.

4. A path detection method, characterized in that, Applied to network devices, the method includes: Receive a probe request message, which is sent by any MLAG device in the cross-device link aggregation group (MLAG) network when probing a target host. The probe request message carries the escape link interface IP address of any MLAG device. If the conditions for responding to the probe request message are met, a probe response message is generated, which includes the IP address of the escape link interface. Send the probe response message so that when any MLAG device determines that the escape link interface IP address carried in the probe response message is the same as the escape link interface IP address of this MLAG device, it can determine that the path between any MLAG device and this network device is reachable.

5. The method according to claim 4, characterized in that, If the network device is an MLAG device, the step of sending the probe response message includes: If the link receiving the probe request message is a Peer-Link link or an escape link, and the source IP address in the probe request message is the same as the Layer 3 interface IP address of this network device, and the escape link interface IP address in the probe request message is different from the escape link interface IP address of this network device, then the escape link interface IP address in the probe request message is used as the destination IP address of the probe response message, and the escape link interface IP address of this network device is used as the source IP address of the probe response message, and the probe response message is sent. If the link receiving the probe request message is a Peer-Link link or an escape link, and the source IP address in the probe request message is different from the Layer 3 interface IP address of this network device, then the source IP address in the probe request message is used as the destination IP address of the probe response message, and the escape link interface IP address of this network device is used as the source IP address of the probe response message, and the probe response message is sent.

6. The method according to claim 4, characterized in that, If the network device is an RR device, the step of sending the probe response message includes: The probe response message is sent by using the source IP address in the probe request message as the destination IP address of the probe response message and the IP address of the Layer 3 interface that receives the probe request message as the source IP address of the probe response message.

7. A path detection device, characterized in that, An MLAG device applied in a cross-device link aggregation (MLAG) network, wherein the MLAG member devices in the MLAG network are configured with Peer-Link links and escape links, the device comprising: The request sending module is used to send a probe request message for path probing of the target host. The probe request message carries the IP address of the escape link interface of this MLAG device. The response receiving module is used to receive probe response messages sent by network devices; The determination module is used to determine that the path between the MLAG device and the network device is reachable if the escape link interface IP address carried in the probe response message is the same as the escape link interface IP address of the MLAG device.

8. A path detection device, characterized in that, Applied to network devices, the device includes: The request receiving module is used to receive probe request messages, which are sent by any MLAG device in the cross-device link aggregation group (MLAG) network when probing the target host. The probe request message carries the escape link interface IP address of any MLAG device. The generation module is used to generate a probe response message if the conditions for responding to the probe request message are met. The probe response message includes the IP address of the escape link interface. The response sending module is used to send the probe response message so that when any MLAG device determines that the escape link interface IP address carried in the probe response message is the same as the escape link interface IP address of this MLAG device, it can determine that the path between any MLAG device and this network device is reachable.

9. A network device, characterized in that, It includes a processor and a memory, the memory being used to store a program, and the processor being used to implement the path detection method according to any one of claims 1-3, and / or the path detection method according to any one of claims 4-6, when executing the program.

10. A program product, characterized in that, When the program product is executed by the processor, it implements the path detection method according to any one of claims 1-3, and / or the path detection method according to any one of claims 4-6.