A cross-platform migration method and device for virtual machine image data

By creating an empty disk on the target virtualization platform and performing format conversion and exception handling, the problem of cross-platform migration of virtual machine image data is solved, achieving efficient data migration and multi-format compatibility, and avoiding additional storage requirements.

CN116774915BActive Publication Date: 2026-04-17FUJIAN CENTM INFORMATION
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
FUJIAN CENTM INFORMATION
Filing Date
2022-09-29
Publication Date
2026-04-17

AI Technical Summary

Technical Problem

Existing technologies cannot effectively achieve cross-platform migration of virtual machine image data between different virtualization platforms, especially when storage formats are incompatible, and additional intermediate or temporary storage is required.

Method used

By creating an empty mirror disk on the target virtualization platform, the mirror data of the source virtualization platform is transmitted via network streaming. Format conversion and exception handling are performed during transmission. An asynchronous approach is used to ensure compatibility with different storage formats, and upload and download speeds are monitored to avoid excessive memory resource consumption.

Benefits of technology

It enables efficient migration of virtual machine image data between different virtualization platforms, is compatible with multiple storage formats, requires no intermediate storage, and improves data migration efficiency and resource utilization.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116774915B_ABST
    Figure CN116774915B_ABST
Patent Text Reader

Abstract

This invention provides a cross-platform migration method and apparatus for virtual machine image data. It uses a streaming approach to transmit data and uses different interface call parameters during the upload and download processes to shield the differences in the underlying storage implementation. This enables compatibility with various data storage formats supported by the virtualization platform and various commonly used data formats. It eliminates the need for intermediate storage or additional temporary storage, achieving a function similar to IO stream forwarding, efficiently migrating data, and requiring only a small memory cache.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of computer technology, and in particular to a method and apparatus for migrating virtual machine image data across different virtualization platforms. Background Technology

[0002] Virtualization technology is a resource management technology that abstracts and transforms hardware devices such as servers, memory, networks, and storage, breaking down barriers between hardware and enabling users to more rationally and fully control and manage various resources.

[0003] A virtualization platform provides the computing, networking, storage, and security infrastructure required by a data center in the form of virtualization. The virtualization platform creates virtual machines based on images, resulting in a system environment consistent with the image, which is then provided to users. An image refers to a template that can run on a hyperconverged platform, typically including an operating system and pre-installed software. Image data is highly valuable data for a virtualization platform.

[0004] Virtualization platforms use various data storage formats, and virtualization platform image data, along with other data, can reside in different types of storage. Data in storage cannot be written to multiple times, otherwise data corruption will occur. Different virtualization platforms typically cannot share storage; even if sharing is possible and multiple reads are allowed, multiple writes are not, otherwise data anomalies will result. Therefore, image data cannot be directly shared across different virtualization platforms. However, in large-scale production environments, there are usually multiple virtualization platform environments, leading to frequent data migration issues between virtualization platforms, typically image data migration.

[0005] In addition, virtualization platforms may interface with and use different storage systems, and the storage for image data on different platforms may vary. Therefore, it is necessary to consider how to ensure compatibility with different storage systems. Summary of the Invention

[0006] The technical problem to be solved by the present invention is to provide a cross-platform migration method and apparatus for virtual machine image data, which does not require additional intermediate or temporary storage and is compatible with multiple types and formats of data storage.

[0007] In a first aspect, the present invention provides a method for cross-platform migration of virtual machine image data. An empty image disk is created on the target virtualization platform through an interface, and the image data of the source virtualization platform is transmitted to the image disk of the target virtualization platform in a streaming manner through the network based on the upload and download functions provided by the virtualization platform.

[0008] Furthermore, if the image data storage format of the source virtualization platform is different from that of the target virtualization platform, the image data of the source virtualization platform will be converted according to the storage format requirements of the target virtualization platform when responding to the data download request, generating converted image data, and then the converted image data will be deleted after the transmission is completed.

[0009] Furthermore, management and scheduling are performed during cross-platform migration. Based on the upload and download functions of the virtualization platform, the interface of the target virtualization platform is connected to shield the differences between underlying storage systems. Data migration is achieved by scheduling the upload and download function interfaces. Different interface call parameters are used to ensure compatibility with storage systems of different data formats and to handle abnormal situations.

[0010] Furthermore, the abnormal situations include situations where the upload speed and download speed are out of sync, resulting in excessive memory resource consumption;

[0011] The handling of the abnormal situation is as follows: monitor the download speed and upload speed. When the download speed exceeds the upload speed threshold, pause the download and wait for coordination until the download speed and upload speed are basically synchronized before resuming the download. Conversely, when the upload speed exceeds the download speed threshold, pause the upload and wait for coordination until the upload speed and download speed are basically synchronized before resuming the upload. This continues until the data migration is complete.

[0012] Furthermore, data migration is performed asynchronously, downloading data chunks from the source virtualization platform image while simultaneously uploading the data chunks to the target virtualization platform.

[0013] Furthermore, before data transmission, the data status of the source virtualization platform and the image is verified to ensure that the image data is not currently in use and is locked.

[0014] Furthermore, the cross-platform migration method for virtual machine image data of the present invention specifically includes the following steps:

[0015] Step 1: Verify the status of the target virtualization platform and storage, and verify the data status of the source virtualization platform and image to ensure that the image data is not currently in use and lock it;

[0016] Step 2: Create a migration task. Based on the storage format of the target virtualization platform, call the format conversion function to convert the image data storage format that needs to be migrated from the source virtualization platform to the corresponding storage format of the target virtualization platform. At the same time, call the interface to create an empty image disk on the target virtualization platform.

[0017] Step 3: Start the data migration task;

[0018] Step 4: Perform data migration asynchronously by connecting to the upload and download function interface of the target virtualization platform. Download the corresponding data blocks on one side and upload the data blocks to the target virtualization platform on the other. By calling different interface parameters, the differences in the underlying storage implementation are masked, and the storage is compatible with different data formats.

[0019] Simultaneously address the potential issue of excessive memory resource consumption due to speed discrepancies between the two parties. Monitor download and upload speeds; when the download speed exceeds the upload speed threshold, pause download and wait for coordination until the download and upload speeds are basically synchronized before resuming download; conversely, when the upload speed exceeds the download speed threshold, pause upload and wait for coordination until the upload and download speeds are basically synchronized before resuming upload; until data migration is complete.

[0020] Step 5: After the migration is complete, delete the conversion image data generated by the source virtualization platform, and notify the target virtualization platform that the data transfer is complete, and unlock the image data of the source virtualization platform.

[0021] Furthermore, both the source virtualization platform and the target virtualization platform are virtualization cluster platforms.

[0022] In a second aspect, the present invention provides a cross-platform migration apparatus for virtual machine image data, used to perform the method described in the first aspect.

[0023] The one or more technical solutions provided in the embodiments of this invention have at least the following technical effects or advantages: This invention enables cross-platform migration of mirror data on a virtualization platform. Data is transmitted in a streaming manner, and the differences in underlying storage implementation are masked by the data stream during upload and download, thereby achieving compatibility with various data storage formats supported by the virtualization platform and various commonly used data formats. No intermediate storage or additional temporary storage is required, achieving a function similar to IO stream forwarding, efficiently migrating data, and requiring only a small memory cache.

[0024] The above description is merely an overview of the technical solution of the present invention. In order to better understand the technical means of the present invention and to implement it in accordance with the contents of the specification, and to make the above and other objects, features and advantages of the present invention more apparent and understandable, specific embodiments of the present invention are described below. Attached Figure Description

[0025] The present invention will be further described below with reference to the accompanying drawings and embodiments.

[0026] Figure 1 This is a schematic diagram of the system framework corresponding to the present invention;

[0027] Figure 2 This is a flowchart of the method in Embodiment 1 of the present invention;

[0028] Figure 3 This is a schematic diagram of the device in Embodiment 2 of the present invention. Detailed Implementation

[0029] This application provides a cross-platform migration method and apparatus for virtual machine image data, which does not require additional intermediate or temporary storage and is compatible with various types and formats of data storage.

[0030] The overall concept of the technical solution in this application is as follows: This invention enables cross-platform migration of image data on a virtualization platform. Data is transmitted via streaming. During the upload and download processes, different interface call parameters are used to shield the differences in the underlying storage implementation, thereby achieving compatibility with various data storage formats supported by the virtualization platform and various commonly used data formats. No intermediate storage or additional temporary storage is required, achieving a function similar to IO stream forwarding, and efficiently performing data migration.

[0031] Before introducing specific embodiments, the system framework corresponding to the method in the embodiments of this application will be introduced first, such as... Figure 1 As shown, the system can be roughly divided into:

[0032] The source virtualization platform contains the image data that needs to be migrated. This source virtualization platform can be a virtualization cluster platform.

[0033] The target virtualization platform is used to receive the image data migrated from the source virtualization platform. Similarly, the source virtualization platform can also be a virtualization cluster platform.

[0034] The source virtualization platform includes:

[0035] The format conversion module is used to convert the image data to be migrated according to the storage format requirements of the target platform and respond to data download requests.

[0036] The data migration module is used to manage and schedule data migration across virtualization platforms. Based on the upload and download functions of the virtualization platform, it interfaces with the target virtualization platform, shields the differences between underlying storage systems, and realizes data migration by scheduling upload and download interfaces. It can call parameters through different interfaces to be compatible with different storage systems and handle abnormal situations.

[0037] Example 1

[0038] like Figure 2As shown, this embodiment provides a cross-platform migration method for virtual machine image data. The overall process is as follows: create an empty image disk on the target virtualization platform through an interface, and based on the upload and download functions provided by the virtualization platform, transmit the image data of the source virtualization platform to the image disk of the target virtualization platform in a streaming manner through the network.

[0039] If the image data storage format of the source virtualization platform is different from that of the target virtualization platform, the image data of the source virtualization platform will be converted according to the storage format requirements of the target virtualization platform when responding to the data download request, generating converted image data, and then the converted image data will be deleted after the transmission is completed.

[0040] During cross-platform migration, management and scheduling are also performed. Based on the upload and download functions of the virtualization platform, the interface of the target virtualization platform is connected to shield the differences between underlying storage systems. Data migration is achieved by scheduling the upload and download function interfaces. Different interface call parameters are used to ensure compatibility with storage systems of different data formats and to handle abnormal situations.

[0041] The abnormal situations mentioned include situations where upload speed and download speed are out of sync, resulting in excessive memory resource consumption.

[0042] The handling of the abnormal situation is as follows: monitor the download speed and upload speed. When the download speed exceeds the upload speed threshold, pause the download and wait for coordination until the download speed and upload speed are basically synchronized before resuming the download. Conversely, when the upload speed exceeds the download speed threshold, pause the upload and wait for coordination until the upload speed and download speed are basically synchronized before resuming the upload. This continues until the data migration is complete.

[0043] Data migration is performed asynchronously, downloading data chunks from the source virtualization platform image while simultaneously uploading the data chunks to the target virtualization platform.

[0044] Before data transfer, the data status of the source virtualization platform and the image is verified to ensure that the image data is not currently in use and is locked.

[0045] The cross-platform migration method for virtual machine image data of the present invention specifically includes the following steps:

[0046] Step 1: Verify the status of the target virtualization platform and storage, and verify the data status of the source virtualization platform and image to ensure that the image data is not currently in use and lock it.

[0047] Step 2: Create a migration task. Based on the storage format of the target virtualization platform, call the format conversion function to convert the image data storage format that needs to be migrated from the source virtualization platform to the corresponding storage format of the target virtualization platform. At the same time, call the interface to create an empty image disk on the target virtualization platform.

[0048] Image data can be stored in various formats, including raw, qcow, and VMDK. Different platforms may have different storage formats and implementations. Therefore, by using a format conversion function to convert the data to the format corresponding to the target virtualization platform before uploading, compatibility with these data storage format differences can be achieved. This not only supports images of the same type of storage across virtualization clusters but also easily supports images of different types of storage across clusters.

[0049] Step 3: Start the data migration task.

[0050] Step 4: Perform data migration asynchronously by connecting to the upload and download function interface of the target virtualization platform. Download the corresponding data blocks on one side and upload the data blocks to the target virtualization platform on the other. Use different interface call parameters to shield the differences in the underlying storage implementation and ensure compatibility with storage of different data formats.

[0051] Data on virtualization platforms is typically stored on dedicated storage. Generally, virtualization platforms do not allow direct external access to their storage. This application addresses this by interfacing two virtualization platforms, masking the differences in storage implementations, and translating these differences into differences in platform interface implementations. A data format conversion module ensures compatibility across different storage types.

[0052] While migrating data, the system addresses potential issues such as speed discrepancies between the two sides, which can lead to excessive memory consumption. It monitors download and upload speeds; if the download speed exceeds the upload speed threshold, downloading is paused pending coordination until the download and upload speeds are essentially synchronized before resuming. Conversely, if the upload speed exceeds the download speed threshold, uploading is paused pending coordination until the upload and download speeds are essentially synchronized before resuming. This process continues until the data migration is complete.

[0053] Step 5: After the migration is complete, delete the conversion image data generated by the source virtualization platform, and notify the target virtualization platform that the data transfer is complete, and unlock the image data of the source virtualization platform.

[0054] Both the source virtualization platform and the target virtualization platform can be virtualization cluster platforms.

[0055] Based on the same inventive concept, this application also provides an apparatus corresponding to the method in Embodiment 1, as detailed in Embodiment 2.

[0056] Example 2

[0057] This embodiment provides a cross-platform migration device for virtual machine image data, used to execute the method described in Embodiment 1.

[0058] Specifically, such as Figure 3 As shown, it includes:

[0059] The format conversion module is used to convert the image data to be migrated according to the storage format requirements of the target platform and respond to data download requests.

[0060] The data migration module is used to manage and schedule data migration across virtualization platforms. Based on the upload and download functions of the virtualization platform, it interfaces with the target virtualization platform, shields the differences between underlying storage systems, and realizes data migration by scheduling upload and download interfaces. It can call parameters through different interfaces to be compatible with different storage systems and handle abnormal situations.

[0061] Since the apparatus described in Embodiment 2 of this invention is the same apparatus used to implement the method of Embodiment 1 of this invention, all methods described in Embodiment 1 of this invention can be executed by the apparatus of Embodiment 2. Furthermore, those skilled in the art will understand the specific structure and variations of this apparatus, and therefore will not be described in detail here. All apparatuses used in the method of Embodiment 1 of this invention fall within the scope of protection of this invention.

[0062] The technical solution provided in this application embodiment has at least the following technical effects or advantages: This invention enables cross-platform migration of mirror data on a virtualization platform. It uses a streaming method to transmit data, shielding the differences in underlying storage implementation through data stream uploads and downloads. This allows for compatibility with various data storage formats supported by the virtualization platform, as well as various commonly used data formats. No intermediate storage or additional temporary storage is required, achieving a function similar to IO stream forwarding, and enabling efficient data migration.

[0063] While specific embodiments of the present invention have been described above, those skilled in the art should understand that the specific embodiments described are merely illustrative and not intended to limit the scope of the present invention. Equivalent modifications and variations made by those skilled in the art in accordance with the spirit of the present invention should be covered within the scope of protection of the claims of the present invention.

Claims

1. A cross-platform migration method of virtual machine image data, characterized by: An empty image disk is created on the target virtualization platform through the interface. Based on the upload and download functions provided by the virtualization platform, the image data of the source virtualization platform is transmitted to the image disk of the target virtualization platform in a streaming manner over the network, without the need for intermediate storage or additional temporary storage. Specifically, the steps include the following: Step 1: Verify the status of the target virtualization platform and storage, and verify the data status of the source virtualization platform and image to ensure that the image data is not currently in use and lock it; Step 2: Create a data migration task. Based on the storage format of the target virtualization platform, call the format conversion function to convert the image data storage format that needs to be migrated from the source virtualization platform to the corresponding storage format of the target virtualization platform. At the same time, call the interface to create an empty image disk on the target virtualization platform. Step 3: Start the data migration task; Step 4: Perform data migration asynchronously by connecting to the upload and download function interface of the target virtualization platform. Download the corresponding data blocks on one side and upload the data blocks to the target virtualization platform on the other. By calling different interface parameters, the differences in the underlying storage implementation are masked, and the storage is compatible with different data formats. Simultaneously address the potential issue of excessive memory resource consumption due to speed discrepancies between the two parties. Monitor download and upload speeds; when the download speed exceeds the upload speed threshold, pause download and wait for coordination until the download and upload speeds are basically synchronized before resuming download; conversely, when the upload speed exceeds the download speed threshold, pause upload and wait for coordination until the upload and download speeds are basically synchronized before resuming upload; until data migration is complete. Step 5: After the migration is complete, delete the conversion image data generated by the source virtualization platform, and notify the target virtualization platform that the data transfer is complete, and unlock the image data of the source virtualization platform.

2. The cross-platform migration method for virtual machine image data according to claim 1, characterized in that: If the image data storage format of the source virtualization platform is different from that of the target virtualization platform, the image data of the source virtualization platform will be converted according to the storage format requirements of the target virtualization platform when responding to the data download request, generating converted image data, and then the converted image data will be deleted after the transmission is completed.

3. The cross-platform migration method for virtual machine image data according to claim 1, characterized in that: During cross-platform migration, management and scheduling are also performed. Based on the upload and download functions of the virtualization platform, the interface of the target virtualization platform is connected to shield the differences between the underlying storage systems. Data migration is achieved by scheduling the upload and download function interfaces. Different interface call parameters are used to ensure compatibility with storage systems of different data formats and to handle abnormal situations.

4. The cross-platform migration method for virtual machine image data according to claim 1, characterized in that: Both the source virtualization platform and the target virtualization platform are virtualization cluster platforms.

5. A cross-platform migration device for virtual machine image data, characterized in that: Used to perform the method as described in any one of claims 1 to 4.

Citation Information

Patent Citations

  • Local storage-based virtual machine migration method and system

    CN107168774A

  • Automatic virtual machine migration method and system for heterogeneous virtualization platform

    CN114090173A