CN109445716A - A kind of cloud hard disk expansion method and device - Google Patents

A kind of cloud hard disk expansion method and device Download PDF

Info

Publication number
CN109445716A
CN109445716A CN201811351038.8A CN201811351038A CN109445716A CN 109445716 A CN109445716 A CN 109445716A CN 201811351038 A CN201811351038 A CN 201811351038A CN 109445716 A CN109445716 A CN 109445716A
Authority
CN
China
Prior art keywords
hard disk
mirror image
cloud
cloud hard
virtual
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
CN201811351038.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.)
Zhengzhou Yunhai Information Technology Co Ltd
Original Assignee
Zhengzhou Yunhai Information 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 Zhengzhou Yunhai Information Technology Co Ltd filed Critical Zhengzhou Yunhai Information Technology Co Ltd
Priority to CN201811351038.8A priority Critical patent/CN109445716A/en
Publication of CN109445716A publication Critical patent/CN109445716A/en
Pending legal-status Critical Current

Links

Classifications

    • 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/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/067Distributed or networked storage systems, e.g. storage area networks [SAN], network attached storage [NAS]
    • 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/0665Virtualisation aspects at area level, e.g. provisioning of virtual or logical volumes
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1095Replication or mirroring of data, e.g. scheduling or transport for data synchronisation between network nodes

Abstract

The invention discloses a kind of cloud hard disk expansion methods, this method comprises: receiving the request for creating cloud host by mirror image, wherein the size of the cloud hard disk of the request comprising cloud host to be created;Obtain the sizes of virtual of the mirror image;If the size of the cloud hard disk is less than the sizes of virtual of the mirror image, and is less than the free memory of rear end storage with the difference of the sizes of virtual of the mirror image, then dilatation is carried out to the cloud hard disk.The invention also discloses a kind of cloud hard disk flash chambers.Method and apparatus provided by the invention solve the problems, such as that the size of the cloud hard disk when cloud platform selects mirror image and specified cloud hard disk creation cloud host is less than the sizes of virtual of mirror image.

Description

A kind of cloud hard disk expansion method and device
Technical field
The present invention relates to cloud hard disk expansion methods a kind of in field of cloud calculation more particularly to field of cloud calculation.
Background technique
In today that cloud computing technology is prevailing, efficient easy-to-use cloud platform is only the foundation stone to keep one's feet.When cloud platform makes When creating cloud host with the mirror image of QCOW2 format, mirror image is locally downloading from distal end, since (such as ceph is shared for shared storage Storage) it supports to simplify the mode of purchasing and (simplifies that purchase be a kind of to deposit by distributing memory space with flexible on-demand to optimize The method for storing up utilization rate.Simplify purchase it is completely different with traditional mode (referred to as thickness is purchased).It purchases, is provided previously a large amount of for thickness Memory space is to meet following storage needs.But space may be not used by always, will lead to be unable to fully utilize in this way Memory capacity.), cause the practical size for occupying memory space of mirror image and mirror image sizes of virtual inconsistent.Using the QCOW2 mirror When as specifying cloud hard disk creation cloud host, it may appear that specified cloud host cloud hard disk size is less than the virtual of QCOW2 mirror image Size still will continue to the creation operation for executing cloud host, needed during creation from mirror image although prompt can be provided Copy data to cloud host target cloud hard disk (i.e. the system disk of cloud host) so that mirror image data is unable to complete copy to cloud The cloud hard disk of host.Cloud host-initiated can be caused to fail due to the missing of data when starting cloud host.
Summary of the invention
The technical problem to be solved in the present invention is to provide a kind of cloud hard disk expansion methods, avoid cloud master to a certain extent Machine starting failure.
In order to solve the above-mentioned technical problem, the embodiment of the invention provides a kind of cloud hard disk expansion methods, comprising:
Receive the request that cloud host is created by mirror image, wherein the request includes the cloud hard disk of cloud host to be created Size;
Obtain the sizes of virtual of the mirror image;
If the size of the cloud hard disk is less than the sizes of virtual of the mirror image, and the difference with the sizes of virtual of the mirror image Less than the free memory of rear end storage, then dilatation is carried out to the cloud hard disk.
In a kind of exemplary embodiment, the above method also has the characteristics that following:
It is described to include: to the progress dilatation of cloud hard disk
By the size dilatation of the cloud hard disk to identical as the sizes of virtual of the mirror image.
In a kind of exemplary embodiment, the above method also has the characteristics that following:
By the facility information table of the size write-in cloud host of the cloud hard disk after dilatation, and notify the cloud hard disk after dilatation Size is written to cloud hard disk information table.
In a kind of exemplary embodiment, the above method also has the characteristics that following:
The mirror image is the mirror image of QCOW2 format.
In a kind of exemplary embodiment, the above method also has the characteristics that following:
The sizes of virtual for obtaining the mirror image includes:
Mirror image is obtained in the sizes of virtual of local cache by qemu order.
To solve the above-mentioned problems, the present invention also provides a kind of cloud hard disk flash chambers, comprising: memory and processing Device;
The memory, for saving the program for being used for the dilatation of cloud hard disk;
The processor executes the program for being used for the dilatation of cloud hard disk for reading, performs the following operations:
Receive the request that cloud host is created by mirror image, wherein the request includes the cloud hard disk of cloud host to be created Size;
Obtain the sizes of virtual of the mirror image;
If the size of the cloud hard disk is less than the sizes of virtual of the mirror image, and the difference with the sizes of virtual of the mirror image Less than the free memory of rear end storage, then dilatation is carried out to the cloud hard disk.
In a kind of exemplary embodiment, above-mentioned apparatus also has the characteristics that following:
It is described to include: to the progress dilatation of cloud hard disk
By the size dilatation of the cloud hard disk to identical as the sizes of virtual of the mirror image.
In a kind of exemplary embodiment, above-mentioned apparatus also has the characteristics that following:
The processor executes the program for being used for the dilatation of cloud hard disk for reading, also performs the following operations:
By the facility information table of the size write-in cloud host of the cloud hard disk after dilatation, and notify the cloud hard disk after dilatation Size is written to cloud hard disk information table.
In a kind of exemplary embodiment, above-mentioned apparatus also has the characteristics that following:
The mirror image is the mirror image of QCOW2 format.
In a kind of exemplary embodiment, above-mentioned apparatus also has the characteristics that following:
The sizes of virtual for obtaining the mirror image includes:
Mirror image is obtained in the sizes of virtual of local cache by qemu order.
To sum up, the embodiment of the present invention provides a kind of cloud hard disk expansion method and device, avoids cloud master to a certain extent Machine starting failure, ensure that the integrality of the cloud disk copy from mirror image data to cloud host, improve creation cloud host at Power.
Detailed description of the invention
Fig. 1 is the schematic diagram according to the cloud hard disk expansion method of the embodiment of the present invention.
Fig. 2 is the flow chart according to the cloud hard disk expansion method of the embodiment of the present invention.
Fig. 3 is the schematic diagram according to the cloud hard disk flash chamber of the embodiment of the present invention.
Specific embodiment
To make the objectives, technical solutions, and advantages of the present invention clearer, below in conjunction with attached drawing to the present invention Embodiment be described in detail.It should be noted that in the absence of conflict, in the embodiment and embodiment in the application Feature can mutual any combination.
Fig. 1 is the schematic diagram of the cloud hard disk expansion method of the embodiment of the present invention, as shown in Figure 1, the cloud hard disk of the present embodiment Expansion method includes:
S11, the request that cloud host is created by mirror image is received.
Wherein, the size of the cloud hard disk for requesting may include cloud host to be created.The mirror image can be QCOW2 The mirror image of format.
S12, the sizes of virtual for obtaining the mirror image.
In a kind of exemplary embodiment, it can be determined that whether current server mirror cache catalogue has existed creation cloud The QCOW2 target mirror image selected when host, if it does, the sizes of virtual of qemu order acquisition mirror image is called, if mirror cache There is no (illustrating that the mirror image is used for the first time), and caching of target is mirrored to local server caching mesh from Remote Switched Port Analyzer library Record.
If the size of S13, the cloud hard disk be less than the mirror image sizes of virtual, and with the sizes of virtual of the mirror image Difference is less than the free memory of rear end storage, then carries out dilatation to the cloud hard disk.
In a kind of exemplary embodiment, by the size dilatation of the cloud hard disk to the sizes of virtual phase with the mirror image Together.I.e. the difference of the size of the sizes of virtual of mirror image and cloud hard disk increases the storage of the dilatation increment size as dilatation increment Space is to cloud hard disk.
In a kind of exemplary embodiment, the size of the cloud hard disk after dilatation can be written to the cloud host of computing module Facility information table, and can notify memory module that the size of the cloud hard disk after dilatation is written to cloud hard disk information table, to guarantee The consistency of same resource data.
Fig. 2 is the schematic diagram of the method for the cloud hard disk dilatation of the embodiment of the present invention.As shown in Fig. 2, comprising the following steps that
Step 201: user issues selection mirror image in cloud platform, specifies the request of cloud hard disk creation cloud host.
Wherein, cloud platform can be based on OpenStack open source projects exploitation cloud management platform, comprising computing module, Memory module, network module etc..Computing module provides the service of calculating, memory module provides storage service.Cloud host belongs to calculating Module resource, cloud hard disk belong to memory module resource, and network belongs to network module.
Wherein, the mirror image can be the mirror image of QCOW2 format.
Step 202: during the creation of cloud host, calculating service to storage service application storage resource, and judge specified Whether cloud hard disk size is less than storage available space size, if specified cloud hard disk size is less than storage available space size, holds Row step 203.If specified cloud hard disk size is greater than storage available space size, carries out rollback and discharge allocated server money Source terminates the creation task of cloud host.
Step 203: obtaining target Mirror Info from shared repository, mirrored pool, judge current server local mirror image The cache information of the whether existing mirror image of CACHE DIRECTORY, and if so, using the cache information as image source;Otherwise, under QCOW2 mirror image data is carried to server local CACHE DIRECTORY.
Step 204: obtaining target QCOW2 mirror image in the sizes of virtual of local cache using qemu order, judge cloud host Whether the size of specified cloud hard disk is less than mirror image sizes of virtual, if the size of target cloud hard disk is less than the sizes of virtual of mirror image, The free memory of current environment rear end storage is then obtained, if the difference of the sizes of virtual of mirror image and the size of target cloud hard disk Available space is stored less than rear end, then dilatation is carried out to target cloud hard disk, by the big of the sizes of virtual of mirror image and target cloud hard disk Increment increment_size of the small difference as dilatation target cloud hard disk.
If increment_size, which is greater than rear end, stores available space, prompts user storage space insufficient, set cloud master Machine state is failure (being in operation if creating successfully), carries out rollback and discharges allocated server resource, terminates cloud master The creation task of machine.
Step 205: by the facility information table of cloud host cloud hard disk size write-in computing module cloud host, and recording its carry Point and ID notify memory module to record current cloud hard disk size to cloud hard disk information table to facility information table.
If the cloud hard disk size configured during cloud hard disk size and creation cloud host is inconsistent, illustrate to cloud hard disk Dilatation is carried out.On the interface cloud host UI, the details of the cloud host of display are the current real deployment information of cloud host.
Fig. 3 is the schematic diagram of the cloud hard disk flash chamber of the embodiment of the present invention, as shown in figure 3, the cloud hard disk of the present embodiment Flash chamber includes: memory and processor;
The memory, for saving the program for being used for the dilatation of cloud hard disk;
The processor executes the program for being used for the dilatation of cloud hard disk for reading, performs the following operations:
Receive the request that cloud host is created by mirror image, wherein the request includes the cloud hard disk of cloud host to be created Size;
Obtain the sizes of virtual of the mirror image;
If the size of the cloud hard disk is less than the sizes of virtual of the mirror image, and the difference with the sizes of virtual of the mirror image Less than the free memory of rear end storage, then dilatation is carried out to the cloud hard disk.
It is described dilatation is carried out to cloud hard disk to include: in a kind of exemplary embodiment
By the size dilatation of the cloud hard disk to identical as the sizes of virtual of the mirror image.
In a kind of exemplary embodiment, the processor executes the program for being used for the dilatation of cloud hard disk for reading, Also perform the following operations:
By the facility information table of the size write-in cloud host of the cloud hard disk after dilatation, and notify the cloud hard disk after dilatation Size is written to cloud hard disk information table.
In a kind of exemplary embodiment, the mirror image is the mirror image of QCOW2 format.
In a kind of exemplary embodiment, the sizes of virtual for obtaining the mirror image includes:
Mirror image is obtained in the sizes of virtual of local cache by qemu order.
Those of ordinary skill in the art will appreciate that all or part of the steps in the above method can be instructed by program Related hardware is completed, and described program can store in computer readable storage medium, such as read-only memory, disk or CD Deng.Optionally, one or more integrated circuits can be used also to realize in all or part of the steps of above-described embodiment.Accordingly Ground, each module/unit in above-described embodiment can take the form of hardware realization, can also use the shape of software function module Formula is realized.The present invention is not limited to the combinations of the hardware and software of any particular form.
The above is only a preferred embodiment of the present invention, and certainly, the invention may also have other embodiments, without departing substantially from this In the case where spirit and its essence, those skilled in the art make various corresponding changes in accordance with the present invention And deformation, but these corresponding changes and modifications all should fall within the scope of protection of the appended claims of the present invention.

Claims (10)

1. a kind of cloud hard disk expansion method, comprising:
Receive the request that cloud host is created by mirror image, wherein the request includes the big of the cloud hard disk of cloud host to be created It is small;
Obtain the sizes of virtual of the mirror image;
If the size of the cloud hard disk is less than the sizes of virtual of the mirror image, and is less than with the difference of the sizes of virtual of the mirror image The free memory of rear end storage, then carry out dilatation to the cloud hard disk.
2. the method as described in claim 1, which is characterized in that described to include: to the progress dilatation of cloud hard disk
By the size dilatation of the cloud hard disk to identical as the sizes of virtual of the mirror image.
3. the method as described in claim 1, which is characterized in that
By the facility information table of the size write-in cloud host of the cloud hard disk after dilatation, and notify the size of the cloud hard disk after dilatation It is written to cloud hard disk information table.
4. the method as described in claim 1, which is characterized in that
The mirror image is the mirror image of QCOW2 format.
5. the method as described in claim 1, which is characterized in that
The sizes of virtual for obtaining the mirror image includes:
Mirror image is obtained in the sizes of virtual of local cache by qemu order.
6. a kind of cloud hard disk flash chamber, comprising: memory and processor;It is characterized by:
The memory, for saving the program for being used for the dilatation of cloud hard disk;
The processor executes the program for being used for the dilatation of cloud hard disk for reading, performs the following operations:
Receive the request that cloud host is created by mirror image, wherein the request includes the big of the cloud hard disk of cloud host to be created It is small;
Obtain the sizes of virtual of the mirror image;
If the size of the cloud hard disk is less than the sizes of virtual of the mirror image, and is less than with the difference of the sizes of virtual of the mirror image The free memory of rear end storage, then carry out dilatation to the cloud hard disk.
7. device as claimed in claim 6, which is characterized in that described to include: to the progress dilatation of cloud hard disk
By the size dilatation of the cloud hard disk to identical as the sizes of virtual of the mirror image.
8. device as claimed in claim 6, which is characterized in that the processor, for reading, execution is described to be used for cloud hard disk The program of dilatation, also performs the following operations:
By the facility information table of the size write-in cloud host of the cloud hard disk after dilatation, and notify the size of the cloud hard disk after dilatation It is written to cloud hard disk information table.
9. device as claimed in claim 6, which is characterized in that
The mirror image is the mirror image of QCOW2 format.
10. device as claimed in claim 6, which is characterized in that
The sizes of virtual for obtaining the mirror image includes:
Mirror image is obtained in the sizes of virtual of local cache by qemu order.
CN201811351038.8A 2018-11-14 2018-11-14 A kind of cloud hard disk expansion method and device Pending CN109445716A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811351038.8A CN109445716A (en) 2018-11-14 2018-11-14 A kind of cloud hard disk expansion method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811351038.8A CN109445716A (en) 2018-11-14 2018-11-14 A kind of cloud hard disk expansion method and device

Publications (1)

Publication Number Publication Date
CN109445716A true CN109445716A (en) 2019-03-08

Family

ID=65552273

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811351038.8A Pending CN109445716A (en) 2018-11-14 2018-11-14 A kind of cloud hard disk expansion method and device

Country Status (1)

Country Link
CN (1) CN109445716A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112532577A (en) * 2020-10-22 2021-03-19 苏州浪潮智能科技有限公司 Mirror image creation cloud hard disk certificate verification method and device and storage medium
WO2021128897A1 (en) * 2019-12-27 2021-07-01 浪潮电子信息产业股份有限公司 Method, apparatus and device for creating thick-provisioned volume, and medium
CN113485645A (en) * 2021-07-07 2021-10-08 北京汇钧科技有限公司 Management method and device of cloud hard disk resource pool, storage medium and electronic equipment

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102427481A (en) * 2012-01-12 2012-04-25 易云捷讯科技(北京)有限公司 System for managing cloud computing service and cloud computing management method
CN104142943A (en) * 2013-05-07 2014-11-12 上海盛大网络发展有限公司 Database expansion method and database
CN105095023A (en) * 2015-08-18 2015-11-25 北京皮尔布莱尼软件有限公司 Cloud host establishing device and method and calculating equipment
CN107479837A (en) * 2017-08-30 2017-12-15 郑州云海信息技术有限公司 The method and apparatus of virtual machine dilatation in cloud data system
CN107506145A (en) * 2017-08-28 2017-12-22 郑州云海信息技术有限公司 A kind of physical store dispatching method and cloud main frame creation method
US20180136858A1 (en) * 2016-11-16 2018-05-17 International Business Machines Corporation Point-in-time backups via a storage controller to an object storage cloud
CN108762890A (en) * 2018-05-31 2018-11-06 郑州云海信息技术有限公司 The management method and device of database in cloud management platform

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102427481A (en) * 2012-01-12 2012-04-25 易云捷讯科技(北京)有限公司 System for managing cloud computing service and cloud computing management method
CN104142943A (en) * 2013-05-07 2014-11-12 上海盛大网络发展有限公司 Database expansion method and database
CN105095023A (en) * 2015-08-18 2015-11-25 北京皮尔布莱尼软件有限公司 Cloud host establishing device and method and calculating equipment
US20180136858A1 (en) * 2016-11-16 2018-05-17 International Business Machines Corporation Point-in-time backups via a storage controller to an object storage cloud
CN107506145A (en) * 2017-08-28 2017-12-22 郑州云海信息技术有限公司 A kind of physical store dispatching method and cloud main frame creation method
CN107479837A (en) * 2017-08-30 2017-12-15 郑州云海信息技术有限公司 The method and apparatus of virtual machine dilatation in cloud data system
CN108762890A (en) * 2018-05-31 2018-11-06 郑州云海信息技术有限公司 The management method and device of database in cloud management platform

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2021128897A1 (en) * 2019-12-27 2021-07-01 浪潮电子信息产业股份有限公司 Method, apparatus and device for creating thick-provisioned volume, and medium
CN112532577A (en) * 2020-10-22 2021-03-19 苏州浪潮智能科技有限公司 Mirror image creation cloud hard disk certificate verification method and device and storage medium
CN113485645A (en) * 2021-07-07 2021-10-08 北京汇钧科技有限公司 Management method and device of cloud hard disk resource pool, storage medium and electronic equipment

Similar Documents

Publication Publication Date Title
US11789823B2 (en) Selective processing of file system objects for image level backups
CN106062742B (en) System and method for improving snapshot performance
CN106598667B (en) Method and apparatus for repairing kernel loophole
CN105630632B (en) The method and virtual machine administration device that a kind of virtual machine recovers
US8738883B2 (en) Snapshot creation from block lists
US8719559B2 (en) Memory tagging and preservation during a hot upgrade
CN106716395B (en) The method, apparatus and computer system of issued transaction
CN105446826A (en) Virtual machine backup and recovery method and device
US20110213954A1 (en) Method and apparatus for generating minimum boot image
CN109445716A (en) A kind of cloud hard disk expansion method and device
CN106227621B (en) The data back up method and system of logic-based volume management simplification volume
CN106055388A (en) Cloud platform application automatic deployment framework
CN109254825A (en) A kind of method and device for receiving pipe virtual hard disk
CN109388478A (en) Method and apparatus for migrating virtual machine in OpenStack environment
CN109495555A (en) A kind of method and apparatus based on cloud platform creation cloud host
JP2023036774A (en) Access control method of shared memory, access control device of shared memory, electronic apparatus, and autonomous vehicle
CN107800730B (en) Capacity expansion method and device for virtual disk
CN108829449A (en) A kind of method, apparatus, equipment and the medium of BIOS start-up operation system
CN105867962A (en) System upgrading method and device
CN110275800A (en) SSD Data Physical backup method, device, computer equipment and storage medium
CN106775481B (en) Method for reading data and equipment
KR101692015B1 (en) Operating system and file storage features removable storage device
US20140281125A1 (en) Systems and methods for in-place reorganization of device storage
CN104063234A (en) Compatible method and device
CN110531925B (en) Data reading method and device, electronic equipment and machine-readable storage medium

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20190308