Data recovery method, system, electronic device and storage medium for hyper-converged host
By monitoring and utilizing the high availability characteristics of hyperconverged clusters, automatically backing up and restoring the system configuration of hyperconverged hosts, the problem of low data recovery efficiency in the existing technology is solved, and an efficient and convenient data recovery process is achieved.
Patent Information
- Application Number
- CN202111394990.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-11-23
- Publication Date
- 2025-03-25
- Estimated Expiration
- 2041-11-23
AI Technical Summary
In the prior art, when the disk of the hyperconverged host system is abnormal or damaged, data recovery efficiency is low and requires manual participation, which takes up a long time and takes up a large storage space.
By monitoring the health status information of hyperconverged cluster nodes and system disks, using high availability features to automatically back up and restore system configurations, and even when the node is not online, the graphical operation is completed through booting the mirror to achieve an automated data recovery process.
It improves the efficiency and convenience of data recovery, and can automatically complete the recovery of system configuration when the hyperconverged system is damaged or the node is completely offline, reducing manual intervention and time consumption.
Smart Images

Figure CN114048074B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of network technology, and in particular to a data recovery method, system, electronic device and storage medium for a hyper-converged host. Background Art
[0002] At present, Hyper Converged Infrastructure (HCI) means that in the same set of unit equipment, not only computing, network, storage and server virtualization resources and technologies are available, but also backup software, snapshot technology, deduplication, online data compression and other elements are included. Multiple sets of unit equipment can be aggregated through the network to achieve modular seamless horizontal expansion (scale-out) to form a unified resource pool. When the system disk of the hyper-converged host is abnormal or damaged, the system disk of the host needs to be replaced and restored to the same configuration as before the damage.
[0003] In the prior art, a third-party disk cloning software is generally used to clone the data of the old system disk to another new system disk, and then the new system disk replaces the old system disk. Disk cloning, also known as disk duplication, is a process of completely copying (cloning) the contents of a disk to another disk through computer software. However, disk cloning technology cannot clone new data generated by the disk in real time. When the disk data changes, it needs to be cloned again. It must rely on the normal host operating system and the normal old disk to complete disk cloning and replace the old system disk. Moreover, the entire cloning process requires manual participation, which is time-consuming and occupies a large amount of storage space. Summary of the invention
[0004] The purpose of the embodiments of the present application is to provide a data recovery method, system, electronic device and storage medium for a hyper-converged host, which can restore the configuration data of the hyper-converged system and improve the technical effect of data recovery efficiency and convenience.
[0005] In a first aspect, an embodiment of the present application provides a data recovery method for a hyper-converged host, comprising:
[0006] Obtain health status information of hyper-converged cluster nodes and system disks;
[0007] Determine whether the system disk is abnormal based on the health status information. If so, perform the following processing on the system disk:
[0008] Determine whether the hyper-converged cluster node is online according to the health status information;
[0009] If the hyper-converged cluster node is online, suspend writing data to the system disk;
[0010] Backing up system configuration options of the hyper-converged cluster node to generate a first system configuration backup file;
[0011] importing the first system configuration backup file into a first new disk;
[0012] Replacing the system disk with the first new disk to complete the data recovery process;
[0013] If the hyper-converged cluster node is not online, replace the system disk with a second new disk;
[0014] Obtaining a second system configuration backup file of the system disk on the healthy node according to the boot image;
[0015] Import the second system configuration backup file into the second new disk to complete the data recovery process.
[0016] In the above implementation process, the data recovery method of the hyper-converged host monitors whether the hyper-converged cluster nodes and system disks are abnormal through health status information, and utilizes the high availability characteristics of the hyper-converged cluster. Even if a node in the hyper-converged cluster fails, after the node completes the recovery process and comes back online, the data can be synchronized to ensure the integrity of the entire cluster data; moreover, when the node is offline and the hyper-converged system file is damaged and the operation interface cannot be entered, the system configuration recovery process of the node is completed through the graphical operation of the interface by reusing the hyper-converged system's boot image (installation image), making the entire recovery process graphical and easy to operate; therefore, the method can be applied to the scenario where the hyper-converged system is damaged and the node is completely offline, to restore the configuration data of the hyper-converged system, and achieve the technical effect of improving data recovery efficiency and convenience.
[0017] Furthermore, before the step of obtaining the health status information of the hyper-converged cluster nodes and the system disk, the method further includes:
[0018] Periodically or manually trigger the system configuration task of the backup host;
[0019] When the system configuration task is triggered, backing up the configuration file of the system disk to generate the second system configuration backup file;
[0020] The second system configuration backup file is saved to other nodes of the hyper-converged cluster.
[0021] In the above implementation process, the configuration information of all nodes in the hyper-converged cluster is automatically and regularly backed up or manually backed up. When the system disk of the host is abnormal or damaged, a new disk is replaced to copy the backed up system configuration backup file from other hosts in the hyper-converged cluster for recovery, thereby ensuring the stable operation of the hyper-converged cluster.
[0022] Furthermore, the step of obtaining the second system configuration backup file of the system disk on the healthy node according to the boot image includes:
[0023] Obtain the IP address information of the healthy node;
[0024] The second system configuration backup file is obtained according to the IP address information.
[0025] In the above implementation process, when replacing and restoring the abnormal system disk according to the boot image, the backup file information (i.e., the second system configuration backup file) of the node (abnormal system disk) can be obtained through the IP address information of the healthy node.
[0026] Furthermore, before the step of suspending writing data into the system disk, the method further includes:
[0027] Migrate the virtual machine on the system disk to the healthy system disk.
[0028] In a second aspect, a data recovery system for a hyper-converged host includes:
[0029] Health acquisition module, used to obtain health status information of hyper-converged cluster nodes and system disks;
[0030] The abnormality judgment module is used to judge whether the system disk is abnormal according to the health status information, and if so, perform the following processing on the system disk:
[0031] A node online judgment module is used to judge whether the hyper-converged cluster node is online according to the health status information;
[0032] A pause module, used for suspending writing data to the system disk if the hyper-converged cluster node is online;
[0033] A backup module, used to back up system configuration options of the hyper-converged cluster node and generate a first system configuration backup file;
[0034] An import module, used for importing the first system configuration backup file into a first new disk;
[0035] A replacement module, used for replacing the system disk with the first new disk to complete the data recovery process;
[0036] The replacement module is also used to replace the system disk with a second new disk if the hyper-converged cluster node is not online;
[0037] A backup acquisition module, used for acquiring a second system configuration backup file of the system disk on the healthy node according to the boot image;
[0038] The import module is also used to import the second system configuration backup file into the second new disk to complete the data recovery process.
[0039] Furthermore, the system further comprises:
[0040] The trigger module is used to periodically or manually trigger the system configuration task of the backup host;
[0041] The backup module is also used to back up the configuration file of the system disk and generate the second system configuration backup file when the system configuration task is triggered;
[0042] The saving module is used to save the second system configuration backup file to other nodes of the hyper-converged cluster.
[0043] Furthermore, the backup acquisition module includes:
[0044] An IP address unit, used to obtain the IP address information of the healthy node;
[0045] A backup acquisition unit is used to acquire the second system configuration backup file according to the IP address information.
[0046] Furthermore, the system also includes a migration module, and the migration module is used to migrate the virtual machine on the system disk to a healthy system disk.
[0047] In a third aspect, an embodiment of the present application provides an electronic device, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the method described in any one of the first aspects when executing the computer program.
[0048] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, on which instructions are stored. When the instructions are executed on a computer, the computer executes the method as described in any one of the first aspects.
[0049] In a fifth aspect, an embodiment of the present application provides a computer program product, which, when running on a computer, enables the computer to execute the method as described in any one of the first aspects.
[0050] Other features and advantages disclosed in the present application will be described in the following description, or some features and advantages can be inferred or determined without doubt from the description, or can be learned by implementing the above-mentioned technology disclosed in the present application.
[0051] In order to make the above-mentioned objects, features and advantages of the present application more obvious and easy to understand, preferred embodiments are specifically cited below and described in detail with reference to the attached drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0052] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments of the present application will be briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.
[0053] Figure 1 A schematic diagram of a data recovery method for a hyper-converged host provided in an embodiment of the present application;
[0054] Figure 2 A schematic diagram of a process flow of another method for recovering data of a hyper-converged host provided in an embodiment of the present application;
[0055] Figure 3 A structural block diagram of a data recovery system for a hyper-converged host provided in an embodiment of the present application;
[0056] Figure 4 A structural block diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0057] The technical solutions in the embodiments of the present application will be described below in conjunction with the drawings in the embodiments of the present application.
[0058] It should be noted that similar reference numerals and letters represent similar items in the following drawings, so once an item is defined in one drawing, it does not need to be further defined and explained in subsequent drawings. At the same time, in the description of this application, the terms "first", "second", etc. are only used to distinguish the description and cannot be understood as indicating or implying relative importance.
[0059] The embodiments of the present application provide a data recovery method, system, electronic device and storage medium for a hyper-converged host, which can be applied to the configuration replacement and recovery of a system disk in a hyper-converged cluster. The data recovery method for the hyper-converged host monitors whether the hyper-converged cluster nodes and system disks are abnormal through health status information, and utilizes the high availability characteristics of the hyper-converged cluster. Even if a node in the hyper-converged cluster fails, after the node completes the recovery process and comes back online, the data can be synchronized to ensure the integrity of the entire cluster data. Moreover, when the node is offline and the hyper-converged system file is damaged and the operation interface cannot be entered, the system configuration recovery process of the node is completed by reusing the boot image (installation image) of the hyper-converged system through the graphical operation of the interface, so that the entire recovery process becomes graphical and easy to operate. Therefore, the method can be applied to the scenario where the hyper-converged system is damaged and the node is completely offline, to restore the configuration data of the hyper-converged system, and to achieve the technical effect of improving data recovery efficiency and convenience.
[0060] See also Figure 1 , Figure 1 A flow chart of a data recovery method for a hyper-converged host provided in an embodiment of the present application, wherein the data recovery method for the hyper-converged host comprises the following steps:
[0061] S100: Obtain health status information of the hyper-converged cluster nodes and system disks;
[0062] For example, a hyper-converged architecture, namely HCI (Hyper Converged Infrastructure), also known as a hyper-converged infrastructure or a hyper-converged infrastructure, refers to an architecture that has computing, networking, storage, server virtualization and other resources and technologies in the same set of unit equipment (such as x86 servers); a high-availability cluster (HACluster) refers to a server cluster technology aimed at reducing service interruption time. It has high availability characteristics and provides uninterrupted services to the outside world by protecting the user's business programs, minimizing the impact of software, hardware and human failures on the business; a hyper-converged cluster refers to bringing together many servers installed with a hyper-converged system to provide the same service.
[0063] For example, the health status information can display the health status of each host in the hyper-converged cluster. When a system disk of a certain node is found to be abnormal, the system disk of the host can be replaced and restored to the same configuration as before the damage.
[0064] S200: Determine whether the system disk is abnormal based on the health status information. If so, perform the following processing on the system disk:
[0065] S300: judging whether the hyper-converged cluster node is online according to the health status information;
[0066] S311: If the hyper-converged cluster node is online, suspend writing data to the system disk;
[0067] S312: Back up system configuration options of the hyper-converged cluster node to generate a first system configuration backup file;
[0068] S313: Importing the first system configuration backup file into the first new disk;
[0069] S314: Replace the system disk with the first new disk, completing the data recovery process.
[0070] Exemplarily, S311-S314 is a process of replacing the abnormal system disk when the system disk is abnormal and the node is online, and the system disk is replaced with the first new disk; wherein the data of the first new disk is the first system configuration backup file of the instant backup.
[0071] S321: If the hyper-converged cluster node is not online, replace the system disk with the second new disk;
[0072] S322: Obtain a second system configuration backup file of the system disk on the healthy node according to the boot image;
[0073] Specifically, the specific operation process of S322 is as follows: use the boot image and utilize the shell script to install the hyper-converged system to the second new disk; then, enter the IP of the healthy node in the cluster and download the second system configuration file of the old system disk of the offline node.
[0074] S323: Import the second system configuration backup file into the second new disk to complete the data recovery process.
[0075] Exemplarily, S321-S323 is the process of replacing the abnormal system disk when the system disk is abnormal and the node is not online, and the system disk is replaced with a second new disk; the data of the second new disk is the second system configuration backup file backed up on other healthy nodes in the hyper-converged cluster.
[0076] Exemplarily, the boot image can be an ISO image; wherein: ISO image is one of the storage formats of CD-ROM images (CDMirror) on computers. Because it is a file stored according to ISO-9660 standards for CD-ROM file systems, it is usually named with the suffix .iso in the computer, commonly known as iso image file.
[0077] In some implementation scenarios, the data recovery method of the hyper-converged host monitors whether the hyper-converged cluster nodes and system disks are abnormal through health status information, and utilizes the high availability characteristics of the hyper-converged cluster. Even if a node in the hyper-converged cluster fails, after the node completes the recovery process and comes back online, the data can be synchronized to ensure the integrity of the entire cluster data; moreover, when the node is offline or the hyper-converged system file is damaged and the operation interface cannot be entered, the system configuration recovery process of the node is completed through the graphical operation of the interface by reusing the hyper-converged system's boot image (installation image), making the entire recovery process graphical and easy to operate; therefore, the method can be applied to scenarios where the hyper-converged system is damaged and the node is completely offline to restore the configuration data of the hyper-converged system, thereby achieving the technical effect of improving data recovery efficiency and convenience.
[0078] See also Figure 2 , Figure 2 A flowchart of another method for recovering data from a hyper-converged host provided in an embodiment of the present application.
[0079] Exemplarily, before the step of S100: obtaining health status information of the hyper-converged cluster nodes and the system disk, the method further includes:
[0080] S101: regularly triggering or manually triggering a system configuration task of a backup host;
[0081] S102: When the system configuration task is triggered, back up the configuration file of the system disk to generate a second system configuration backup file;
[0082] S103: Save the second system configuration backup file to other nodes of the hyper-converged cluster.
[0083] Exemplarily, the scheduled task of the periodic module is enabled to automatically and manually back up the configuration information of all nodes in the hyper-converged cluster; when the system disk of the host is abnormal or damaged, a new disk is replaced to copy the backed up system configuration backup file from other hosts in the hyper-converged cluster for recovery, thereby ensuring the stable operation of the hyper-converged cluster.
[0084] In some implementations, a cross-backup method may be used, that is, each node is guaranteed to have two system configuration backup files, thus achieving double protection.
[0085] In some implementation scenarios, the specific process of manually triggering the system configuration task of the backup host is as follows:
[0086] (1.1) The UI (User Interface) requests the host-service to back up the system configuration.
[0087] (1.2) After receiving the request, host-service performs parameter check on the request;
[0088] (1.3) Host-service handles when the local host storage backup package directory deletes backup packages that are more than 30 days old;
[0089] (1.4) host-service packages the system configurations that need to be backed up;
[0090] (1.5) Host-service backup configuration to adjacent nodes;
[0091] (1.6) host-service cleans up old backup packages of the host on adjacent hosts;
[0092] (1.7) Return the backup result to the UI.
[0093] Exemplarily, the system configuration task of the backup host is triggered on a scheduled basis: in the host-service module, the scheduled task function is used to add the scheduled backup configuration. The scheduled backup configuration process is the same as the steps (1.2)-(1.6) of manually triggering the call interface for backup.
[0094] In some implementation scenarios, automatic backup uses the crond scheduled task function, and scheduled backup is performed every morning; the system configuration of each host is backed up twice in the cluster. If it is a hyper-converged cluster with 2 hosts, only 1 copy is backed up, and no backup is performed on a single host; in the process of selecting the host configuration backup location, all hosts in the cluster are arranged in a ring. Taking 3 hosts as an example, host1 is backed up to host2 and host3, host2 is backed up to host3 and host1, and host3 is backed up to host1 and host2; the system configuration backup directory can be: / data / local / home_backup; the backup file naming format is: hostname_ip_mac_time; in addition, the method of the embodiment of the present application also has the function of automatic cleanup using the crond scheduled task function, which regularly detects the backup time of the backup file every day and cleans up the backup files from 30 days ago.
[0095] Exemplarily, S322: the step of obtaining the second system configuration backup file of the system disk on the healthy node according to the boot image includes:
[0096] S3221: Obtain the IP address information of the healthy node;
[0097] S3222: Obtain a second system configuration backup file according to the IP address information.
[0098] For example, during the process of replacing and restoring the abnormal system disk based on the boot image (the specific process is: using a shell script to install the hyper-converged system to the second new disk, entering the IP address of a healthy node in the cluster, and downloading the second system configuration file of the old system disk of the offline node), the backup file information of this node (abnormal system disk) (i.e., the second system configuration backup file) can be obtained through the IP address information of the healthy node.
[0099] Exemplarily, before the step of S311: pausing writing data to the system disk, the method further includes:
[0100] S3101: Migrate the virtual machine on the system disk to the healthy system disk.
[0101] In some implementation scenarios, the process of replacing a system disk when the system disk is abnormal and the node is online is as follows:
[0102] (2.1) The virtual machine on the node where the abnormal system disk is located is migrated to a healthy node;
[0103] (2.2) Enable node maintenance mode and stop writing data to the abnormal system disk to avoid secondary damage;
[0104] (2.3) In the platform software of the hyper-converged cluster, click the option to back up the system configuration immediately and wait for the backup to be successful (the first system configuration backup file);
[0105] (2.4) Insert a new disk with the same capacity as the first one on which the hyper-converged system is installed on the node, and import the first system configuration backup file that has just been completed;
[0106] (2.5) Shut down the node, unplug the abnormal system disk, and replace the first new disk to this location;
[0107] (2.6) The node is powered on, the configuration is restored successfully, and the abnormal system disk is safely replaced.
[0108] In some implementation scenarios, the process of replacing a system disk when the system disk is abnormal and the node is offline is as follows:
[0109] (3.1) Shut down the node;
[0110] (3.2) Remove the abnormal system disk and insert the second new disk in its original location;
[0111] (3.3) Copy the boot image in ISO format to the second new disk;
[0112] (3.4) After the node is powered on, follow the boot process of the boot image to enter the interface for replacing the system disk;
[0113] (3.5) After logging in with your user account and password, enter the IP address information of other healthy nodes;
[0114] (3.6) After successfully obtaining the backup file of the abnormal node, import it into the second new disk;
[0115] (3.7) The second new disk successfully imported the backup file;
[0116] (3.8) Restart the node and wait for the recovery progress bar to reach 100%. The safe replacement of the abnormal system disk is completed.
[0117] In some implementation scenarios, an example of a processing flow of a data recovery method for a hyper-converged host provided in an embodiment of the present application is as follows:
[0118] (4.1) Check whether the hardware meets the installation conditions. The code refers to the non_network_install.sh script code of the original installation system module.
[0119] (4.2) The user enters the host IP information, the master IP and the password, and the background verifies whether the information is available. If the information is available, the host network is configured. If the information is not available, the terminal pops up an input box to ask the user to re-enter the information. The verification information part refers to the non_network_install.sh script code installed by the system. In addition, the arping command is used to detect which eth network card of the host can connect to the master IP. If none of the network cards can connect, it returns to ask the user to confirm whether there is a problem with the network card link and re-enter the IP information.
[0120] (4.3) Filter the latest backed-up configuration (through sshpass ssh remote command execution):
[0121] (4.3.1) The latest backup package of the host to be restored is selected from each online host. If no backup package is found, an error is recorded in the log and the terminal prompts the user that the backup package cannot be found.
[0122] (4.3.2) Compare the backup packages selected in 1) based on the {now_time} segment of the package name, and select the latest backup package name in the cluster, the host IP where the package is located, and the source directory name corresponding to the / boot / firmware / current link directory.
[0123] (4.3.3) The time of printing the backup package is printed to the terminal, and then the user is asked to confirm whether to continue restoring the system configuration.
[0124] (4.4) Download the backup package to the host (via sshpass scp remote copy): If the download fails, provide a "Retry Download" button option to retry downloading the backup package. If the user chooses to cancel, the log is recorded and the terminal prompts the user that the backup package download failed.
[0125] (4.5) Unzip the backup package: The unzipped files include: default_conf_backup, version, disk.uuid, backup_sysdisk.md5 and backup packages of other fields;
[0126] (4.6) Pre-restore configuration condition check: Check the host information, including:
[0127] (4.6.1) Whether the major version number of the newly installed system is consistent with that of the master control ( / sf / version);
[0128] (4.6.2) Whether the major version information of the version file in the backup package is consistent with that of the master control;
[0129] (4.7) User selects new system disk: The newly inserted disk is selected according to the disk.uuid file in the backup package for the user to select as the new system disk. Only one disk can be selected correctly. If multiple disks are selected or no disk is selected, an error message will be displayed. If the life of the new SSD disk is less than 80%, the user will be prompted whether to continue to use it to install the system.
[0130] (4.8) Install the system on the system disk selected by the user: use the master's / boot / firmware / current to install the software (mainly including vm, rd, and patch packages), and use the ISO image to install grub; the function is implemented in the replace_system_disk_iso_install.sh script, which refers to the original iso-install.sh system installation code. The difference is that the master's / boot / firmware / current is used to install the software (mainly including vm, rd, and patch packages).
[0131] (4.9) Restore configuration: Use the backup_sysdisk.tar.gz file obtained by decompressing the backup package to restore the system configuration. The system restore configuration operation is: tar-xzPf backup_sysdisk.tar.gz-C / .
[0132] See also Figure 3 , Figure 3 This is a structural block diagram of a data recovery system for a hyper-converged host provided in an embodiment of the present application. The data recovery system for a hyper-converged host includes:
[0133] A health acquisition module 100 is used to obtain health status information of the hyper-converged cluster nodes and system disks;
[0134] The abnormality determination module 200 is used to determine whether the system disk is abnormal according to the health status information. If so, the following processing is performed on the system disk:
[0135] A node online judgment module 300 is used to judge whether a hyper-converged cluster node is online according to health status information;
[0136] The pause module 400 is used to pause writing data to the system disk if the hyper-converged cluster node is online;
[0137] The backup module 500 is used to back up the system configuration options of the hyper-converged cluster node and generate a first system configuration backup file;
[0138] An import module 600 is used to import the first system configuration backup file into the first new disk;
[0139] A replacement module 700 is used to replace the system disk with a first new disk to complete the data recovery process;
[0140] The replacement module 700 is also used to replace the system disk with a second new disk if the hyper-converged cluster node is not online;
[0141] The backup acquisition module 800 is used to acquire the second system configuration backup file of the system disk on the healthy node according to the boot image;
[0142] The import module 600 is also used to import the second system configuration backup file into the second new disk to complete the data recovery process.
[0143] Exemplarily, the system further includes:
[0144] A trigger module is used to periodically or manually trigger the system configuration task of the backup host;
[0145] The backup module is also used to back up the configuration file of the system disk and generate a second system configuration backup file when the system configuration task is triggered;
[0146] The saving module is used to save the second system configuration backup file to other nodes of the hyper-converged cluster.
[0147] Exemplarily, the backup acquisition module includes:
[0148] IP address unit, used to obtain the IP address information of healthy nodes;
[0149] The backup acquisition unit is used to acquire the second system configuration backup file according to the IP address information.
[0150] Exemplarily, the system further includes a migration module, and the migration module is used to migrate the virtual machine on the system disk to the healthy system disk.
[0151] This application also provides an electronic device, see Figure 4 , Figure 4 A block diagram of an electronic device provided in an embodiment of the present application. The electronic device may include a processor 510, a communication interface 520, a memory 530, and at least one communication bus 540. The communication bus 540 is used to realize direct connection and communication between these components. The communication interface 520 of the electronic device in the embodiment of the present application is used to communicate signaling or data with other node devices. The processor 510 may be an integrated circuit chip with signal processing capabilities.
[0152] The processor 510 mentioned above can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiments of the present application can be implemented or executed. The general-purpose processor can be a microprocessor or the processor 510 can also be any conventional processor, etc.
[0153] The memory 530 may be, but is not limited to, a random access memory (RAM), a read only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electric erasable programmable read-only memory (EEPROM), etc. The memory 530 stores computer-readable instructions. When the computer-readable instructions are executed by the processor 510, the electronic device can execute the above-mentioned Figure 1 to Figure 2 The method embodiment involves various steps.
[0154] Optionally, the electronic device may further include a storage controller and an input / output unit.
[0155] The memory 530, storage controller, processor 510, peripheral interface, input and output unit components are directly or indirectly electrically connected to each other to achieve data transmission or interaction. For example, these components can be electrically connected to each other via one or more communication buses 540. The processor 510 is used to execute executable modules stored in the memory 530, such as software function modules or computer programs included in the electronic device.
[0156] The input and output unit is used to provide users with the task creation and to create a start optional time period or preset execution time for the task to realize the interaction between the user and the server. The input and output unit can be, but is not limited to, a mouse and a keyboard.
[0157] Understandably, Figure 4 The structure shown is for illustration only, and the electronic device may also include Figure 4 More or fewer components as shown, or with Figure 4 Different configurations shown. Figure 4 Each component shown in the figure can be implemented by hardware, software or a combination thereof.
[0158] An embodiment of the present application further provides a storage medium having instructions stored thereon. When the instructions are run on a computer, the computer program is executed by a processor to implement the method described in the method embodiment. To avoid repetition, the method will not be described here.
[0159] The present application also provides a computer program product, which, when executed on a computer, enables the computer to execute the method described in the method embodiment.
[0160] In several embodiments provided in the present application, it should be understood that the disclosed devices and methods can also be implemented in other ways. The device embodiments described above are merely schematic. For example, the flowcharts and block diagrams in the accompanying drawings show the possible architecture, functions and operations of the devices, methods and computer program products according to multiple embodiments of the present application. In this regard, each box in the flowchart or block diagram can represent a module, a program segment or a part of a code, and the module, a program segment or a part of a code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flowchart, and the combination of boxes in the block diagram and / or flowchart can be implemented with a dedicated hardware-based system that performs a specified function or action, or can be implemented with a combination of dedicated hardware and computer instructions.
[0161] In addition, the functional modules in the various embodiments of the present application may be integrated together to form an independent part, or each module may exist separately, or two or more modules may be integrated to form an independent part.
[0162] If the functions are implemented in the form of software function modules and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application can be essentially or partly embodied in the form of a software product that contributes to the prior art. The computer software product is stored in a storage medium, including several instructions to enable 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 methods described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.
[0163] The above description is only an embodiment of the present application and is not intended to limit the scope of protection of the present application. For those skilled in the art, the present application may have various changes and variations. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application should be included in the scope of protection of the present application. It should be noted that similar reference numerals and letters represent similar items in the following drawings, so once an item is defined in one drawing, it does not need to be further defined and explained in the subsequent drawings.
[0164] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
[0165] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.
Claims
1. A data recovery method for a hyper-converged host, characterized in that: include: Obtain health status information of a hyper-converged cluster node and a system disk of the obtained hyper-converged cluster node; Determine whether the system disk is abnormal based on the health status information, and if so, perform the following processing on the system disk: Determine whether the hyper-converged cluster node is online according to the health status information; If the hyper-converged cluster node is online, suspend writing data to the system disk; Backing up system configuration options of the hyper-converged cluster node to generate a first system configuration backup file; importing the first system configuration backup file into a first new disk; Replacing the system disk with the first new disk to complete the data recovery process; If the hyper-converged cluster node is not online, replace the system disk with a second new disk; Obtaining a second system configuration backup file of the system disk on the healthy node according to the boot image; Import the second system configuration backup file into the second new disk to complete the data recovery process.
2. The data recovery method of a hyper-converged host according to claim 1, characterized in that: Before the step of obtaining the health status information of the hyper-converged cluster nodes and the system disk, the method further includes: Periodically or manually trigger the system configuration task of the backup host; When the system configuration task is triggered, backing up the configuration file of the system disk to generate the second system configuration backup file; The second system configuration backup file is saved to other nodes of the hyper-converged cluster.
3. The data recovery method of a hyper-converged host according to claim 2, characterized in that: The step of obtaining the second system configuration backup file of the system disk on the healthy node according to the boot image includes: Obtain the IP address information of the healthy node; The second system configuration backup file is obtained according to the IP address information.
4. The data recovery method of a hyper-converged host according to claim 1, characterized in that: Before the step of suspending writing data into the system disk, the method further includes: Migrate the virtual machine on the system disk to the healthy system disk.
5. A data recovery system for a hyper-converged host, characterized in that: include: A health acquisition module, used to acquire health status information of a hyper-converged cluster node and a system disk of the acquired hyper-converged cluster node; The abnormality judgment module is used to judge whether the system disk is abnormal according to the health status information, and if so, perform the following processing on the system disk: A node online judgment module is used to judge whether the hyper-converged cluster node is online according to the health status information; A pause module, used for suspending writing data to the system disk if the hyper-converged cluster node is online; A backup module, used to back up system configuration options of the hyper-converged cluster node and generate a first system configuration backup file; An import module, used for importing the first system configuration backup file into a first new disk; A replacement module, used for replacing the system disk with the first new disk to complete the data recovery process; The replacement module is also used to replace the system disk with a second new disk if the hyper-converged cluster node is not online; A backup acquisition module, used for acquiring a second system configuration backup file of the system disk on the healthy node according to the boot image; The import module is also used to import the second system configuration backup file into the second new disk to complete the data recovery process.
6. The data recovery system for a hyper-converged host according to claim 5, characterized in that: The system further comprises: The trigger module is used to periodically or manually trigger the system configuration task of the backup host; The backup module is also used to back up the configuration file of the system disk and generate the second system configuration backup file when the system configuration task is triggered; The saving module is used to save the second system configuration backup file to other nodes of the hyper-converged cluster.
7. The data recovery system of a hyper-converged host according to claim 6, characterized in that: The backup acquisition module includes: An IP address unit, used to obtain the IP address information of the healthy node; A backup acquisition unit is used to acquire the second system configuration backup file according to the IP address information.
8. The data recovery system for a hyper-converged host according to claim 5, characterized in that: The system further comprises a migration module, and the migration module is used to migrate the virtual machine on the system disk to a healthy system disk.
9. An electronic device, characterized in that: include: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the steps of the data recovery method for a hyper-converged host as described in any one of claims 1 to 4 are implemented.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores instructions, and when the instructions are executed on a computer, the computer executes the data recovery method for a hyper-converged host according to any one of claims 1 to 4.
Citation Information
Patent Citations
Realization method of automation synchronous mirror image and restoration
CN101833487A
Recovery method and recovery system of virtual machine in cluster
CN104899071A