Traffic lead result determination method and apparatus based on loopback detection
By using loopback detection method in cloud networks, the problem that public network gateways cannot confirm traffic traction results is solved, effectively monitoring and alarming of traffic traction processes is realized, and the reliability and detectability of traffic traction are ensured.
Patent Information
- Application Number
- PCT/CN2023/143157
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2023-12-11
- Filing Date
- 2023-12-29
- Publication Date
- 2024-11-07
AI Technical Summary
In the cloud network scenario, especially underlay is a layer two-layer networking architecture, when the public network gateway uses the GARP mechanism to traction traffic, it cannot confirm whether the peer device receives and effectively processes the message, resulting in the inability to determine the traffic traction result and cannot perform Effective monitoring and alarm.
Using a loopback detection method, a loopback detection message is constructed through the main device and sent to the upstream forwarding device to detect whether the message is received. If it is received, it is determined that the traffic traction result is completed; if it is not received , then record the number of times and report connectivity problems to the alarm system.
Effectively determine the traffic traction results, provide problems monitoring and alarming methods during traffic traction of upstream forwarding equipment, and solves the problem of GARP unreliable notification mechanism.
Smart Images

Figure CN2023143157_07112024_PF_FP_ABST
Abstract
Description
Method and device for determining traffic traction results based on loopback detection Technical Field
[0001] The present application relates to the field of network security technology, and in particular to a method, apparatus, computer equipment, and storage medium for determining traffic traction results based on loopback detection. Background Art
[0002] In cloud network scenarios, with a three-layer underlay architecture, the public network gateway that carries north-south traffic generally uses BGP to pull traffic. In a two-layer underlay architecture (where the number of nodes is less than 500), the public network gateway generally uses GARP to pull traffic. However, GARP is a one-way announcement message, and it cannot confirm whether the peer device has received and effectively processed the message. It also cannot effectively monitor and issue alerts, making it impossible to determine the results of traffic pulling, monitor problems, and issue alerts. Therefore, how to confirm the traffic pulling results of the peer device, effectively discover problems, and monitor and issue alerts has become an urgent issue that needs to be addressed.
[0003] Summary of the Invention
[0004] The present application provides a method, apparatus, computer equipment and storage medium for determining traffic traction results based on loopback detection to confirm the traffic traction results of the opposite device, effectively discover problems, and monitor and alarm.
[0005] In a first aspect, the present application provides a method for determining a traffic pulling result based on loopback detection, the method comprising:
[0006] Constructing a GARP message based on the EIP-GARP module of the master device and sending the GARP message to the upstream forwarding device;
[0007] After detecting that the GARP message is successfully sent, constructing a loopback detection message based on the master device, and sending the loopback detection message to the upstream forwarding device;
[0008] When it is detected that the master device receives the loopback detection message sent by the upstream forwarding device, it is determined that the traffic pulling result is completed.
[0009] Furthermore, the loopback detection message is a message whose source IP address and destination IP address are both the elastic public IP address EIP of the master device.
[0010] Furthermore, before detecting that the master device receives the loopback detection message sent by the upstream forwarding device and determining that the traffic pulling result is completed, the method further includes:
[0011] Obtaining an Address Resolution Protocol ARP table entry based on the GARP message learned by the upstream forwarding device;
[0012] When the ARP entry is a valid entry, the public network traffic is forwarded to the master device based on the ARP entry, and the loopback detection message is returned to the master device.
[0013] Furthermore, after learning the GARP message based on the upstream forwarding device and obtaining the Address Resolution Protocol ARP table entry, the method further includes:
[0014] When the ARP entry is an invalid entry, the loopback detection message is discarded or the loopback detection message is forwarded to another device other than the master device.
[0015] Furthermore, after detecting that the GARP message is successfully sent, constructing a loopback detection message based on the master device, and sending the loopback detection message to the upstream forwarding device, the method further includes:
[0016] When it is detected that the master device has not received the loopback detection message sent by the upstream forwarding device, the master device continues to send the GARP message to the upstream forwarding device to drive the upstream forwarding device to learn the GARP message, and records the number of times the master device has not received the loopback detection message.
[0017] Furthermore, after the master device continues to send the GARP message to the upstream forwarding device to drive the upstream forwarding device to learn the GARP message and records the number of times the master device fails to receive the loopback detection message, the method further includes:
[0018] Obtaining the number of times the master device fails to receive the loopback detection message;
[0019] Comparing a preset number threshold with the number of times the master device fails to receive the loopback detection message;
[0020] When the master device fails to receive the loopback detection message for a number not less than the preset number threshold, a connectivity problem of the EIP is reported to the alarm system, and an operation and maintenance personnel is reminded to perform maintenance based on the alarm system.
[0021] Furthermore, the sending of the loopback detection message to the upstream forwarding device includes:
[0022] The loopback detection message is periodically sent and received based on the master device.
[0023] In a second aspect, the present application further provides a device for determining a flow pulling result based on loopback detection, the device comprising:
[0024] A GARP message sending module, configured to construct a registration protocol GARP message based on the EIP-GARP module of the master device, and send the GARP message to an upstream forwarding device;
[0025] A loopback detection message sending module is used to construct a loopback detection message based on the master device after detecting that the GARP message is successfully sent, and send the loopback detection message to the upstream forwarding device;
[0026] The traffic traction result determination module is used to determine that the traffic traction result is completed when detecting that the main device receives the loopback detection message sent by the upstream forwarding device.
[0027] In a third aspect, the present application also provides a computer device, which includes a memory and a processor; the memory is used to store a computer program; the processor is used to execute the computer program and implement the above-mentioned method for determining traffic traction results based on loopback detection when executing the computer program.
[0028] In a fourth aspect, the present application also provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the processor implements the method for determining traffic traction results based on loopback detection as described above.
[0029] The present application discloses a method, apparatus, computer equipment and storage medium for determining a traffic traction result based on loopback detection, which constructs a registration protocol GARP message based on the EIP-GARP module of the master device and sends the GARP message to the upstream forwarding device; after detecting that the GARP message is successfully sent, constructs a loopback detection message based on the master device and sends the loopback detection message to the upstream forwarding device; when detecting that the master device receives the loopback detection message sent by the upstream forwarding device, determines that the traffic traction result is completed. The present application constructs a loopback detection message, sends the loopback detection message to the upstream forwarding device, and detects whether the master device receives the loopback detection message returned by the upstream forwarding device. If the loopback detection message returned by the upstream forwarding device is received, the traffic traction result is determined to be completed. This can effectively determine the traffic traction result and monitor problems that occur during the traffic traction process of the upstream forwarding device. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following is a brief introduction to the drawings required for use in the description of the embodiments. Obviously, the drawings described below are some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0031] FIG1 is a schematic flow chart of a first embodiment of a method for determining a flow pulling result based on loopback detection provided by an embodiment of the present application;
[0032] FIG2 is a flow traction diagram of a flow traction result determination method based on loopback detection provided in an embodiment of the present application;
[0033] 3 is a schematic diagram of a loopback detection message format of a method for determining a flow traction result based on loopback detection provided in an embodiment of the present application;
[0034] 4 is a schematic diagram of message interaction between a master device and an upstream forwarding device according to a method for determining a traffic pulling result based on loopback detection provided by an embodiment of the present application;
[0035] FIG5 is a schematic flowchart of a second embodiment of a method for determining a flow pulling result based on loopback detection provided in an embodiment of the present application;
[0036] FIG6 is a schematic flowchart of a third embodiment of a method for determining a flow pulling result based on loopback detection provided in an embodiment of the present application;
[0037] FIG7 is a schematic block diagram of a device for determining a flow pulling result based on loopback detection according to an embodiment of the present application;
[0038] FIG8 is a schematic block diagram of the structure of a computer device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0039] The following will be combined with the drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are part of the embodiments of this application, not all of them. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.
[0040] The flowcharts shown in the accompanying drawings are for illustrative purposes only and do not necessarily include all contents and operations / steps, nor must they be executed in the order described. For example, some operations / steps may be decomposed, combined, or partially merged, so the actual execution order may vary depending on the actual situation.
[0041] It should be understood that the terms used in this specification are only for the purpose of describing specific embodiments and are not intended to limit the present application. As used in this specification and the appended claims, the singular forms "a", "an", and "the" are intended to include the plural forms unless the context clearly indicates otherwise.
[0042] It will also be understood that the term "and / or" used in this specification and the appended claims refers to and includes any and all possible combinations of one or more of the associated listed items.
[0043] Embodiments of the present application provide a method, apparatus, computer device, and storage medium for determining traffic pull results based on loopback detection. The method can be applied to a server, effectively determining traffic pull results through loopback detection messages and monitoring problems that occur during traffic pull on upstream forwarding devices. The server can be a standalone server or a server cluster.
[0044] The following describes some embodiments of the present application in detail with reference to the accompanying drawings. In the absence of conflict, the following embodiments and features therein may be combined with each other.
[0045] Please refer to Figure 1, which is a schematic flow chart of a method for determining traffic traction results based on loopback detection, provided in an embodiment of the present application. This method for determining traffic traction results based on loopback detection can be applied to a server to effectively determine traffic traction results through loopback detection messages and monitor problems that occur during traffic traction on upstream forwarding devices.
[0046] As shown in FIG1 , the method for determining a traffic traction result based on loopback detection specifically includes steps S101 to S103 .
[0047] S101: Construct a registration protocol GARP message based on the EIP-GARP module of the master device, and send the GARP message to an upstream forwarding device.
[0048] In one embodiment, as shown in Figure 2, when a cloud host accesses the public network, the traffic is first tunneled by the VM-HOST (virtual host) and sent to the active and standby public network gateway cluster. The public network gateway then maps the EIP (Elastic Public IP) to the traffic and sends it to the Bleaf (Border Leaf, egress gateway). The return traffic is forwarded by Bleaf to the public network gateway master node, and then the public network gateway completes the address mapping and forwards it to the cloud host. EIP stands for Elastic Public IP. Alibaba Cloud Elastic Public IP (Internet Protocol Address), or EIP, is an independent public IP resource.
[0049] In the underlay Layer 2 networking architecture, when the Internet Gateway (IGW) receives the EIP configuration, it needs to send the EIP's GARP (Generic Attribute Registration Protocol) message to Bleaf. In this way, Bleaf can learn the EIP's ARP (Address Resolution Protocol) and generate a forwarding table entry. In this way, traffic coming from the public network can be forwarded normally to the public network gateway device through Bleaf.
[0050] Among them, underlay is the actual physical infrastructure layer network equipment and the network of the data center basic forwarding architecture.
[0051] In one embodiment, taking the IGW as the master device and Bleaf as the upstream forwarding device as an example, when the IGW is the master device, the EIP-GARP module of the IGW constructs a GARP message and sends the GARP message to Bleaf.
[0052] S102: After detecting that the GARP message is sent successfully, construct a loopback detection message based on the master device, and send the loopback detection message to the upstream forwarding device.
[0053] In one embodiment, the loopback detection message is a message whose source IP address and destination IP address are both the elastic public IP address EIP of the master device.
[0054] Furthermore, sending the loopback detection message to the upstream forwarding device includes: periodically sending and receiving the loopback detection message based on the master device.
[0055] In one embodiment, the IGW periodically constructs a UDP-echo message (the source IP and the destination IP are both EIPs) and sends it to Bleaf. The UDP-echo message is a loopback detection message.
[0056] In one embodiment, as shown in Figure 3, a schematic diagram of the loopback detection message format for a method for determining traffic traction results based on loopback detection is provided in an embodiment of the present application. In the figure, the time to live, EIP, and IP-header are special fields filled in the message and are used to distinguish it from customer service messages.
[0057] Furthermore, after detecting that the GARP message is sent successfully, constructing a loopback detection message based on the master device, and sending the loopback detection message to the upstream forwarding device, it also includes: when detecting that the master device has not received the loopback detection message sent by the upstream forwarding device, continuing to send the GARP message to the upstream forwarding device based on the master device to drive the upstream forwarding device to learn the GARP message, and recording the number of times the master device has not received the loopback detection message.
[0058] In one embodiment, the IGW monitors UDP-echo packets (i.e., loopback detection packets). If Bleaf does not loopback and forward the UDP-echo packets sent by the IGW itself, it indicates that Bleaf has not correctly processed the GARP packets. In this case, the IGW continues to send GARP packets with the problematic EIP address to drive Bleaf to learn.
[0059] In one embodiment, the number of times that the IGW fails to receive the udp-echo message is recorded. If the message is still not received when the set number threshold is reached, an alarm message is sent to the monitoring platform.
[0060] S103: When detecting that the master device receives the loopback detection message sent by the upstream forwarding device, determine that the traffic pulling result is completed.
[0061] In one embodiment, the IGW monitors udp-echo messages. If Bleaf loops back and forwards the udp-echo message sent by the IGW itself, it means that the EIP-GARP message sent by the IGW itself is effectively received and correctly processed by Bleaf, indicating that the traffic pulling result is completed.
[0062] In one embodiment, as shown in Figure 4, a schematic diagram of message interaction between a master device and an upstream forwarding device in a method for determining traffic diversion results based on loopback detection is provided in an embodiment of the present application. EIP-GARP and service messages are the system's existing interaction message types. The curved arrows indicate the loopback detection messages proposed in this application.
[0063] The above embodiment provides a method, device, computer equipment and storage medium for determining the result of traffic traction based on loopback detection, constructing a registration protocol GARP message based on the EIP-GARP module of the master device, and sending the GARP message to the upstream forwarding device; after detecting that the GARP message is sent successfully, constructing a loopback detection message based on the master device, and sending the loopback detection message to the upstream forwarding device; when detecting that the master device receives the loopback detection message sent by the upstream forwarding device, determining that the traffic traction result is completed. This application constructs a loopback detection message, sends the loopback detection message to the upstream forwarding device, and detects whether the master device receives the loopback detection message returned by the upstream forwarding device. If the loopback detection message returned by the upstream forwarding device is received, determining that the traffic traction result is completed, solves the unreliable notification mechanism of GARP, can effectively determine the traffic traction result, and provides a monitoring and alarm means to monitor problems occurring during the traffic traction process of the upstream forwarding device, and can discover problems before the business.
[0064] Please refer to Figure 5, which is a schematic flow chart of a method for determining traffic pull results based on loopback detection, provided in an embodiment of the present application. This method for determining traffic pull results based on loopback detection can be applied to a server to effectively determine traffic pull results through loopback detection messages and monitor problems that occur during traffic pull on upstream forwarding devices.
[0065] As shown in FIG5 , before step S103 of the method for determining the traffic traction result based on loopback detection, the method further includes steps S201 to S202 .
[0066] S201: Obtain an Address Resolution Protocol ARP entry based on the GARP message learned by the upstream forwarding device;
[0067] S202: When the ARP entry is a valid entry, forward the public network traffic to the master device based on the ARP entry, and return the loopback detection message to the master device.
[0068] Furthermore, after learning the GARP message based on the upstream forwarding device and obtaining the Address Resolution Protocol ARP table entry, it also includes: when the ARP table entry is an invalid table entry, discarding the loopback detection message or forwarding the loopback detection message to other devices other than the master device.
[0069] In one embodiment, after receiving the udp-echo message, Bleaf learns and obtains an ARP entry according to EIP-GARP.
[0070] In one embodiment, if the ARP entry is a valid entry, packet forwarding is performed based on the ARP entry to implement traffic diversion, and a udp-echo packet is returned to the IGW.
[0071] In one embodiment, if there is no ARP entry or the ARP entry is not a valid entry, Bleaf will discard the UDP-echo packet or forward it to an undesired destination address, that is, other devices other than the current IGW.
[0072] Please refer to Figure 6, which is a schematic flow chart of a method for determining traffic pull results based on loopback detection, provided in an embodiment of the present application. This method for determining traffic pull results based on loopback detection can be applied to a server to effectively determine traffic pull results through loopback detection messages and monitor problems that occur during traffic pull on upstream forwarding devices.
[0073] As shown in Figure 6, the steps of the method for determining the traffic traction results based on loopback detection are based on the main device continuing to send the GARP message to the upstream forwarding device to drive the upstream forwarding device to learn the GARP message, and recording the number of times the main device has not received the loopback detection message, and specifically also include steps S301 to S303.
[0074] S301: Obtain the number of times the master device fails to receive the loopback detection message.
[0075] S302: Compare a preset number threshold with the number of times the master device fails to receive the loopback detection message.
[0076] S303: When the master device fails to receive the loopback detection message for a number of times not less than the preset number threshold, report to the alarm system that there is a connectivity problem with the EIP, and remind the operation and maintenance personnel to perform maintenance based on the alarm system.
[0077] In one embodiment, when the number of times the master device fails to receive the udp-echo message reaches a preset threshold, a connectivity problem of the current EIP is reported to the alarm system to remind operation and maintenance personnel to access the process and perform maintenance.
[0078] In one embodiment, the preset number threshold can be set by the user according to needs, can be set in advance in the system, and can also be changed during the execution process.
[0079] In another embodiment, when the number of times the master device has not received the udp-echo message does not reach a preset number threshold, it continues to send GARP messages to the upstream forwarding device until the master device receives the udp-echo message sent by the master device itself returned by the upstream forwarding device or the number of times the master device has not received the udp-echo message does not reach a preset number threshold.
[0080] Please refer to Figure 7, which is a schematic block diagram of a device for determining a traffic traction result based on loopback detection according to an embodiment of the present application. The device for determining a traffic traction result based on loopback detection is used to perform the aforementioned method for determining a traffic traction result based on loopback detection. The device for determining a traffic traction result based on loopback detection can be configured on a server.
[0081] As shown in FIG7 , the apparatus 400 for determining a flow pulling result based on loopback detection includes:
[0082] A GARP message sending module 401 is configured to construct a registration protocol GARP message based on the EIP-GARP module of the master device and send the GARP message to an upstream forwarding device;
[0083] A loopback detection message sending module 402 is configured to construct a loopback detection message based on the master device after detecting that the GARP message is successfully sent, and send the loopback detection message to the upstream forwarding device;
[0084] The traffic pulling result determining module 403 is configured to determine that the traffic pulling result is completed when detecting that the master device receives the loopback detection message sent by the upstream forwarding device.
[0085] Furthermore, the loopback detection message is a message whose source IP address and destination IP address are both the elastic public IP address EIP of the master device.
[0086] Furthermore, the traffic pulling result determination device 400 based on loopback detection further includes a loopback detection message returning module, and the loopback detection message returning module includes:
[0087] An ARP entry obtaining unit, configured to obtain an Address Resolution Protocol ARP entry based on learning the GARP message by the upstream forwarding device;
[0088] The loopback detection message returning unit is configured to forward the public network traffic to the master device based on the ARP table entry when the ARP table entry is a valid table entry, and return the loopback detection message to the master device.
[0089] Furthermore, the loopback detection message returning module further includes:
[0090] The loopback detection message discarding unit is configured to discard the loopback detection message or forward the loopback detection message to another device other than the master device when the ARP table entry is an invalid table entry.
[0091] Furthermore, the flow pulling result determination device 400 based on loopback detection further includes:
[0092] A message retransmission module is used to, when detecting that the master device has not received the loopback detection message sent by the upstream forwarding device, continue to send the GARP message to the upstream forwarding device based on the master device, so as to drive the upstream forwarding device to learn the GARP message, and record the number of times the master device has not received the loopback detection message.
[0093] Furthermore, the message retransmission module further includes:
[0094] A number obtaining unit, configured to obtain the number of times the master device fails to receive the loopback detection message;
[0095] A number comparison unit, configured to compare a preset number threshold with the number of times the master device fails to receive the loopback detection message;
[0096] The problem warning unit is used to report the EIP connectivity problem to the alarm system when the number of times the main device fails to receive the loopback detection message is not less than the preset number threshold, and to remind the operation and maintenance personnel to perform maintenance based on the alarm system.
[0097] Furthermore, the loopback detection message sending module 402 includes:
[0098] The loopback detection message sending unit is used to periodically send and receive the loopback detection message based on the master device.
[0099] It should be noted that those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the above-described devices and modules can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0100] The above-mentioned apparatus may be implemented in the form of a computer program, and the computer program may be run on a computer device as shown in FIG8 .
[0101] Please refer to Figure 8, which is a schematic block diagram of the structure of a computer device provided in an embodiment of the present application. The computer device may be a server.
[0102] 8 , the computer device includes a processor, a memory, and a network interface connected via a system bus, wherein the memory may include a non-volatile storage medium and an internal memory.
[0103] The non-volatile storage medium can store an operating system and a computer program. The computer program includes program instructions, which, when executed, can cause the processor to execute any method for determining a traffic traction result based on loopback detection.
[0104] The processor is used to provide computing and control capabilities and support the operation of the entire computer equipment.
[0105] The internal memory provides an environment for the operation of the computer program in the non-volatile storage medium. When the computer program is executed by the processor, the processor can execute any method for determining the traffic traction result based on loopback detection.
[0106] The network interface is used for network communication, such as sending assigned tasks, etc. Those skilled in the art will understand that the structure shown in FIG8 is merely a block diagram of a portion of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. A specific computer device may include more or fewer components than shown in the figure, or combine certain components, or have a different arrangement of components.
[0107] It should be understood that the processor may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor, etc.
[0108] In one embodiment, the processor is configured to execute a computer program stored in the memory to implement the following steps:
[0109] Constructing a GARP message based on the EIP-GARP module of the master device and sending the GARP message to the upstream forwarding device;
[0110] After detecting that the GARP message is successfully sent, constructing a loopback detection message based on the master device, and sending the loopback detection message to the upstream forwarding device;
[0111] When it is detected that the master device receives the loopback detection message sent by the upstream forwarding device, it is determined that the traffic pulling result is completed.
[0112] In one embodiment, the loopback detection message is a message whose source IP address and destination IP address are both the elastic public IP address EIP of the master device.
[0113] In one embodiment, the processor is further configured to implement, before detecting that the master device receives the loopback detection message sent by the upstream forwarding device and determining that the traffic pulling result is completed:
[0114] Obtaining an Address Resolution Protocol ARP table entry based on the GARP message learned by the upstream forwarding device;
[0115] When the ARP entry is a valid entry, the public network traffic is forwarded to the master device based on the ARP entry, and the loopback detection message is returned to the master device.
[0116] In one embodiment, after the processor learns the GARP message based on the upstream forwarding device and obtains the Address Resolution Protocol ARP table entry, the processor is further configured to implement:
[0117] When the ARP entry is an invalid entry, the loopback detection message is discarded or the loopback detection message is forwarded to another device other than the master device.
[0118] In one embodiment, after detecting that the GARP message is successfully sent, the processor constructs a loopback detection message based on the master device and sends the loopback detection message to the upstream forwarding device, and is further configured to:
[0119] When it is detected that the master device has not received the loopback detection message sent by the upstream forwarding device, the master device continues to send the GARP message to the upstream forwarding device to drive the upstream forwarding device to learn the GARP message, and records the number of times the master device has not received the loopback detection message.
[0120] In one embodiment, after the processor continues to send the GARP message to the upstream forwarding device based on the master device to drive the upstream forwarding device to learn the GARP message and records the number of times the master device fails to receive the loopback detection message, it is further configured to implement:
[0121] Obtaining the number of times the master device fails to receive the loopback detection message;
[0122] Comparing a preset number threshold with the number of times the master device fails to receive the loopback detection message;
[0123] When the master device fails to receive the loopback detection message for a number not less than the preset number threshold, a connectivity problem of the EIP is reported to the alarm system, and an operation and maintenance personnel is reminded to perform maintenance based on the alarm system.
[0124] In one embodiment, sending the loopback detection message to the upstream forwarding device includes:
[0125] The loopback detection message is periodically sent and received based on the master device.
[0126] An embodiment of the present application also provides a computer-readable storage medium, which stores a computer program, and the computer program includes program instructions. The processor executes the program instructions to implement any one of the traffic traction result determination methods based on loopback detection provided in the embodiments of the present application.
[0127] The computer-readable storage medium may be an internal storage unit of the computer device described in the aforementioned embodiment, such as a hard disk or memory of the computer device. The computer-readable storage medium may also be an external storage device of the computer device, such as a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, etc., equipped on the computer device.
[0128] The above description is merely a specific embodiment of the present application, but the scope of protection of the present application is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in the present application, and such modifications or substitutions should be included in the scope of protection of the present application. Therefore, the scope of protection of the present application should be based on the scope of protection of the claims.
Claims
1. A method for determining flow traction results based on loopback detection, It is characterized in that include: Constructing a registration protocol GARP message based on the EIP-GARP module of the master device, and sending the GARP message to an upstream forwarding device; After detecting that the GARP message is sent successfully, constructing a loopback detection message based on the master device, and sending the loopback detection message to the upstream forwarding device; When it is detected that the master device receives the loopback detection message sent by the upstream forwarding device, it is determined that the traffic traction result is completed.
2. The method for determining the flow traction result based on loopback detection according to claim 1, It is characterized in that The loopback detection message is a message whose source IP address and destination IP address are both the elastic public IP address EIP of the master device.
3. The method for determining a flow traction result based on loopback detection according to claim 1, It is characterized in that Before the process of determining that the traffic pulling result is completed when detecting that the master device receives the loopback detection message sent by the upstream forwarding device, further includes: Acquire an Address Resolution Protocol ARP table entry based on the upstream forwarding device learning the GARP message; When the ARP entry is a valid entry, the public network traffic is forwarded to the master device based on the ARP entry, and the loopback detection message is returned to the master device.
4. The method for determining the flow traction result based on loopback detection according to claim 3, It is characterized in that After learning the GARP message based on the upstream forwarding device and obtaining the address resolution protocol ARP table entry, the method further includes: When the ARP entry is an invalid entry, the loopback detection message is discarded or the loopback detection message is forwarded to other devices other than the master device.
5. The method for determining a flow traction result based on loopback detection according to claim 1, It is characterized in that After detecting that the GARP message is successfully sent, constructing a loopback detection message based on the master device, and sending the loopback detection message to the upstream forwarding device, the method further includes: When it is detected that the master device does not receive the loopback detection message sent by the upstream forwarding device, The master device continues to send the GARP message to the upstream forwarding device to drive the upstream forwarding device to learn the GARP message, and records the number of times the master device fails to receive the loopback detection message.
6. The method for determining the flow traction result based on loopback detection according to claim 5, It is characterized in that After the master device continues to send the GARP message to the upstream forwarding device to drive the upstream forwarding device to learn the GARP message and records the number of times the master device does not receive the loopback detection message, the method further includes: Obtain the number of times the master device fails to receive the loopback detection message; Compare the preset number threshold with the number of times the master device fails to receive the loopback detection message; When the number of times that the master device fails to receive the loopback detection message is not less than the preset number threshold, a connectivity problem of the EIP is reported to the alarm system, and an operation and maintenance personnel is reminded to perform maintenance based on the alarm system.
7. The method for determining a flow traction result based on loopback detection according to any one of claims 1 to 6, It is characterized in that The sending the loopback detection message to the upstream forwarding device includes: Based on the periodic sending and receiving of the loopback detection message by the master device.
8. A flow traction result determination device based on loopback detection, It is characterized in that include: A GARP message sending module, used to construct a registration protocol GARP message based on the EIP-GARP module of the master device, and send the GARP message to an upstream forwarding device; A loopback detection message sending module, configured to construct a loopback detection message based on the master device after detecting that the GARP message is successfully sent, and send the loopback detection message to the upstream forwarding device; The traffic traction result determination module is used to determine that the traffic traction result is completed when it is detected that the main device receives the loopback detection message sent by the upstream forwarding device.
9. A computer device, It is characterized in that The computer device includes a memory and a processor; The memory is used to store computer programs; The processor is used to execute the computer program and implement the method for determining a traffic traction result based on loopback detection as described in any one of claims 1 to 7 when executing the computer program.
10. A computer-readable storage medium, It is characterized in that The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the processor implements the method for determining a traffic traction result based on loopback detection according to any one of claims 1 to 7.
Citation Information
Patent Citations
Assess method and device of GVRP-based video monitoring system
CN104486589A
Data processing method and device
CN113938405A
Public network IP network state detection method and system
CN114629816A
Routing system, routing method and routing device of virtual network
CN115277550A
Address registration
US20220210064A1
