Cloud platform switching method, device, electronic device and storage medium

By proactively detecting the status of the backup cloud platform and modifying its protocol address when the primary cloud platform fails, automatic switching between the primary and backup cloud platforms is achieved, solving the problem of insufficient disaster recovery capabilities of cloud platforms and ensuring users' network experience and data security.

CN117201507BActive Publication Date: 2024-11-19INSPUR SUZHOU INTELLIGENT TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311477946.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-11-08
Publication Date
2024-11-19
Estimated Expiration
2043-11-08

AI Technical Summary

Technical Problem

Existing cloud platforms lack sufficient disaster recovery capabilities and cannot effectively address data loss caused by unforeseen circumstances.

Method used

By proactively detecting faults in both the primary and backup cloud platforms when a primary cloud platform failure is detected, and setting the primary cloud platform to a non-active state while the backup cloud platform is active, and modifying the Internet Protocol address of the domain name service, automatic traffic forwarding and switching are achieved, reducing network congestion.

Benefits of technology

It enables seamless switching between primary and backup cloud platforms, reduces network congestion, ensures a good network experience for users, and improves the disaster recovery capabilities of the cloud platform.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117201507B_ABST
    Figure CN117201507B_ABST
Patent Text Reader

Abstract

The present invention provides a cloud platform switching method, device, electronic device and storage medium, which relate to the field of data processing technology, including: when a fault is detected in a main cloud platform, fault detection is performed on a backup cloud platform; when the backup cloud platform is in a surviving state, the main cloud platform is set to a non-surviving state, and a first Internet Protocol address corresponding to a first domain name service in the backup cloud platform is modified to a second Internet Protocol address; wherein the first Internet Protocol address is the Internet Protocol address of the main cloud platform service in the main cloud platform, and the second Internet Protocol address is the Internet Protocol address of the backup cloud platform service in the backup cloud platform.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of data processing technology, and in particular to a cloud platform switching method, device, electronic device and storage medium. Background Art

[0002] With the continuous development of cloud computing technology, cloud technology has been more and more widely used. More and more users or enterprises will store data in the cloud platform. Once the data of the cloud platform is lost, it will have a significant impact on users. However, in the actual operation of the cloud platform, there are often a variety of force majeure factors, such as earthquakes, fires, floods, etc., which lead to cloud platform failures and data loss. Therefore, in order to prevent data loss, the requirements for the disaster recovery capabilities of the cloud platform are getting higher and higher.

[0003] How to better improve the disaster recovery capabilities of cloud platforms has become an urgent problem to be solved in the industry. Summary of the invention

[0004] The present invention provides a cloud platform switching method, device, electronic device and storage medium, which are used to solve the defects in the prior art of how to better improve the disaster recovery capability of the cloud platform.

[0005] The present invention provides a cloud platform switching method, comprising:

[0006] When a failure is detected on the primary cloud platform, the backup cloud platform is tested for the failure;

[0007] When the backup cloud platform is in a live state, the primary cloud platform is set to a non-live state, and a first Internet Protocol address corresponding to a first domain name service in the backup cloud platform is modified to a second Internet Protocol address;

[0008] The first Internet Protocol address is an Internet Protocol address of a primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is an Internet Protocol address of a backup cloud platform service in the backup cloud platform.

[0009] According to a cloud platform switching method provided by the present invention, after the step of modifying the first Internet Protocol address corresponding to the first domain name service in the backup cloud platform to the second Internet Protocol address, the method further includes:

[0010] The first Internet Protocol address corresponding to the second domain name service in the primary cloud platform is modified to the second Internet Protocol address.

[0011] According to a cloud platform switching method provided by the present invention, after the step of modifying the first Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the second Internet Protocol address, the method further includes:

[0012] When a network jitter occurs in the process of performing domain name resolution for a first domain name accessed by a user by the first domain name service of the backup cloud platform, forwarding the first domain name to the second domain name service of the primary cloud platform;

[0013] The second domain name service of the main cloud platform performs domain name resolution on the first domain name, and accesses data through the first and second Internet Protocol addresses corresponding to the second domain name service.

[0014] According to a cloud platform switching method provided by the present invention, after the step of modifying the first Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the second Internet Protocol address, the method further includes:

[0015] When the primary cloud platform switches from a non-survival state to a surviving state, synchronizing the incremental data in the backup cloud platform to the primary cloud platform; the incremental data is the data processed by the backup cloud platform during the period when the primary cloud platform is in a non-survival state;

[0016] The second Internet Protocol address corresponding to the second domain name service in the primary cloud platform is modified to the first Internet Protocol address.

[0017] According to a cloud platform switching method provided by the present invention, when a fault occurs on the primary cloud platform, after the step of performing fault detection on the backup cloud platform, the method further includes:

[0018] When the standby cloud platform is in a non-survival state, the switching of the primary and standby cloud platforms is stopped, and fault warning information is generated.

[0019] According to a cloud platform switching method provided by the present invention, after the step of modifying the first Internet Protocol address corresponding to the first domain name service in the backup cloud platform to the second Internet Protocol address, the method further includes:

[0020] Receiving a third domain name visited by a user, and performing global domain name resolution on the third domain name;

[0021] When the primary cloud platform is in a non-survival state, forwarding the third domain name to the first domain name service of the backup cloud platform through domain name forwarding;

[0022] After the first domain name service performs domain name resolution on the third domain name, data access is performed through the second Internet Protocol address corresponding to the first domain name service.

[0023] The present invention also provides a cloud platform switching method, comprising:

[0024] When a failure is detected on the backup cloud platform, the primary cloud platform is tested for the failure;

[0025] When the primary cloud platform is in a live state, modify the second Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the first Internet Protocol address, and set the backup cloud platform to a non-live state;

[0026] The first Internet Protocol address is an Internet Protocol address of a primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is an Internet Protocol address of a backup cloud platform service in the backup cloud platform.

[0027] According to a cloud platform switching method provided by the present invention, after the step of modifying the second Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the first Internet Protocol address and setting the backup cloud platform to a non-survival state, the method further includes:

[0028] The second Internet Protocol address corresponding to the first domain name service in the backup cloud platform is modified to the first Internet Protocol address.

[0029] According to a cloud platform switching method provided by the present invention, after the step of modifying the second Internet Protocol address corresponding to the first domain name service in the backup cloud platform to the first Internet Protocol address, the method further includes:

[0030] When network jitter occurs in the process of the second domain name service performing domain name resolution for the second domain name accessed by the user, forwarding the second domain name to the first domain name service of the backup cloud platform;

[0031] The first domain name service of the backup cloud platform performs domain name resolution on the second domain name, and accesses data through a first Internet Protocol address corresponding to the first domain name service.

[0032] According to a cloud platform switching method provided by the present invention, when a failure of the standby cloud platform is detected, after the step of performing a fault detection on the main cloud platform, the method further includes:

[0033] When the primary cloud platform is in a non-survival state, the switching of the primary and standby cloud platforms is stopped, and fault warning information is generated.

[0034] According to a cloud platform switching method provided by the present invention, when a fault is detected on the primary cloud platform, before the step of performing fault detection on the backup cloud platform, the method further includes:

[0035] Through the heartbeat mechanism, heartbeat detection information is sent to the active cloud platform or backup cloud platform;

[0036] When the feedback information of the heartbeat detection information meets the fault condition, the primary cloud platform or the backup cloud platform in the non-survival state is determined.

[0037] According to a cloud platform switching method provided by the present invention, a heartbeat detection information is sent to a primary cloud platform or a backup cloud platform in a survival state through a heartbeat mechanism, including:

[0038] According to a first preset period, regularly sending first heartbeat detection information to an Internet Protocol address corresponding to a second domain name service in a primary cloud platform or a first domain name service in a backup cloud platform in a survival state;

[0039] The first heartbeat detection information is used to request the primary cloud platform or the backup cloud platform in a survival state to respond.

[0040] According to a cloud platform switching method provided by the present invention, after the step of regularly sending first heartbeat detection information to the Internet protocol address corresponding to the second domain name service in the primary cloud platform or the first domain name service in the backup cloud platform in a survival state according to a first preset period, the method further includes:

[0041] If no response information of the primary cloud platform or the backup cloud platform in the survival state to the first heartbeat detection information is received within a first preset time period, it is determined that the primary cloud platform or the backup cloud platform in the survival state fails;

[0042] Switch the primary cloud platform or the backup cloud platform from a surviving state to a non-surviving state.

[0043] According to a cloud platform switching method provided by the present invention, a heartbeat detection information is sent to a primary cloud platform or a backup cloud platform in a survival state through a heartbeat mechanism, including:

[0044] According to a second preset period, regularly sending second heartbeat detection information to an Internet Protocol address corresponding to a second domain name service in the primary cloud platform or a first domain name service in the backup cloud platform that is in a survival state;

[0045] Among them, the second heartbeat detection information is used to request the main cloud platform or the backup cloud platform in a survival state to execute a target instruction.

[0046] According to a cloud platform switching method provided by the present invention, after the step of regularly sending a second heartbeat detection information to an Internet protocol address corresponding to a second domain name service in a primary cloud platform or a first domain name service in a backup cloud platform in a survival state according to a second preset period, the method further includes:

[0047] In a case where the primary cloud platform or the backup cloud platform in the surviving state fails to execute the target instruction, determining that the primary cloud platform or the backup cloud platform in the surviving state fails;

[0048] Switch the primary cloud platform or the backup cloud platform from a surviving state to a non-surviving state.

[0049] According to a cloud platform switching method provided by the present invention, the method further includes:

[0050] Obtaining status information of the primary cloud platform and the backup cloud platform;

[0051] Through the heartbeat mechanism, a heartbeat detection is performed on the main cloud platform or the backup cloud platform whose status information is in a survival state.

[0052] The present invention also provides a cloud platform switching device, comprising:

[0053] The first detection module is used to perform fault detection on the backup cloud platform when a fault is detected on the primary cloud platform;

[0054] A first switching module is used to set the main cloud platform to a non-survival state when the backup cloud platform is in a survival state, and to modify the first Internet Protocol address corresponding to the first domain name service in the backup cloud platform to a second Internet Protocol address;

[0055] The first Internet Protocol address is an Internet Protocol address of a primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is an Internet Protocol address of a backup cloud platform service in the backup cloud platform.

[0056] According to a cloud platform switching device provided by the present invention, the device is also used for:

[0057] The first Internet Protocol address corresponding to the second domain name service in the primary cloud platform is modified to the second Internet Protocol address.

[0058] According to a cloud platform switching device provided by the present invention, the device is also used for:

[0059] When network jitter occurs in the process of the first domain name service performing domain name resolution for the first domain name accessed by the user, forwarding the first domain name to the second domain name service of the primary cloud platform;

[0060] The second domain name service of the main cloud platform performs domain name resolution on the first domain name, and accesses data through a second Internet Protocol address corresponding to the second domain name service.

[0061] According to a cloud platform switching device provided by the present invention, the device is also used for:

[0062] When the primary cloud platform switches from a non-survival state to a surviving state, synchronizing the incremental data in the backup cloud platform to the primary cloud platform; the incremental data is the data processed by the backup cloud platform during the period when the primary cloud platform is in a non-survival state;

[0063] The second Internet Protocol address corresponding to the second domain name service in the primary cloud platform is modified to the first Internet Protocol address.

[0064] According to a cloud platform switching device provided by the present invention, the device is also used for:

[0065] When the standby cloud platform is in a non-survival state, the switching of the primary and standby cloud platforms is stopped, and fault warning information is generated.

[0066] The present invention also provides a cloud platform switching device, comprising:

[0067] The second detection module performs fault detection on the main cloud platform when a fault is detected on the backup cloud platform;

[0068] The second switching module modifies the second Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the first Internet Protocol address when the primary cloud platform is in a live state, and sets the backup cloud platform to a non-live state;

[0069] The first Internet Protocol address is an Internet Protocol address of a primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is an Internet Protocol address of a backup cloud platform service in the backup cloud platform.

[0070] Optionally, the device is further used to: modify the second Internet Protocol address corresponding to the first domain name service in the backup cloud platform to the first Internet Protocol address.

[0071] Optionally, the device is further used for:

[0072] When network jitter occurs in the process of the second domain name service performing domain name resolution for the second domain name accessed by the user, forwarding the second domain name to the first domain name service of the backup cloud platform;

[0073] The first domain name service of the backup cloud platform performs domain name resolution on the second domain name, and accesses data through a first Internet Protocol address corresponding to the first domain name service.

[0074] Optionally, the device is further used for:

[0075] When the primary cloud platform is in a non-survival state, the switching of the primary and standby cloud platforms is stopped, and fault warning information is generated.

[0076] Optionally, the device is further used for:

[0077] Through the heartbeat mechanism, heartbeat detection information is sent to the active cloud platform or backup cloud platform;

[0078] When the feedback information of the heartbeat detection information meets the fault condition, the primary cloud platform or the backup cloud platform in the non-survival state is determined.

[0079] Optionally, the device is further used for:

[0080] According to a first preset period, regularly sending first heartbeat detection information to an Internet Protocol address corresponding to a second domain name service in a primary cloud platform or a first domain name service in a backup cloud platform in a survival state;

[0081] The first heartbeat detection information is used to request the primary cloud platform or the backup cloud platform in a survival state to respond.

[0082] Optionally, the device is further used for:

[0083] If no response information of the primary cloud platform or the backup cloud platform in the survival state to the first heartbeat detection information is received within a first preset time period, it is determined that the primary cloud platform or the backup cloud platform in the survival state fails;

[0084] Switch the primary cloud platform or the backup cloud platform from a surviving state to a non-surviving state.

[0085] Optionally, the device is further used for:

[0086] According to a second preset period, regularly sending second heartbeat detection information to an Internet Protocol address corresponding to a second domain name service in the primary cloud platform or a first domain name service in the backup cloud platform that is in a survival state;

[0087] Among them, the second heartbeat detection information is used to request the main cloud platform or the backup cloud platform in a survival state to execute a target instruction.

[0088] Optionally, the device is further used for:

[0089] In a case where the primary cloud platform or the backup cloud platform in the surviving state fails to execute the target instruction, determining that the primary cloud platform or the backup cloud platform in the surviving state fails;

[0090] Switch the primary cloud platform or the backup cloud platform from a surviving state to a non-surviving state.

[0091] Optionally, the device is further used for:

[0092] Obtaining status information of the primary cloud platform and the backup cloud platform;

[0093] Through the heartbeat mechanism, a heartbeat detection is performed on the main cloud platform or the backup cloud platform whose status information is in a survival state.

[0094] Optionally, the device is further used for:

[0095] Receiving a third domain name visited by a user, and performing global domain name resolution on the third domain name;

[0096] When the primary cloud platform is in a non-survival state, forwarding the third domain name to the first domain name service of the backup cloud platform through domain name forwarding;

[0097] After the first domain name service performs domain name resolution on the third domain name, data access is performed through the second Internet Protocol address corresponding to the first domain name service.

[0098] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the cloud platform switching method described above is implemented.

[0099] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements any of the cloud platform switching methods described above.

[0100] The present invention also provides a computer program product, including a computer program, which, when executed by a processor, implements any of the cloud platform switching methods described above.

[0101] The cloud platform switching method, device, electronic device and storage medium provided by the present invention prepare a main cloud platform and a backup cloud platform that backs up the main cloud platform data at the same time, actively perform fault detection on the main cloud platform and the backup cloud platform, and when a fault is detected in the main cloud platform, determine whether the backup cloud platform is in a surviving state. If the backup cloud platform is detected to be in a surviving state, the main and backup platforms can be switched, the main cloud platform can be set to a non-surviving state, and the first Internet Protocol address corresponding to the first domain name service in the backup cloud platform can be modified to a second Internet Protocol address to complete automatic forwarding and switching of traffic. The switching process of the entire cloud platform only needs to be performed between the main and backup cloud platforms, which reduces the network freeze that may occur during the cloud platform switching process, reduces the impact on users, and ensures the user's process network experience. BRIEF DESCRIPTION OF THE DRAWINGS

[0102] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0103] Figure 1 One of the flow charts of the cloud platform switching method provided in the embodiment of the present application;

[0104] Figure 2 The second flow chart of the cloud platform switching method provided in the embodiment of the present application;

[0105] Figure 3 An access processing flow chart provided for an embodiment of the present application;

[0106] Figure 4 One of the schematic diagrams of the structure of the cloud platform switching device provided in the embodiment of the present application;

[0107] Figure 5 The second schematic diagram of the structure of the cloud platform switching device provided in the embodiment of the present application;

[0108] Figure 6 It is a structural schematic diagram of the electronic device provided by the present invention. DETAILED DESCRIPTION

[0109] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. Obviously, the described embodiments are 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.

[0110] Figure 1 One of the flow charts of the cloud platform switching method provided in the embodiment of the present application is as follows: Figure 1 As shown, including:

[0111] Step 110, when a fault is detected on the primary cloud platform, a fault detection is performed on the backup cloud platform;

[0112] The main cloud platform described in the embodiments of the present application refers to the main cloud computing platform, which undertakes core business functions and provides services to users. The main cloud platform is usually fully configured and optimized in terms of high performance, high reliability and security to ensure the stable operation of the business.

[0113] The backup cloud platform described in the embodiments of the present application is a backup of the main cloud platform, and plays a role when the main cloud platform fails or fails to work properly. The backup cloud platform has the same or similar environment and functions as the main cloud platform, and can quickly switch to a backup state to ensure the continuity and availability of the system. The backup cloud platform is usually deployed in different physical locations or data centers to avoid single point failures and disasters.

[0114] In the embodiment of the present application, during the operation of the main cloud platform, the data in the main cloud platform will be synchronized to the backup cloud platform regularly to maintain data consistency. When the main cloud platform fails to work properly, the backup cloud platform will take over the main business functions and provide services to users until the main cloud platform returns to normal or other measures are taken.

[0115] In an optional embodiment, a fault detection module deployed in a third-party arbitration area independent of the primary cloud platform and the backup cloud platform can be used to regularly and proactively perform fault detection on the primary cloud platform in a surviving state. The specific detection algorithm can be a conventional fault detection service. If a fault is detected in the primary cloud platform, in order to ensure the normal operation of the cloud platform, it is necessary to switch the primary and backup cloud platforms.

[0116] In order to prevent the backup cloud platform from running smoothly after switching, it is also necessary to further perform fault detection on the backup cloud platform.

[0117] In an embodiment of the present application, fault detection on the backup cloud platform may be specifically performed by detecting the backup cloud platform through the above-mentioned fault detection algorithm, and then only when the backup cloud platform passes the fault detection, the state of the backup cloud platform will be modified to a survival state and cloud platform switching will be started.

[0118] Step 120, when the backup cloud platform is in a live state, setting the primary cloud platform to a non-live state, and modifying the first Internet Protocol address corresponding to the first domain name service in the backup cloud platform to a second Internet Protocol address;

[0119] The first Internet Protocol address is an Internet Protocol address of a primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is an Internet Protocol address of a backup cloud platform service in the backup cloud platform.

[0120] In the embodiment of the present application, when the backup cloud platform is in a surviving state, it is considered that the primary and backup cloud platforms need to be switched, and the primary and backup cloud platforms can be switched at this time.

[0121] In an embodiment of the present application, there is a corresponding relationship between the Domain Name Service (DNS) and the IP address of the cloud platform service. The system converts the domain name entered by the user into the IP address associated with it through domain name resolution, so that the user can access the corresponding network resources, such as websites, applications, etc.

[0122] In an embodiment of the present application, when the main cloud platform operates normally, the user performs domain name resolution by accessing the second domain name service of the main cloud platform, and the second domain name service corresponds to the first Internet Protocol address.

[0123] In an embodiment of the present application, the first Internet Protocol address is an Internet Protocol address of the main cloud platform service in the main cloud platform.

[0124] In an embodiment of the present application, in order to avoid access jams caused by network jitter, the Internet Protocol address corresponding to the first domain name service of the backup cloud platform may also be set to the first Internet Protocol address of the main cloud platform service in the main cloud platform.

[0125] In the embodiment of the present application, in order to avoid access jams caused by network jitter, the second domain name service of the main cloud platform and the second domain name service of the backup cloud platform both correspond to the first Internet Protocol address of the main cloud platform service in the main cloud platform.

[0126] Therefore, during the cloud platform switching process, it is necessary to modify the first Internet Protocol address corresponding to the first domain name service in the backup cloud platform to the second Internet Protocol address. In this way, when the user initiates an access request, the domain name resolution system will forward it to the first domain name service of the backup cloud platform, and call the backup cloud platform service normally through the second Internet Protocol address corresponding to the first domain name service, so that the user can continue to access the system and obtain services.

[0127] In the embodiment of the present application, such configuration changes are usually performed in the case of failover or disaster recovery to ensure the availability and continuity of the system. By modifying the Internet Protocol address corresponding to the domain name service, it is possible to quickly switch to the backup platform and correctly route the user's request to the backup platform, thereby minimizing the impact of business interruption on end users.

[0128] In an optional embodiment, when the primary cloud platform is in a live state, the second domain name service in the primary cloud platform corresponds to the first Internet Protocol address, and at this time, the first domain name service in the backup cloud platform also corresponds to the first Internet Protocol address;

[0129] When network jitter occurs in the process of performing domain name resolution on the domain name accessed by the user on the primary cloud platform, the domain name is forwarded to the first domain name service of the backup cloud platform; wherein the first domain name service corresponds to the Internet protocol address of the primary cloud platform service in the primary cloud platform;

[0130] The first domain name service of the backup cloud platform performs domain name resolution on the second domain name, and performs data access through a first Internet Protocol address corresponding to the first domain name service;

[0131] When a failure is detected on the primary cloud platform, the backup cloud platform is tested for the failure;

[0132] When the backup cloud platform is in a surviving state, the main cloud platform is set to a non-surviving state, and the first Internet Protocol address corresponding to the first domain name service in the backup cloud platform is modified to a second Internet Protocol address; in an embodiment of the present application, by simultaneously preparing the main cloud platform and the backup cloud platform that backs up the main cloud platform data, fault detection is actively performed on the main cloud platform and the backup cloud platform. When a fault is detected in the main cloud platform, it is determined whether the backup cloud platform is in a surviving state. If the backup cloud platform is detected to be in a surviving state, the main and backup platforms can be switched, and the main cloud platform can be set to a non-surviving state, and the first Internet Protocol address corresponding to the first domain name service in the backup cloud platform is modified to a second Internet Protocol address to complete automatic forwarding and switching of traffic. The switching process of the entire cloud platform only needs to be performed between the main and backup cloud platforms. The cloud platform can be switched without the user noticing, thereby ensuring the user's process network experience.

[0133] Optionally, after the step of modifying the first Internet Protocol address corresponding to the first domain name service in the backup cloud platform to the second Internet Protocol address, the method further includes:

[0134] The first Internet Protocol address corresponding to the second domain name service in the primary cloud platform is modified to the second Internet Protocol address.

[0135] In an embodiment of the present application, after the first Internet Protocol address corresponding to the first domain name service in the backup cloud platform is modified to the second Internet Protocol address, since the user's access request is now by default prioritized by the first domain name service corresponding to the backup cloud platform for domain name resolution, in order to avoid network jitter affecting the access to the primary and backup cloud platforms, the second domain name service of the primary cloud platform can be further adjusted.

[0136] In an embodiment of the present application, the first Internet Protocol address corresponding to the second domain name service in the main cloud platform is modified to the second Internet Protocol address. Through such modification, if network jitter occurs during the process of domain name resolution on the backup cloud platform, it can be further forwarded to the second domain name service of the main cloud platform, so that the user's request can be correctly routed to the backup cloud platform and continue to obtain services.

[0137] In an optional embodiment, before making any modification, it is necessary to ensure that the domain name service of the backup cloud platform has been configured and is working properly.

[0138] In an embodiment of the present application, after completing the primary-backup switching, the first Internet Protocol address corresponding to the second domain name service in the primary cloud platform can be further modified to a second Internet Protocol address, so that when the network jitters, the access request can be forwarded from the first domain name service of the backup cloud platform to the second domain name service of the primary cloud platform, thereby ensuring smooth access.

[0139] Optionally, after the step of modifying the first Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the second Internet Protocol address, the method further includes:

[0140] When network jitter occurs in the process of the first domain name service performing domain name resolution for the first domain name accessed by the user, forwarding the first domain name to the second domain name service of the primary cloud platform;

[0141] The second domain name service of the main cloud platform performs domain name resolution on the first domain name, and accesses data through a second Internet Protocol address corresponding to the second domain name service.

[0142] In the embodiments of the present application, network jitter is usually measured by the change in network delay, that is, the change in the round-trip time of transmitting data packets. Normal network delay has a certain fluctuation range, but when the network jitter is large, the transmission delay of the data packet will be obviously unstable, and may even cause delays, data errors and performance degradation.

[0143] In an embodiment of the present application, when network jitter occurs during the domain name resolution of the first domain name accessed by the user on the backup cloud platform, network lag and other problems may occur if it is not handled. Therefore, in an embodiment of the present application, the first domain name can be directly forwarded to the second domain name service of the primary cloud platform.

[0144] At this time, the second domain name service of the main cloud platform will continue to resolve the first domain name, and the second domain name service of the main cloud platform will process the domain name resolution, and then access the data through the second Internet Protocol address corresponding to the second domain name service. In this way, different devices can accurately find each other on the Internet and send and receive network data to them.

[0145] In an embodiment of the present application, when network jitter occurs, the first domain name can be forwarded to the second domain name service of the main cloud platform, and the backup cloud platform service in the backup cloud platform can continue to be called normally through the second Internet Protocol address corresponding to the second domain name service, thereby avoiding network jams.

[0146] Optionally, after the step of modifying the first Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the second Internet Protocol address, the method further includes:

[0147] When the primary cloud platform switches from a non-survival state to a surviving state, synchronizing the incremental data in the backup cloud platform to the primary cloud platform; the incremental data is the data processed by the backup cloud platform during the period when the primary cloud platform is in a non-survival state;

[0148] The second Internet Protocol address corresponding to the second domain name service in the primary cloud platform is modified to the first Internet Protocol address.

[0149] In the embodiment of the present application, since the main cloud platform refers to the main cloud computing platform, it undertakes the core business functions and provides services to users. The main cloud platform is usually fully configured and optimized in terms of high performance, high reliability and security to ensure the stable operation of the business. Therefore, if the main cloud platform is restored to a surviving state where it can work normally, it is still more inclined to migrate the data back to the main cloud platform for processing.

[0150] In addition, since the backup cloud platform will not actively synchronize data to the primary cloud platform during data processing, in order to ensure the smooth switching of the backup and primary cloud platforms, the incremental data processed by the backup cloud platform during the period when the primary cloud platform is in a non-survival state needs to be synchronized to the primary cloud platform. Specifically, all data in the backup database can be exported and imported into the primary environment based on the mysqldump command, and then the primary-to-backup incremental data synchronization can be configured based on otter.

[0151] In an embodiment of the present application, after completing data synchronization, the second Internet Protocol address corresponding to the second domain name service in the main cloud platform can be further modified to the first Internet Protocol address.

[0152] At the same time, since the standby-active switch has been completed at this time, it is necessary to further set the status of the standby cloud platform to a non-survival state.

[0153] In an embodiment of the present application, when the main cloud platform switches from a non-survival state to a survival state, the backup main cloud platform is switched, and the incremental data in the backup cloud platform is synchronized to the main cloud platform, effectively ensuring the effective synchronization of the data after the switch and ensuring normal access to the cloud platform.

[0154] Optionally, when a fault is detected on the primary cloud platform, after the step of performing fault detection on the backup cloud platform, the method further includes:

[0155] When the standby cloud platform is in a non-survival state, the switching of the primary and standby cloud platforms is stopped, and fault warning information is generated.

[0156] In an embodiment of the present application, if a failure is detected in the primary cloud platform and the backup cloud platform is also detected to be in a non-survival state, it means that both the primary platform and the backup platform are unable to provide services, switching is stopped, and a fault warning message is generated.

[0157] The fault warning information in the embodiment of the present application is used to warn and notify the operation and maintenance personnel to handle the fault.

[0158] In an embodiment of the present application, by stopping the switching of the primary and secondary cloud platforms and generating fault warning information when both the secondary cloud platform and the primary cloud platform are in a non-survival state, invalid switching can be effectively avoided, and timely warnings can be issued to help discover problems more quickly.

[0159] Figure 2 The second flow chart of the cloud platform switching method provided in the embodiment of the present application is as follows: Figure 2 As shown, including:

[0160] Step 210, when a failure of the backup cloud platform is detected, a failure detection is performed on the primary cloud platform;

[0161] In an optional embodiment, a fault detection module deployed in a third-party arbitration area independent of the primary cloud platform and the backup cloud platform can be used to regularly and proactively perform fault detection on the backup cloud platform in a surviving state. The specific detection algorithm can be a conventional fault detection service. If a fault is detected in the primary cloud platform, in order to ensure the normal operation of the cloud platform, it is necessary to switch the primary and backup cloud platforms.

[0162] In order to prevent the main cloud platform from running smoothly after switching, it is also necessary to further perform fault detection on the main cloud platform.

[0163] In an embodiment of the present application, fault detection on the main cloud platform can be specifically performed by detecting the main cloud platform through the above-mentioned fault detection algorithm, and then only when the main cloud platform passes the fault detection, the state of the main cloud platform will be modified to a survival state, and the switching of the backup main cloud platform will be started.

[0164] Step 220, when the primary cloud platform is in a live state, modify the second Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the first Internet Protocol address, and set the backup cloud platform to a non-live state;

[0165] The first Internet Protocol address is the Internet Protocol address of the primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is the Internet Protocol address of the backup cloud platform service in the backup cloud platform. In the embodiment of the present application, when the primary cloud platform is in a surviving state, it is considered that a backup primary cloud platform switch is required at this time, and the backup primary cloud platform switch can be performed at this time.

[0166] In an embodiment of the present application, when the backup cloud platform is operating normally, users obtain services by accessing the domain name address of the backup cloud platform. At this time, in order to avoid access jams caused by network jitter, the Internet Protocol address corresponding to the second domain name service in the main cloud platform can be set to the second Internet Protocol address of the backup cloud platform service in the backup cloud platform.

[0167] In the embodiment of the present application, in order to avoid access jams caused by network jitter, the domain name services of the main cloud platform and the backup cloud platform both correspond to the second Internet Protocol address of the backup cloud platform service in the backup cloud platform.

[0168] Therefore, in the process of switching cloud platforms, the second Internet Protocol address corresponding to the second domain name service in the main cloud platform needs to be modified to the first Internet Protocol address. In this way, when a user initiates an access request, the domain name resolution system will forward it to the second Internet Protocol address corresponding to the second domain name service in the main cloud platform, so that the user can continue to access the system and obtain services.

[0169] In the embodiment of the present application, such configuration change is usually performed in the case of failover or disaster recovery to ensure the availability and continuity of the system.

[0170] In an optional embodiment, when the backup cloud platform is in a live state, the first domain name service in the backup cloud platform corresponds to the second Internet Protocol address, and the second domain name service in the primary cloud platform corresponds to the second Internet Protocol address;

[0171] When network jitter occurs in the backup cloud platform during the process of performing domain name resolution on the domain name accessed by the user, forwarding the first domain name to the second domain name service of the primary cloud platform;

[0172] The second domain name service of the main cloud platform performs domain name resolution on the first domain name, and accesses data through a second Internet Protocol address corresponding to the second domain name service.

[0173] When a failure is detected on the backup cloud platform, the primary cloud platform is tested for the failure;

[0174] When the primary cloud platform is in a live state, modify the second Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the first Internet Protocol address, and set the backup cloud platform to a non-live state;

[0175] The first Internet Protocol address is an Internet Protocol address of a primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is an Internet Protocol address of a backup cloud platform service in the backup cloud platform.

[0176] In an embodiment of the present application, fault detection is actively performed on the main cloud platform and the backup cloud platform. When a fault is detected in the main cloud platform, it is determined whether the backup cloud platform is in a surviving state. If the backup cloud platform is detected to be in a surviving state, the main and backup platforms can be switched, and the second Internet Protocol address corresponding to the second domain name service in the main cloud platform is modified to the first Internet Protocol address, and the backup cloud platform is set to a non-surviving state to complete automatic forwarding and switching of traffic. The switching process of the entire cloud platform only needs to be performed between the main and backup cloud platforms. The user will not perceive the switching process of the cloud platform, thereby ensuring the user's process network experience.

[0177] Optionally, after the step of modifying the second Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the first Internet Protocol address and setting the backup cloud platform to a non-survival state, the method further includes:

[0178] The second Internet Protocol address corresponding to the first domain name service in the backup cloud platform is modified to the first Internet Protocol address.

[0179] In an embodiment of the present application, after the second Internet Protocol address corresponding to the second domain name service in the primary cloud platform is modified to the first Internet Protocol address, since the user's access request is now by default prioritized by the second domain name service corresponding to the primary cloud platform for domain name resolution, in order to avoid network jitter affecting the access to the primary and backup cloud platforms, the domain name service of the backup cloud platform can be further adjusted.

[0180] In an embodiment of the present application, the second Internet Protocol address corresponding to the first domain name service in the backup cloud platform is modified to the first Internet Protocol address. Through the modification, if network jitter occurs during the process of the main cloud platform continuing the domain name resolution, it can be further forwarded to the first domain name service of the backup cloud platform, through the first Internet Protocol address corresponding to the first domain name service, and continue to obtain the main cloud platform service.

[0181] In an embodiment of the present application, after completing the primary-backup switching, the second Internet Protocol address corresponding to the first domain name service in the backup cloud platform can be further modified to the first Internet Protocol address, so that when the network jitters, the access request can be forwarded from the first domain name service of the backup cloud platform to the second domain name service of the primary cloud platform, thereby ensuring smooth access.

[0182] Optionally, after the step of modifying the second Internet Protocol address corresponding to the first domain name service in the backup cloud platform to the first Internet Protocol address, the method further includes:

[0183] When network jitter occurs in the process of the second domain name service performing domain name resolution for the second domain name accessed by the user, forwarding the second domain name to the first domain name service of the backup cloud platform;

[0184] The first domain name service of the backup cloud platform performs domain name resolution on the second domain name, and accesses data through a first Internet Protocol address corresponding to the first domain name service.

[0185] In an embodiment of the present application, when network jitter occurs during the domain name resolution of the second domain name accessed by the user on the primary cloud platform, network lag and other problems may occur if it is not handled. Therefore, in an embodiment of the present application, the second domain name can be directly forwarded to the first domain name service of the backup cloud platform.

[0186] At this time, the first domain name service of the backup cloud platform will continue to resolve the second domain name, and access data through the first Internet Protocol address corresponding to the second domain name. This allows different devices to accurately find each other on the Internet and send and receive network data to them.

[0187] In the embodiment of the present application, when network jitter occurs, the second domain name can also be forwarded to the first domain name service of the backup cloud platform to avoid network jam.

[0188] Optionally, when it is detected that the standby cloud platform fails, after the step of performing fault detection on the primary cloud platform, the method further includes:

[0189] When the primary cloud platform is in a non-survival state, the switching of the primary and standby cloud platforms is stopped, and fault warning information is generated.

[0190] In an embodiment of the present application, if a failure occurs on the backup cloud platform, the primary cloud platform will also be faulty after fault detection. At this time, the primary cloud platform will also be in a non-survival state. At this time, fault warning information should be generated to prompt the operation and maintenance that both the primary and backup cloud platforms have faults and cannot operate normally.

[0191] In the embodiment of the present application, when a failure occurs on the backup cloud platform, the main cloud platform is detected to also have a fault, and fault warning information is generated, which can quickly help operation and maintenance personnel discover the fault, thereby improving the efficiency of fault resolution.

[0192] Optionally, when a fault is detected on the primary cloud platform, before the step of performing fault detection on the standby cloud platform, the method further includes:

[0193] Through the heartbeat mechanism, heartbeat detection information is sent to the active cloud platform or backup cloud platform;

[0194] When the feedback information of the heartbeat detection information meets the fault condition, the primary cloud platform or the backup cloud platform in the non-survival state is determined.

[0195] In an embodiment of the present application, it can be deployed in a third-party arbitration area outside the primary cloud platform and the backup cloud platform. The primary and backup fault detection services use the heartbeat mechanism to periodically send heartbeat detection to the user authentication service of the primary and backup cloud platforms. When the heartbeat detection information meets the fault condition, it is considered that the cloud platform has a fault, triggering the primary and backup switching process to complete the automatic switching of the primary and backup disaster recovery.

[0196] In an embodiment of the present application, the heartbeat mechanism may specifically be to determine the status and availability of the server by sending a response request to the target server and waiting for a preset time to confirm whether a response is received.

[0197] Optionally, a heartbeat detection message is sent to the active cloud platform or standby cloud platform through a heartbeat mechanism, including:

[0198] According to a first preset period, regularly sending first heartbeat detection information to the first domain name service in the primary cloud platform or the backup cloud platform in a survival state or to the Internet Protocol address corresponding to the first domain name service in the backup cloud platform;

[0199] The first heartbeat detection information is used to request the primary cloud platform or the backup cloud platform in a survival state to respond.

[0200] In the embodiment of the present application, the first preset period may specifically refer to a pre-set period, for example, one period is every 3 seconds, or one period is every 10 seconds.

[0201] In a more specific embodiment, a timer may be started to periodically send the first heartbeat detection information to the Internet Protocol address corresponding to the primary cloud platform or the backup cloud platform in a survival state.

[0202] The first heartbeat detection information is used to request the primary cloud platform or the backup cloud platform in the survival state to respond. After sending the first heartbeat detection information, you can further wait for a response from the primary cloud platform or the backup cloud platform in the survival state.

[0203] If no response information of the primary cloud platform or the backup cloud platform in the survival state to the first heartbeat detection information is received within a first preset time period, it is determined that the primary cloud platform or the backup cloud platform in the survival state fails;

[0204] Switch the primary cloud platform or the backup cloud platform from a surviving state to a non-surviving state.

[0205] The first preset time period described in the embodiment of the present application may specifically be a pre-set time period, such as 15 seconds or 20 seconds.

[0206] If no response information is received from the primary cloud platform or the backup cloud platform in a surviving state to the first heartbeat detection information within a first preset time period, it means that the primary cloud platform or the backup cloud platform in a surviving state has a fault or abnormality and cannot provide services normally. Accordingly, the primary cloud platform or the backup cloud platform that was originally in a surviving state is modified to a non-surviving state.

[0207] Optionally, a heartbeat detection message is sent to the active cloud platform or standby cloud platform through a heartbeat mechanism, including:

[0208] According to a second preset period, regularly sending second heartbeat detection information to an Internet Protocol address corresponding to a second domain name service in the primary cloud platform or a first domain name service in the backup cloud platform that is in a survival state;

[0209] Among them, the second heartbeat detection information is used to request the main cloud platform or the backup cloud platform in a survival state to execute a target instruction.

[0210] In the embodiment of the present application, the second preset period may also be a pre-set period, for example, a period with a repeated cycle of 45 seconds.

[0211] In an embodiment of the present application, the primary cloud platform and the backup cloud platform are deployed in a third-party arbitration area outside the primary cloud platform and the backup cloud platform. The primary and backup fault detection services use a heartbeat mechanism to periodically send a second heartbeat detection message to the Internet Protocol address corresponding to the primary cloud platform or the backup cloud platform according to a second preset period.

[0212] After receiving the second heartbeat detection information, the active cloud platform or standby cloud platform sets a scheduled task to regularly call the target service API interface or execute related commands. If the interface or command execution fails, it means that the active cloud platform or standby cloud platform has a fault. At this time, the active cloud platform or standby cloud platform will be switched from the active state to the non-active state.

[0213] Optionally, the method further comprises:

[0214] Obtaining status information of the primary cloud platform and the backup cloud platform;

[0215] Through the heartbeat mechanism, a heartbeat detection is performed on the Internet Protocol address corresponding to the primary cloud platform or the backup cloud platform whose status information is in the survival state.

[0216] In an embodiment of the present application, the monitoring object of the heartbeat mechanism is only the Internet Protocol address corresponding to the surviving primary cloud platform or the backup cloud platform. After the primary-backup status is switched, the corresponding monitoring object will be re-determined based on the survival status of the primary cloud platform or the backup cloud platform.

[0217] For example, when the standby environment is changed to a surviving state and the primary environment is changed to a non-surviving state, the object of the fault detection service can be changed to the primary cloud platform IP.

[0218] For another example, when the primary cloud platform is changed to a surviving state and the backup cloud platform is changed to a non-surviving state, the detection center of the fault detection service and the configuration compensation service is changed to the IP address of the backup cloud platform.

[0219] In an embodiment of the present application, by deploying a monitoring module outside the primary and backup cloud platforms, active detection of the primary and backup cloud platforms can be effectively achieved, the survival status of the primary and backup cloud platforms can be effectively judged, and the cloud platforms can be switched in a timely manner to ensure the stability of data access.

[0220] Optionally, Figure 3 The access processing flow chart provided in the embodiment of the present application is as follows: Figure 3 As shown, when a user accesses, a global domain name resolution is performed first. The global domain name resolution server will be pre-configured with a domain name forwarding strategy, which will further include the NodeLocalDNS service IP address of the primary cloud platform and the NodeLocalDNS service IP address of the backup cloud platform.

[0221] Initialize the correspondence between the domain name and IP of the primary and standby cloud platform NodeLocalDNS. At this time, the IP corresponds to the IP address of the cloud platform's primary environment. When traffic is forwarded from the global domain name resolution to the primary NodeLocalDNS service or the standby NodeLocalDNS service, the NodeLocalDNS service forwards all traffic to the corresponding primary cloud platform IP.

[0222] The third-party arbitration area deploys a fault detection module service. The fault detection service uses a heartbeat mechanism to periodically check the cloud platform user authentication service. When a fault trigger condition is met, the automatic switching process is triggered.

[0223] The fault detection service supports multiple detection parameter configurations, such as heartbeat frequency, number of retries, timeout threshold, etc. When each request exceeds the timeout threshold, the request is considered to have failed. When the request exceeds the number of retries, the service is considered to be abnormal, and the primary cloud platform is initially identified as faulty. An alarm is issued, and the automatic primary-backup switching process is triggered.

[0224] According to the current cloud platform's label and survival status, the fault detection service will automatically configure the inspection object. For example, if the backup cloud platform is alive now, the inspection object will be configured as the service address of the backup cloud platform.

[0225] If a cloud platform failure is detected, the failover process is triggered:

[0226] When switching between the primary and backup cloud platforms, the availability of the backup cloud platform is first detected. The detection algorithm is similar to the fault detection service. When the backup cloud platform is detected to meet the switching conditions, the switching is triggered. Otherwise, the switching is stopped and an alarm is issued to notify the operation and maintenance personnel to handle it.

[0227] If the primary cloud platform is switched to the backup cloud platform:

[0228] First, obtain the IP address of the backup cloud platform, modify the domain name and IP corresponding configuration of the NodeLocalDNS service of the primary and backup environments, change the IP to the backup center IP, change the backup environment to a surviving state and the primary environment to a non-surviving state, and change the detection center of the fault detection service and configuration compensation service to the primary center IP.

[0229] If the backup cloud platform is switched to the primary cloud platform:

[0230] First, export all the data in the standby database based on the mysqldump command and import it into the primary environment. Then configure incremental synchronization of primary to standby data based on otter. Get the primary environment IP, call the disaster recovery module interface to configure the domain name corresponding to the IP of the primary environment in the NodeLocalDNS service of the primary and standby environments respectively. Set the primary environment to the surviving state and the standby environment to the non-surviving state. Change the detection center of the fault detection service and configuration compensation service to the standby center IP.

[0231] In an embodiment of the present application, when a user accesses a domain name, the global domain name resolution service will forward the request based on the domain name, and first forward the request to the NodeLocalDNS service of the primary cloud platform. If the NodeLocalDNS service of the primary cloud platform is not accessible or is in a non-surviving state, it will be forwarded to the NodeLocalDNS service of the backup cloud platform, thereby realizing traffic switching.

[0232] The cloud platform switching device provided by the present invention is described below. The cloud platform switching device described below and the cloud platform switching method described above can be referenced to each other.

[0233] Figure 4 One of the schematic diagrams of the cloud platform switching device structure provided in the embodiment of the present application is as follows: Figure 4 As shown, including:

[0234] The first detection module 410 is used to perform fault detection on the backup cloud platform when a fault is detected on the primary cloud platform;

[0235] The first switching module 420 is used to set the main cloud platform to a non-survival state when the backup cloud platform is in a survival state, and to modify the first Internet Protocol address corresponding to the first domain name service in the backup cloud platform to a second Internet Protocol address;

[0236] Wherein, the first Internet Protocol address is the Internet Protocol address of the primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is the Internet Protocol address of the backup cloud platform service in the backup cloud platform. Optionally, the device is further used to:

[0237] Modify the first Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the second Internet Protocol address

[0238] Optionally, the device is also used for:

[0239] When network jitter occurs in the process of the first domain name service performing domain name resolution for the first domain name accessed by the user, forwarding the first domain name to the second domain name service of the primary cloud platform;

[0240] The second domain name service of the main cloud platform performs domain name resolution on the first domain name, and accesses data through a second Internet Protocol address corresponding to the second domain name service.

[0241] Optionally, the device is also used for:

[0242] When the primary cloud platform switches from a non-survival state to a surviving state, synchronizing the incremental data in the backup cloud platform to the primary cloud platform; the incremental data is the data processed by the backup cloud platform during the period when the primary cloud platform is in a non-survival state;

[0243] The second Internet Protocol address corresponding to the second domain name service in the primary cloud platform is modified to the first Internet Protocol address.

[0244] Optionally, the device is also used for:

[0245] When the standby cloud platform is in a non-survival state, the switching of the primary and standby cloud platforms is stopped, and fault warning information is generated.

[0246] Figure 5 The second schematic diagram of the cloud platform switching device structure provided in the embodiment of the present application is as follows: Figure 5 As shown, including:

[0247] The second detection module 510 is used to perform fault detection on the main cloud platform when a fault is detected on the standby cloud platform;

[0248] The second switching module 520 is used to

[0249] When the primary cloud platform is in a live state, modify the second Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the first Internet Protocol address, and set the backup cloud platform to a non-live state;

[0250] The first Internet Protocol address is the Internet Protocol address of the primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is the Internet Protocol address of the backup cloud platform service in the backup cloud platform. Optionally, the device is further used to: modify the second Internet Protocol address corresponding to the first domain name service in the backup cloud platform to the first Internet Protocol address.

[0251] Optionally, the device is further used for:

[0252] When network jitter occurs in the process of the second domain name service performing domain name resolution for the second domain name accessed by the user, forwarding the second domain name to the first domain name service of the backup cloud platform;

[0253] The first domain name service of the backup cloud platform performs domain name resolution on the second domain name, and accesses data through a first Internet Protocol address corresponding to the first domain name service.

[0254] Optionally, the device is further used for:

[0255] When the primary cloud platform is in a non-survival state, the switching of the primary and standby cloud platforms is stopped, and fault warning information is generated.

[0256] Optionally, the device is further used for:

[0257] Through the heartbeat mechanism, heartbeat detection information is sent to the active cloud platform or backup cloud platform;

[0258] When the feedback information of the heartbeat detection information meets the fault condition, the primary cloud platform or the backup cloud platform in the non-survival state is determined.

[0259] Optionally, the device is further used for:

[0260] According to a first preset period, regularly sending first heartbeat detection information to an Internet Protocol address corresponding to a second domain name service in a primary cloud platform or a first domain name service in a backup cloud platform in a survival state;

[0261] The first heartbeat detection information is used to request the primary cloud platform or the backup cloud platform in a survival state to respond.

[0262] Optionally, the device is further used for:

[0263] If no response information of the primary cloud platform or the backup cloud platform in the survival state to the first heartbeat detection information is received within a first preset time period, it is determined that the primary cloud platform or the backup cloud platform in the survival state fails;

[0264] Switch the primary cloud platform or the backup cloud platform from a surviving state to a non-surviving state.

[0265] Optionally, the device is further used for:

[0266] According to a second preset period, regularly sending second heartbeat detection information to an Internet Protocol address corresponding to a second domain name service in the primary cloud platform or a first domain name service in the backup cloud platform that is in a survival state;

[0267] Among them, the second heartbeat detection information is used to request the main cloud platform or the backup cloud platform in a survival state to execute a target instruction.

[0268] Optionally, the device is further used for:

[0269] In a case where the primary cloud platform or the backup cloud platform in the surviving state fails to execute the target instruction, determining that the primary cloud platform or the backup cloud platform in the surviving state fails;

[0270] Switch the primary cloud platform or the backup cloud platform from a surviving state to a non-surviving state.

[0271] Optionally, the device is further used for:

[0272] Obtaining status information of the primary cloud platform and the backup cloud platform;

[0273] Through the heartbeat mechanism, a heartbeat detection is performed on the main cloud platform or the backup cloud platform whose status information is in a survival state.

[0274] Optionally, the device is further used for:

[0275] Receiving a third domain name visited by a user, and performing global domain name resolution on the third domain name;

[0276] When the primary cloud platform is in a non-survival state, forwarding the third domain name to the first domain name service of the backup cloud platform through domain name forwarding;

[0277] After the first domain name service performs domain name resolution on the third domain name, data access is performed through the second Internet Protocol address corresponding to the first domain name service.

[0278] In an embodiment of the present application, by simultaneously preparing a main cloud platform and a backup cloud platform that backs up the main cloud platform data, fault detection is actively performed on the main cloud platform and the backup cloud platform. When a fault is detected in the main cloud platform, it is determined whether the backup cloud platform is in a surviving state. If the backup cloud platform is detected to be in a surviving state, the main and backup platforms can be switched, and the main cloud platform can be set to a non-surviving state. The first Internet Protocol address corresponding to the first domain name service in the backup cloud platform is modified to a second Internet Protocol address to complete automatic forwarding and switching of traffic. The switching process of the entire cloud platform only needs to be performed between the main and backup cloud platforms, which reduces the network freeze that may occur during the cloud platform switching process, reduces the impact on users, and ensures the user's process network experience.

[0279] Figure 6 is a schematic diagram of the structure of the electronic device provided by the present invention, such as Figure 6 As shown, the electronic device may include: a processor 610, a communication interface 620, a memory 630 and a communication bus 640, wherein the processor 610, the communication interface 620 and the memory 630 communicate with each other through the communication bus 640. The processor 610 may call the logic instructions in the memory 630 to execute the cloud platform switching method, which includes: in the case of detecting that a failure occurs in the main cloud platform, performing a fault detection on the backup cloud platform;

[0280] When the backup cloud platform is in a live state, the primary cloud platform is set to a non-live state, and a first Internet Protocol address corresponding to a first domain name service in the backup cloud platform is modified to a second Internet Protocol address;

[0281] The first Internet Protocol address is an Internet Protocol address of a primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is an Internet Protocol address of a backup cloud platform service in the backup cloud platform.

[0282] Or, in case a failure of the backup cloud platform is detected, the primary cloud platform is tested for failure;

[0283] When the primary cloud platform is in a live state, modify the second Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the first Internet Protocol address, and set the backup cloud platform to a non-live state;

[0284] The first Internet Protocol address is an Internet Protocol address of a primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is an Internet Protocol address of a backup cloud platform service in the backup cloud platform.

[0285] In addition, the logic instructions in the above-mentioned memory 630 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc. Various media that can store program codes.

[0286] On the other hand, the present invention further provides a computer program product, the computer program product includes a computer program, the computer program can be stored on a non-transitory computer-readable storage medium, when the computer program is executed by a processor, the computer can execute the cloud platform switching method provided by the above methods, the method includes:

[0287] When a failure is detected on the primary cloud platform, the backup cloud platform is tested for the failure;

[0288] When the backup cloud platform is in a live state, the primary cloud platform is set to a non-live state, and a first Internet Protocol address corresponding to a first domain name service in the backup cloud platform is modified to a second Internet Protocol address;

[0289] The first Internet Protocol address is an Internet Protocol address of a primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is an Internet Protocol address of a backup cloud platform service in the backup cloud platform.

[0290] Or, in case a failure of the backup cloud platform is detected, the primary cloud platform is tested for failure;

[0291] When the primary cloud platform is in a live state, modify the second Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the first Internet Protocol address, and set the backup cloud platform to a non-live state;

[0292] The first Internet Protocol address is an Internet Protocol address of a primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is an Internet Protocol address of a backup cloud platform service in the backup cloud platform.

[0293] In another aspect, the present invention further provides a non-transitory computer-readable storage medium having a computer program stored thereon, which is implemented when the computer program is executed by a processor to execute the cloud platform switching method provided by the above methods, the method comprising:

[0294] When a failure is detected on the primary cloud platform, the backup cloud platform is tested for the failure;

[0295] When the backup cloud platform is in a live state, the primary cloud platform is set to a non-live state, and a first Internet Protocol address corresponding to a first domain name service in the backup cloud platform is modified to a second Internet Protocol address;

[0296] The first Internet Protocol address is an Internet Protocol address of a primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is an Internet Protocol address of a backup cloud platform service in the backup cloud platform.

[0297] Or, in case a failure of the backup cloud platform is detected, the primary cloud platform is tested for failure;

[0298] When the primary cloud platform is in a live state, modify the second Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the first Internet Protocol address, and set the backup cloud platform to a non-live state;

[0299] The first Internet Protocol address is an Internet Protocol address of a primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is an Internet Protocol address of a backup cloud platform service in the backup cloud platform.

[0300] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.

[0301] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.

[0302] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A cloud platform switching method, characterized in that: include: In the case where a failure of the primary cloud platform is detected, a failure detection is performed on the backup cloud platform; wherein the second domain name service in the primary cloud platform corresponds to a first Internet Protocol address, and the first domain name service in the backup cloud platform corresponds to the first Internet Protocol address; When the backup cloud platform is in a live state, the primary cloud platform is set to a non-live state, and a first Internet Protocol address corresponding to a first domain name service in the backup cloud platform is modified to a second Internet Protocol address; The first Internet Protocol address is the Internet Protocol address of the primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is the Internet Protocol address of the backup cloud platform service in the backup cloud platform; Wherein, after the step of modifying the first Internet Protocol address corresponding to the first domain name service in the backup cloud platform to the second Internet Protocol address, the method further includes: The first Internet Protocol address corresponding to the second domain name service in the primary cloud platform is modified to the second Internet Protocol address; wherein, after the step of modifying the first Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the second Internet Protocol address, the step further includes: When network jitter occurs in the process of the first domain name service performing domain name resolution for the first domain name accessed by the user, forwarding the first domain name to the second domain name service of the primary cloud platform; The second domain name service of the main cloud platform performs domain name resolution on the first domain name, and accesses data through a second Internet Protocol address corresponding to the second domain name service.

2. The cloud platform switching method according to claim 1, characterized in that: After the step of modifying the first Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the second Internet Protocol address, the method further includes: When the primary cloud platform switches from a non-survival state to a surviving state, synchronizing the incremental data in the backup cloud platform to the primary cloud platform; the incremental data is the data processed by the backup cloud platform during the period when the primary cloud platform is in a non-survival state; The second Internet Protocol address corresponding to the second domain name service in the primary cloud platform is modified to the first Internet Protocol address.

3. The cloud platform switching method according to claim 1, characterized in that: When a failure of the primary cloud platform is detected, after the step of performing failure detection on the backup cloud platform, the following steps are also included: When the standby cloud platform is in a non-survival state, the switching of the primary and standby cloud platforms is stopped, and fault warning information is generated.

4. The cloud platform switching method according to claim 1, characterized in that: After the step of modifying the first Internet Protocol address corresponding to the first domain name service in the backup cloud platform to the second Internet Protocol address, the method further includes: Receiving a third domain name visited by a user, and performing global domain name resolution on the third domain name; When the primary cloud platform is in a non-survival state, forwarding the third domain name to the first domain name service of the backup cloud platform through domain name forwarding; After the first domain name service performs domain name resolution on the third domain name, data access is performed through the second Internet Protocol address corresponding to the first domain name service.

5. A cloud platform switching method, characterized in that: include: In the case where a failure of the backup cloud platform is detected, a failure detection is performed on the primary cloud platform; wherein the second domain name service in the primary cloud platform corresponds to a second Internet Protocol address, and the first domain name service in the backup cloud platform corresponds to the second Internet Protocol address; When the primary cloud platform is in a live state, modify the second Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the first Internet Protocol address, and set the backup cloud platform to a non-live state; The first Internet Protocol address is the Internet Protocol address of the primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is the Internet Protocol address of the backup cloud platform service in the backup cloud platform; Wherein, after the step of modifying the second Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the first Internet Protocol address and setting the backup cloud platform to a non-survival state, it also includes: Modify the second Internet Protocol address corresponding to the first domain name service in the backup cloud platform to the first Internet Protocol address; Wherein, after the step of modifying the second Internet Protocol address corresponding to the first domain name service in the backup cloud platform to the first Internet Protocol address, the method further includes: When network jitter occurs in the process of the second domain name service performing domain name resolution for the second domain name accessed by the user, forwarding the second domain name to the first domain name service of the backup cloud platform; The first domain name service of the backup cloud platform performs domain name resolution on the second domain name, and accesses data through a first Internet Protocol address corresponding to the first domain name service.

6. The cloud platform switching method according to claim 5, characterized in that: When a failure of the standby cloud platform is detected, after the step of performing a failure detection on the primary cloud platform, the following steps are also included: When the primary cloud platform is in a non-survival state, the switching of the primary and standby cloud platforms is stopped, and fault warning information is generated.

7. The cloud platform switching method according to any one of claims 5-6, characterized in that: When a failure of the standby cloud platform is detected, before the step of performing a failure detection on the primary cloud platform, the following steps are also included: Through the heartbeat mechanism, heartbeat detection information is sent to the active cloud platform or backup cloud platform; When the feedback information of the heartbeat detection information meets the fault condition, the primary cloud platform or the backup cloud platform in the non-survival state is determined.

8. The cloud platform switching method according to claim 7, characterized in that: Through the heartbeat mechanism, heartbeat detection information is sent to the active cloud platform or standby cloud platform, including: According to a first preset period, regularly sending first heartbeat detection information to an Internet Protocol address corresponding to a second domain name service in a primary cloud platform or a first domain name service in a backup cloud platform in a survival state; The first heartbeat detection information is used to request the primary cloud platform or the backup cloud platform in a survival state to respond.

9. The cloud platform switching method according to claim 8, characterized in that: After the step of regularly sending the first heartbeat detection information to the Internet Protocol address corresponding to the second domain name service in the primary cloud platform or the first domain name service in the backup cloud platform in the survival state according to the first preset period, the method further includes: If no response information of the primary cloud platform or the backup cloud platform in the survival state to the first heartbeat detection information is received within a first preset time period, it is determined that the primary cloud platform or the backup cloud platform in the survival state fails; Switch the primary cloud platform or the backup cloud platform from a surviving state to a non-surviving state.

10. The cloud platform switching method according to claim 7, characterized in that: Through the heartbeat mechanism, heartbeat detection information is sent to the active cloud platform or standby cloud platform, including: According to a second preset period, regularly sending second heartbeat detection information to an Internet Protocol address corresponding to a second domain name service in the primary cloud platform or a first domain name service in the backup cloud platform that is in a survival state; Among them, the second heartbeat detection information is used to request the main cloud platform or the backup cloud platform in a survival state to execute a target instruction.

11. The cloud platform switching method according to claim 10, characterized in that: After the step of regularly sending the second heartbeat detection information to the Internet Protocol address corresponding to the second domain name service in the primary cloud platform or the first domain name service in the backup cloud platform in the survival state according to the second preset period, the method further includes: In a case where the primary cloud platform or the backup cloud platform in the surviving state fails to execute the target instruction, determining that the primary cloud platform or the backup cloud platform in the surviving state fails; Switch the primary cloud platform or the backup cloud platform from a surviving state to a non-surviving state.

12. The cloud platform switching method according to any one of claims 5 to 6, characterized in that: The method further comprises: Obtaining status information of the primary cloud platform and the backup cloud platform; Through the heartbeat mechanism, a heartbeat detection is performed on the main cloud platform or the backup cloud platform whose status information is in a survival state.

13. A cloud platform switching device, characterized in that: include: A first detection module is used to perform fault detection on the backup cloud platform when a fault is detected on the primary cloud platform; wherein the second domain name service in the primary cloud platform corresponds to a first Internet Protocol address, and the first domain name service in the backup cloud platform corresponds to the first Internet Protocol address; A first switching module is used to set the main cloud platform to a non-survival state when the backup cloud platform is in a survival state, and to modify the first Internet Protocol address corresponding to the first domain name service in the backup cloud platform to a second Internet Protocol address; The first Internet Protocol address is the Internet Protocol address of the primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is the Internet Protocol address of the backup cloud platform service in the backup cloud platform; Wherein, the device is also used for: Modify the first Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the second Internet Protocol address; Wherein, the device is also used for: When network jitter occurs in the process of the first domain name service performing domain name resolution for the first domain name accessed by the user, forwarding the first domain name to the second domain name service of the primary cloud platform; The second domain name service of the main cloud platform performs domain name resolution on the first domain name, and accesses data through a second Internet Protocol address corresponding to the second domain name service.

14. A cloud platform switching device, characterized in that: include: A second detection module performs fault detection on the primary cloud platform when a fault is detected in the backup cloud platform; wherein the second domain name service in the primary cloud platform corresponds to a second Internet Protocol address, and the first domain name service in the backup cloud platform corresponds to the second Internet Protocol address; The second switching module modifies the second Internet Protocol address corresponding to the second domain name service in the primary cloud platform to the first Internet Protocol address when the primary cloud platform is in a live state, and sets the backup cloud platform to a non-live state; The first Internet Protocol address is the Internet Protocol address of the primary cloud platform service in the primary cloud platform, and the second Internet Protocol address is the Internet Protocol address of the backup cloud platform service in the backup cloud platform; Wherein, the device is also used for: Modify the second Internet Protocol address corresponding to the first domain name service in the backup cloud platform to the first Internet Protocol address; Wherein, the device is also used for: When network jitter occurs in the process of the second domain name service performing domain name resolution for the second domain name accessed by the user, forwarding the second domain name to the first domain name service of the backup cloud platform; The first domain name service of the backup cloud platform performs domain name resolution on the second domain name, and accesses data through a first Internet Protocol address corresponding to the first domain name service.

15. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the program, the cloud platform switching method as described in any one of claims 1 to 12 is implemented.

16. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the cloud platform switching method as described in any one of claims 1 to 12 is implemented.