Cloud computer migration method and device, equipment, storage medium and program product

Through system snapshot transmission and multiple adaptation methods, efficient, resource conservation and high compatibility migration of physical machines to cloud computers is achieved, and the problems of migration restrictions and resource utilization in the existing technology are solved.

CN119645572APending Publication Date: 2025-03-18CHINA TELECOM CLOUD TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411791707.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-06
Publication Date
2025-03-18

AI Technical Summary

Technical Problem

The prior art has limitations when the physical machine is migrated to a cloud computer, and the transfer server method has a large resource occupancy and poor adaptability.

Method used

By determining whether the source host supports migration to the target cloud computer, lock the target cloud computer and enter rescue mode, back up the system boot files, generate system snapshots, transmit snapshots to the target cloud computer, perform preliminary adaptation, restore boot files, exit rescue mode, and then perform secondary adaptation to complete the migration.

Benefits of technology

It realizes the migration of different systems to cloud computers, with less resource occupancy and high adaptability, and solves the problem that the physical machine cannot be compatible with basic cloud computer services due to lack of plug-ins after the migration.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119645572A_ABST
    Figure CN119645572A_ABST
Patent Text Reader

Abstract

The invention relates to a cloud computer migration method and device, equipment, a storage medium and a program product. The method comprises the steps that whether a source end host supports migration to a target cloud computer or not is judged, if yes, the target cloud computer is locked, and the target cloud computer is controlled to enter a rescue mode; backing up a system boot file of the target cloud computer, and generating a system snapshot of the source end host; transmitting the system snapshot to a target cloud computer, and performing preliminary adaptation on the source end host and the target cloud computer based on the system type of the source end host; under the condition of successful preliminary adaptation, restoring the system boot file, and exiting the rescue mode; and carrying out secondary adaptation on the source end host and the target cloud computer, completing the current migration under the condition that the secondary adaptation is successful, and unlocking the target cloud computer. By adopting the method, different types of source end hosts can be migrated to the cloud computer.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of cloud computing technology, and in particular to a cloud computer migration method, device, equipment, storage medium and program product. Background Art

[0002] The widespread application of cloud computing and virtualization technology has provided enterprises with greater flexibility, efficiency and reliability, and has become a key component of existing infrastructure. Due to various reasons such as enterprise cloud migration, upgrading, and resource upgrades, migrating hosts in different environments to cloud computers that are more convenient to use and have richer resources has become a new demand.

[0003] In response to the need to migrate to cloud computers, the existing mainstream technical solutions are to use image import, that is, the source virtual host first generates an image file through a virtual machine, and then uses the underlying virtualization technology of the cloud computer to import the image to generate a new target cloud computer, thereby realizing the cloud computer migration needs. However, since physical machines cannot directly generate image files, this method is quite limited in the scenario of migrating physical machines to cloud computers. The second is to use a transit server to adapt some drivers on the transit server. This solution consumes a lot of resources and has poor adaptability. Summary of the invention

[0004] Based on this, it is necessary to provide a cloud computer migration method, device, equipment, storage medium and program product that can realize the migration of different systems to cloud computers and occupy less resources in order to solve the above technical problems.

[0005] In a first aspect, the present application provides a cloud computer migration method, comprising:

[0006] Determine whether the source host supports migration to the target cloud computer. If so, lock the target cloud computer and control the target cloud computer to enter rescue mode.

[0007] Backing up the system boot file of the target cloud computer and generating a system snapshot of the source host;

[0008] The system snapshot is transmitted to the target cloud computer, and based on the system type of the source host, the source host and the target cloud computer are preliminarily adapted;

[0009] If the initial adaptation is successful, restoring the system boot file and exiting the rescue mode;

[0010] The source host and the target cloud computer are adapted for a second time, and when the second adaptation is successful, the current migration is completed and the target cloud computer is unlocked.

[0011] In one embodiment, determining whether the source host supports migration to the target cloud computer includes:

[0012] The host information of the source host and the target cloud computer is obtained respectively, and based on the host information, it is determined whether the source host supports migration to the target cloud computer, wherein the host information at least includes the host system type and disk partition information.

[0013] In one embodiment, before transmitting the system snapshot to the target cloud computer, the process includes:

[0014] After backing up the system boot file of the target cloud computer, format the original system partition of the target cloud computer, and notify the source host that the target cloud computer is ready.

[0015] In one embodiment, the transmitting the system snapshot to the target cloud computer includes:

[0016] Acquire a file transfer tool, and control the source host to transfer the system snapshot based on a client of the file transfer tool;

[0017] The target cloud computer is controlled to monitor the transmission process of the system snapshot based on the server of the file transfer tool.

[0018] In one embodiment, the preliminary adaptation of the source host and the target cloud computer based on the system type of the source host includes:

[0019] Determine whether the system type of the source host is the same as the system type of the target cloud computer;

[0020] If the two are different, an adapter driver is obtained, and based on the adapter driver, a preliminary adaptation is performed on the source host and the target cloud computer.

[0021] In one embodiment, the secondary adaptation of the source host and the target cloud computer includes:

[0022] Determine whether the system type of the source host is the same as the system type of the target cloud computer;

[0023] If the two are different, the adapter component will be automatically started when the target cloud computer is turned on; wherein the adapter component is used to initialize the service and personalize the target cloud computer.

[0024] In a second aspect, the present application also provides a cloud computer migration device, including:

[0025] A determination module, used to determine whether the source host supports migration to the target cloud computer, and if so, lock the target cloud computer and control the target cloud computer to enter a rescue mode;

[0026] A backup module, used to back up the system boot file of the target cloud computer and generate a system snapshot of the source host;

[0027] A first adaptation module, used to transmit the system snapshot to the target cloud computer, and perform preliminary adaptation between the source host and the target cloud computer based on the system type of the source host;

[0028] A restoration module, used to restore the system boot file and exit the rescue mode if the initial adaptation is successful;

[0029] The second adaptation module is used to perform secondary adaptation on the source host and the target cloud computer, complete the current migration when the secondary adaptation is successful, and unlock the target cloud computer.

[0030] In a third aspect, the present application further provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the following steps are implemented:

[0031] Determine whether the source host supports migration to the target cloud computer. If so, lock the target cloud computer and control the target cloud computer to enter rescue mode.

[0032] Backing up the system boot file of the target cloud computer and generating a system snapshot of the source host;

[0033] The system snapshot is transmitted to the target cloud computer, and based on the system type of the source host, the source host and the target cloud computer are preliminarily adapted;

[0034] If the initial adaptation is successful, restoring the system boot file and exiting the rescue mode;

[0035] The source host and the target cloud computer are adapted for a second time, and when the second adaptation is successful, the current migration is completed and the target cloud computer is unlocked.

[0036] In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the following steps are implemented:

[0037] Determine whether the source host supports migration to the target cloud computer. If so, lock the target cloud computer and control the target cloud computer to enter rescue mode.

[0038] Backing up the system boot file of the target cloud computer and generating a system snapshot of the source host;

[0039] The system snapshot is transmitted to the target cloud computer, and based on the system type of the source host, the source host and the target cloud computer are preliminarily adapted;

[0040] If the initial adaptation is successful, restoring the system boot file and exiting the rescue mode;

[0041] The source host and the target cloud computer are adapted for a second time, and when the second adaptation is successful, the current migration is completed and the target cloud computer is unlocked.

[0042] In a fifth aspect, the present application further provides a computer program product, including a computer program, which implements the following steps when executed by a processor:

[0043] Determine whether the source host supports migration to the target cloud computer. If so, lock the target cloud computer and control the target cloud computer to enter rescue mode.

[0044] Backing up the system boot file of the target cloud computer and generating a system snapshot of the source host;

[0045] The system snapshot is transmitted to the target cloud computer, and based on the system type of the source host, the source host and the target cloud computer are preliminarily adapted;

[0046] If the initial adaptation is successful, restoring the system boot file and exiting the rescue mode;

[0047] The source host and the target cloud computer are adapted for a second time, and when the second adaptation is successful, the current migration is completed and the target cloud computer is unlocked.

[0048] The above-mentioned cloud computer migration method, device, computer equipment, computer-readable storage medium and computer program product use system snapshots to transmit data, back up boot files in advance to prevent the inconsistency between the two systems from causing the target cloud computer to be unable to boot normally, and adapt based on the system type of the source host and the target cloud computer to solve the problem of incompatibility of cloud computer basic services due to lack of plug-ins after physical / virtual machine migration. This application can realize heterogeneous migration services with high driver adaptability based on the rescue mode capability of the cloud computer itself without occupying additional storage resources. BRIEF DESCRIPTION OF THE DRAWINGS

[0049] In order to more clearly illustrate the technical solutions in the embodiments of the present application or related technologies, the drawings required for use in the embodiments of the present application or related technical descriptions will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.

[0050] Figure 1 A schematic diagram of a process of a cloud computer migration method in one embodiment;

[0051] Figure 2 A schematic diagram of the architecture of a cloud computer migration method in one embodiment;

[0052] Figure 3 It is a flowchart of a cloud computer migration method in a specific embodiment;

[0053] Figure 4 is a structural block diagram of a cloud computer migration device in one embodiment;

[0054] Figure 5 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION

[0055] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0056] With the rise of cloud computing, the widespread application of cloud computing and virtualization technology has provided enterprises with greater flexibility, efficiency and reliability, and has become a key component of existing infrastructure. Due to various reasons such as enterprise cloud migration, upgrading, resource upgrades, etc., migrating hosts in different environments to cloud computers that are more convenient to use and have richer resources has become a new demand.

[0057] In response to the need to migrate to cloud computers, the current mainstream technical solutions are to use image import, that is, the source virtual host first generates image files such as vmdk through a virtual machine (such as VMware), and then uses the underlying virtualization technology of the cloud computer to import the image to generate a new target cloud computer, thereby realizing the cloud computer migration needs. However, since physical machines cannot directly generate image files, this method is quite limited in the scenario of migrating physical machines to cloud computers. The second is to use a transit server (also called a shadow server) to adapt some drivers on the transit server. This solution consumes a lot of resources and has poor adaptability.

[0058] In one embodiment, Figure 1As shown, a cloud computer migration method is provided. This embodiment uses the method applied to a terminal as an example for illustration. It can be understood that the method can also be applied to a server, and can also be applied to a system including a terminal and a server, and is implemented through the interaction between the terminal and the server. In this embodiment, the method includes the following steps:

[0059] Step 101, determining whether the source host supports migration to the target cloud computer, and if so, locking the target cloud computer and controlling the target cloud computer to enter rescue mode;

[0060] Step 102, backing up the system boot file of the target cloud computer and generating a system snapshot of the source host;

[0061] Step 103, transmitting the system snapshot to the target cloud computer, and performing preliminary adaptation between the source host and the target cloud computer based on the system type of the source host;

[0062] Step 104, if the initial adaptation is successful, restore the system boot file and exit the rescue mode;

[0063] Step 105, performing secondary adaptation on the source host and the target cloud computer, completing the current migration when the secondary adaptation is successful, and unlocking the target cloud computer.

[0064] Exemplarily, computer migration refers to migrating the entire operating system, configuration, and applications of one computer to another computer. The cloud computer migration described in this article specifically refers to migrating the source host (including physical machine / virtual machine / cloud computer) to the cloud computer as a whole. Rescue mode is a special startup mode that comes with a cloud computer and is used by the operating system for troubleshooting and repair. It usually loads minimal system resources and drivers to ensure that the original system can still start and run normally in a faulty state. A snapshot refers to a fully usable copy of a specified data set, which includes an image of the corresponding data at a certain point in time. In the cloud computer migration method of this embodiment, two adaptations are performed to ensure the normal operation of system applications. The specific adaptation method will be described later.

[0065] For example, see Figure 2 This embodiment adopts Figure 2 The overall architecture is mainly composed of the management console, migration agent, synchronization node and proxy. The functions of each part include:

[0066] The management console is used to coordinate and manage the process scheduling of cloud computer migration, collect the status and progress of various migration tasks, issue various instructions, and also rely on internal capabilities to implement related operations on the target cloud computer (such as creating a cloud computer, mounting disks, switching to rescue mode, etc.);

[0067] Migration agent: It is used to receive various instructions issued by the execution management console, report task status, and perform specific migration operations;

[0068] Synchronization node, used to open up a channel between the source host and the target cloud computer for migration;

[0069] Proxy (proxy mode): used to connect the national region with the target resource pool network;

[0070] The main network links are divided into two categories:

[0071] Migration network: The migration agent of the source host and the migration agent of the target cloud computer register with the migration nodes deployed in the national region through the external network, establish a long connection, and open up the migration channel. It should be noted that if the target cloud computer does not have external network capabilities, it needs to register with the migration node through a proxy.

[0072] Scheduling network, the migration agent of the source host is registered with the management console deployed in the national region through the external network, and the migration agent of the target cloud computer is registered with the management console deployed in the national region through the external network. Similarly, if the target cloud computer does not have external network capabilities, it needs to register with the management console through a proxy.

[0073] The main process is divided into four stages: inspection, preparation, migration, and adaptation. The source host runs normally without the user noticing, and the target cloud computer switches between rescue mode and normal operating mode.

[0074] In the above-mentioned cloud computer migration method, a migration method based on the file system level in the native rescue mode of the cloud computer is adopted, which can solve the problem of storage resource waste based on the rescue mode capability of the cloud computer itself; it supports a wide range of application scenarios and can realize heterogeneous migration in a variety of environments, allowing users to seamlessly migrate physical machines, virtual machines, and (non-) homologous cloud computers to cloud computers. At the same time, it has a highly compatible driver adaptation strategy that can realize automatic identification, dynamic loading and abnormal rollback of drivers. Without occupying additional resources, a heterogeneous migration service with high driver adaptability is realized.

[0075] In an exemplary embodiment, determining whether the source host supports migration to the target cloud computer includes: respectively obtaining host information of the source host and the target cloud computer, and determining whether the source host supports migration to the target cloud computer based on the host information, wherein the host information includes at least the host system type and disk partition information.

[0076] Specifically, this step corresponds to the inspection phase above. The source host and the target cloud computer report host information respectively, mainly including the host system type (physical machine / virtual machine / cloud computer) and disk partition information, etc., to determine whether the current machine supports migration to the cloud computer; at the same time, identify the hardware driver of the source host and clarify the one-to-one correspondence between the source host and the target cloud computer's disk.

[0077] At this time, the target cloud computer is in normal operating mode, and then the target cloud computer is locked to prevent users from logging in and enters the rescue mode.

[0078] In this embodiment, the rescue mode can handle the write operation of the original system disk. When the target cloud computer is in the rescue mode, it is booted as the rescue minimum system, and the original system disk is mounted as a normal data disk, which is convenient for data transmission and overwriting without worrying about permission issues.

[0079] In an exemplary embodiment, before transferring the system snapshot to the target cloud computer, the steps include: after backing up the system boot file of the target cloud computer, formatting the original system partition of the target cloud computer, and notifying the source host that the target cloud computer is ready.

[0080] Specifically, we enter the preparation stage of cloud computer migration: to pave the way for the formal migration, the target cloud computer performs backup, formatting and other preparatory operations in rescue mode during this stage; the backup is to back up the original system boot files (such as bootnxt, etc.), and restore them during the adaptation stage to prevent the inconsistency between the two systems from causing the target cloud computer to fail to boot normally; the source host actively generates a temporary system snapshot through the Volume Shadow Copy Service (VSS) that comes with the Windows system to ensure system consistency and solve the problem of read permissions for some system files.

[0081] In an exemplary embodiment, the transmitting the system snapshot to the target cloud computer includes:

[0082] Obtain a file transfer tool, control the source host to transfer the system snapshot based on the client of the file transfer tool; control the target cloud computer to monitor the transmission process of the system snapshot based on the server of the file transfer tool.

[0083] Cloud PC migration based on the file system: the source host transfers the snapshot content to the target cloud PC in the form of file transfer (customized fsync transmission technology or other file transfer technologies can be used).

[0084] In this embodiment, migration based on the file system and system image can avoid the problem that the physical machine cannot directly generate an image file, and there is no need to use a transit server. Data can be directly transmitted between the source host and the target cloud computer without occupying a large amount of resources.

[0085] In an exemplary embodiment, the preliminarily adapting the source host and the target cloud computer based on the system type of the source host includes:

[0086] Determine whether the system type of the source host is the same as the system type of the target cloud computer; if they are different, obtain an adapter driver, and perform preliminary adaptation of the source host and the target cloud computer based on the adapter driver.

[0087] After the migration is completed, in order to ensure the normal operation of the system application, some adaptation processing needs to be performed on the target cloud computer. Part of the adaptation stage is carried out in rescue mode, and some operations cannot be installed offline and need to be switched to normal operating mode and then automatically executed after startup. Based on this, this application divides the adaptation stage into preliminary adaptation and secondary adaptation. Specifically, the preliminary adaptation includes: in rescue mode, the target cloud computer automatically installs hardware drivers according to the driver information reported by the source host based on whether the source host is a cloud computer, to ensure that the migrated system can start normally-usually install viostor and vioscsi, and dynamically and selectively install drivers such as netkvm. If the adaptation is abnormal, it can also be rolled back to a stable state to ensure system reliability. In addition, it is necessary to restore the system boot files backed up in the preparation stage, and the offline registration service automatically performs secondary adaptation after entering the normal operating mode and starting up.

[0088] In an exemplary embodiment, the secondary adaptation of the source host and the target cloud computer includes:

[0089] Determine whether the system type of the source host is the same as the system type of the target cloud computer; if the two are different, automatically start the adapter component when the target cloud computer is turned on; wherein the adapter component is used to initialize the service and personalize the target cloud computer.

[0090] Exemplarily, the adaptation component refers to the cloud computer custom component. At this point, the rescue mode has been exited and the normal operation mode has been entered. In the normal operation mode, the target cloud computer installs the cloud computer custom component according to whether the source host is a cloud computer. Exemplarily, the functions of the custom component include: completing initialization services including automated network settings, patch update installation, storage volume management configuration, etc., while performing personalized settings such as virtual printing and program performance optimization, to solve the problem of incompatibility of cloud computer basic services due to lack of plug-ins after physical machine / virtual machine migration;

[0091] In this embodiment, the problem of compatibility between different types of source hosts (mainly physical machines / virtual machines) after migration to cloud computers is solved through custom components, and a heterogeneous migration service with high driver adaptability can be implemented without occupying additional storage resources.

[0092] To explain the cloud computer migration method in detail, the following is a most detailed example:

[0093] See also Figure 3 , Figure 3 A flowchart of a specific implementation method provided for this application: This application can be applied to scenarios of migration to cloud computers in different environments (physical machines / virtual machines / cloud computers). For ease of explanation, a specific implementation example is given for the scenario of VMware virtual machines migrating to cloud computers.

[0094] Inspection phase:

[0095] Install the migration agent on the VMware virtual machine, register it to the console and create a migration task; the virtual machine reports the host information (including system type, disk partition, system architecture, etc.) and driver information.

[0096] If migrating to a new machine, a cloud computer will be created based on the host information of the VMware virtual machine; if migrating to an existing cloud computer, it will be determined whether it meets the migration conditions. The cloud computer will be locked into rescue mode to prevent users from logging in.

[0097] Preparation stage:

[0098] The target cloud computer backs up the original system boot files (bootnxt, bootmgr, boot\) to the specified directory of the current boot disk, and restores them in the adaptation phase to ensure that the cloud computer can boot normally after the subsequent migration. The target cloud computer formats the original system partition. The VMware virtual machine generates a VSS temporary snapshot to ensure system consistency and solve some system file read permission issues that may arise during the subsequent migration process.

[0099] Migration phase:

[0100] The target cloud computer starts the fsync (fsync is a custom file transfer tool that is optimized for transfer efficiency and Windows file attributes) server to monitor the transfer process, and the VMware virtual machine starts the fsync client to start the migration of the system snapshot. For example, file transfer can also be implemented using other file transfer tools such as rsync.

[0101] Adaptation phase:

[0102] The target cloud computer installs viostor and vioscsi drivers according to the driver information reported by the VMware virtual machine during the inspection phase; at the same time, registers the offline service Bootstrap for self-starting installation of cloud computer custom components. Restore the system boot files backed up in the preparation phase to the original system.

[0103] Then, the target cloud computer exits the rescue mode and enters the normal operation mode. The target cloud computer automatically starts to install the cloud computer custom component (named ctyun_xx_mirror_xx.exe, which includes the installation of components such as clinkagent, cloudupdate, virtualprinter and other personalized configurations) to adapt the operation of the cloud computer. After the adaptation is completed, the target cloud computer is unlocked and locked, the migration is completed, and the user can log in and use it.

[0104] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.

[0105] Based on the same inventive concept, the embodiment of the present application also provides a cloud computer migration device for implementing the cloud computer migration method involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in one or more cloud computer migration device embodiments provided below can refer to the limitations of the cloud computer migration method above, and will not be repeated here.

[0106] In an exemplary embodiment, Figure 4 As shown, a cloud computer migration device is provided, including: a judgment module 401, a backup module 402, a first adaptation module 403, a restoration module 404 and a second adaptation module 405, wherein:

[0107] The determination module 401 is used to determine whether the source host supports migration to the target cloud computer. If so, the target cloud computer is locked and the target cloud computer is controlled to enter a rescue mode.

[0108] A backup module 402 is used to back up the system boot file of the target cloud computer and generate a system snapshot of the source host;

[0109] A first adaptation module 403 is used to transmit the system snapshot to the target cloud computer and perform preliminary adaptation between the source host and the target cloud computer based on the system type of the source host;

[0110] A restoration module 404, used to restore the system boot file and exit the rescue mode if the initial adaptation is successful;

[0111] The second adaptation module 405 is used to perform secondary adaptation on the source host and the target cloud computer, complete the current migration if the secondary adaptation is successful, and unlock the target cloud computer.

[0112] The judging module 401 is further used for:

[0113] The host information of the source host and the target cloud computer is obtained respectively, and based on the host information, it is determined whether the source host supports migration to the target cloud computer, wherein the host information at least includes the host system type and disk partition information.

[0114] The backup module 402 is further used for:

[0115] After backing up the system boot file of the target cloud computer, format the original system partition of the target cloud computer, and notify the source host that the target cloud computer is ready.

[0116] The first adaptation module 403 is further used for:

[0117] Acquire a file transfer tool, and control the source host to transfer the system snapshot based on a client of the file transfer tool;

[0118] The target cloud computer is controlled to monitor the transmission process of the system snapshot based on the server of the file transfer tool.

[0119] The first adaptation module 403 is further used for:

[0120] Determine whether the system type of the source host is the same as the system type of the target cloud computer;

[0121] If the two are different, an adapter driver is obtained, and based on the adapter driver, a preliminary adaptation is performed on the source host and the target cloud computer.

[0122] The second adaptation module 405 is further used for:

[0123] Determine whether the system type of the source host is the same as the system type of the target cloud computer;

[0124] If the two are different, the adapter component will be automatically started when the target cloud computer is turned on; wherein the adapter component is used to initialize the service and personalize the target cloud computer.

[0125] Each module in the above-mentioned cloud computer migration device can be implemented in whole or in part by software, hardware and their combination. Each of the above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the corresponding operations of each of the above modules.

[0126] In an exemplary embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as shown in FIG. Figure 5 As shown. The computer device includes a processor, a memory, an input / output interface, a communication interface, a display unit and an input device. The processor, the memory and the input / output interface are connected through a system bus, and the communication interface, the display unit and the input device are connected to the system bus through the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The input / output interface of the computer device is used to exchange information between the processor and the external device. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be implemented through WIFI, a mobile cellular network, near field communication (NFC) or other technologies. When the computer program is executed by the processor, a cloud computer migration method is implemented. The display unit of the computer device is used to form a visually visible picture, which can be a display screen, a projection device or a virtual reality imaging device. The display screen can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device can be a touch layer covering the display screen, or a button, trackball or touchpad set on the computer device shell, or an external keyboard, touchpad or mouse.

[0127] Those skilled in the art will understand that Figure 5 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0128] In an exemplary embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the computer program, the following steps are implemented:

[0129] Determine whether the source host supports migration to the target cloud computer. If so, lock the target cloud computer and control the target cloud computer to enter rescue mode.

[0130] Backing up the system boot file of the target cloud computer and generating a system snapshot of the source host;

[0131] The system snapshot is transmitted to the target cloud computer, and based on the system type of the source host, the source host and the target cloud computer are preliminarily adapted;

[0132] If the initial adaptation is successful, restoring the system boot file and exiting the rescue mode;

[0133] The source host and the target cloud computer are adapted for a second time, and when the second adaptation is successful, the current migration is completed and the target cloud computer is unlocked.

[0134] In one embodiment, a computer readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented:

[0135] Determine whether the source host supports migration to the target cloud computer. If so, lock the target cloud computer and control the target cloud computer to enter rescue mode.

[0136] Backing up the system boot file of the target cloud computer and generating a system snapshot of the source host;

[0137] The system snapshot is transmitted to the target cloud computer, and based on the system type of the source host, the source host and the target cloud computer are preliminarily adapted;

[0138] If the initial adaptation is successful, restoring the system boot file and exiting the rescue mode;

[0139] The source host and the target cloud computer are adapted for a second time, and when the second adaptation is successful, the current migration is completed and the target cloud computer is unlocked.

[0140] In one embodiment, a computer program product is provided, comprising a computer program, which, when executed by a processor, implements the following steps:

[0141] Determine whether the source host supports migration to the target cloud computer. If so, lock the target cloud computer and control the target cloud computer to enter rescue mode.

[0142] Backing up the system boot file of the target cloud computer and generating a system snapshot of the source host;

[0143] The system snapshot is transmitted to the target cloud computer, and based on the system type of the source host, the source host and the target cloud computer are preliminarily adapted;

[0144] If the initial adaptation is successful, restoring the system boot file and exiting the rescue mode;

[0145] The source host and the target cloud computer are adapted for a second time, and when the second adaptation is successful, the current migration is completed and the target cloud computer is unlocked.

[0146] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant regulations.

[0147] A person of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment method can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, an artificial intelligence (AI) processor, etc., but are not limited to this.

[0148] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.

[0149] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.

Claims

1. A cloud computer migration method, characterized in that: The method comprises: Determine whether the source host supports migration to the target cloud computer. If so, lock the target cloud computer and control the target cloud computer to enter rescue mode. Backing up the system boot file of the target cloud computer and generating a system snapshot of the source host; The system snapshot is transmitted to the target cloud computer, and based on the system type of the source host, the source host and the target cloud computer are preliminarily adapted; If the initial adaptation is successful, restoring the system boot file and exiting the rescue mode; The source host and the target cloud computer are adapted for a second time, and when the second adaptation is successful, the current migration is completed and the target cloud computer is unlocked.

2. The method according to claim 1, characterized in that: The step of determining whether the source host supports migration to the target cloud computer includes: The host information of the source host and the target cloud computer is obtained respectively, and based on the host information, it is determined whether the source host supports migration to the target cloud computer, wherein the host information at least includes the host system type and disk partition information.

3. The method according to claim 1, characterized in that Before transmitting the system snapshot to the target cloud computer, the method includes: After backing up the system boot file of the target cloud computer, format the original system partition of the target cloud computer, and notify the source host that the target cloud computer is ready.

4. The method according to claim 1, characterized in that The transmitting the system snapshot to the target cloud computer includes: Acquire a file transfer tool, and control the source host to transfer the system snapshot based on a client of the file transfer tool; The target cloud computer is controlled to monitor the transmission process of the system snapshot based on the server of the file transfer tool.

5. The method according to claim 1, characterized in that The preliminary adaptation of the source host and the target cloud computer based on the system type of the source host includes: Determine whether the system type of the source host is the same as the system type of the target cloud computer; If the two are different, an adapter driver is obtained, and based on the adapter driver, a preliminary adaptation is performed on the source host and the target cloud computer.

6. The method according to claim 1, characterized in that The secondary adaptation of the source host and the target cloud computer includes: Determine whether the system type of the source host is the same as the system type of the target cloud computer; If the two are different, the adapter component will be automatically started when the target cloud computer is turned on; wherein the adapter component is used to initialize the service and personalize the target cloud computer.

7. A cloud computer migration device, characterized in that: The device comprises: A determination module, used to determine whether the source host supports migration to the target cloud computer, and if so, lock the target cloud computer and control the target cloud computer to enter a rescue mode; A backup module, used to back up the system boot file of the target cloud computer and generate a system snapshot of the source host; A first adaptation module, configured to transmit the system snapshot to the target cloud computer, and perform preliminary adaptation between the source host and the target cloud computer based on the system type of the source host; A restoration module, used to restore the system boot file and exit the rescue mode if the initial adaptation is successful; The second adaptation module is used to perform secondary adaptation on the source host and the target cloud computer, complete the current migration when the secondary adaptation is successful, and unlock the target cloud computer.

8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 6 are implemented.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.

10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.