Main-standby switching method for floating IP (Internet Protocol) addresses of double hosts

By detecting the working status and heartbeat mechanism of local business processes, the master-slip switching of dual-host floating IP addresses is realized, which solves the problem that existing solutions cannot deeply monitor the health status and configuration of the application layer, and realizes a simple, support for multi-operation systems and low resource occupation switching mechanism.

CN119676210APending Publication Date: 2025-03-21SHANGHAI GBCOM COMM TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411853173.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-16
Publication Date
2025-03-21

AI Technical Summary

Technical Problem

The existing dual-host floating IP address master-support switching solution cannot deeply monitor the health status of the application layer, the configuration is complex, the deployment is difficult, and it does not support Windows environment and Linux operating systems.

Method used

By detecting the working status and heartbeat mechanism of local business processes, the main and backup switching is realized, the switching mechanism is simplified, the reliance on third-party software, and supports operating systems such as Windows, Linux, Unix, etc.

Benefits of technology

It realizes a simple master-stop switching mechanism, avoids process deadlocks and dead loops, supports heterogeneous operating systems, has low resource usage, and is suitable for embedded devices and high availability application scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119676210A_ABST
    Figure CN119676210A_ABST
Patent Text Reader

Abstract

The invention provides a dual-host floating IP (Internet Protocol) address master-slave switching method, which belongs to the technical field of communication and comprises the following steps of: detecting whether a local service process is normal or not; if the local service process is normal and the heartbeat message of the opposite-end host is not received overtime, carrying out main-standby switching according to a first preset switching strategy; and if the local service process is abnormal, carrying out main-standby switching according to a second preset switching strategy. The method has the beneficial effects that main-standby switching is realized by combining the working state of the local service process with a heartbeat mechanism, and the switching mechanism is simple and does not need to depend on third-party software; meanwhile, main and standby switching is carried out according to the internal working state of the service process, so that the situation of switching failure caused by process deadlock, endless loop and the like can be avoided; in addition, the method supports Windows, Linux, Unix and other operating systems, is wide in application range, supports deployment under a heterogeneous operating system, is extremely low in resource occupation, is suitable for being deployed in various embedded devices, and is suitable for embedded application scenes needing main and standby redundancy and meeting high availability requirements.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of communication technology, and in particular to a dual-host floating IP address active-standby switching method. Background Art

[0002] Dual-host floating IP address active-standby switching means configuring two hosts (one active and one standby) to share a virtual floating IP address. When the active host fails, the standby host can quickly take over the floating IP address and services, thereby ensuring service continuity and stability and improving system reliability and availability.

[0003] In the prior art, the dual-host floating IP address active-standby switching solution is based on the Virtual Router Redundancy Protocol (VRRP) and the keepalived service. This method is mainly applicable to the Linux operating system and implements dynamic monitoring through keepalived. However, since it depends on the VRRP status for inspection, the health check function is limited and it is impossible to deeply monitor the health status of the application layer; at the same time, the configuration of the VRRP protocol and the keepalived service is relatively complex and does not support the Windows environment.

[0004] On the other hand, dual-host floating IP address master-slave switching can also be achieved based on Windows Failover Clustering. This method is applicable to Windows Server operating systems and requires the configuration of corresponding services. However, since shared storage needs to be configured, its scope of use and usage scenarios are limited; in addition, this method also cannot deeply monitor the health status of the application layer and does not support the Linux operating system.

[0005] Both of the above two typical implementation methods have problems such as the inability to deeply monitor the health status of the application layer, limited usage scenarios, complex configuration, and high deployment difficulty. This, to a certain extent, limits the application and promotion of dual-host floating IP technology in different scenarios. Summary of the invention

[0006] In order to solve the above technical problems, the present invention provides a dual-host floating IP address active-standby switching method.

[0007] The technical problem solved by the present invention can be achieved by adopting the following technical solutions:

[0008] A dual-host floating IP address active / standby switching method, comprising:

[0009] Check whether the local business process is normal;

[0010] If the local service process is normal and the heartbeat message from the opposite host is not received within a timeout period, the master-slave switch is performed according to the first preset switch strategy;

[0011] If the local service process is abnormal, the active / standby switching is performed according to the second preset switching strategy.

[0012] Preferably, the detecting whether the local service process is normal includes:

[0013] Send heartbeat messages to the peer host;

[0014] Receive a heartbeat message sent by the opposite host.

[0015] Preferably, the detecting whether the local service process is normal includes:

[0016] According to the monitored process configured by the local host, obtaining the working status of the monitored process;

[0017] Detecting whether the local business process is normal according to the working status of the monitored process;

[0018] When the monitored process is running, determining that the local business process is normal;

[0019] When the monitored process is not running, it is determined that the local business process is abnormal.

[0020] Preferably, the detecting whether the local service process is normal includes:

[0021] Receiving the internal working status reported by the monitored process, and detecting whether the local business process is normal according to the received internal working status reported by the monitored process;

[0022] When the internal working state reported by the monitored process is normal, determining that the local business process is normal;

[0023] When the internal working state reported by the monitored process is abnormal, it is determined that the local business process is abnormal.

[0024] Preferably, the detecting whether the local business process is normal according to the received internal working state reported by the monitored process further comprises:

[0025] When the internal working status reported by the monitored process is not received within a timeout period, it is determined that the local service process is abnormal.

[0026] Preferably, the first preset switching strategy includes:

[0027] Maintain or switch the local host to the active state.

[0028] Preferably, the second preset switching strategy includes:

[0029] Keep or switch the local host to standby status.

[0030] Preferably, the dual hosts are in an initial state when started, and in the initial state, the dual hosts are both set to a standby state.

[0031] Preferably, the dual host includes a first host and a second host, and the first host and the second host correspond to different migration priorities respectively;

[0032] Under the same working status, the host with a higher migration priority is switched to the active state, and the host with a lower migration priority is switched to the standby state.

[0033] Preferably, the two hosts share the same floating IP address, and the floating IP address is associated with the host switched to the active state.

[0034] The advantages or beneficial effects of the technical solution of the present invention are:

[0035] The present invention realizes active-standby switching by combining the working status of the local business process with the heartbeat mechanism. The switching mechanism is simple and does not need to rely on third-party software. At the same time, active-standby switching is performed according to the internal working status of the business process, which can avoid switching failures caused by process deadlock, infinite loop, etc. In addition, it supports operating systems such as Windows, Linux, and Unix, has a wide range of applications, and supports deployment under heterogeneous operating systems, with extremely low resource usage, and is suitable for deployment in various embedded devices, and is suitable for embedded application scenarios that require active-standby redundancy and meet high availability requirements. BRIEF DESCRIPTION OF THE DRAWINGS

[0036] Figure 1 A schematic diagram of the main process in a preferred embodiment of the present invention;

[0037] Figure 2 A schematic diagram of a process flow of active / standby switching detection in a preferred embodiment of the present invention;

[0038] Figure 3 The figure is a flow chart of the active / standby state migration of dual hosts in a preferred embodiment of the present invention. DETAILED DESCRIPTION

[0039] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0040] It should be noted that, in the absence of conflict, the embodiments of the present invention and the features in the embodiments may be combined with each other.

[0041] The present invention will be further described below in conjunction with the accompanying drawings and specific embodiments, but they are not intended to limit the present invention.

[0042] In a preferred embodiment of the present invention, based on the above problems existing in the prior art, a dual-host floating IP address active-standby switching method is provided. Figure 1 and Figure 2 As shown, including:

[0043] Check whether the local business process is normal;

[0044] If the local service process is normal and the heartbeat message from the opposite host is not received within a timeout period, the master-slave switch is performed according to the first preset switch strategy;

[0045] If the local service process is abnormal, the active / standby switching is performed according to the second preset switching strategy.

[0046] Specifically, the existing dual-host floating IP address active-standby switching implementation solutions based on VRRP+keepalived or Windows Failover Clustering have the problems of being unable to deeply monitor the health status of the application layer, limited usage scenarios, complex configuration, and high deployment difficulty. The embodiments of the present invention implement active-standby switching by combining the working status of the local business process with the heartbeat mechanism. The switching mechanism is simple and does not need to rely on third-party software.

[0047] At the same time, active / standby switching is performed according to the internal working status of the business process, which can avoid switching failures caused by process deadlock, infinite loop, etc.

[0048] The method of the present invention also supports operating systems such as Windows, Linux, and Unix, has a wide range of applications, and supports deployment under heterogeneous operating systems, with extremely low resource usage, and is suitable for deployment in various embedded devices, and is suitable for embedded application scenarios that require primary and standby redundancy and meet high availability requirements.

[0049] The dual-host floating IP address active-standby switching method shown in the embodiment of the present invention is mainly used as a software embodiment (such as monitoring software) and is configured to run in a computer device. For example, monitoring software is deployed in dual hosts, namely the first host and the second host, to monitor the working status of the local business process, realize mutual heartbeat detection with the opposite host, and communicate the working status of the local host, and then make a comprehensive judgment on the working status of the local host and the opposite host. If the conditions are met, active-standby switching is performed to realize active-standby switching of dual hosts sharing a floating IP address.

[0050] Specifically, for the monitoring software deployed in the first host, the first host is regarded as the local host, and the second host is regarded as the opposite host.

[0051] For the monitoring software deployed in the second host, the second host is regarded as the local host, and the first host is regarded as the remote host.

[0052] Specifically, after the monitoring software is started, the monitoring configuration data of the local host is obtained, including but not limited to the default working status, service address, network card name, peer heartbeat address, etc.

[0053] The heartbeat address is pre-configured in the two hosts for mutual detection between the master and the backup. The heartbeat address and the business address (floating IP address) used by the business process are configured on the same physical network card to ensure that the third party's access to the heartbeat address and the business address remains consistent when the network card, network cable, and switch port are normal or abnormal. They can be accessed under normal circumstances, but cannot be accessed under abnormal circumstances.

[0054] As a preferred implementation, the process of detecting whether the local service process is normal includes:

[0055] Send heartbeat messages to the peer host;

[0056] Receive heartbeat messages sent by the peer host.

[0057] Specifically, in this embodiment, after obtaining the monitoring configuration data of the local host, a heartbeat message is periodically sent to the opposite host, and the message content of the message is the master-slave status (active or standby) of the local host and the working status (normal or abnormal) of the business process of the local host; then, the heartbeat message of the opposite host is received, and after receiving the heartbeat message from the opposite host, the working status of the opposite host is updated according to the heartbeat message, so as to judge the status when the master-slave switch is performed.

[0058] The master-slave switch detection process is performed according to the master-slave status of the local host and the remote host and the working status of the service process.

[0059] As a preferred implementation, detecting whether the local service process is normal includes:

[0060] According to the monitored process configured on the local host, obtain the working status of the monitored process;

[0061] Detect whether the local business process is normal based on the working status of the monitored process;

[0062] When the monitored process is running, the local business process is determined to be normal;

[0063] When the monitored process is not running, the local business process is determined to be abnormal.

[0064] Specifically, in this embodiment, in the active / standby switching detection process, the process name of the monitored process is pre-configured on the local host to obtain the working status of the monitored process.

[0065] The monitored process shown in this embodiment is a process that needs to be monitored, such as a core business process of the local machine.

[0066] In this embodiment, the working status of the monitored process includes normal or abnormal.

[0067] Specifically, if the monitored process is running, the monitored process exists, that is, it is determined that the monitored process is normal.

[0068] On the contrary, if the monitored process is not running, the monitored process does not exist, that is, the monitored process is determined to be abnormal.

[0069] As a preferred implementation, detecting whether the local service process is normal includes:

[0070] Receive the internal working status reported by the monitored process, and detect whether the local business process is normal according to the internal working status reported by the monitored process;

[0071] When the internal working status reported by the monitored process is normal, the local business process is determined to be normal;

[0072] When the internal working state reported by the monitored process is abnormal, the local business process is determined to be abnormal.

[0073] As a preferred implementation, the step of detecting whether the local service process is normal according to the internal working state reported by the monitored process includes:

[0074] When the internal working status reported by the monitored process is not received within a timeout period, it is determined that the local business process is abnormal.

[0075] Specifically, in this embodiment, an internal interface may also be provided in the process of the local host so that the monitored process, such as the local core business process, can report the working status of the process.

[0076] The monitored process periodically and dynamically reports its internal working status, such as normal or abnormal, through this interface according to the actual running status. The specific judgment criteria are determined by the business process, such as failure to connect to the database server, failure to initialize key resources, etc.

[0077] If the monitoring software does not receive the report content of the business process for multiple consecutive times (or timeout), the working status will be set to abnormal.

[0078] Furthermore, if the monitored process does not need to report the internal working status, the internal interface can be not configured, and the process working status is simply judged by whether the business process exists, that is, if the process exists, the local business process is normal, otherwise the local business process is judged to be abnormal.

[0079] In summary, when it is detected that the local host business process is not running, or the internal working status reported by the local host business process is abnormal, or the internal working status reported by the local host business process is not received after a timeout, the local business process is determined to be abnormal; otherwise, the local business process is determined to be normal.

[0080] The method shown in the present invention performs active / standby switching according to the internal working state of the business process, and can avoid switching failures caused by process deadlock, infinite loop, etc.

[0081] As a preferred implementation, the first preset switching strategy includes:

[0082] Maintain or switch the local host to the active state.

[0083] As a preferred implementation, the second preset switching strategy includes:

[0084] Keep or switch the local host to standby status.

[0085] Specifically, in the master-slave switching detection process, when the network between the hosts is normal, if the business process of the local host (i.e., the local business process) and the business process of the other host are both normal, then the master-slave switching is performed according to the migration priority of the two hosts, that is, the host with a higher migration priority switches to the master state, and the host with a lower migration priority switches to the standby state.

[0086] If the service process of the local host is normal, but the service process of the remote host is abnormal, if the original state of the local host is the active state, it will remain in the active state; if the original state of the local host is the standby state, it will switch to the active state.

[0087] If the service process of the local host is abnormal, while the service process of the other host is normal, if the original state of the local host is the active state, it will switch to the standby state; if the original state of the local host is the standby state, it will remain in the standby state.

[0088] If the network between the hosts is disconnected or the heartbeat message of the other host is not received within a timeout period, if the original state of the local host is the active state, it will remain in the active state; if the original state of the local host is the standby state, it will switch to the active state.

[0089] Furthermore, if the host network is disconnected or the local host does not receive the heartbeat message of the other host due to timeout, if the original state of the other host is the active state, the active / active state will appear, that is, both hosts are in the active state. At this time, generally one of the hosts has an abnormal network connection, while the other host has a normal network connection. The host with a normal network connection can continue to provide services, and the operation of the business is usually not affected.

[0090] In order to maintain the normal operation of the system and avoid potential conflicts, once the network connection between the hosts returns to normal, the host with the original abnormal network connection will be immediately switched to standby status.

[0091] As an example and not a limitation, in the master / master state, a host with a normal network connection continues to add a request message in the heartbeat message to switch the host with an abnormal network connection to a standby state, so that after the host network connection returns to normal, it immediately switches to the standby state in response to the request message.

[0092] As a preferred implementation, the dual hosts are in an initial state when they are started, and in the initial state, both hosts are set to a standby state.

[0093] As a preferred implementation, the dual host includes a first host and a second host, and the first host and the second host correspond to different migration priorities respectively;

[0094] Under the same working status, the host with a higher migration priority is switched to the active state, and the host with a lower migration priority is switched to the standby state.

[0095] Specifically, in order to achieve state migration under the same working state, the two hosts need to configure their own migration priorities, and the migration priorities of the two hosts cannot be the same. Under the same working state, the host with a higher migration priority switches to the active state, and the host with a lower migration priority switches to the standby state.

[0096] In this embodiment, the migration priority of the first host configuration is higher than that of the second host. That is, when the working status of the first host and the second host are both normal, the first host switches to the active state and the second host switches to the standby state. The embodiment of the present invention takes the first host with a higher priority as an example.

[0097] On the contrary, if the migration priority configured for the second host is higher than that of the first host, that is, when the working status of the first host and the second host are both normal, the second host switches to the active state, and the first host switches to the standby state.

[0098] In this embodiment, the monitoring software periodically performs switching judgment:

[0099] If the local business process does not exist, no further judgment is made.

[0100] If the heartbeat message from the peer host is not received within a timeout period, the working state of the peer host is set to abnormal.

[0101] If the local host has a high migration priority, if the local business process is normal, the local host will be switched to the active state; if the local business process is abnormal and the business process of the other host is normal, the local host will be switched to the standby state, and other situations will remain the same.

[0102] If the local host has a low migration priority, if the peer service process is normal, the local host will be switched to the standby state; if the local service process is normal and the peer service process is abnormal, the local host will be switched to the active state, and other situations will remain the same.

[0103] like Figure 3 The figure shows the active / standby state transition diagram of dual hosts. Figure 3 The circle in the figure indicates the primary and secondary master status, including the following four states:

[0104] Standby / Standby means that both hosts are set to standby status. Standby / Standby is a temporary state. After a period of detection, it will switch to active / standby or standby / active status.

[0105] Active / standby means that the first host is set to active state and the second host is set to standby state.

[0106] Backup / Active means that the first host is set to the backup state and the second host is set to the active state.

[0107] Active / Active means that both hosts are set to active status. The Active / Active status occurs when the communication between the hosts is disconnected, which usually occurs when the network connection of one host is abnormal. If the network connection of the other host is normal at this time, there is no impact on the business.

[0108] The details of active / standby state migration are as follows:

[0109] Initial status Standby / Standby: When the master-slave monitoring process starts, its own working status is set to standby. At this time, the status of the two hosts is: Standby / Standby;

[0110] Backup / backup to active / backup: If the network between the hosts is normal and the service process of the first host is normal, the first host switches to the active state and the second host remains in the backup state. At this time, the status of the two hosts is: active / backup;

[0111] Backup / backup to backup / primary: If the network between the hosts is normal, and the service process of the first host is abnormal, and the service process of the second host is normal, the second host switches to the primary state, and the first host remains in the backup state. At this time, the status of the two hosts is: backup / primary;

[0112] Active / standby to standby / active: If the network between the hosts is normal, and the service process of the first host is abnormal, and the service process of the second host is normal, the second host switches to the active state, and the first host switches to the standby state. At this time, the status of the two hosts is standby / active;

[0113] Backup / Active to Active / Backup: If the network between the hosts is normal, and the service process of the first host is normal, and the service process of the second host is abnormal, the first host switches to the active state and the second host switches to the backup state. At this time, the status of the two hosts is: active / backup;

[0114] Active / standby to active / active: If the network between the hosts is disconnected, or the second host times out without receiving the heartbeat message from the other end, the first host remains in active state and the second host switches to active state. At this time, the status of the two hosts is: active / active;

[0115] Backup / Active to Active / Active: If the network between the hosts is disconnected, or the first host times out without receiving the heartbeat message from the other end, the second host remains in the active state and the first host switches to the active state. At this time, the states of the two hosts are: Active / Active;

[0116] Master / Master to Master / Backup: If the network between the hosts returns to normal, the first host remains in the master state and the second host switches to the backup state. At this time, the status of the two hosts is: master / backup.

[0117] As a preferred implementation, two hosts share the same floating IP address, and the floating IP address is associated with the host switched to the active state.

[0118] Specifically, the method shown in the present invention is applied in a dual-host environment, and the operating status of the local host and the remote host is monitored in real time through monitoring software. After the switching conditions are met, the IP address is automatically migrated to realize the floating IP externally.

[0119] The floating IP address floats with the active and standby states of the host. The floating IP address is effective only on the active host. The standby host does not respond to any external data packets.

[0120] In this embodiment, the first host and the second host share the same floating IP address, and the floating IP address is associated with the host switched to the active state.

[0121] For example, when the first host switches to the active state, a floating IP address is added to the first host. Similarly, when the second host switches to the active state, a floating IP address is added to the second host.

[0122] Furthermore, the method further includes: for a host switched from an active state to a standby state, deleting a floating IP address from the standby host.

[0123] For example, when the first host switches from the active state to the standby state, the floating IP address is deleted from the first host. Similarly, when the second host switches from the active state to the standby state, the floating IP address is deleted from the second host.

[0124] If the host needs to be switched to the active state, a floating IP address will be added to the host; if the host needs to be switched to the standby state, the floating IP address in the host will be deleted.

[0125] In the dual-host floating IP address active-standby mode, only one host is in the active state at the same time. At this time, the floating IP address is migrated to the host in the active state, and the floating IP address is deleted from the host in the standby state. The address migration and deletion are implemented by the monitoring software.

[0126] The advantages or beneficial effects of adopting the above technical solution are: the present invention realizes the master-slave switching by combining the working status of the local business process with the heartbeat mechanism, and the switching mechanism is simple and does not need to rely on third-party software; at the same time, the master-slave switching is performed according to the internal working status of the business process, which can avoid the switching failure caused by process deadlock, infinite loop, etc.; in addition, it supports Windows, Linux, Unix and other operating systems, has a wide range of applications, and supports deployment under heterogeneous operating systems, and has extremely low resource usage, is suitable for deployment in various embedded devices, and is suitable for embedded application scenarios that require master-slave redundancy and meet high availability requirements.

[0127] Those skilled in the art will appreciate that various aspects of the present invention, or possible implementations of various aspects, may be specifically implemented as systems, methods, or computer program products. Therefore, various aspects of the present invention, or possible implementations of various aspects, may take the form of complete hardware embodiments, complete software embodiments (including firmware, resident software, etc.), or embodiments of combined software and hardware aspects, all collectively referred to herein as "circuits," "modules," or "systems." In addition, various aspects of the present invention, or possible implementations of various aspects, may take the form of computer program products, which refer to computer instructions stored in a memory.

[0128] Computer instructions can be executed completely on the user's local computer, partially on the user's local computer, as a separate software package, partially on the user's local computer and partially on a remote computer, or completely on a remote computer or server. It should also be noted that in some alternative embodiments, the functions noted in each step in the flow chart or each block in the block diagram may not occur in the order noted in the figure. For example, depending on the functions involved, two steps or two blocks shown in succession may actually be executed roughly simultaneously, or these blocks may sometimes be executed in reverse order.

[0129] The above are only preferred embodiments of the present invention, and are not intended to limit the implementation methods and protection scope of the present invention. Those skilled in the art should be aware that all solutions obtained by equivalent substitutions and obvious changes made using the contents of this specification and illustrations should be included in the protection scope of the present invention.

Claims

1. A dual-host floating IP address active / standby switching method, characterized in that: include: Check whether the local business process is normal; If the local service process is normal and the heartbeat message from the opposite host is not received within a timeout period, the master-slave switch is performed according to the first preset switch strategy; If the local service process is abnormal, the active / standby switching is performed according to the second preset switching strategy.

2. The dual-host floating IP address active-standby switching method according to claim 1, characterized in that: The detecting whether the local service process is normal includes: Send heartbeat messages to the peer host; Receive a heartbeat message sent by the opposite host.

3. The dual-host floating IP address active-standby switching method according to claim 1, characterized in that: The detecting whether the local service process is normal includes: According to the monitored process configured by the local host, obtaining the working status of the monitored process; Detecting whether the local business process is normal according to the working status of the monitored process; When the monitored process is running, determining that the local business process is normal; When the monitored process is not running, it is determined that the local business process is abnormal.

4. The dual-host floating IP address active-standby switching method according to claim 1, characterized in that: The detecting whether the local service process is normal includes: Receiving the internal working status reported by the monitored process, and detecting whether the local business process is normal according to the received internal working status reported by the monitored process; When the internal working state reported by the monitored process is normal, determining that the local business process is normal; When the internal working state reported by the monitored process is abnormal, it is determined that the local business process is abnormal.

5. The dual-host floating IP address active-standby switching method according to claim 4 is characterized in that: The detecting whether the local business process is normal according to the received internal working state reported by the monitored process also includes: When the internal working status reported by the monitored process is not received within a timeout period, it is determined that the local service process is abnormal.

6. The dual-host floating IP address active-standby switching method according to claim 1, characterized in that: The first preset switching strategy includes: Maintain or switch the local host to the active state.

7. The dual-host floating IP address active-standby switching method according to claim 1, characterized in that: The second preset switching strategy includes: Keep or switch the local host to standby status.

8. The dual-host floating IP address active-standby switching method according to claim 1, characterized in that: The dual hosts are in an initial state when starting up, and in the initial state, both hosts are set to a standby state.

9. The dual-host floating IP address active-standby switching method according to claim 1, characterized in that: The dual host comprises a first host and a second host, and the first host and the second host respectively correspond to different migration priorities; Under the same working status, the host with a higher migration priority is switched to the active state, and the host with a lower migration priority is switched to the standby state.

10. The dual-host floating IP address active / standby switching method according to claim 1, characterized in that: The two hosts share the same floating IP address, and the floating IP address is associated with the host switched to the active state.