Method for actively detecting BM by BMGW-VIP cluster

By specifying VNI using the -p parameter of the ping program in the BMGW-VIP cluster, the problem of being unable to actively detect BM in the BMGW-VIP cluster is solved, and the operation and maintenance process is simplified.

WO2025124474A9PCT designated stage expired Publication Date: 2025-08-14CHINA TELECOM CLOUD TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2024/138787
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-12-13
Filing Date
2024-12-12
Publication Date
2025-08-14

AI Technical Summary

Technical Problem

In BMGW-VIP cluster, it is impossible to actively detect overlay BM hosts using general programs, resulting in complex operation and maintenance.

Method used

By using the -p parameter of the ping program in the BMGW-VIP cluster to specify the VNI where the BM is located, the BMGW service receives the ICMP request, extracts the VNI as the VXLAN tunnel message encapsulation parameter, modifys the source IP of the ping message, and forwards the reply message to the cluster member of the source request through the LEAF node.

Benefits of technology

It realizes the reuse of standard ping programs in the BMGW-VIP cluster to detect overlay BM, simplifying the operation and maintenance process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2024138787_14082025_PF_FP_ABST
    Figure CN2024138787_14082025_PF_FP_ABST
Patent Text Reader

Abstract

The present application discloses a method for actively detecting a BM by a BMGW-VIP cluster, comprising: using, in BMGW-VIP cluster members, a ping program to detect an IP of a BM, and using a -p parameter to specify a VNI where the BM is located; a BMGW service detecting a ping packet, and extracting the VNI as a VNI parameter for BM VXLAN tunnel packet encapsulation; on the basis of information queried by the VNI, the BMGW service modifying a source IP of the ping packet and filling the source IP to the ping packet, encapsulating a VXLAN packet by using the VNI where the BM is located, and sending same to a LEAF node; a BMGW cluster member receiving a replied ping packet and forwarding the ping packet to a cluster member of a source request; and the cluster member of the source request receiving the ping packet and sending same to a kernel. The present application solves the problem of a BMGW-VIP actively detecting a BM, and simplifies the operation and maintenance of a BMGW cluster.
Need to check novelty before this filing date? Find Prior Art

Description

A method for BMGW-VIP cluster to actively detect BM

[0001] This application claims priority to Chinese patent application number CN202311712747.5, filed on December 13, 2023, entitled “A method for active BM detection by BMGW-VIP cluster”, the entire text of which is hereby incorporated by reference. Technical Field

[0002] The present application relates to the field of IT and software development technology, and in particular to a method for a BMGW-VIP cluster to actively detect BM. Background Art

[0003] Cloud servers in cloud computing services can be divided into virtual cloud hosts and physical cloud hosts. They are the foundation of cloud services. Physical cloud hosts can be broadly divided into standard physical machines, also known as bare metal servers (BMs), which are physical machines with built-in smart network adapters. Bare metal servers are hardware devices that combine the characteristics of traditional physical servers with the virtualization services of cloud computing technology. They are a combination of hardware and software advantages, essentially a server that combines the functions of cloud computing services with the performance of physical devices. Bare metal servers connect to the cloud through the bare metal gateway (BMGW). BMGW enables seamless integration and compatibility with other cloud services provided by cloud vendors, such as VPC private networks, cloud database services, EIPs, shared bandwidth, rate limiting, cloud firewalls, and other cloud products within network services.

[0004] The bare metal gateway (BMGW) provides various cloud services for bare metal servers to access the cloud. To ensure the performance and reliability of bare metal server access, bare metal gateways are typically composed of multiple devices forming a BMGW cluster to provide services to the BMGW. Tianyi Cloud primarily provides access services to BMs within the resource pool through the BMGW-VIP cluster and BM access switches. Figure 2 shows a schematic diagram of BM access to the BMGW-VIP cluster. The management and control system is the cloud system for automatically managing bare metal servers, bare metal gateways, and access switches; the LEAF switches are basic network switching and routing devices; and the "other" clusters represent other service clusters within the cloud.

[0005] As shown in Figure 3, the BM gateway is located on the BMGW cluster. The cluster members are independent of each other and can back up each other. The BMGW-VIP cluster and the access switch are linked through a VIP-based VXLAN tunnel. The gateway of the subnet where the BM server is located is located on the BMGW. After the message from the BM server to the BM subnet gateway arrives at the BM cluster, it is directly answered by the BM where it is located.

[0006] Tianyi Cloud mainly provides access services for BM in the resource pool through the BMGW-VIP cluster and BM access switch. The BMGW service of the cluster members hides overlay-related services such as VPC. Therefore, cluster members cannot use the general program ping to actively detect the overlay BM host. In addition, since BMGW is deployed in VIP mode, the data replied by BM to the cluster is shared equally on the corresponding cluster members according to the encapsulation information of the outer VXLAN. Therefore, the request message and the reply message to the request message cannot be returned to the same BMGW. Summary of the Invention

[0007] This application aims to address, at least to some extent, one of the technical problems in the related art. To this end, one purpose of this application is to provide a method, system, electronic device, and readable storage medium for actively detecting BMs in a BMGW-VIP cluster. This application addresses the issue of BMGW-VIP actively detecting BMs, enabling the reuse of a standard ping program in a BMGW-VIP cluster to detect overlay BMs, simplifying the operation and maintenance of the BMGW cluster.

[0008] A first aspect disclosed in the present application provides a method for a BMGW-VIP cluster to actively detect a BM, the method comprising:

[0009] Use the ping program to detect the IP address of the BM in the BMGW-VIP cluster member, use the -p parameter to specify the VNI where the BM is located, and the ping program uses ICMP to send a request to the BMGW service to detect the BM;

[0010] The BMGW service receives ICMP probe requests from the BM, detects ping packets, and extracts the VNI, which is used as the VNI parameter for encapsulating BM VXLAN tunnel packets.

[0011] The BMGW service modifies the source IP of the ping message based on the VNI query information and fills the source IP into the ping message, encapsulates the VXLAN message using the VNI where the BM is located, and sends it to the LEAF node;

[0012] The BMGW cluster member receives the reply ping message and forwards the ping message to the cluster member that originated the request based on the data in the ping message.

[0013] After receiving the ping message, the cluster member that originated the request restores the ping message based on the data in the ping message and sends it to the kernel.

[0014] The method of using the ping program to detect the IP address of the BM in the BMGW-VIP cluster member, using the -p parameter to specify the VNI where the BM is located, and using the ICMP to send a request to detect the BM to the BMGW service includes:

[0015] Fill the parameter -p with the content of the general ping program and specify the VNI where the BM is located, where VNI is the tunnel identifier of the VXLAN. When the -p parameter is executed, the general ping program can automatically fill the content of BM-VXLAN-VNI into the ping message. The specific format is as follows:

[0016] ping BM-IP-p BM-VXLAN-VNI-c xx-i yy.

[0017] The BMGW service receives an ICMP probe request from the BM, detects the ping message, and extracts the VNI as a VNI parameter for encapsulating the BM VXLAN tunnel message, including:

[0018] The BMGW service receives ICMP probe requests from BM;

[0019] Detect ping packets;

[0020] If the ping message contains BM-VXLAN-VNI, extract the BM-VXLAN-VNI field.

[0021] Use the BM-VXLAN-VNI field to find the BM subnet, obtain the subnet gateway IP address, and the VXLAN information required to access the BM.

[0022] Used as the VNI parameter for BM VXLAN tunnel packet encapsulation.

[0023] The BMGW service modifies the source IP of the ping message and fills the source IP into the ping message according to the VNI query information, encapsulates the VXLAN message using the VNI where the BM is located, and sends the message to the LEAF node, including:

[0024] BMGW service queries information based on VNI;

[0025] Replace the source IP address of the ping message with the subnet gateway IP address.

[0026] Fill the source IP of the ping message into the ping message;

[0027] Encapsulate the original ping packet using VXLAN encapsulation information.

[0028] The encapsulated original ping message is sent to the LEAF node.

[0029] The step of sending the encapsulated original ping message to the LEAF node includes:

[0030] BM receives the ping message request and generates a reply message;

[0031] The reply message is encapsulated into VXLAN by the BM access switch;

[0032] The BMGW cluster member forwards the ping reply message to the BMGW cluster member. The cluster member detects the ping reply message and finds that it is a reply message requesting the subnet gateway IP address.

[0033] If the BM real IP carried in the ping message is destined for the local machine, the BM real IP is used to replace the destination IP of the inner ping message and sent to the kernel. If it is not destined for the local machine, the BM real IP is used to replace the VXLAN destination IP and sent to the LEAF node.

[0034] The step of the BMGW cluster member receiving the reply ping message and forwarding the ping message to the cluster member that originated the request according to the data in the ping message includes:

[0035] The BMGW cluster member receives the reply ping message;

[0036] BMGW cluster members need to parse the received reply ping message;

[0037] Forwards the ping message to the cluster member that originated the request based on the data in the ping message.

[0038] The step of the BMGW-VIP cluster member of the source request receiving the ping message, restoring the ping message according to the ping message, and sending the ping message to the kernel includes:

[0039] The BMGW-VIP cluster member that originated the request receives the ping message;

[0040] Detect received ping packets;

[0041] Restore the ping message based on the ping message;

[0042] Sent to the kernel.

[0043] A second aspect disclosed in the present application provides a system for a BMGW-VIP cluster to actively detect BMs, the system comprising:

[0044] A sending request module is used to use the ping program to detect the IP of the BM in the BMGW-VIP cluster member, use the -p parameter to specify the VNI where the BM is located, and the ping program uses ICMP to send a request to detect the BM to the BMGW service;

[0045] In the detection module, the BMGW service receives ICMP probe requests from BM, detects ping messages, and extracts the VNI, which is used as the VNI parameter for BM VXLAN tunnel message encapsulation.

[0046] A modification module is used for the BMGW service to modify the source IP of the ping message and fill the source IP into the ping message according to the VNI query information, encapsulate the VXLAN message using the VNI where the BM is located, and send it to the LEAF node;

[0047] The forwarding module is used for the BMGW cluster member to receive the reply ping message and forward the ping message to the cluster member that originated the request according to the data in the ping message;

[0048] The ping message is sent to the kernel module. After receiving the ping message, the cluster member that originated the request restores the ping message based on the data in the ping message and sends it to the kernel.

[0049] The third aspect disclosed in the present application is an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, the steps in a method for actively detecting BM by a BMGW-VIP cluster are implemented.

[0050] The fourth aspect disclosed in the present application is a readable storage medium, which stores a computer program. The computer program is suitable for being loaded by a processor to execute the steps in the method of actively detecting BM by a BMGW-VIP cluster.

[0051] Compared with the existing technology, the method of actively detecting BM by BMGW-VIP cluster proposed in this application has the following advantages:

[0052] This application uses the -p parameter of the ping program to carry the VNI parameter into the ICMP request data, so as to carry the VNI system to the BMGW service, solving the problem of the system program passing the VPC VNI through extended parameters;

[0053] Replace the source IP of ICMP requests with the subnet gateway IP for better compatibility with BM system settings, and restore the ICMP reply request message based on the data in the ICMP reply message;

[0054] ICMP request data carries the source IP address of the message. Cluster members can then confirm the source request node by checking ping data. Then, they modify the VXLAN message header to forward the message to the source request node, solving the same-source-sink problem.

[0055] This application solves the problem of BMGW-VIP actively detecting BM, and can reuse the standard ping program in the BMGW-VIP cluster to detect overlay BM, simplifying the operation and maintenance of the BMGW cluster. BRIEF DESCRIPTION OF THE DRAWINGS

[0056] FIG1 is a schematic diagram of a method for a BMGW-VIP cluster to actively detect BMs according to an embodiment of the present application;

[0057] FIG2 is a schematic diagram of a BM accessing a BMGW-VIP cluster provided by an embodiment of the present application;

[0058] FIG3 is a schematic diagram of linking a BMGW-VIP cluster and an access switch via a VIP-based VXLAN tunnel according to an embodiment of the present application;

[0059] FIG4 is a schematic diagram of a message forwarding process related to a BMGW service provided in one embodiment of the present application;

[0060] FIG5 is a schematic diagram of a message during the message forwarding process related to a BMGW service provided by an embodiment of the present application;

[0061] FIG6 is a schematic diagram of a system for actively detecting BMs in a BMGW-VIP cluster according to an embodiment of the present application;

[0062] FIG7 is a schematic diagram of the structure of an electronic device provided by an embodiment of the present application;

[0063] FIG8 is a schematic diagram of the structure of a computer-readable storage medium provided by an embodiment of the present application. DETAILED DESCRIPTION

[0064] To better understand the present application, various aspects of the present application will be described in more detail with reference to the accompanying drawings. It should be understood that these detailed descriptions are merely descriptions of exemplary embodiments of the present application and are not intended to limit the scope of the present application in any way. Throughout the specification, the same reference numerals refer to the same elements. The expression "and / or" includes any and all combinations of one or more of the associated listed items.

[0065] In the accompanying drawings, the size, dimensions, and shapes of the elements have been slightly adjusted for ease of illustration. The accompanying drawings are for illustration only and are not drawn strictly to scale. As used herein, the terms "substantially," "approximately," and similar terms are used to indicate approximate values, not degrees, and are intended to illustrate inherent deviations in measurements or calculations that would be recognized by a person of ordinary skill in the art. In addition, in this application, the order in which the steps are described does not necessarily represent the order in which these steps would occur in actual operation, unless otherwise specified or inferred from the context.

[0066] It should also be understood that expressions such as "including", "comprising", "having", "containing" and / or "comprising" are open rather than closed expressions in this specification, which indicate the presence of the stated features, elements and / or components, but do not exclude the presence of one or more other features, elements, components and / or combinations thereof. In addition, when expressions such as "at least one of..." appear after a list of listed features, they modify the entire list of features rather than just the individual elements in the list. In addition, when describing embodiments of the present application, "may" is used to mean "one or more embodiments of the present application". And, the term "exemplary" is intended to refer to an example or illustration.

[0067] Unless otherwise defined, all words used herein (including engineering terms and scientific and technological terms) have the same meaning as commonly understood by those skilled in the art to which this application belongs. It should also be understood that, unless otherwise specified in this application, words defined in commonly used dictionaries should be interpreted as having the same meaning as they do in the context of the relevant technology, and should not be interpreted in an idealized or overly formal sense.

[0068] It should be noted that, in the absence of conflict, the embodiments and features of the embodiments in this application can be combined with each other. The present application will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.

[0069] Example 1

[0070] FIG1 is a schematic diagram of a method for a BMGW-VIP cluster to actively detect BMs according to an embodiment of the present application. As shown in FIG1 , a method for a BMGW-VIP cluster to actively detect BMs includes:

[0071] Use the ping program to detect the IP address of the BM in the BMGW-VIP cluster member, use the -p parameter to specify the VNI where the BM is located, and the ping program uses ICMP to send a request to the BMGW service to detect the BM;

[0072] The BMGW-VIP cluster is a BMGW cluster implemented based on VIP. The BMGW cluster serves as the VXLAN VTEP node of the BM cloud network. BMGW cluster members each run a routing protocol to establish neighbor relationships with the LEAF switches interconnecting the cluster and advertise the cluster VIP address. The VIP routes advertised by the cluster form VIP equivalent routes on the LEAF switches. Service traffic encapsulated using the VIP+VXLAN tunnel is automatically load-balanced to cluster members by searching for equivalent routes on LEAF switches outside the cluster. After processing services, cluster members obtain the VIP of the next cluster and again encapsulate VXLAN packets using the VIP, sending service traffic to subsequent clusters to complete tenant service forwarding. The BM access switch connects to bare metal servers and serves as the VTEP node for the VXLAN tunnel connecting bare metal to the cloud. The destination address of the VXLAN tunnel is the VIP address of the BMGW cluster.

[0073] Use the ping program in the BMGW-VIP cluster member to detect the BM's IP address. Use the -p parameter to specify the VNI where the BM is located. The ping program uses ICMP to send a request to the BMGW service to detect the BM, including:

[0074] Fill the parameter -p with the content of the general ping program and specify the VNI where the BM is located, where VNI is the tunnel identifier of the VXLAN. When the -p parameter is executed, the general ping program can automatically fill the content of BM-VXLAN-VNI into the ping message. The specific format is as follows:

[0075] ping BM-IP-p BM-VXLAN-VNI-c xx-i yy.

[0076] The BMGW service receives ICMP probe requests from the BM, detects ping packets, and extracts the VNI, which is used as the VNI parameter for encapsulating BM VXLAN tunnel packets.

[0077] The BMGW service receives the ICMP probe request from the BM, detects the ping message, and extracts the VNI, which is used as the VNI parameter for encapsulating the BM VXLAN tunnel message. The steps include:

[0078] The BMGW service receives ICMP probe requests from BM;

[0079] Detect ping packets;

[0080] If the ping message contains BM-VXLAN-VNI, extract the BM-VXLAN-VNI field.

[0081] Use the BM-VXLAN-VNI field to find the BM subnet, obtain the subnet gateway IP address, and the VXLAN information required to access the BM.

[0082] Used as the VNI parameter for BM VXLAN tunnel packet encapsulation.

[0083] Among them, ICMP is the protocol used by Ping. Ping uses the requests and replies in the ICMP protocol to perform its functions. When sending a Ping request, the Ping tool creates an ICMP request message and sends it to the target host, and then waits for the target host's ICMP reply response.

[0084] The BMGW service modifies the source IP of the ping message based on the VNI query information and fills the source IP into the ping message, encapsulates the VXLAN message using the VNI where the BM is located, and sends it to the LEAF node;

[0085] The BMGW service modifies the source IP of the ping message and fills the source IP into the ping message according to the VNI query information, encapsulates the VXLAN message using the VNI where the BM is located, and sends the message to the LEAF node, including:

[0086] BMGW service queries information based on VNI;

[0087] Replace the source IP address of the ping message with the subnet gateway IP address.

[0088] Fill the source IP of the ping message into the ping message;

[0089] Encapsulate the original ping packet using VXLAN encapsulation information.

[0090] The encapsulated original ping message is sent to the LEAF node.

[0091] The step of sending the encapsulated original ping message to the LEAF node includes:

[0092] BM receives the ping message request and generates a reply message;

[0093] The reply message is encapsulated into VXLAN by the BM access switch;

[0094] The BMGW cluster member forwards the ping reply message to the BMGW cluster member. The cluster member detects the ping reply message and finds that it is a reply message requesting the subnet gateway IP address.

[0095] If the BM real IP carried in the ping message is destined for the local machine, the BM real IP is used to replace the destination IP of the inner ping message and sent to the kernel. If it is not destined for the local machine, the BM real IP is used to replace the VXLAN destination IP and sent to the LEAF node.

[0096] The BMGW cluster member receives the reply ping message and forwards the ping message to the cluster member that originated the request based on the data in the ping message.

[0097] The step of the BMGW cluster member receiving the reply ping message and forwarding the ping message to the cluster member that originated the request according to the data in the ping message includes:

[0098] The BMGW cluster member receives the reply ping message;

[0099] BMGW cluster members need to parse the received reply ping message;

[0100] Forwards the ping message to the cluster member that originated the request based on the data in the ping message.

[0101] After receiving the ping message, the cluster member that originated the request restores the ping message based on the data in the ping message and sends it to the kernel.

[0102] The step of the BMGW-VIP cluster member of the source request receiving the ping message, restoring the ping message according to the ping message, and sending the ping message to the kernel includes:

[0103] The BMGW-VIP cluster member that originated the request receives the ping message;

[0104] Detect received ping packets;

[0105] Restore the ping message based on the ping message;

[0106] Sent to the kernel.

[0107] Example 2

[0108] FIG6 is a schematic diagram of a system for actively detecting BMs by a BMGW-VIP cluster according to an embodiment of the present application. As shown in FIG6 , a system for actively detecting BMs by a BMGW-VIP cluster includes:

[0109] A sending request module is used to use the ping program to detect the IP of the BM in the BMGW-VIP cluster member, use the -p parameter to specify the VNI where the BM is located, and the ping program uses ICMP to send a request to detect the BM to the BMGW service;

[0110] In the detection module, the BMGW service receives ICMP probe requests from BM, detects ping messages, and extracts the VNI, which is used as the VNI parameter for BM VXLAN tunnel message encapsulation.

[0111] A modification module is used for the BMGW service to modify the source IP of the ping message and fill the source IP into the ping message according to the VNI query information, encapsulate the VXLAN message using the VNI where the BM is located, and send it to the LEAF node;

[0112] The forwarding module is used for the BMGW cluster member to receive the reply ping message and forward the ping message to the cluster member that originated the request according to the data in the ping message;

[0113] The ping message is sent to the kernel module. After receiving the ping message, the cluster member that originated the request restores the ping message based on the data in the ping message and sends it to the kernel.

[0114] Example 3

[0115] FIG4 is a schematic diagram of a message forwarding process related to a BMGW service provided in one embodiment of the present application. As shown in FIG4 , the message forwarding process related to a BMGW service includes:

[0116] After receiving the ping message through the VETH-BMGW interface, the BMGW of BMGW member 1 detects the content of the ping message. If the ping message contains BM-VXLAN-VNI, the field is extracted and the BM-VXLAN-VNIi field is used to find the BM subnet, obtain the subnet gateway IP and the VXLAN information required to access the BM, and replace the source IP of the ping message with the subnet gateway IP. The source IP of the message is filled into the ping message and the original ping message is encapsulated with VXLAN encapsulation information. After receiving the BM's ping request, the BM generates a reply message, which is then accessed by the BM switch. After the machine encapsulates VXLAN, it is forwarded to a member of the BMGW cluster. The cluster member detects the ping reply and finds that it is a reply message requesting the subnet gateway IP. If the BM real IP carried in the ping message is for the local machine, the BM real IP is used to replace the destination IP of the inner ping message and the message is sent to the kernel; if it is not for the local machine, the VXLAN destination IP is replaced with the BM real IP and the message is sent to the LEAF node. The LEAF node forwards the message to the real member node. After receiving the packet, the cluster member node detects that if the ping reply content belongs to the local machine, the BM real IP is used to replace the destination IP of the inner ping message and the message is sent to the kernel.

[0117] As shown in Figure 5, the detailed steps for message forwarding related to BMGW service implementation are as follows:

[0118] Receive the ping request message, i.e., request message 1. The source IP of the message is the real IP of BMGW, the destination IP is the IP of the target BM, and the content is the content filled with -p;

[0119] The BMGW service extracts VNI information, searches for subnets based on the VNI information, and obtains the subnet gateway IP and VXLAN encapsulation information.

[0120] The BMGW service replaces the source IP address of request message 1 with the subnet gateway IP address and fills the BM real IP address into the data to generate request message 2.

[0121] The BMGW service encapsulates request message 2 using VXLAN information to generate request message 3.

[0122] The BMGW service receives the reply message from the BM and responds with a reply message;

[0123] Based on the BM real IP address in the reply message, if the ping message is not a reply message to the local request, the BM real IP address is used to replace the VXLAN outer destination IP address and reply message 2 is sent.

[0124] Decapsulate reply message 2, and based on the padding content of the reply message, modify the destination IP to the BM real IP, generate reply message 3, and then send it to the Linux kernel.

[0125] Example 4

[0126] Figure 7 is a schematic diagram of the structure of an electronic device provided by one embodiment of the present application. As shown in Figure 7, according to another aspect of the present application, an electronic device 500 is provided. The electronic device 500 may include one or more processors and one or more memories. The memories may store computer-readable code that, when executed by the one or more processors, may execute a method for a BMGW-VIP cluster to actively detect a BM.

[0127] The method or system according to the embodiments of the present application can also be implemented with the aid of the architecture of the electronic device shown in FIG7 . As shown in FIG7 , the electronic device 500 may include a bus 501, one or more CPUs 502, a read-only memory (ROM) 503, a random access memory (RAM) 504, a communication port 505 connected to a network, an input / output component 506, a hard disk 507, and the like. A storage device in the electronic device 500, such as the ROM 503 or the hard disk 507, may store a method for a BMGW-VIP cluster to actively detect a BM provided in the present application. A method for actively detecting a BM in a BMGW-VIP cluster may, for example, include: using a ping program in a BMGW-VIP cluster member to detect the IP address of the BM, using the -p parameter to specify the VNI where the BM is located, and using the ping program to send a BM detection request to the BMGW service using ICMP; the BMGW service receives the ICMP detection request for the BM, detects the ping message, and extracts the VNI as the VNI parameter for encapsulating the BM VXLAN tunnel message; the BMGW service modifies the source IP address of the ping message and fills the source IP address into the ping message based on the VNI query information, encapsulates the VXLAN message using the VNI where the BM is located, and sends the message to the LEAF node; the BMGW cluster member receives the reply ping message and forwards the ping message to the cluster member that originated the request based on the data in the ping message; after receiving the ping message, the cluster member that originated the request restores the ping message based on the data in the ping message and sends it to the kernel. Furthermore, the electronic device 500 may also include a user interface 508. Of course, the architecture shown in FIG. 7 is merely exemplary. When implementing different devices, one or more components of the electronic device shown in FIG. 7 may be omitted based on actual needs.

[0128] Example 5

[0129] FIG8 is a schematic diagram of the structure of a computer-readable storage medium provided by an embodiment of the present application. As shown in FIG8 , a computer-readable storage medium 600 according to an embodiment of the present application is shown. Computer-readable instructions are stored on the computer-readable storage medium 600. When the computer-readable instructions are executed by the processor, a method for actively detecting BM by a BMGW-VIP cluster according to an embodiment of the present application described with reference to the above figures can be executed. The storage medium 600 includes, but is not limited to, for example, volatile memory and / or non-volatile memory. Volatile memory may include, for example, random access memory (RAM) and cache memory. Non-volatile memory may include, for example, read-only memory (ROM), hard disk, flash memory, etc.

[0130] It should be understood that the methods, apparatuses, and devices of the present application can be implemented in many ways. For example, the methods, apparatuses, and devices of the present application can be implemented by software, hardware, firmware, or any combination of software, hardware, and firmware. The above order of steps used for the method is for illustration only, and the steps of the method of the present application are not limited to the order specifically described above unless otherwise specified. In addition, in some embodiments, the present application can also be implemented as programs recorded in a recording medium, which include machine-readable instructions for implementing the method according to the present application. Therefore, the present application also covers recording media that store programs for executing the method according to the present application.

[0131] In addition, the parts of the above technical solutions provided in the embodiments of the present application that are consistent with the implementation principles of the corresponding technical solutions in the prior art are not described in detail to avoid excessive redundancy.

[0132] The above-described specific embodiments further illustrate the purpose, technical solutions, and beneficial effects of this application. It should be understood that the above description is merely a specific embodiment of this application and is not intended to limit this application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of this application shall be included within the scope of protection of this application.

Claims

1. A method for BMGW-VIP cluster to actively detect BM, characterized in that: The following steps are involved: Use the ping program to detect the IP address of the BM in the BMGW-VIP cluster member, use the -p parameter to specify the VNI where the BM is located, and the ping program uses ICMP to send a request to the BMGW service to detect the BM; The BMGW service receives ICMP probe requests from the BM, detects ping packets, and extracts the VNI, which is used as the VNI parameter for encapsulating BM VXLAN tunnel packets. The BMGW service modifies the source IP of the ping message based on the VNI query information and fills the source IP into the ping message, encapsulates the VXLAN message using the VNI where the BM is located, and sends it to the LEAF node; The BMGW cluster member receives the reply ping message and forwards the ping message to the cluster member that originated the request based on the data in the ping message. After receiving the ping message, the cluster member that originated the request restores the ping message based on the data in the ping message and sends it to the kernel.

2. The method for actively detecting BM by a BMGW-VIP cluster according to claim 1, characterized in that: The method of using the ping program to detect the IP address of the BM in the BMGW-VIP cluster member, using the -p parameter to specify the VNI where the BM is located, and using the ICMP to send a request to detect the BM to the BMGW service includes: Fill the parameter -p with the content of the general ping program and specify the VNI where the BM is located, where VNI is the tunnel identifier of the VXLAN. When the -p parameter is executed, the general ping program can automatically fill the content of BM-VXLAN-VNI into the ping message. The specific format is as follows: ping BM-IP-p BM-VXLAN-VNI-c xx-i yy.

3. The method for actively detecting BM by a BMGW-VIP cluster according to claim 1, characterized in that: The BMGW service receives an ICMP probe request from the BM, detects the ping message, and extracts the VNI as a VNI parameter for encapsulating the BM VXLAN tunnel message, including: The BMGW service receives ICMP probe requests from BM; Detect ping packets; If the ping message contains BM-VXLAN-VNI, extract the BM-VXLAN-VNI field. Use the BM-VXLAN-VNI field to find the BM subnet, obtain the subnet gateway IP address, and the VXLAN information required to access the BM. Used as the VNI parameter for BM VXLAN tunnel packet encapsulation.

4. The method for actively detecting BM by a BMGW-VIP cluster according to claim 1, characterized in that: The BMGW service modifies the source IP of the ping message and fills the source IP into the ping message according to the VNI query information, encapsulates the VXLAN message using the VNI where the BM is located, and sends the message to the LEAF node, including: BMGW service queries information based on VNI; Replace the source IP address of the ping message with the subnet gateway IP address. Fill the source IP of the ping message into the ping message; Encapsulate the original ping packet using VXLAN encapsulation information. The encapsulated original ping message is sent to the LEAF node.

5. The method for actively detecting BM by a BMGW-VIP cluster according to claim 4, characterized in that: The step of sending the encapsulated original ping message to the LEAF node includes: BM receives the ping message request and generates a reply message; The reply message is encapsulated into VXLAN by the BM access switch; The BMGW cluster member forwards the ping reply message to the BMGW cluster member. The cluster member detects the ping reply message and finds that it is a reply message requesting the subnet gateway IP address. If the BM real IP carried in the ping message is destined for the local machine, the BM real IP is used to replace the destination IP of the inner ping message and sent to the kernel. If it is not destined for the local machine, the BM real IP is used to replace the VXLAN destination IP and sent to the LEAF node.

6. The method for actively detecting BM by a BMGW-VIP cluster according to claim 1, characterized in that: The step of the BMGW cluster member receiving the reply ping message and forwarding the ping message to the cluster member that originated the request according to the data in the ping message includes: The BMGW cluster member receives the reply ping message; BMGW cluster members need to parse the received reply ping message; Forwards the ping message to the cluster member that originated the request based on the data in the ping message.

7. The method for actively detecting BM by a BMGW-VIP cluster according to claim 1, characterized in that: The step of the BMGW-VIP cluster member of the source request receiving the ping message, restoring the ping message according to the ping message, and sending the ping message to the kernel includes: The BMGW-VIP cluster member that originated the request receives the ping message; Detect received ping packets; Restore the ping message based on the ping message; Sent to the kernel.

8. A system for BMGW-VIP cluster to actively detect BM, characterized in that: The system comprises: A sending request module is used to use the ping program to detect the IP of the BM in the BMGW-VIP cluster member, use the -p parameter to specify the VNI where the BM is located, and the ping program uses ICMP to send a request to detect the BM to the BMGW service; In the detection module, the BMGW service receives ICMP probe requests from BM, detects ping messages, and extracts the VNI, which is used as the VNI parameter for BM VXLAN tunnel message encapsulation. A modification module is used for the BMGW service to modify the source IP of the ping message and fill the source IP into the ping message according to the VNI query information, encapsulate the VXLAN message using the VNI where the BM is located, and send it to the LEAF node; The forwarding module is used for the BMGW cluster member to receive the reply ping message and forward the ping message to the cluster member that originated the request according to the data in the ping message; The ping message is sent to the kernel module. After receiving the ping message, the cluster member that originated the request restores the ping message based on the data in the ping message and sends it to the kernel.

9. An electronic device, characterized in that: The method comprises a memory, a processor and a computer program stored in the memory and executable on the processor. When the processor executes the program, the method realizes the steps in the method for active BM detection by a BMGW-VIP cluster according to any one of claims 1 to 7.

10. A readable storage medium, characterized in that: The readable storage medium stores a computer program, and the computer program is suitable for being loaded by a processor to execute the method for actively detecting BM by a BMGW-VIP cluster according to any one of claims 1 to 7.