CN115268950A - Mirror image file importing method and device - Google Patents

Mirror image file importing method and device Download PDF

Info

Publication number
CN115268950A
CN115268950A CN202210867984.8A CN202210867984A CN115268950A CN 115268950 A CN115268950 A CN 115268950A CN 202210867984 A CN202210867984 A CN 202210867984A CN 115268950 A CN115268950 A CN 115268950A
Authority
CN
China
Prior art keywords
image file
format
resource pool
storage resource
cloud platform
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210867984.8A
Other languages
Chinese (zh)
Inventor
刘苏
汪银
曹磊
张玉
鞠娜
张武
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tianyi Cloud Technology Co Ltd
Original Assignee
Tianyi Cloud Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tianyi Cloud Technology Co Ltd filed Critical Tianyi Cloud Technology Co Ltd
Priority to CN202210867984.8A priority Critical patent/CN115268950A/en
Publication of CN115268950A publication Critical patent/CN115268950A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/61Installation
    • G06F8/63Image based installation; Cloning; Build to order
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5011Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals
    • G06F9/5016Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals the resource being the memory
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • G06F2009/45583Memory management, e.g. access or allocation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • G06F2009/45595Network integration; Enabling network access in virtual machine instances
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/50Indexing scheme relating to G06F9/50
    • G06F2209/5011Pool

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The application discloses a method and a device for importing mirror image files, wherein the method comprises the following steps: acquiring a mirror image file and format information of the mirror image file; storing the mirror image file to an object storage resource pool of the cloud platform; determining the format of the image file to belong to the image file format allowing the import of the block storage resource pool according to the format information of the image file; and importing the mirror image file from the object storage resource pool into a block storage resource pool of the cloud platform. The method can support a user to import the mirror image files in various formats, and improve the flexibility of obtaining the mirror image files.

Description

Mirror image file importing method and device
Technical Field
The embodiment of the application relates to the field of cloud platforms, in particular to a method and a device for importing an image file.
Background
The mirror image management service comprises a mirror image template used for managing and opening the virtual machine, and specifically comprises a public mirror image and a private mirror image. When a user needs to import and use an image file from other cloud platforms, the existing image management service cannot support the user to import the image file from other cloud platforms to the cloud platform used by the user.
Therefore, the mirror image file can only be generated on the cloud platform by the user, but the mirror image file cannot be imported into the cloud platform, and the problem of single mirror image file acquisition mode exists.
Disclosure of Invention
The embodiment of the application provides a method and a device for importing an image file, and the importing method can reduce space resources required by storage of a physical machine where an image management component is located, and improve flexibility of obtaining the image file.
In a first aspect, an image file importing method provided in an embodiment of the present application includes:
acquiring a mirror image file and format information of the mirror image file; storing the mirror image file to an object storage resource pool of a cloud platform; determining the format of the image file to belong to the image file format allowing the import of the block storage resource pool according to the format information of the image file; and importing the image file from the object storage resource pool into a block storage resource pool of the cloud platform, wherein the image file is used for opening a virtual machine in the block storage resource pool of the cloud platform.
According to the method, a user can be supported to import the image files in various formats according to the image management service of the cloud platform. The method solves the problem that the existing mirror image management service can not support the user to import the mirror image file from other cloud platforms, and improves the flexibility of obtaining the mirror image file.
In one possible design, the image file is generated on a kvm cloud platform, a vmware cloud platform, or a hyper v cloud platform. The format of the image file allowing the import of the block storage resource pool is raw format, qcow2 format, vhd format or vhdx format.
According to the design, the method can support the acquisition of the image files in various formats from various cloud platforms, and further improve the flexibility of acquiring the image files.
In one possible design, the method further includes: after the image file is stored in an object storage resource pool of a cloud platform, a storage address corresponding to the image file is obtained; the importing the image file from the object storage resource pool to the block storage resource pool of the cloud platform includes: and according to the storage address, the image file is imported into a block storage resource pool of the cloud platform from the object storage resource pool.
According to the design, the image file can be accurately obtained from the object storage resource pool according to the storage address, and the image file importing efficiency is improved.
In one possible design, the format information of the image file is used to indicate that the format of the image file is a first format, where the first format is different from a second format, and the second format is a format of an image file supported by the cloud platform, where the method further includes: modifying the format of the image file into the second format; the first format and the second format belong to the image file format of the storage resource pool of the allowable import block.
According to the design, the cloud platform can be further supported to acquire the image files in various formats, and the flexibility of acquiring the image files is further improved.
In a second aspect, an image file importing apparatus provided in an embodiment of the present application includes:
the storage module is used for acquiring the image file and the format information of the image file;
the storage module is further used for storing the mirror image file to an object storage resource pool of a cloud platform;
the determining module is used for determining that the format of the image file belongs to the image file format of the storage resource pool of the import permitted block according to the format information of the image file;
and the import module is used for importing the mirror image file from the object storage resource pool into a block storage resource pool of the cloud platform.
In one possible design, the image file is generated on a kvm cloud platform, a vmware cloud platform, or a hyper v cloud platform; the image file format allowing the import of the block storage resource pool is a raw format, a qcow2 format, a vhd format or a vhdx format.
In one possible design, the memory module is further configured to:
after the image file is stored in an object storage resource pool of a cloud platform, a storage address corresponding to the image file is obtained; the import module is specifically configured to: and according to the storage address, the image file is imported into a block storage resource pool of the cloud platform from the object storage resource pool.
In one possible design, the format information of the image file is used to indicate that the format of the image file is a first format, where the first format is different from a second format, and the second format is a format of the image file supported by the cloud platform, and the import module is further configured to: modifying the format of the mirror image file into the second format; the first format and the second format belong to the mirror image file format of the storage resource pool of the import permission block.
In a third aspect, an embodiment of the present application further provides a computer-readable storage medium, where a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the computer program implements the first aspect and the method designed by any one of the aspects.
In a fourth aspect, an embodiment of the present application further provides an electronic device, which includes a memory and a processor, where the memory stores a computer program that is executable on the processor, and when the computer program is executed by the processor, the processor is caused to implement the method of the first aspect or any design thereof.
The technical effects of the second to fourth aspects and any design thereof can be referred to the technical effects of the corresponding design in the first aspect, and are not described herein again.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a schematic flowchart of an image file importing method according to an embodiment of the present disclosure;
fig. 2 is a schematic diagram of a total import task flow of an image file import method according to an embodiment of the present application;
fig. 3 is a schematic diagram of an import subtask flow of an image file import method according to an embodiment of the present application;
fig. 4 is a schematic structural diagram of an apparatus according to an embodiment of the present disclosure;
fig. 5 is a schematic structural diagram of another apparatus provided in the embodiment of the present application.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the present application more apparent, the present application will be described in alternative detail with reference to the accompanying drawings, and it is to be understood that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments obtained by a person of ordinary skill in the art based on the embodiments in the present application without making any creative effort belong to the protection scope of the present application. It should be understood that the specific methods of operation in the method embodiments described below may also be applied to either the apparatus embodiments or the system embodiments.
The existing mirror image management service comprises mirror image files for managing and opening the virtual machine, and specifically comprises public mirror image files and private mirror image files. The public mirror image file refers to a mirror image file generated in the current cloud platform. For example, the public image may be an operating system template. The public mirror image can be used for unspecified users and can be used for opening the virtual machine according to the user requirements. Correspondingly, the private image file refers to an image file generated in a platform other than the current cloud platform. When a user needs to import a private image file into a cloud platform and open a virtual machine according to the private image file, the existing image management service cannot support the user to import the image file from other cloud platforms, and only the user can recreate the image file on the current cloud platform. For example, the private images may include private images imported from other cloud platforms and/or private images generated from public images. The private image may be targeted for partial users or for use by a single user.
Unless otherwise specified below, an image file in this application refers to a private image file.
In order to solve the above problems, the present application provides an image file importing method, which is used for meeting the requirement of a user for importing an image file on a cloud platform and improving the flexibility of obtaining the image file.
In the embodiment of the application, an image file and format information of the image file are obtained. And storing the mirror image file to an object storage resource pool of the cloud platform. And determining the format of the image file to belong to the image file format allowing the import of the block storage resource pool according to the format information of the image file. And importing the image file from the object storage resource pool into a block storage resource pool of the cloud platform, wherein the image file can be used for opening a virtual machine in the block storage resource pool of the cloud platform. The method can meet the requirement of a user for importing the image file of the cloud platform, and improves the flexibility of obtaining the image file.
It is understood that an image file importing method provided by the present application may be executed by an image file importing apparatus (hereinafter, referred to as an importing apparatus). For example, the apparatus may be a device or a component in a device used by a user to access the cloud platform, or may be a device (e.g., a cloud platform server) or a component in a device capable of communicating with the device. For example, the device may be a server, a processor, a chip, a smart terminal, or other device with data analysis and processing capabilities.
As shown in fig. 1, the importing method provided in the embodiment of the present application includes the specific steps of:
step 101, obtaining an image file and format information of the image file.
Optionally, step 101 includes: a user can import the mirror image file to the import device through a front-end operating system of the cloud platform. Accordingly, the importing device can obtain the image file through the front-end operating system. And acquiring the image file from the cloud platform for generating the image file or the storage equipment for storing the image file, and extracting format information of the image file according to the image file.
Illustratively, the front-end operating system may comprise a yacos system. Therefore, the user can operate the yacos system, select the image file to be imported, and accordingly, the yacos system can extract the format information of the image file.
Illustratively, the cloud platform generating the image file may include a kvm platform, a vmware platform, a hyperv platform, or the like. The kvm platform is a cloud platform supporting full virtualization, the vmware platform is a cloud platform providing server and/or desktop virtualization, and the hyperv platform is a cloud platform providing hardware virtualization. For example, the importing device acquires an image file generated on the kvm cloud platform from the kvm platform. Specifically, the cloud platform includes: the front-end operating system is used for acquiring an image file and format information of the image file.
The storage device for storing the image file may specifically be a storage medium such as a hard disk, or may also be a device including the storage medium, such as a device used by a user to access a cloud platform, which is not specifically limited.
Illustratively, the format information of the image file may include a raw image file format, a qcow2 image file format, a vhd image file format, a vhdx image file format, or a vmdk image file format. The format of the raw mirror image file is an image mirror image file format, the format of the qcow2 mirror image file is a disk mirror image file format, the format of the vhd mirror image file is a disk mirror image file format, the format of the vhdx mirror image file is a disk mirror image file format, and the format of the vmdk mirror image file is a disk mirror image file format.
It is to be understood that the source of the image file is not limited in this application.
And 102, storing the mirror image file to an object storage resource pool of the cloud platform.
The object storage resource pool may be a storage resource pool for storing files in a cloud platform resource pool. The object storage resource pool only has the function of storing files and does not have the function of processing files. The functions of storing files in the object storage resource pool include: and storing the storage file to a storage bucket in any object storage resource pool, and providing a storage address corresponding to the storage file in the storage bucket according to the storage.
In addition, the cloud platform resource pool may further include a block storage resource pool, as distinguished from the object storage resource pool. It is understood that the object storage resource pool and the block storage resource pool are different storage areas in the cloud platform resource pool. The block resource storage pool may be a pool that provides storage functionality and may partition the storage area for individual use by the virtual machines. The files imported to the cloud platform by the user are generally stored in the object storage resource pool. The image file generally needs to be stored in a block storage resource pool, and a virtual machine is implemented in the block storage resource pool. For example, the pool of block storage resources may be used to create a cloud hard disk (including system disks and data disks) that may be used to open virtual machine resources and/or mount onto a virtual machine for use.
Optionally, the importing apparatus may store the image file in a bucket of the object storage resource pool, and obtain a storage address corresponding to the image file. Further optionally, the device may also present the corresponding storage address of the image file to the user via the front-end operating system. For example, the storage address is Uniform Resource code (URL). A URL may be used to indicate the bucket address and/or the storage file address.
And 103, determining that the format of the image file belongs to the image file format allowing the import of the block storage resource pool according to the format information of the image file.
Optionally, the importing device may create a database entry corresponding to the image file in the cloud platform according to an image management component in the cloud platform. The image management component can be a cloud platform service component for executing image file import. For example, the import apparatus executes a _ CreateImage command through the image management component for creating a database entry in the cloud platform.
For example, in step 103, the importing apparatus may extract format information of the image file according to a storage address corresponding to the image file.
Optionally, the importing device may call a command in the image management component to view format information of the image file. For example, the import apparatus may view format information of the image file through a qemu-img info command.
Optionally, the importing apparatus determines the image file allowed to be imported according to the image file format of the storage resource pool of the import-allowed block.
The image file format of the storage resource pool of the import permission block can be stored as a list, so that the import device can determine whether the format of the image file to be imported belongs to the format of the image file of which the import permission is allowed according to the format information of the image file to be imported, and avoid the import format error or the image file with the format which is not supported by the cloud platform. For example, the formats of the image files allowed to be imported include a raw format, a qcow2 format, a vhd format, a vhdx format, and a vmdk format, and the format of the image file to be imported is a raw format, and then the format of the image file to be imported belongs to the format of the image file allowed to be imported in the format, and the importing apparatus may determine that the image file is allowed to be imported.
Alternatively, the image file format (or the list) allowing the import block storage resource pool may be preset. For example, the configuration may be internal configuration of the cloud platform, and may be set or updated by the cloud platform operation and maintenance personnel, which is not specifically required in the present application.
Alternatively, if the importing apparatus determines that the image file is not allowed to be imported according to the image file format list of the storage resource pool of the import-allowed block, for example, the format of the image file does not belong to the image file format of the storage resource pool of the import block, the importing apparatus may delete the database entry created before.
The implementation of step 103 is illustrated here by way of example. In step 103, the importing apparatus may extract an image file corresponding to the URL from the bucket according to the URL storage address. If the importing device determines that the image file is in a qcow2 format, and determines that the qcow2 format belongs to the image file format of the storage resource pool of the import permission block according to the image file format list of the storage resource pool of the import permission block, the importing device may determine that the image file is an image file allowed to be imported.
And 104, importing the image file from the object storage resource pool into a block storage resource pool of the cloud platform, wherein the image file is used for opening a virtual machine in the block storage resource pool of the cloud platform.
Optionally, the importing device may convert the format of the image file to be imported, and then import the image file after the format conversion into the block storage resource pool, or import the image file to be imported into the block storage resource pool and then perform the format conversion.
For example, the format of the image file to be imported is a first format, that is, the format information of the image file indicates that the format is the first format, the format of the converted image file is recorded as a second format, and the second format may be a format of the image file supported by the cloud platform. For example, the format of the image file generated at the current cloud platform is the second format. It is understood that the first format and the second format both belong to an image file format that allows importing the block storage resource pool.
For example, the first format is a qcow2 format, the second format is a raw format, and the image file format allowing the import of the block storage resource pool includes a raw format, a qcow2 format, a vhd format, a vhdx format, and a vmdk format, and then the import device may convert the format of the image file into a raw format and import the image file into the block storage resource pool.
Optionally, when performing format conversion, the importing apparatus may call a qemu-img convert command through an image management component, and convert the image file in the first format into the image file in the second format.
Furthermore, if the first format is the same as the second format, the importing means may import the image file into the block storage resource pool without performing format conversion.
For example, as shown in fig. 2, a user may start an image file import process through a front-end management system, and upload an image file to an object storage resource pool in a resource pool of a cloud platform. In the image file importing process, the importing apparatus imports the image file in the object storage resource pool into the block storage resource pool through the image management component, so as to implement the above steps 101 to 104.
For example, as shown in fig. 3, the importing apparatus may call at least one of a _ CreateImage command, a _ impottostore command, and a qemu-img convert command, a _ SaveImage command, and a _ completettask command through the image management component to implement the above steps 103 to 104, which may be referred to as an image import sub-task flow.
Based on the flow shown in fig. 2, the embodiment of the application provides an image file importing method, which can improve flexibility of an image file obtaining manner to meet user requirements.
In addition, in the importing process, a file stream mode is adopted, the mirror image file in the object storage is imported into a block storage pool of the cloud platform by using tools such as qemu-img and the like, and the storage space resource of a physical machine where the mirror image management component is located cannot be occupied.
Based on the same technical concept, the present application exemplarily provides an architecture diagram of an image file importing apparatus, as shown in fig. 4, the apparatus includes:
the storage module 401 is configured to obtain an image file and format information of the image file;
the storage module 401 is further configured to store the image file to an object storage resource pool of a cloud platform;
a determining module 402, configured to determine, according to the format information of the image file, that the format of the image file belongs to an image file format that allows an import block storage resource pool;
an importing module 403, configured to import the image file from the object storage resource pool to a block storage resource pool of the cloud platform.
Optionally, the storage module 401 is further configured to obtain a storage address corresponding to the image file after the image file is stored in an object storage resource pool of a cloud platform;
the importing module 403 is specifically configured to import the image file from the object storage resource pool to a block storage resource pool of the cloud platform according to the storage address.
Optionally, the format information of the image file is used to indicate that the format of the image file is a first format, where the first format is different from a second format, and the second format is a format of the image file supported by the cloud platform, and the import module 403 is further configured to:
modifying the format of the image file into the second format;
the first format and the second format belong to the image file format of the storage resource pool of the allowable import block.
The electronic equipment is based on the same inventive concept as the method embodiment, and the embodiment of the application also provides the electronic equipment. The electronic device may be configured to perform the actions described in the above method embodiments. In this embodiment, the structure of the electronic device may be as shown in fig. 5, including a memory 501 and one or more processors 502.
A memory 501 for storing computer programs executed by the processor 502. The memory 501 may mainly include a program storage area and a data storage area, where the program storage area may store an operating system, programs needed for running an instant messaging function, and the like; the storage data area can store various instant messaging information, operation instruction sets and the like.
The memory 501 may be a volatile memory (volatile memory), such as a random-access memory (RAM); the memory 501 may also be a non-volatile memory (non-volatile memory) such as, but not limited to, a read-only memory (rom), a flash memory (flash memory), a Hard Disk Drive (HDD) or a solid-state drive (SSD), or the memory 801 may be any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer. The memory 501 may be a combination of the above memories.
The processor 502 may include one or more Central Processing Units (CPUs), or be a digital processing unit, etc. A processor 502 for implementing the above method when invoking a computer program stored in the memory 501.
The specific connection medium between the memory 501 and the processor 502 is not limited in the embodiments of the present application. As an example, in fig. 5, the memory 501 and the processor 502 are connected by a bus 503, the bus 503 is represented by a thick line in fig. 5, and the connection manner between other components is merely illustrative and is not limited. The bus 503 may be divided into an address bus, a data bus, a control bus, and the like. For ease of illustration, only one thick line is shown in FIG. 5, but this is not intended to represent only one bus or type of bus.
Optionally, the processor 502 may be configured to perform the actions performed by any one or more of the storage module 401, the determination module 402, and the import module 403.
According to an aspect of the application, there is provided a computer program product or computer program comprising computer instructions stored in a computer readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions to cause the computer device to perform the method in the above-described embodiment.
The program product may employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the readable storage medium include: an electrical connection having one or more wires, a portable disk, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
The above description is only for the specific embodiments of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present application, and shall be covered by the scope of the present application.

Claims (10)

1. An image file importing method is characterized by comprising the following steps:
acquiring a mirror image file and format information of the mirror image file;
storing the mirror image file to an object storage resource pool of a cloud platform;
determining the format of the image file to belong to the image file format allowing the import of the block storage resource pool according to the format information of the image file;
and importing the image file from the object storage resource pool into a block storage resource pool of the cloud platform, wherein the image file is used for opening a virtual machine in the block storage resource pool of the cloud platform.
2. The method of claim 1, wherein the image file is generated on a kvm cloud platform, a vmware cloud platform, or a hyperv cloud platform;
the image file format allowing the import of the block storage resource pool is a raw format, a qcow2 format, a vhd format or a vhdx format.
3. The method of claim 1, wherein the method further comprises:
after the image file is stored in an object storage resource pool of a cloud platform, a storage address corresponding to the image file is obtained;
the importing the image file from the object storage resource pool to the block storage resource pool of the cloud platform includes:
and according to the storage address, the mirror image file is imported into a block storage resource pool of the cloud platform from the object storage resource pool.
4. The method of claim 1, wherein the format information of the image file is used to indicate that the format of the image file is a first format, the first format being different from a second format, the second format being a format of the image file supported by the cloud platform, the method further comprising:
modifying the format of the image file into the second format;
the first format and the second format belong to the mirror image file format of the storage resource pool of the import permission block.
5. An image file importing apparatus, comprising:
the storage module is used for acquiring the image file and the format information of the image file;
the storage module is further used for storing the mirror image file to an object storage resource pool of a cloud platform;
the determining module is used for determining that the format of the image file belongs to the image file format of the storage resource pool of the import block according to the format information of the image file;
and the import module is used for importing the mirror image file from the object storage resource pool into a block storage resource pool of the cloud platform.
6. The apparatus of claim 5, wherein the image file is generated at a kvm cloud platform, a vmware cloud platform, or a hyper v cloud platform;
the image file format allowing the import of the block storage resource pool is a raw format, a qcow2 format, a vhd format or a vhdx format.
7. The apparatus of claim 6, wherein the storage module is further to:
after the image file is stored in an object storage resource pool of a cloud platform, a storage address corresponding to the image file is obtained;
the import module is specifically configured to:
and according to the storage address, the image file is imported into a block storage resource pool of the cloud platform from the object storage resource pool.
8. The apparatus of claim 6, wherein the format information of the image file is used to indicate that the format of the image file is a first format, the first format being different from a second format, the second format being a format of the image file supported by the cloud platform, and the import module is further configured to:
modifying the format of the image file into the second format;
the first format and the second format belong to the mirror image file format of the storage resource pool of the import permission block.
9. An electronic device, comprising a processor and a memory, wherein the memory stores program code which, when executed by the processor, causes the processor to perform the steps of the method of any of claims 1 to 4.
10. A computer-readable storage medium, characterized in that it comprises program code for causing an electronic device to perform the steps of the method of any one of claims 1 to 4, when said program code is run on the electronic device.
CN202210867984.8A 2022-07-22 2022-07-22 Mirror image file importing method and device Pending CN115268950A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210867984.8A CN115268950A (en) 2022-07-22 2022-07-22 Mirror image file importing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210867984.8A CN115268950A (en) 2022-07-22 2022-07-22 Mirror image file importing method and device

Publications (1)

Publication Number Publication Date
CN115268950A true CN115268950A (en) 2022-11-01

Family

ID=83770649

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210867984.8A Pending CN115268950A (en) 2022-07-22 2022-07-22 Mirror image file importing method and device

Country Status (1)

Country Link
CN (1) CN115268950A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116302210A (en) * 2023-05-17 2023-06-23 阿里云计算有限公司 Image file importing method and device, electronic equipment and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116302210A (en) * 2023-05-17 2023-06-23 阿里云计算有限公司 Image file importing method and device, electronic equipment and storage medium
CN116302210B (en) * 2023-05-17 2023-08-04 阿里云计算有限公司 Image file importing method and device, electronic equipment and storage medium

Similar Documents

Publication Publication Date Title
US11709705B2 (en) Event proxies for functions-as-a-service (FaaS) infrastructures
US10635406B2 (en) Determining the identity of software in software containers
CN109597677B (en) Method and apparatus for processing information
CN109634718B (en) Method and system for creating mirror image by cloud platform
JP7512334B2 (en) Method and apparatus for managing virtual machines for cloud platforms
CN103795759B (en) The dispatching method and system of a kind of virtual machine image file
CN112181602A (en) Resource arranging method and device, electronic equipment and storage medium
US20140137114A1 (en) Virtual machine template creation based on data feeds
CN108132826B (en) Mirror image management method and device for cross-cloud server and server
US11960578B2 (en) Correspondence of external operations to containers and mutation events
US20190227995A1 (en) Layer-Based File Access Method and Apparatus of Virtualization Instance
CN109684038B (en) Docker service container log processing method and device and electronic equipment
CN112346818A (en) Container application deployment method and device, electronic equipment and storage medium
CN114124739B (en) Method and device for deploying FreeWITCH service, electronic equipment and storage medium
US11838296B1 (en) Providing secure software project development environments
US10057331B2 (en) Automatic abstraction of flow of control in a distributed virtualization platform
US10318343B2 (en) Migration methods and apparatuses for migrating virtual machine including locally stored and shared data
CN112286633A (en) Virtual machine creating method, device, equipment and storage medium based on CloudStack platform
CN103995772A (en) RAID card log completely-storing method based on LINUX operation system
US11010149B2 (en) Shared middleware layer containers
CN115268950A (en) Mirror image file importing method and device
WO2022100439A1 (en) Workflow patching
CN105677481B (en) A kind of data processing method, system and electronic equipment
US20230342134A1 (en) Hybrid approach to performing a lazy pull of container images
CN115774742A (en) Data storage newly-increased method, device, equipment, medium and product of private cloud

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination