CN113821307A - Method, device and equipment for quickly importing virtual machine mirror image - Google Patents

Method, device and equipment for quickly importing virtual machine mirror image Download PDF

Info

Publication number
CN113821307A
CN113821307A CN202111124465.4A CN202111124465A CN113821307A CN 113821307 A CN113821307 A CN 113821307A CN 202111124465 A CN202111124465 A CN 202111124465A CN 113821307 A CN113821307 A CN 113821307A
Authority
CN
China
Prior art keywords
virtual machine
mirror image
image
target virtual
uploading
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.)
Granted
Application number
CN202111124465.4A
Other languages
Chinese (zh)
Other versions
CN113821307B (en
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.)
Jinan Inspur Data Technology Co Ltd
Original Assignee
Jinan Inspur Data 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 Jinan Inspur Data Technology Co Ltd filed Critical Jinan Inspur Data Technology Co Ltd
Priority to CN202111124465.4A priority Critical patent/CN113821307B/en
Publication of CN113821307A publication Critical patent/CN113821307A/en
Application granted granted Critical
Publication of CN113821307B publication Critical patent/CN113821307B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • 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
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0662Virtualisation aspects
    • G06F3/0667Virtualisation aspects at data level, e.g. file, record or object virtualisation
    • 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/45562Creating, deleting, cloning virtual machine instances

Abstract

The application discloses a method, a device and equipment for quickly importing a virtual machine image, wherein the method comprises the following steps: the method comprises the steps of firstly determining a target virtual machine mirror image, uploading the target virtual machine mirror image to an object for storage, then uploading a blank mirror image corresponding to the target virtual machine mirror image through a cloud platform, creating a blank mirror image file in a storage node according to the blank mirror image, storing attribute information and metadata information of the target virtual machine mirror image in a database, and then copying the target virtual machine mirror image from the object for storage to the blank mirror image file of the storage node. Therefore, the virtual machine mirror image can be uploaded to the object storage through the storage network directly, when the cloud platform uploads the virtual machine mirror image, the transmission link of the mirror image data stream is reduced, the uploading time is shortened, meanwhile, the flow of the management network is not occupied, the success rate of mirror image uploading is improved, the virtual machine mirror image is uploaded quickly and efficiently, and the user experience is improved.

Description

Method, device and equipment for quickly importing virtual machine mirror image
Technical Field
The present application relates to the field of computer technologies, and in particular, to a method, an apparatus, and a device for quickly importing a virtual machine image.
Background
With the continuous expansion of the market scale of the internet, a large number of heterogeneous resources are uniformly managed through a cloud platform. When a virtual machine is created on a cloud platform, a local image needs to be uploaded to the cloud platform.
In the current distributed storage field, ceph has become an industry benchmark, is supported by numerous cloud computing and storage manufacturers, and becomes an open source distributed storage platform with the most wide application. Approximately 75% of the production environment ceph serves as a storage back end of openstack, and components including nova, circular, manila and gland can use ceph, wherein the gland uses the block storage of ceph as a mirrored storage back end. openstack uses ceph as the storage back-end, and the nova, glance, and cinator components are generally divided into different pool for use. For example, assuming nova uses poolvms and liance uses poolmages, when creating a virtual machine from an image, images to vms are needed, and to ensure high performance and not occupy the storage space of a compute node, a copy method of ceph is directly used to perform operations at the ceph level. The current mirror upload flow is shown in fig. 1, but this last-time approach has three disadvantages: firstly, when the mirror image is large, the flow of the management network can influence the calling speed of the cloud pipe platform interface; secondly, the time consumption of the uploading process is large due to the fact that the middle process is subjected to four data moving processes; thirdly, if the user accidentally turns off the browser in the uploading process or interrupts the uploading process, the user needs to upload again from the beginning, which also results in poor user experience. Therefore, how to optimize the uploading process of the virtual machine image so that the virtual machine image can be quickly imported into the storage node of the database is an urgent problem to be solved at present.
Disclosure of Invention
The embodiment of the application mainly aims to provide a method, a device and equipment for quickly importing a virtual machine image, wherein the virtual machine image can be quickly and efficiently uploaded through a cloud platform, and then user experience is improved.
In a first aspect, an embodiment of the present application provides a method for quickly importing a virtual machine image, including:
determining a target virtual machine mirror image, and uploading the target virtual machine mirror image to an object storage;
uploading an empty mirror image corresponding to the target virtual machine mirror image through a cloud platform, creating an empty mirror image file in a storage node according to the empty mirror image, and storing attribute information and metadata information of the target virtual machine mirror image into a database;
and copying the target virtual machine image from the object storage to an empty image file of the storage node.
Optionally, the uploading, by the cloud platform, the empty image corresponding to the target virtual machine image, creating an empty image file in a storage node according to the empty image, and storing the attribute information and the metadata information of the target virtual machine image in a database includes:
uploading an empty mirror image corresponding to the target virtual machine mirror image through a cloud platform, acquiring an information flow corresponding to the target virtual machine mirror image according to the empty mirror image, and uploading the information flow to a UI server of the cloud platform after ingress load distribution and gateway authentication;
uploading the information stream to an image module of the cloud platform after gateway authentication through a UI server of the cloud platform, so that the image module stores the attribute information and the metadata information of the target virtual machine image in a database;
after the information stream is checked for quota validity through an image module of the cloud platform, the information stream is uploaded to a GLANCE module of a cloud operating system OPENSTACK so as to be subjected to ingress load distribution and keystone authentication through the GLANCE module;
creating an empty mirror image file in a storage node according to the empty mirror image through the GLANCE module; and completing the registration of the target virtual machine mirror image in a database by using the attribute information and the metadata information of the target virtual machine mirror image through the GLANCE module.
Optionally, the uploading the target virtual machine image to an object storage includes:
and directly uploading the target virtual machine mirror to object storage through an Amazon S3 interface through a storage network.
Optionally, the empty image file is stored in a ceph image pool configured by the chord module.
In a second aspect, an embodiment of the present application further provides a device for quickly importing a virtual machine image, including:
the first uploading unit is used for determining a target virtual machine mirror image and uploading the target virtual machine mirror image to an object storage;
the second uploading unit is used for uploading the empty mirror image corresponding to the target virtual machine mirror image through the cloud platform, creating an empty mirror image file in a storage node according to the empty mirror image, and storing the attribute information and the metadata information of the target virtual machine mirror image into a database;
and the copying unit is used for copying the target virtual machine image from the object storage to the empty image file of the storage node.
Optionally, the second uploading unit includes:
the first uploading subunit is used for uploading an empty mirror image corresponding to the target virtual machine mirror image through the cloud platform, acquiring an information flow corresponding to the target virtual machine mirror image according to the empty mirror image, and uploading the information flow to a UI server of the cloud platform after ingress load distribution and gateway authentication;
the second uploading subunit is used for uploading the information stream to an image module of the cloud platform after gateway authentication through a UI server of the cloud platform, so that the image module can store the attribute information and the metadata information of the target virtual machine image in a database;
the third uploading subunit is configured to upload, by an image module of the cloud platform, the information stream to a global module of a cloud operating system OPENSTACK after the information stream is checked for quota validity, so as to perform ingress load shedding and keystone authentication by the global module;
the creating subunit is configured to create, by the chord module, an empty mirror image file in a storage node according to the empty mirror image; and completing the registration of the target virtual machine mirror image in a database by using the attribute information and the metadata information of the target virtual machine mirror image through the GLANCE module.
Optionally, the first uploading unit is specifically configured to:
and directly uploading the target virtual machine mirror to object storage through an Amazon S3 interface through a storage network.
Optionally, the empty image file is stored in a ceph image pool configured by the chord module.
The embodiment of the present application further provides a fast importing device of a virtual machine image, including: a processor, a memory, a system bus;
the processor and the memory are connected through the system bus;
the memory is used for storing one or more programs, and the one or more programs comprise instructions which when executed by the processor cause the processor to execute any one implementation mode of the quick import method of the virtual machine image.
An embodiment of the present application further provides a computer-readable storage medium, where instructions are stored in the computer-readable storage medium, and when the instructions are run on a terminal device, the terminal device is enabled to execute any implementation manner of the above method for quickly importing a virtual machine image.
According to the method, the device and the equipment for quickly importing the virtual machine mirror image, the target virtual machine mirror image is determined firstly, the target virtual machine mirror image is uploaded to an object for storage, then the empty mirror image corresponding to the target virtual machine mirror image is uploaded through a cloud platform, an empty mirror image file is created in a storage node according to the empty mirror image, attribute information and metadata information of the target virtual machine mirror image are stored in a database, and then the target virtual machine mirror image can be copied to the empty mirror image file of the storage node from the object for storage. Therefore, the virtual machine mirror image can be uploaded to the object storage through the storage network directly, when the cloud platform uploads the virtual machine mirror image, the transmission link of the mirror image data stream is reduced, the uploading time is shortened, meanwhile, the flow of the management network is not occupied, the success rate of mirror image uploading is improved, the virtual machine mirror image is uploaded quickly and efficiently, and the user experience is improved.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, and it is obvious that the drawings in the following description are 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 flowchart illustrating uploading of a current virtual machine image according to an embodiment of the present disclosure;
fig. 2 is a schematic flowchart of a method for quickly importing a virtual machine image according to an embodiment of the present disclosure;
fig. 3 is an overall flowchart of a method for quickly importing an image of a virtual machine based on object storage according to an embodiment of the present disclosure;
fig. 4 is a schematic composition diagram of a fast importing device of a virtual machine image according to an embodiment of the present disclosure.
Detailed Description
In the cloud computing era, with the continuous expansion of the market scale of the internet, a large number of heterogeneous resources are uniformly managed through a cloud platform. When a virtual machine is created on a cloud platform, a local image needs to be uploaded to the cloud platform.
The current mirror image uploading process is shown in fig. 1, and may specifically include the following 4 steps:
(1) the mirror image stored locally by the user is uploaded to the UI module of the cloud platform through the management network through the uploading interface, and the operation such as gateway shunting, authority authentication and the like can be performed in the middle.
(2) And (3) forwarding the data stream passing the verification in the step (1) to the cloud platform IMAGE module through the management network by the UI module of the cloud platform.
(3) After caching the mirror IMAGE file, the cloud platform IMAGE module calls a GLANCE interface of OPENSSTATK through a management network, and the mirror IMAGE is uploaded to a GLANCE control node. The process needs to pass the INGRESS forwarding and KEYSTONE authentication of OPENSACK.
(4) The GLANCE control node stores the mirror image to the configured storage node and finishes mirror image registration in the database.
However, the above-mentioned existing mirror last time approach has three disadvantages: firstly, when the mirror image is large, the flow of the management network can influence the calling speed of the cloud pipe platform interface; secondly, the time consumption of the uploading process is large due to the fact that the middle process is subjected to four data moving processes; thirdly, if the user accidentally turns off the browser in the uploading process or interrupts the uploading process, the user needs to upload again from the beginning, which also results in poor user experience. Therefore, how to optimize the uploading process of the virtual machine image so that the virtual machine image can be quickly imported into the storage node of the database is an urgent problem to be solved at present.
In order to solve the above defect, an embodiment of the present application provides a method for quickly importing a virtual machine image, where a target virtual machine image is determined first, and the target virtual machine image is uploaded to an object for storage, then an empty image corresponding to the target virtual machine image is uploaded through a cloud platform, an empty image file is created in a storage node according to the empty image, attribute information and metadata information of the target virtual machine image are stored in a database, and then the target virtual machine image can be copied from the object for storage to the empty image file of the storage node. Therefore, the virtual machine mirror image can be uploaded to the object storage through the storage network directly, when the cloud platform uploads the virtual machine mirror image, the transmission link of the mirror image data stream is reduced, the uploading time is shortened, meanwhile, the flow of the management network is not occupied, the success rate of mirror image uploading is improved, the virtual machine mirror image is uploaded quickly and efficiently, and the user experience is improved.
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some embodiments of the present application, but not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
First embodiment
Referring to fig. 2, a schematic flowchart of a method for quickly importing a virtual machine image provided in this embodiment is shown, where the method includes the following steps:
s201: and determining a target virtual machine image, and uploading the target virtual machine image to an object storage.
It should be noted that, in the current distributed storage field, there are three disadvantages to the mirror upload flow shown in fig. 1: firstly, when the mirror image is large, the flow of the management network can influence the calling speed of the cloud pipe platform interface; secondly, the time consumption of the uploading process is large due to the fact that the middle process is subjected to four data moving processes; thirdly, if the user accidentally turns off the browser in the uploading process or interrupts the uploading process, the user needs to upload again from the beginning, which also results in poor user experience.
Therefore, in this embodiment, in order to realize fast and efficient uploading of the virtual machine image to improve the user experience, the target virtual machine image is determined first, and the target virtual machine image is uploaded to the object storage to continue to execute the subsequent steps S202 and S203.
The object storage refers to an object/file-oriented massive internet storage, and may also be directly referred to as "cloud storage". Although the object is a file, it is an encapsulated file (the object in programming has the characteristic of encapsulation), that is, in the object storage system, the file cannot be directly opened/modified, but the file can be uploaded and downloaded like ftp. In addition, the object storage does not have a file structure with a plurality of levels like a file system, but only has the concept of a 'bucket' (namely storage space), and all objects in the 'bucket' are objects, so that the object storage is a very flat storage mode. The main characteristic is that the name of its object is a domain name address, once the object is set as "public", all users can access it; its owner may also access objects therein by way of the REST API. Therefore, the object storage is a more mainstream usage scenario, that is, static content (videos, pictures, files, software installation packages, and the like) of internet/mobile internet applications such as websites and mobile apps is stored.
And OpenStack in fig. 1 refers to an open-source cloud computing management platform project.
An optional implementation manner is that, in step S201, an implementation process of "uploading the target virtual machine image to the object storage" may specifically include: and directly uploading the target virtual machine mirror to the object storage through an Amazon S3 interface through a storage network.
Specifically, in this implementation, after determining the target virtual machine image that the user needs to upload, the target virtual machine image that needs to upload is first uploaded to the object storage directly through the storage network via the Amazon S3 interface, and since the storage network has a large width ratio and the data stream in this process is not split by other forwarding, the transmission speed is fast.
Wherein, Amazon S3 refers to Amazon Simple Storage Service for short, and is also an internet Storage solution. This service is intended to reduce the difficulty of developers performing network scale level calculations. Amazon S3 provides a simple Web services interface that can be used to store and retrieve any amount of data anywhere on the Web at any time. The service enables all developers to access the same data storage infrastructure with high expansibility, reliability, safety, rapidness and low price.
S202: the method comprises the steps of uploading a null mirror image corresponding to a target virtual machine mirror image through a cloud platform, creating a null mirror image file in a storage node according to the null mirror image, and storing attribute information and metadata information of the target virtual machine mirror image in a database.
In this embodiment, in order to reduce a transmission link of a target virtual machine image, shorten an upload time, simultaneously not occupy a management network traffic, and improve an upload success rate of the target virtual machine image, after the target virtual machine image is uploaded to an object for storage in step S201, further, an empty image corresponding to the target virtual machine image may be uploaded through a cloud platform, an empty image file is created in a storage node according to the empty image, and attribute information (for example, attribute information such as a memory size and a hard disk size required for creating an operating system using the virtual machine image) and metadata information of the target virtual machine image are stored in a database, so as to perform subsequent step S203.
An optional implementation manner is that the specific implementation process of step S202 may include the following steps a to D:
step A: the method comprises the steps of uploading an empty mirror image corresponding to a target virtual machine mirror image through a cloud platform, obtaining an information flow corresponding to the target virtual machine mirror image according to the empty mirror image, and uploading the information flow to a UI server of the cloud platform after the information flow is subjected to ingress load distribution and gateway authentication.
In the implementation mode, when the empty mirror image corresponding to the target virtual machine mirror image is uploaded through the cloud platform, the web page reads the target virtual machine mirror image data, acquires the information flow corresponding to the target virtual machine mirror image according to the empty mirror image, distributes the information flow through the ingress loads, and finally uploads the information flow to the cloud management platform UI server through gateway authentication.
And B: and uploading the information stream to an image module of the cloud platform after passing gateway authentication through a UI server of the cloud platform, so that the image module stores the attribute information and the metadata information of the target virtual machine mirror image in a database.
And C: after the information stream is checked for quota validity through an image module of the cloud platform, the information stream is uploaded to a GLANCE module of a cloud operating system OPENSTACK, so that the ingress load distribution and the keystone authentication of the GLANCE module are facilitated.
Step D: creating an empty mirror image file in a storage node according to the empty mirror image through a GLANCE module; and completing the registration of the target virtual machine mirror image in the database by using the attribute information and the metadata information of the target virtual machine mirror image through the GLANCE module.
In the implementation manner, after receiving the information stream data, the chord module of the OPENSTACK stores the empty image file in the back end configured by the chord module, and registers the image information of the target virtual machine image in the database. That is, at this time, the chord module creates an empty image file in the storage node, and stores the empty image file in the ceph image pool configured by the chord module.
In this way, since the information stream data uploaded in the steps a-D are all empty files, no long time is consumed.
S203: and copying the target virtual machine image from the object storage to an empty image file of the storage node.
In this embodiment, after the target virtual machine image is uploaded to the object storage in step S201 and the empty image file is created in the storage node in step S202, the target virtual machine image may be further copied from the object storage to the empty image file of the storage node.
Specifically, after the target virtual machine image is uploaded to the object storage and an empty image file is created in the storage node, further, the target virtual machine image may be copied from the object storage to the empty image file in the ceph image pool configured by the chord module using the rbd client of the ceph cluster, that is, the empty image file is overwritten by the target virtual machine image, so as to realize fast import of the target virtual machine image.
Further, after checking whether the state of the mirror image of the target virtual machine is normal, it can be determined whether mirror image service can be provided to the outside, that is, when the state of the mirror image of the target virtual machine is normal, mirror image service can be provided to the outside.
To facilitate understanding of the method for quickly importing a virtual machine image provided by the present application, the present application will next describe, with reference to fig. 3, an overall flow of the method for quickly importing a virtual machine image based on object storage according to the embodiment of the present application:
as shown in fig. 3, the method for quickly importing a virtual machine image provided in the embodiment of the present application specifically includes: first, the virtual machine image to be uploaded is directly uploaded to the object storage through the storage network via the Amazon S3 interface, as shown in step 0 marked in fig. 3, since the storage network has a large width ratio and the data stream of this process is not split by other forwarding, the transmission speed is fast.
Then, an empty mirror image is uploaded through the cloud management platform, at this time, the web page reads local mirror image data of the user, and the local mirror image data is subjected to ingress load distribution, then is finally uploaded to the cloud management platform UI server through gateway authentication, as shown in step 1 marked in fig. 3.
Then, the cloud management platform UI server uploads the data stream to the cloud management platform image module after passing through gateway authentication, and the cloud management platform image module records information such as mirror image information and metadata in the database, as shown in step 2 marked in fig. 3.
Furthermore, after the Image module checks quota validity and the like of the mirror Image data, the Image module uploads the data to the GLANCE module of the OPENSTACK. This requires ingress load shedding and keystone authentication through the OPENSTACK module, as shown in step 3 labeled in FIG. 3.
Further, after the data stream is received by the chord module of the OPENSTACK, the mirror image file is stored in the rear end configured by the chord module, and the mirror image information is registered in the database. At this time, the chord module will create an empty image file in the storage node, and since the data stream uploaded in these steps is an empty file, it will not take too long, as shown in step 4 marked in fig. 3. And finally, finding the position of the previously uploaded empty file through the storage network and the rbd client by using the real mirror image, and directly covering the empty file by copying the real mirror image, as shown in a step 5 marked in the figure 3.
Therefore, after a reasonable mirror image uploading strategy is designed, the virtual machine mirror image can be uploaded quickly and efficiently through the cloud platform.
In summary, according to the method for quickly importing a virtual machine image provided in this embodiment, a target virtual machine image is determined, the target virtual machine image is uploaded to an object storage, then an empty image corresponding to the target virtual machine image is uploaded through a cloud platform, an empty image file is created in a storage node according to the empty image, attribute information and metadata information of the target virtual machine image are stored in a database, and then the target virtual machine image can be copied from the object storage to the empty image file of the storage node. Therefore, the virtual machine mirror image can be uploaded to the object storage through the storage network directly, when the cloud platform uploads the virtual machine mirror image, the transmission link of the mirror image data stream is reduced, the uploading time is shortened, meanwhile, the flow of the management network is not occupied, the success rate of mirror image uploading is improved, the virtual machine mirror image is uploaded quickly and efficiently, and the user experience is improved.
Second embodiment
In this embodiment, a fast importing apparatus of a virtual machine image will be described, and please refer to the above method embodiment for related contents.
Referring to fig. 4, a schematic composition diagram of a fast importing apparatus of a virtual machine image provided in this embodiment is shown, where the apparatus includes:
a first uploading unit 401, configured to determine a target virtual machine image, and upload the target virtual machine image to an object storage;
a second uploading unit 402, configured to upload, through a cloud platform, an empty mirror image corresponding to the target virtual machine mirror image, create an empty mirror image file in a storage node according to the empty mirror image, and store attribute information and metadata information of the target virtual machine mirror image in a database;
a copying unit 403, configured to copy the target virtual machine image from the object storage to an empty image file of the storage node.
In an implementation manner of this embodiment, the second uploading unit 402 includes:
the first uploading subunit is used for uploading an empty mirror image corresponding to the target virtual machine mirror image through the cloud platform, acquiring an information flow corresponding to the target virtual machine mirror image according to the empty mirror image, and uploading the information flow to a UI server of the cloud platform after ingress load distribution and gateway authentication;
the second uploading subunit is used for uploading the information stream to an image module of the cloud platform after gateway authentication through a UI server of the cloud platform, so that the image module can store the attribute information and the metadata information of the target virtual machine image in a database;
the third uploading subunit is configured to upload, by an image module of the cloud platform, the information stream to a global module of a cloud operating system OPENSTACK after the information stream is checked for quota validity, so as to perform ingress load shedding and keystone authentication by the global module;
the creating subunit is configured to create, by the chord module, an empty mirror image file in a storage node according to the empty mirror image; and completing the registration of the target virtual machine mirror image in a database by using the attribute information and the metadata information of the target virtual machine mirror image through the GLANCE module.
In an implementation manner of this embodiment, the first uploading unit 401 is specifically configured to:
and directly uploading the target virtual machine mirror to object storage through an Amazon S3 interface through a storage network.
In an implementation manner of this embodiment, the empty image file is stored in a ceph image pool configured by the chord module.
In summary, according to the fast importing device of a virtual machine image provided in this embodiment, a target virtual machine image is determined first, and the target virtual machine image is uploaded to an object storage, then an empty image corresponding to the target virtual machine image is uploaded through a cloud platform, an empty image file is created in a storage node according to the empty image, attribute information and metadata information of the target virtual machine image are stored in a database, and then the target virtual machine image can be copied from the object storage to the empty image file of the storage node. Therefore, the virtual machine mirror image can be uploaded to the object storage through the storage network directly, when the cloud platform uploads the virtual machine mirror image, the transmission link of the mirror image data stream is reduced, the uploading time is shortened, meanwhile, the flow of the management network is not occupied, the success rate of mirror image uploading is improved, the virtual machine mirror image is uploaded quickly and efficiently, and the user experience is improved.
Further, an embodiment of the present application further provides a fast importing device of a virtual machine image, including: a processor, a memory, a system bus;
the processor and the memory are connected through the system bus;
the memory is used for storing one or more programs, and the one or more programs comprise instructions which when executed by the processor cause the processor to execute any implementation method of the above-mentioned fast import method of the virtual machine image.
Further, an embodiment of the present application further provides a computer-readable storage medium, where instructions are stored in the computer-readable storage medium, and when the instructions are run on a terminal device, the terminal device is caused to execute any implementation method of the above-mentioned method for quickly importing a virtual machine image.
As can be seen from the above description of the embodiments, those skilled in the art can clearly understand that all or part of the steps in the above embodiment methods can be implemented by software plus a necessary general hardware platform. Based on such understanding, the technical solution of the present application may be essentially or partially implemented in the form of a software product, which may be stored in a storage medium, such as a ROM/RAM, a magnetic disk, an optical disk, etc., and includes several instructions for enabling a computer device (which may be a personal computer, a server, or a network communication device such as a media gateway, etc.) to execute the method according to the embodiments or some parts of the embodiments of the present application.
It should be noted that, in the present specification, the embodiments are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments may be referred to each other. The device disclosed by the embodiment corresponds to the method disclosed by the embodiment, so that the description is simple, and the relevant points can be referred to the method part for description.
It is further noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present application. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the application. Thus, the present application is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (10)

1. A method for quickly importing a virtual machine image is characterized by comprising the following steps:
determining a target virtual machine mirror image, and uploading the target virtual machine mirror image to an object storage;
uploading an empty mirror image corresponding to the target virtual machine mirror image through a cloud platform, creating an empty mirror image file in a storage node according to the empty mirror image, and storing attribute information and metadata information of the target virtual machine mirror image into a database;
and copying the target virtual machine image from the object storage to an empty image file of the storage node.
2. The method according to claim 1, wherein the uploading, by the cloud platform, the empty image corresponding to the target virtual machine image, creating an empty image file in a storage node according to the empty image, and storing the attribute information and the metadata information of the target virtual machine image in a database includes:
uploading an empty mirror image corresponding to the target virtual machine mirror image through a cloud platform, acquiring an information flow corresponding to the target virtual machine mirror image according to the empty mirror image, and uploading the information flow to a UI server of the cloud platform after ingress load distribution and gateway authentication;
uploading the information stream to an image module of the cloud platform after gateway authentication through a UI server of the cloud platform, so that the image module stores the attribute information and the metadata information of the target virtual machine image in a database;
after the information stream is checked for quota validity through an image module of the cloud platform, the information stream is uploaded to a GLANCE module of a cloud operating system OPENSTACK so as to be subjected to ingress load distribution and keystone authentication through the GLANCE module;
creating an empty mirror image file in a storage node according to the empty mirror image through the GLANCE module; and completing the registration of the target virtual machine mirror image in a database by using the attribute information and the metadata information of the target virtual machine mirror image through the GLANCE module.
3. The method of claim 1, wherein uploading the target virtual machine image to an object store comprises:
and directly uploading the target virtual machine mirror to object storage through an Amazon S3 interface through a storage network.
4. The method of claim 2, wherein the empty image file is stored in a ceph image pool configured by the GLANCE module.
5. A fast importing device of a virtual machine image is characterized by comprising:
the first uploading unit is used for determining a target virtual machine mirror image and uploading the target virtual machine mirror image to an object storage;
the second uploading unit is used for uploading the empty mirror image corresponding to the target virtual machine mirror image through the cloud platform, creating an empty mirror image file in a storage node according to the empty mirror image, and storing the attribute information and the metadata information of the target virtual machine mirror image into a database;
and the copying unit is used for copying the target virtual machine image from the object storage to the empty image file of the storage node.
6. The apparatus of claim 5, wherein the second uploading unit comprises:
the first uploading subunit is used for uploading an empty mirror image corresponding to the target virtual machine mirror image through the cloud platform, acquiring an information flow corresponding to the target virtual machine mirror image according to the empty mirror image, and uploading the information flow to a UI server of the cloud platform after ingress load distribution and gateway authentication;
the second uploading subunit is used for uploading the information stream to an image module of the cloud platform after gateway authentication through a UI server of the cloud platform, so that the image module can store the attribute information and the metadata information of the target virtual machine image in a database;
the third uploading subunit is configured to upload, by an image module of the cloud platform, the information stream to a global module of a cloud operating system OPENSTACK after the information stream is checked for quota validity, so as to perform ingress load shedding and keystone authentication by the global module;
the creating subunit is configured to create, by the chord module, an empty mirror image file in a storage node according to the empty mirror image; and completing the registration of the target virtual machine mirror image in a database by using the attribute information and the metadata information of the target virtual machine mirror image through the GLANCE module.
7. The apparatus according to claim 5, wherein the first uploading unit is specifically configured to:
and directly uploading the target virtual machine mirror to object storage through an Amazon S3 interface through a storage network.
8. The apparatus of claim 6, wherein the empty image file is stored in a ceph image pool configured by the GLANCE module.
9. A fast import device of a virtual machine image is characterized by comprising: a processor, a memory, a system bus;
the processor and the memory are connected through the system bus;
the memory is to store one or more programs, the one or more programs comprising instructions, which when executed by the processor, cause the processor to perform the method of any of claims 1-4.
10. A computer-readable storage medium having stored therein instructions that, when executed on a terminal device, cause the terminal device to perform the method of any one of claims 1-4.
CN202111124465.4A 2021-09-24 2021-09-24 Method, device and equipment for quickly importing virtual machine images Active CN113821307B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111124465.4A CN113821307B (en) 2021-09-24 2021-09-24 Method, device and equipment for quickly importing virtual machine images

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111124465.4A CN113821307B (en) 2021-09-24 2021-09-24 Method, device and equipment for quickly importing virtual machine images

Publications (2)

Publication Number Publication Date
CN113821307A true CN113821307A (en) 2021-12-21
CN113821307B CN113821307B (en) 2024-02-23

Family

ID=78915447

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111124465.4A Active CN113821307B (en) 2021-09-24 2021-09-24 Method, device and equipment for quickly importing virtual machine images

Country Status (1)

Country Link
CN (1) CN113821307B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113890881A (en) * 2021-10-13 2022-01-04 济南浪潮数据技术有限公司 Method, system, storage medium and equipment for quickly uploading mirror image of virtual machine
CN117370079A (en) * 2023-10-30 2024-01-09 广州鼎甲计算机科技有限公司 Data recovery method, apparatus, device, storage medium and computer program product

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011154522A (en) * 2010-01-27 2011-08-11 Hitachi Ltd System and method for supporting simulation
CN104463012A (en) * 2014-11-24 2015-03-25 东软集团股份有限公司 Virtual machine image file exporting and importing method and device
CN107197022A (en) * 2017-06-02 2017-09-22 华南理工大学 OpenStack storage optimization methods and system
CN111352700A (en) * 2020-02-29 2020-06-30 苏州浪潮智能科技有限公司 Method, system, terminal and storage medium for online migration of virtual machine across clouds
CN111414231A (en) * 2020-03-18 2020-07-14 上海云轴信息科技有限公司 Method and equipment for mutual conversion between virtual machine mirror image and container mirror image
CN111427666A (en) * 2020-04-01 2020-07-17 山东汇贸电子口岸有限公司 Method and system for quickly importing virtual machine image in OpenStack environment
CN112445570A (en) * 2019-09-03 2021-03-05 中移(苏州)软件技术有限公司 Cloud platform resource migration method and device and storage medium

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011154522A (en) * 2010-01-27 2011-08-11 Hitachi Ltd System and method for supporting simulation
CN104463012A (en) * 2014-11-24 2015-03-25 东软集团股份有限公司 Virtual machine image file exporting and importing method and device
CN107197022A (en) * 2017-06-02 2017-09-22 华南理工大学 OpenStack storage optimization methods and system
CN112445570A (en) * 2019-09-03 2021-03-05 中移(苏州)软件技术有限公司 Cloud platform resource migration method and device and storage medium
CN111352700A (en) * 2020-02-29 2020-06-30 苏州浪潮智能科技有限公司 Method, system, terminal and storage medium for online migration of virtual machine across clouds
CN111414231A (en) * 2020-03-18 2020-07-14 上海云轴信息科技有限公司 Method and equipment for mutual conversion between virtual machine mirror image and container mirror image
CN111427666A (en) * 2020-04-01 2020-07-17 山东汇贸电子口岸有限公司 Method and system for quickly importing virtual machine image in OpenStack environment

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
范久岳;: "基于OpenStack的云计算实验平台建设与应用", 数字通信世界, no. 04, 1 April 2019 (2019-04-01), pages 143 *
金永霞;孙宁;: "基于OpenStack的云计算实验平台建设与应用", 实验技术与管理, no. 06, 22 June 2016 (2016-06-22), pages 145 - 149 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113890881A (en) * 2021-10-13 2022-01-04 济南浪潮数据技术有限公司 Method, system, storage medium and equipment for quickly uploading mirror image of virtual machine
CN117370079A (en) * 2023-10-30 2024-01-09 广州鼎甲计算机科技有限公司 Data recovery method, apparatus, device, storage medium and computer program product

Also Published As

Publication number Publication date
CN113821307B (en) 2024-02-23

Similar Documents

Publication Publication Date Title
US10826799B2 (en) Apparatus for providing cloud service based on cloud service brokerage and method thereof
US9898260B2 (en) Adaptive function-based dynamic application extension framework
US11120107B2 (en) Managing content delivery to client devices
US11064041B2 (en) Apparatus for providing cloud service using cloud service brokerage based on multiple clouds and method thereof
CN114008994B (en) Method and system for proxy server to receive request from client to network server and response from network server to client corresponding to the request
TWI712907B (en) Method and device for obtaining blockchain certificate for webpage through file acquisition
CN104715309A (en) Service control method and device
CN113821307A (en) Method, device and equipment for quickly importing virtual machine mirror image
US10834220B2 (en) Apparatus for providing cloud brokerage service based on multiple clouds and method thereof
US9396053B2 (en) Error handling in a network resource generation environment
CN110959165A (en) Techniques for automatically verifying functionality of offers in a cloud service broker system
US8782285B1 (en) Lazy transcoding and re-transcoding of media objects in an online video platform
CN112988378A (en) Service processing method and device
CN108196902A (en) For showing the method and apparatus for advertisement of spreading its tail
CN109032693B (en) Method and device for loading display information, electronic equipment and readable storage medium
US9183189B1 (en) Network site hosting in a managed environment
US9779070B2 (en) Providing aggregated data to page generation code for network page generation
US9665732B2 (en) Secure Download from internet marketplace
US20160028553A1 (en) Network Adaptive Content Download
CN114885024B (en) Routing method, device, equipment and medium of application instance
CN116521317A (en) Mirror image management method and device, electronic equipment and computer readable storage medium
CN110737852A (en) Information processing method, information processing apparatus, electronic device, and medium
CN113890881A (en) Method, system, storage medium and equipment for quickly uploading mirror image of virtual machine
CN113726855A (en) Service aggregation method, device, electronic equipment and computer-readable storage medium
US10417398B2 (en) Restricted and unrestricted states for content based on installation status of applications

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
GR01 Patent grant
GR01 Patent grant