CN102520881B - A kind of virtual machine snapshot management method of cloud computing platform and system - Google Patents

A kind of virtual machine snapshot management method of cloud computing platform and system Download PDF

Info

Publication number
CN102520881B
CN102520881B CN201110397190.1A CN201110397190A CN102520881B CN 102520881 B CN102520881 B CN 102520881B CN 201110397190 A CN201110397190 A CN 201110397190A CN 102520881 B CN102520881 B CN 102520881B
Authority
CN
China
Prior art keywords
virtual machine
snapshot
described virtual
disk
state
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.)
Active
Application number
CN201110397190.1A
Other languages
Chinese (zh)
Other versions
CN102520881A (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.)
China Standard Software Co Ltd
Original Assignee
China Standard Software 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 China Standard Software Co Ltd filed Critical China Standard Software Co Ltd
Priority to CN201110397190.1A priority Critical patent/CN102520881B/en
Publication of CN102520881A publication Critical patent/CN102520881A/en
Application granted granted Critical
Publication of CN102520881B publication Critical patent/CN102520881B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention discloses a kind of cloud computing platform virtual machine snapshot management method and system, the method comprises: when being the virtual machine creating virtual machine snapshot of clustered node, perform following steps.Preparation process: if the state of described virtual machine is for run, described virtual machine to suspend by calling Virtual Machine Manager instrument and to create the memory image of described virtual machine by the Controlling vertex of cloud computing platform; Disk snapshot step: described Controlling vertex calls virtualization management tool to create the disk snapshot of described virtual machine; Subsequent processing steps: if the state of described virtual machine is for run, then make described virtual machine resume operation by calling described virtualization management tool to utilize created memory image.The invention provides good user's snapshot management to experience, ensure that consistance and the stability of cloud computing platform.

Description

A kind of virtual machine snapshot management method of cloud computing platform and system
Technical field
The present invention relates to the virtual machine snapshot administrative skill under cloud computing platform, espespecially a kind of under Linux environment, in cloud computing platform, the method for virtual machine snapshot management is carried out based on Virtual Machine Manager instruments such as Libvirt.
Background technology
Cloud computing is a kind of method of emerging shared architecture, and calculation task is distributed on the resource pool of a large amount of computing machine formation by it, enables various application system obtain computing power, storage space and various software service as required.The bottom of cloud computing needs Intel Virtualization Technology support.By Intel Virtualization Technology, cloud computing can realize using flexibly and efficiently resource, thus provides quality services for user.
Libvirt is the C function library of the virtual instrument of main flow under a set of free, support Linux of increasing income, and its object is for multiple virtual instrument provides a set of convenience, reliably DLL (dynamic link library), and supports to bind with multiple main flow development language.Current, support under Linux that the main flow cloud computing platform major part of multiple virtual instrument is all use Libvirt storehouse to carry out the multiple virtual instrument of compatible management.By Libvirt storehouse, cloud computing platform can shield the isomerism of various virtual instrument, thus does not need, for a set of corresponding management interface all developed by often kind of virtual instrument, to reduce the complicacy of cloud computing platform.
Virtual machine snapshot is that virtual machine is at some point to the duplicate that dummy machine system backs up.When dummy machine system collapse or exception, virtual machine snapshot can be returned to by use and keep file system and system storage.The state of virtual machine snapshot residing for dummy machine system during establishment snapshot is divided into start snapshot and shutdown snapshot.Start snapshot includes the snapshot created internal memory and disk two parts, is the virtual machine snapshot carrying out when dummy machine system is in running status creating.Shutdown snapshot comprises disk establishment snapshot, is the virtual machine snapshot carrying out when dummy machine system is in closed condition creating.
Libvirt is that snapshot management provides DLL (dynamic link library).In Libvirt, register virtual machine have two kinds of modes, one is permanent registration, and one is provisional registration.Permanent registration refers in virtual machine operational process, some bookkeepings that user carries out virtual machine all can by Libvirt record, after virtual machine is closed, these operations can not disappear, unless nullified this virtual machine in Libvirt, such as: the snapshot created when virtual machine runs, still can operate on it, until user has nullified this virtual machine in Libvirt when virtual machine startup next time.Provisional registration refers to that life cycle that virtual machine managed by Libvirt is closed during this period of time to it as the one-shot from virtual machine, that is, user operates in after virtual machine closes at virtual machine cura generalis of doing when time to run, in Libvirt, all do not have respective record.Such as: the snapshot created when virtual machine runs, the snapshot record before cannot finding when virtual machine startup next time, also just cannot operate the snapshot created before, although it exists.
The principle that Libvirt creates snapshot is all kept in the middle of the disk image of virtual machine by the virtual machine current memory run, CPU register and disc information etc., directly cannot operate the snapshot utilizing Libvirt to create from disk outside, Libvirt DLL (dynamic link library) can only be called; Once cannot find the recorded information of this snapshot in Libvirt, so this snapshot cannot use, and this is also the provisional defect being registered in snapshot management aspect and existing.
The provisional registration of the use Libvirt that the cloud computing platform of main flow has under Linux, the permanent registration of some uses.Current, use the cloud platform of provisional registration when carrying out snapshot management Problems existing clearly, create impinge upon soon virtual machine restart after possibly cannot use, thus the management function of snapshot cannot be realized.
Summary of the invention
In view of the defect using the Virtual Machine Manager instruments such as Libvirt to carry out cloud computing platform existence when carrying out snapshot management of Virtual Machine Manager under linux, especially the provisional registration problem of Virtual Machine Manager instrument, proposes a kind of virtual machine snapshot management method and system of cloud computing platform.
In order to solve the problems of the technologies described above, the invention provides a kind of cloud computing platform virtual machine snapshot management method, it is characterized in that, when being the virtual machine creating virtual machine snapshot of clustered node, perform following steps: preparation process: if the state of described virtual machine is for run, described virtual machine to suspend by calling Virtual Machine Manager instrument and to create the memory image of described virtual machine by the Controlling vertex of cloud computing platform; Disk snapshot step: described Controlling vertex calls virtualization management tool to create the disk snapshot of described virtual machine; Subsequent processing steps: if the state of described virtual machine is for run, then make described virtual machine resume operation by calling described virtualization management tool to utilize created memory image.
Further, the method also comprises: when created virtual machine snapshot will be utilized to recover described virtual machine, and described Controlling vertex recovers the disk snapshot of described virtual machine by the disk snapshot calling described virtualization management tool and utilize described disk snapshot step to generate.
Further, the method also comprises: if the state of described virtual machine is for run, and the type of created virtual machine snapshot is set to snapshot of starting shooting, otherwise, then the type of created virtual machine snapshot is set to the snapshot that shuts down.
Further, the method also comprises: when to utilize created virtual machine snapshot type for the virtual machine snapshot of snapshot of starting shooting to recover described virtual machine time: if the state of current described virtual machine is for run, then first call Virtual Machine Manager instrument and suspend virtual machine, and current virtual machine state is preserved into memory image, the disk snapshot in the virtual machine snapshot that recycling creates and memory image are to recover described virtual machine; And if the state of current described virtual machine is not running, then utilize disk snapshot in the virtual machine snapshot that creates and memory image to recover described virtual machine.
Further, the method also comprises: when to utilize created virtual machine snapshot type for the virtual machine snapshot of snapshot of shutting down to recover described virtual machine time, if the state of current described virtual machine is running, then first call Virtual Machine Manager instrument to be closed by virtual machine, the disk snapshot in the snapshot that recycling creates is to recover described virtual machine; And if the state of current described virtual machine is not running, then utilize disk snapshot in the virtual machine snapshot that creates to recover described virtual machine.
Further, the method also comprises: when deleting the virtual machine snapshot created, if the state of current described virtual machine is running, then first call described Virtual Machine Manager instrument and suspend described virtual machine, after deleting the virtual machine snapshot that creates, then call described Virtual Machine Manager instrument and recover described virtual machine; If the state of current described virtual machine is not running, then directly delete the virtual machine snapshot created.
Further, the method also comprises: call described Virtual Machine Manager instrument and delete memory image, and calls virtualization management tool and delete disk snapshot.
Further, the method also comprises: described Virtual Machine Manager instrument is Libvirt, and described virtualization management tool is KVM or Xen.
Present invention also offers a kind of virtual machine snapshot management system based on cloud computing platform, it is characterized in that, comprise with lower unit: virtual machine state judging unit, for judging whether the current state of described virtual machine is just in running status; Snapshot type judging unit, for judging that described snapshot type is as start snapshot or shutdown snapshot; Snapshot creation unit, creates memory image for calling Virtual Machine Manager instrument, and calls virtualization management tool establishment disk snapshot; Snapshot restore unit, recovers described memory image for calling described Virtual Machine Manager instrument, and calls described virtualization management tool and recover described disk snapshot; Snapshot delete cells, deletes described memory image for calling described Virtual Machine Manager instrument, and calls described virtualization management tool and delete described disk snapshot.
Further, this system also comprises: described Virtual Machine Manager instrument is Libvirt, and described virtualization management tool is KVM or Xen.
Compared with prior art, the present invention at least has the following advantages:
The present invention does not need to revise Libvirt source code and the cloud computing platform carrying out any kind of Virtual Machine Manager under being suitable for Linux based on Libvirt, ensures the consistance of cloud computing platform simultaneously, and provides good user's snapshot management to experience.
The present invention only revises the platform management code on cloud computing platform Controlling vertex, and do not need to revise clustered node and on the virtualization management tool such as Virtual Machine Manager instrument and KVM such as Libvirt, by the mode of a kind of new snapshot management method under introducing cloud computing platform, make to be limited in minimum scope to the change of cloud computing platform.
The present invention is that the cloud computing platform carrying out Virtual Machine Manager based on Virtual Machine Manager instruments such as Libvirt under Linux provides a kind of general snapshot management method, effectively compensate for the defect cannot carrying out effective snapshot management existing for the existing cloud computing platform based on Virtual Machine Manager tool management virtual machines such as Libvirt, while providing good user's snapshot management to experience, ensure that the stability of cloud computing platform.
The present invention, mainly for the cloud computing platform using the provisional registration of the Virtual Machine Manager instruments such as Libvirt to carry out Virtual Machine Manager, has versatility for all cloud computing platforms carrying out Virtual Machine Manager based on Virtual Machine Manager instruments such as Libvirt.The virtual machine snapshot management method that the present invention proposes comprises virtual machine snapshot establishment, snapshot restore and snapshot and deletes three aspects, covers all main behavior operation of virtual machine snapshot management.The present invention, when not carrying out snapshot management, does not affect the normal work of cloud computing platform.
Other features and advantages of the present invention will be set forth in the following description, and, partly become apparent from instructions, or understand by implementing the present invention.Object of the present invention and other advantages realize by structure specifically noted in instructions, claims and accompanying drawing and obtain.
Accompanying drawing explanation
Accompanying drawing is used to provide a further understanding of the present invention, and forms a part for instructions, together with embodiments of the present invention for explaining the present invention, is not construed as limiting the invention.In the accompanying drawings:
Fig. 1 is the cloud computing platform general frame figure of the embodiment of the present invention;
Fig. 2 is the process flow diagram according to the establishment virtual machine snapshot in the snapshot management method of the cloud computing platform of the embodiment of the present invention one;
Fig. 3 is the process flow diagram according to the recovery virtual machine snapshot in the snapshot management method of the cloud computing platform of the embodiment of the present invention one;
Fig. 4 is the process flow diagram according to the deletion virtual machine snapshot in the snapshot management method of the cloud computing platform of the embodiment of the present invention one;
Fig. 5 is the structural representation of the snapshot management system based on cloud computing platform according to the embodiment of the present invention two.
Embodiment
Describe embodiments of the present invention in detail below with reference to drawings and Examples, to the present invention, how application technology means solve technical matters whereby, and the implementation procedure reaching technique effect can fully understand and implement according to this.It should be noted that, only otherwise form conflict, each embodiment in the present invention and each feature in each embodiment can be combined with each other, and the technical scheme formed is all within protection scope of the present invention.
In addition, can perform in the computer system of such as one group of computer executable instructions in the step shown in the process flow diagram of accompanying drawing, and, although show logical order in flow charts, but in some cases, can be different from the step shown or described by order execution herein.
The present invention mainly uses the Virtual Machine Manager instruments such as Libvirt to carry out the defect problem of cloud computing platform existence when carrying out snapshot management of Virtual Machine Manager to solve under Linux environment, proposes a kind of virtual machine snapshot management method based on cloud computing.
Embodiments of the invention comprise virtual machine snapshot establishment, snapshot restore and snapshot and delete three aspects, will be explained respectively by reference to the accompanying drawings.Preferably, embodiments of the invention adopt the cloud computing platform NKSCLOUD in acceptance of the bid kylin secure cloud operating system to realize various function and effect, and wherein cloud computing platform NKSCLOUD can use the provisional registration of Libvirt to carry out managing virtual machines.
Fig. 1 is according to the cloud computing platform general frame figure based on Virtual Machine Manager tool management virtual machines such as Libvirt under Linux of the present invention.Controlling vertex is the management end of cloud computing platform, runs all services managed cloud computing platform thereon, as network management, storage administration, Virtual Machine Manager, snapshot management and database service etc.Clustered node is to provide the server of virtual machine service, thereon except running multiple virtual machine, also run and carry out the Libvrit function library of Virtual Machine Manager and the virtualization management tool of virtualization is provided, such as KVM (Kernel-based Virtual Machine), Xen etc., KVM is the virtual machine monitor of increasing income be integrated in linux kernel, and Xen is the virtual machine monitor of increasing income developed by Cambridge University.KVM and Xen is the virtualization management tool of main flow under Linux.In cloud computing platform, allow existence Controlling vertex and multiple clustered node, Controlling vertex carries out corresponding management by network to multiple clustered node.
Embodiment one
Fig. 2 is the process flow diagram based on the establishment virtual machine snapshot in the snapshot management method of cloud computing platform according to the embodiment of the present invention one.Wherein the direction of arrow illustrates the direction of workflow.This flow process specifically comprises the following steps
Step S110, the Controlling vertex of cloud computing platform sends the order creating snapshot to virtual machine.
Step S111, Controlling vertex makes the preliminary work before snapshot creation.
Wherein specifically comprise: the record adding a new snapshot according to the input information of user in a database, this record comprises snapshot title, snapshot description, snapshot creation time etc., it is unavailable for arranging this snapshot state, and record this snapshot type for start snapshot or shutdown snapshot, concrete, Controlling vertex determines the type of recent snapshot according to virtual machine current operating conditions, if virtual machine is current for run, then snapshot type is start snapshot, if virtual machine current state is off-mode, then snapshot type is shutdown snapshot.
Step S112, Controlling vertex is selected snapshot type according to current virtual machine state and is performed corresponding steps.If virtual machine state is for run, then enter step S113, if virtual machine state is off-mode, then directly enter step S114.
Step S113, the long-range clustered node that is connected to of Controlling vertex calls Virtual Machine Manager instrument, first virtual machine is suspended, then current virtual machine state is preserved into file, namely memory image, after current virtual machine state success preserved by Virtual Machine Manager instrument, notice Controlling vertex, and enter step S115.
Step S114, Controlling vertex is long-range to be connected to clustered node and to call virtualization management tool and make disk snapshot to magnetic disk of virtual machine reflection.After clustered node does disk snapshot success to virtual machine, notice Controlling vertex, and enter step S117.
Step S115, Controlling vertex is long-range to be connected to clustered node and to call virtualization management tool and make disk snapshot to magnetic disk of virtual machine reflection.After clustered node does disk snapshot success to virtual machine, notice Controlling vertex.
Step S116, Controlling vertex is long-range to be connected to clustered node to call Virtual Machine Manager instrument by virtual machine is running status from the file access pattern preserved before.After Virtual Machine Manager tool operation runs succeeded, notice Controlling vertex.Enter step S117.
Step S117, the snapshot creation subsequent treatment that Controlling vertex carries out.
Specifically comprise: the snapshot state in Update Table storehouse is available, increase virtual machine snapshot reference count, and revise current active snapshot and create successful snapshot etc. for this.
Wherein, in step S111, add in a database snapshot record comprise check whether there is snapshot of the same name, whether existing snapshot number reaches the upper limit etc.
Wherein, in step S113, the file (that is, memory image) of establishment saves total data in the middle of virtual machine current memory and current C PU buffer status.This file can be saved, to use as memory image when recovering virtual machine.
Wherein, in step S113, S114, S115 and S116, if operation failure, be defined as this snapshot creation failure, delete snapshot record corresponding in Controlling vertex database.
Wherein, in step S114 and S115, the disk snapshot that virtualization management tool produces is kept in the middle of magnetic disk of virtual machine reflection, is not kept at the outside of disk image.
As from the foregoing, when creating virtual machine snapshot, if the state of virtual machine is for run, then described virtual machine snapshot comprises created memory image and the disk snapshot created, otherwise described virtual machine snapshot comprises created disk snapshot.
Thus, according to the visioning procedure of Fig. 2, can by judging the running status establishment start snapshot that virtual machine is current or shutdown snapshot.
Fig. 3 is the process flow diagram according to the recovery virtual machine snapshot in the snapshot management method of the embodiment of the present invention, and wherein the direction of arrow illustrates the direction of workflow.Specifically comprise the following steps:
Step S210, cloud computing platform Controlling vertex sends the order recovering virtual machine snapshot to virtual machine.
Step S211, Controlling vertex makes the preliminary work before snapshot restore.
Specifically comprise: search the snapshot, acquisition virtual machine current state, acquisition snapshot type etc. of specifying in a database according to the snapshot name of user's input.
Step S212, judges if the state of virtual machine is for run, then to enter into the running status that virtual machine is current step S213, otherwise enter into step S214.
Step S213, judges whether snapshot type to be restored is start snapshot, if then enter into step S215, otherwise enters into step S217.
Step S214, judges whether snapshot type to be restored is start snapshot, if then enter into step S216, otherwise enters into step S218.
Step S215, the long-range clustered node that is connected to of Controlling vertex calls Virtual Machine Manager instrument, first virtual machine is suspended, then (namely current virtual machine state is preserved into file, save as memory image), after virtual machine success preserved by Virtual Machine Manager instrument, notice Controlling vertex, and enter step S216.
Step S216, clustered node calls virtualization management tool and carries out disk recovery operation according to the snapshot of specifying to magnetic disk of virtual machine, and clustered node, to after the disk snapshot recovery operation success of virtual machine, notifies Controlling vertex, and enters step S219.
Step S217, clustered node calls Virtual Machine Manager instrument and carries out power-off operation to current virtual machine, and enters step S218.
Step S218, clustered node calls virtualization management tool and carries out disk recovery operation according to the snapshot of specifying to magnetic disk of virtual machine, and clustered node, to after the disk snapshot recovery operation success of virtual machine, notifies Controlling vertex, and enters step S220.It should be noted that, comprise two step S218 in fig. 2, these two steps are same steps, are only and draw convenient and separately represent.
Step S219, clustered node calls Virtual Machine Manager instrument, according to the memory image file of specifying, virtual machine is reverted to running status.After Virtual Machine Manager tool operation runs succeeded, notice Controlling vertex, and enter step S220.
Step S220, Controlling vertex carries out subsequent treatment to snapshot restore.
Specifically comprise: amendment current active snapshot is the snapshot etc. that this is successfully recovered;
Be more than recover the flow process of snapshot, wherein, in step S211, find the snapshot of specifying, comprise the memory image name, disk snapshot name and this snapshot that obtain this snapshot and the relevant SNAPSHOT INFO such as whether can to use.The file preserved by virtual machine state in step S215 uses to prevent virtual machine cannot being returned to correct running status when snapshot restore procedure failure.
Wherein, in step S215, if operation failure, namely virtual machine is preserved into file failure by Virtual Machine Manager instrument, and virtual machine can be reverted to running status by Virtual Machine Manager instrument automatically.
Wherein, in step S216 and S218, if operation failure, be defined as this snapshot restore operation failure, virtual machine is reverted to running status by the file according to the preservation in step S215.
Thus, according to the recovery flow process of Fig. 3, by judging the type of the running status that virtual machine is current and appointment snapshot, snapshot can be recovered, when can preserve to avoid recovering failure to virtual machine running status, virtual machine cannot be returned to correct running status simultaneously.
Fig. 4 is the process flow diagram according to the deletion virtual machine snapshot in the snapshot management method of the embodiment of the present invention, and wherein the direction of arrow illustrates the direction of workflow.Specifically comprise the following steps:
Step S310, cloud computing platform Controlling vertex sends the order of deleting virtual machine snapshot to virtual machine.
Step S311, Controlling vertex does the preliminary work before snapshot deletion.Specifically comprise: search snapshot, virtual machine current operating conditions etc. in a database.
Step S312, judges the running status that virtual machine is current.If virtual machine state is for run, enter step S313, otherwise enter step S316.
Step S313, clustered node calls Virtual Machine Manager instrument and fixes tentatively this virtual machine.After Virtual Machine Manager instrument suspends virtual machine success, notice Controlling vertex.
Step S314, Controlling vertex is long-range to be connected to clustered node and to delete memory image and call virtualization management tool and delete the disk snapshot of specifying.After clustered node deletes corresponding snapshot document, notice Controlling vertex, and enter step S315.
Step S315, Controlling vertex is long-range to be connected to clustered node and to call Virtual Machine Manager instrument and reverted to by time-out by virtual machine state and run, after Virtual Machine Manager tool operation runs succeeded, notice Controlling vertex, and enter step S317.
Step S316, Controlling vertex is long-range to be connected to clustered node and to delete memory image and call virtualization management tool and delete the disk snapshot of specifying.After clustered node deletes corresponding snapshot document, notice Controlling vertex, and enter step S317.
Step S317, cloud computing platform carries out the subsequent treatment of snapshot deletion.
Specifically comprise: the snapshot record in delete database, reduce virtual machine available snapshot counting, amendment current active snapshot etc.
Wherein, in step S311, find the snapshot of specifying, comprise the memory image name, disk snapshot name etc. that obtain this snapshot.
Wherein, the time-out virtual machine of step S313 can not have an impact to the operating system run when operating magnetic disk of virtual machine reflection to ensure.
Wherein, in step S313, S315 and S316, if operation failure, then define this and delete snapshot operation failure, this snapshot of clustered node notice Controlling vertex is deleted unsuccessfully, and Controlling vertex returns results according to different orders and carries out corresponding subsequent treatment.
Wherein, in step S314, if operation failure, then define this and delete snapshot operation failure, clustered node calls Virtual Machine Manager instrument and is reverted to by time-out by virtual machine state and run.
Wherein, in step S314 and S316, Controlling vertex can judge snapshot type, if snapshot type is start snapshot, then according to the execution described in step S314 and S316; If snapshot type is shutdown snapshot, then clustered node only need delete disk snapshot.
Embodiment two
Fig. 5 is the structural representation of the snapshot management system based on cloud computing platform according to the embodiment of the present invention two, describes the composition of this system components below according to Fig. 5 in detail.
Virtual machine state judging unit, for judging whether the current state of virtual machine is just in running status.
Snapshot type judging unit, for judging that snapshot type is start snapshot or shutdown snapshot.
Snapshot creation unit, creates memory image for calling Virtual Machine Manager instrument, and calls virtualization management tool establishment disk snapshot.Concrete, be just operationally create start snapshot in the state of virtual machine, create shutdown snapshot when virtual machine is off-mode, start snapshot comprises memory image and disk snapshot two parts, and shutdown snapshot only comprises disk snapshot.Call Virtual Machine Manager instrument by the long-range clustered node that is connected to of the Controlling vertex of cloud computing platform current virtual machine state is preserved into file to form memory image.By Controlling vertex long-range be connected to clustered node call virtualization management tool to magnetic disk of virtual machine reflection make disk snapshot.
Snapshot restore unit, recovers described memory image for calling described Virtual Machine Manager instrument, and calls described virtualization management tool and recover described disk snapshot.Concrete, be in just under operation at virtual machine, for start snapshot, first call Virtual Machine Manager instrument by the long-range clustered node that is connected to of Controlling vertex (namely current virtual machine state is preserved into file, save as memory image), recycling clustered node calls virtualization management tool and carries out disk recovery operation according to the disk snapshot of specifying to magnetic disk of virtual machine, calls Virtual Machine Manager instrument, according to the memory image file of specifying, virtual machine is reverted to running status; For shutdown snapshot, first utilize clustered node to call Virtual Machine Manager instrument and carry out power-off operation to current virtual machine, recycling clustered node calls virtualization management tool and carries out disk recovery operation according to the disk snapshot of specifying to magnetic disk of virtual machine.In the power-offstate, for start snapshot, utilize clustered node to call virtualization management tool, according to the disk snapshot of specifying, disk recovery operation is carried out to magnetic disk of virtual machine, call Virtual Machine Manager instrument, according to the memory image file of specifying, virtual machine is reverted to running status; For shutdown snapshot, clustered node calls virtualization management tool and carries out disk recovery operation according to the disk snapshot of specifying to magnetic disk of virtual machine.
Snapshot delete cells, deletes described memory image for calling described Virtual Machine Manager instrument, and calls described virtualization management tool and delete described disk snapshot.Concrete, be in just under operation at virtual machine, first clustered node is utilized to suspend virtual machine, recycling Controlling vertex is long-range to be connected to clustered node and to call Virtual Machine Manager instrument and delete memory image and call virtualization management tool and delete the disk snapshot of specifying, and utilizes the long-range clustered node that is connected to of Controlling vertex to call Virtual Machine Manager instrument and reverted to by time-out by virtual machine state and run afterwards; In the power-offstate, the long-range clustered node that is connected to of Controlling vertex is directly utilized to call Virtual Machine Manager instrument and delete memory image and call virtualization management tool and delete the disk snapshot of specifying.
The present invention is all under being applicable to Linux applies the cloud computing platform that the Virtual Machine Manager instruments such as Libvirt carry out Virtual Machine Manager.Virtual machine snapshot management method provided by the invention effectively solves and uses the Virtual Machine Manager instruments such as Libvirt to carry out the defect problem of virtual machine snapshot management in cloud computing environment.Virtual machine snapshot management method provided by the invention comprises cloud computing platform to the establishment of virtual machine snapshot, recovery and deletion.
The present invention is only described for the cloud computing platform NKSCLOUD got the bid in kylin secure cloud operating system, and in fact the Virtual Machine Manager instrument such as all application Libvirt carries out the snapshot management of the cloud computing platform of Virtual Machine Manager all within solution scope of the present invention.
Those skilled in the art should be understood that, above-mentioned of the present invention each module or each step can realize with general calculation element, they can concentrate on single calculation element, or be distributed on network that multiple calculation element forms, alternatively, they can realize with the executable program code of calculation element, thus, they can be stored and be performed by calculation element in the storage device, or they are made into each integrated circuit modules respectively, or the multiple module in them or step are made into single integrated circuit module to realize.Like this, the present invention is not restricted to any specific hardware and software combination.
Although the embodiment disclosed by the present invention is as above, the embodiment that described content just adopts for the ease of understanding the present invention, and be not used to limit the present invention.Technician in any the technical field of the invention; under the prerequisite not departing from the spirit and scope disclosed by the present invention; any amendment and change can be done what implement in form and in details; but scope of patent protection of the present invention, the scope that still must define with appending claims is as the criterion.

Claims (9)

1. a cloud computing platform virtual machine snapshot management method, is characterized in that, the Controlling vertex of cloud computing platform, by the multiple clustered node of network management, when being the virtual machine creating virtual machine snapshot of clustered node, performs following steps:
Preparation process: if the state of described virtual machine is for run, described virtual machine to suspend by calling Virtual Machine Manager instrument in clustered node and to create the memory image of described virtual machine by the Controlling vertex of cloud computing platform;
Disk snapshot step: described Controlling vertex calls virtualization management tool in clustered node to create the disk snapshot of described virtual machine, wherein, if the state of described virtual machine is for run, the type of created virtual machine snapshot is set to snapshot of starting shooting, otherwise, then the type of created virtual machine snapshot is set to the snapshot that shuts down;
When created virtual machine snapshot will be utilized to recover described virtual machine, perform subsequent processing steps: if the current state of described virtual machine is for run, then by memory image that the virtualization management tool called in described clustered node utilizes described preparation process to create, the state that described virtual machine is returned to when memory image is created is run, wherein
When to utilize created virtual machine snapshot type for the virtual machine snapshot of snapshot of starting shooting to recover described virtual machine time, if the state of current described virtual machine is not running, then utilize disk snapshot in the virtual machine snapshot that creates and memory image to recover described virtual machine.
2. method according to claim 1, it is characterized in that, when created virtual machine snapshot will be utilized to recover described virtual machine, described Controlling vertex recovers the disk snapshot of described virtual machine by the disk snapshot calling described virtualization management tool and utilize described disk snapshot step to generate.
3. method according to claim 1, is characterized in that, when to utilize created virtual machine snapshot type for the virtual machine snapshot of snapshot of starting shooting to recover described virtual machine time:
If the state of current described virtual machine is for run, then first call Virtual Machine Manager instrument and suspend virtual machine, and current virtual machine state is preserved into memory image, the disk snapshot in the virtual machine snapshot that recycling creates and memory image are to recover described virtual machine.
4. method according to claim 1, is characterized in that, when to utilize created virtual machine snapshot type for the virtual machine snapshot of snapshot of shutting down to recover described virtual machine time,
If the state of current described virtual machine is running, then first call Virtual Machine Manager instrument and closed by virtual machine, the disk snapshot in the snapshot that recycling creates is to recover described virtual machine; And
If the state of current described virtual machine is not running, then utilize disk snapshot in the virtual machine snapshot that creates to recover described virtual machine.
5. method according to claim 1, is characterized in that, when deleting the virtual machine snapshot created,
If the state of current described virtual machine is running, then first call described Virtual Machine Manager instrument and suspend described virtual machine, after deleting the virtual machine snapshot that creates, then call described Virtual Machine Manager instrument and recover described virtual machine;
If the state of current described virtual machine is not running, then directly delete the virtual machine snapshot created.
6. method according to claim 5, is characterized in that, calls described Virtual Machine Manager instrument and deletes memory image, and calls virtualization management tool and delete disk snapshot.
7. according to any one method described in claim 1 to 6, it is characterized in that, described Virtual Machine Manager instrument is Libvirt, and described virtualization management tool is KVM or Xen.
8. based on a virtual machine snapshot management system for cloud computing platform, it is characterized in that, comprise with lower unit:
Virtual machine state judging unit, for judging whether the current state of described virtual machine is just in running status;
Snapshot type judging unit, for judging that described snapshot type is as start snapshot or shutdown snapshot, if the state of described virtual machine is for run, is set to snapshot of starting shooting by the type of created virtual machine snapshot, otherwise, then the type of created virtual machine snapshot is set to the snapshot that shuts down;
Snapshot creation unit, creates memory image for the Virtual Machine Manager instrument called by the Controlling vertex of cloud computing platform in clustered node, and the virtualization management tool called in clustered node creates disk snapshot;
Snapshot restore unit, for the Virtual Machine Manager instrument called in described clustered node, described memory image is recovered, and the virtualization management tool called in described clustered node is recovered described disk snapshot, wherein, when to utilize created virtual machine snapshot type for the virtual machine snapshot of snapshot of starting shooting to recover described virtual machine time, if the state of current described virtual machine is not running, then utilize disk snapshot in the virtual machine snapshot that creates and memory image to recover described virtual machine;
Snapshot delete cells, deletes described memory image for the Virtual Machine Manager instrument called in described clustered node, and the virtualization management tool called in described clustered node is deleted described disk snapshot.
9. system according to claim 8, is characterized in that, described Virtual Machine Manager instrument is Libvirt, and described virtualization management tool is KVM or Xen.
CN201110397190.1A 2011-12-02 2011-12-02 A kind of virtual machine snapshot management method of cloud computing platform and system Active CN102520881B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201110397190.1A CN102520881B (en) 2011-12-02 2011-12-02 A kind of virtual machine snapshot management method of cloud computing platform and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201110397190.1A CN102520881B (en) 2011-12-02 2011-12-02 A kind of virtual machine snapshot management method of cloud computing platform and system

Publications (2)

Publication Number Publication Date
CN102520881A CN102520881A (en) 2012-06-27
CN102520881B true CN102520881B (en) 2015-09-09

Family

ID=46291826

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201110397190.1A Active CN102520881B (en) 2011-12-02 2011-12-02 A kind of virtual machine snapshot management method of cloud computing platform and system

Country Status (1)

Country Link
CN (1) CN102520881B (en)

Families Citing this family (29)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103853632B (en) * 2012-12-07 2016-08-10 华为技术有限公司 Snapshot Method, service node, main controlled node and system
CN104572138B (en) * 2013-10-10 2018-10-30 腾讯科技(深圳)有限公司 The startup method and device of application program
CN104636125B (en) * 2013-11-13 2018-03-23 联想(北京)有限公司 A kind of information processing method and device
CN103729223A (en) * 2013-12-31 2014-04-16 曙光云计算技术有限公司 PAAS platform quick deployment and application method and system
CN104793981B (en) * 2014-01-20 2018-08-31 联想(北京)有限公司 A kind of online snapshot management method and device of cluster virtual machine
CN105022656B (en) * 2014-04-21 2018-09-14 中国电信股份有限公司 virtual machine snapshot management method and device
CN104375877A (en) * 2014-10-15 2015-02-25 国云科技股份有限公司 Virtual machine online snapshot generating and deleting method
CN105354127A (en) * 2015-10-27 2016-02-24 北京天华星航科技有限公司 Cloud management platform based monitoring method
CN105468433B (en) * 2015-11-19 2019-03-29 北京北信源软件股份有限公司 A kind of acquisition methods and system of magnetic disk of virtual machine data
CN105446834B (en) 2015-11-30 2018-10-19 华为技术有限公司 The generation method and device of virtual machine snapshot
CN105740042B (en) * 2016-01-15 2019-07-02 北京京东尚科信息技术有限公司 The management method and management system of virutal machine memory
CN107179934B (en) * 2016-03-10 2021-03-05 中标软件有限公司 Method and system for automatically restoring virtual machine in cloud computing environment
WO2017190758A1 (en) * 2016-05-02 2017-11-09 Nokia Solutions And Networks Oy Snapshot creation in virtual network environment
CN106293535B (en) * 2016-08-12 2020-04-03 浪潮(北京)电子信息产业有限公司 NAS performance optimization method and device
CN106775939B (en) * 2016-12-06 2019-12-31 爱普(福建)科技有限公司 Memory snapshot management method in industrial control system
CN109002343B (en) * 2017-06-07 2023-08-25 中兴通讯股份有限公司 Method and device for realizing batch creation of virtual machines
CN109032327A (en) * 2018-07-26 2018-12-18 郑州云海信息技术有限公司 A kind of energy consumption of virtual machine management method and device
CN109101323A (en) * 2018-09-10 2018-12-28 南京铱迅信息技术股份有限公司 Snapshot implementing method based on qcow2 format under virtual machine operating status
CN109284171A (en) * 2018-09-17 2019-01-29 广州惠创信息科技有限公司 A kind of privately owned cloud management platform of enterprise
CN109358947B (en) * 2018-10-08 2023-01-10 郑州云海信息技术有限公司 Method and system for realizing virtual machine snapshot
CN109739687A (en) * 2018-12-03 2019-05-10 国云科技股份有限公司 A kind of snapshot management system and method based on Elasticsearch
CN110502392A (en) * 2019-07-17 2019-11-26 华东计算技术研究所(中国电子科技集团公司第三十二研究所) Cloud platform management and monitoring system
CN110865873A (en) * 2019-11-20 2020-03-06 西安雷风电子科技有限公司 Dynamic shutdown and recovery method for virtual machine resources
CN111078368B (en) * 2019-12-26 2023-03-21 浪潮电子信息产业股份有限公司 Memory snapshot method and device of cloud computing platform virtual machine and readable storage medium
CN111158954A (en) * 2019-12-29 2020-05-15 北京浪潮数据技术有限公司 Cloud host snapshot method, system, equipment and computer readable storage medium
CN114237988B (en) * 2022-02-25 2022-06-03 广州锦行网络科技有限公司 Memory snapshot processing method and device, storage medium and electronic device
CN114968670B (en) * 2022-07-27 2022-11-18 国网信息通信产业集团有限公司 Virtual machine backup and recovery method and device
CN117093332B (en) * 2023-10-20 2024-02-27 杭州优云科技有限公司 Method and device for realizing cloning of virtual machine
CN117130980B (en) * 2023-10-24 2024-02-27 杭州优云科技有限公司 Virtual machine snapshot management method and device

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5089429B2 (en) * 2008-02-21 2012-12-05 キヤノン株式会社 Information processing apparatus, control method therefor, and program
CN101770410B (en) * 2009-01-07 2016-08-17 联想(北京)有限公司 System reducing method based on client operating system, virtual machine manager and system
CN101609419B (en) * 2009-06-29 2012-05-30 北京航空航天大学 Continuous on-line transferring data backup method of virtual machine and device thereof
JP5440273B2 (en) * 2010-03-09 2014-03-12 富士通株式会社 Snapshot management method, snapshot management device, and program
CN102147843A (en) * 2011-05-16 2011-08-10 湖南大学 Rootkit intrusion detection and system recovery method based on inner core invariant protection

Also Published As

Publication number Publication date
CN102520881A (en) 2012-06-27

Similar Documents

Publication Publication Date Title
CN102520881B (en) A kind of virtual machine snapshot management method of cloud computing platform and system
US20220114067A1 (en) Systems and methods for instantiation of virtual machines from backups
US11544137B2 (en) Data processing platform monitoring
CN104102506B (en) A kind of Android Acceleration of starting methods based on ARM platforms
CN107329799A (en) A kind of fusion Docker containers and the system of KVM virtualization technology
CN103077071B (en) The acquisition methods of a kind of KVM virtual machine progress information and system
US8893272B2 (en) Method and device for recombining runtime instruction
CN112035172A (en) Operating system starting method, device, server and storage medium
WO2014024055A1 (en) Image instance mapping
US20050257090A1 (en) Method of restoring processes within process domain
CN103077034B (en) hybrid virtualization platform JAVA application migration method and system
CN111656325B (en) Fast recovery from failures in a time-ordered log-structured key-value storage system
CN109240809A (en) Process maintenance management method, container maintaining method, device and operating system
CN113419817A (en) Front-end application nesting method, device, equipment and storage medium
US20210286645A1 (en) Transferral Of Process State And/Or Components In Computing Environments
CN105183591A (en) High-availability cluster implementation method and system
CN108205440A (en) A kind of task flow framework implementation method for supporting rollback
CN108369549B (en) Versioned record management computing system, method and computer readable medium
Giuffrida et al. A taxonomy of live updates
CN117520049A (en) Backup restoration method and device of operating system, electronic equipment and storage medium
CN105843881A (en) Picture processing url mapping method and apparatus
CN105787359A (en) Course guarding method and device
Pan et al. Design and Implementation of Server Management System Based on Docker
CN102419806A (en) Batch off-line anti-virus method of virtual machines
CN113326098B (en) Cloud management platform supporting KVM virtualization and container virtualization

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant