CN105279011A - Method for performing system restoring on virtual machine according to mirror image - Google Patents

Method for performing system restoring on virtual machine according to mirror image Download PDF

Info

Publication number
CN105279011A
CN105279011A CN201510789206.1A CN201510789206A CN105279011A CN 105279011 A CN105279011 A CN 105279011A CN 201510789206 A CN201510789206 A CN 201510789206A CN 105279011 A CN105279011 A CN 105279011A
Authority
CN
China
Prior art keywords
virtual machine
mirror image
snapshot
restoring
carry out
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
CN201510789206.1A
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.)
G Cloud Technology Co Ltd
Original Assignee
G Cloud Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by G Cloud Technology Co Ltd filed Critical G Cloud Technology Co Ltd
Priority to CN201510789206.1A priority Critical patent/CN105279011A/en
Publication of CN105279011A publication Critical patent/CN105279011A/en
Pending legal-status Critical Current

Links

Landscapes

  • Storage Device Security (AREA)

Abstract

The invention relates to the technical field of cloud computing, and particularly to a method for performing system restoring on a virtual machine according to a mirror image. The method comprises the steps of selecting the mirror image, shutting the virtual machine down, performing external snapshot according to the mirror image for restoring, restarting the virtual machine after restoring succeeds, and restoring the system of the virtual machine to the selected mirror image system. No storage space is occupied in creating the external snapshot. The snapshot can be directly replaced according to a system disc snapshot path of the virtual machine. Furthermore the mirror image can be selected for restoring the system of a random mirror image. The method of the invention satisfies a requirement of restoring the virtual machine to other systems according to the mirror image, and furthermore can realize restoring of the virtual machine system to an initial state through selecting or no selecting of the mirror image after system breakdown or operating system collapse caused by virus infection or malicious attack, etc., thereby shortening time in stopping applications and services. The method of the invention can be used for restoring the virtual machine system.

Description

A kind of virtual machine can carry out the method for system reducing according to mirror image
Technical field
The present invention relates to field of cloud computer technology, refer in particular to a kind of virtual machine can carry out system reducing method according to mirror image.
Background technology
Under the megatrend of cloud computing development, no matter be physical machine or virtual machine, a lot of user, in the process used, has the demand of replacing system or restoring system, wish virtual machine be replaced with its system selected or revert to the initial state of original system, facilitate it to use.Such as user needs upgrade-system, or incompatible the causing of system needs replacing system etc.; Particularly run the virtual machine of application and service, often faced the danger of virus and malicious attack, the probability of delay machine and operating system collapse is higher.Therefore, need to reduce or replacing system to the system disk of virtual machine, an initial normal state can be quickly recovered to after operating system collapse, the time that application and service stops is shortened as far as possible.Main to change system for main analysis below.
The method of typically changing system to virtual machine is exactly that user needs the system downloading other again to install step by step again, just can convert thereof into other system.And following problem can be brought:
One is want replacing system inconvenient, needs user manually to go to download mirror image, then installs, download and install length consuming time;
Two is that some user may be bad to download and install mirror image, brings inconvenience to a certain extent;
Three is may maloperation occur and cause correctly installing when allowing user install voluntarily, or is configured with misleading and causes and cannot normally work;
Four to be that user obtains the approach of mirror image various, and the mirror image of acquisition cannot ensure its security, may contain malicious code or virus, once outburst, will cause great impact to the network of cloud computing center;
The efficiency of system is changed in order to promote virtual machine, strengthen the convenience that virtual machine changes system, need a kind of virtual machine can carry out the method for system reducing according to mirror image, one key is reduced into the system that user needs, can also solve virtual machine due to poisoning or by the reasons such as malicious attack cause the machine of delaying and operating system collapse after, a key reverts to the state of a normal system.
Summary of the invention
The technical matters that the present invention solves is to provide a kind of virtual machine can carry out the method for system reducing according to mirror image, solve the demand that user can be reduced into virtual machine according to mirror image other system, can also solve virtual machine due to poisoning or by the reasons such as malicious attack cause the machine of delaying and operating system collapse after, by selecting or not selecting mirror image to reduce dummy machine system to initial state, the time that application and service is stopped shortens as far as possible.
The technical scheme that the present invention solves the problems of the technologies described above is:
Step 1, runs a virtual machine at the outside snapshot of host image file, during establishment, all for creating system disk in virtual machine image file;
Step 2, selects mirror image;
Step 3, judges whether virtual machine shuts down, and is shut down when not shutting down, if shutdown directly performs step 4;
Step 4, fill order, creates the outside snapshot of virtual machine, directly replaces original virtual machine snapshot;
Step 5, after snapshot success, judges the state that virtual machine starts most, if shutdown just directly performs step 6, otherwise is just started shooting;
Step 6, mirror image reduction terminates.
The mirror image that described virtual machine can be selected according to user carry out the reduction of system, can be reverted to user-selected system, if do not select the mirror image of mirror image so virtual machine to remain unchanged, is just reverted to initial state.
Described virtual machine directly can carry out snapshot, no longer takies the space of storage, directly can replace virtual machine snapshot according to the system disk snapshot path of virtual machine.
The reduction of described mirror image can at virtual machine due to poisoning or caused the machine of delaying and operating system collapse by reasons such as malicious attacks after, and by selecting or not selecting mirror image to reduce dummy machine system to initial state, the time that application and service is stopped tries one's best shortening.
The mirror image that virtual machine of the present invention can be selected according to user carry out the reduction of system, can be reverted to user-selected system, if do not select the mirror image of mirror image so virtual machine to remain unchanged, is just reverted to initial state.Directly can carry out snapshot, no longer take the space of storage, directly can replace virtual machine snapshot according to the system disk snapshot path of virtual machine.Can virtual machine due to poisoning or caused by reasons such as malicious attacks the machine of delaying and operating system collapse after, by select or do not select mirror image reduce dummy machine system to initial state, the time that application and service is stopped try one's best shortening.
Accompanying drawing explanation
Below in conjunction with accompanying drawing, the present invention is further described:
Fig. 1 is process flow diagram of the present invention;
Fig. 2 is whether the present invention selects mirror image process flow diagram.
Embodiment
As Fig. 1, shown in 2.Idiographic flow of the present invention is as follows:
1. create an outside snapshot at host image file, then create a virtual machine with this outside snapshot as the system disk of virtual machine
Qemu-imgcreate-b mirror path-fqcow2 system disk snapshot path mirror image size G
2. judge whether user selects mirror image, judge whether mirror image meets the demand creating virtual machine, if do not select mirror image to revert to an initial state of virtual machine original system;
3. judge whether virtual machine shuts down, if shutdown does not just call shutdown command;
4. perform the order of mirror image reduction, directly replace original virtual machine system disk snapshot;
Qemu-imgcreate-b mirror path-fqcow2 system disk snapshot path mirror image size G
5. check whether snapshot creates successfully;
Qemu-imginfo system disk snapshot path
6., after creating snapshot success, judge the state that virtual machine is original, if start, power-on command will be called again and be started shooting;
7. long-rangely after start check whether virtual machine has been replaced with other system or the initial state of the system that reverts to.

Claims (5)

1. virtual machine can carry out a method for mirror image reduction according to system, it is characterized in that: described method comprises the steps:
Step 1, runs a virtual machine at the outside snapshot of host image file, during establishment, all for creating system disk in virtual machine image file;
Step 2, selects mirror image;
Step 3, judges whether virtual machine shuts down, and is shut down when not shutting down, if shutdown directly performs step 4;
Step 4, fill order, creates the outside snapshot of virtual machine, directly replaces original virtual machine snapshot;
Step 5, after snapshot success, judges the state that virtual machine starts most, if shutdown just directly performs step 6, otherwise is just started shooting;
Step 6, mirror image reduction terminates.
2. a kind of virtual machine according to claim 1 can carry out the method for system reducing according to mirror image, it is characterized in that: the mirror image that described virtual machine can be selected according to user carries out the reduction of system, user-selected system can be reverted to, if do not select the mirror image of mirror image so virtual machine to remain unchanged, just reverted to initial state.
3. a kind of virtual machine according to claim 1 can carry out the method for system reducing according to mirror image, it is characterized in that: described virtual machine directly can carry out snapshot, no longer take the space of storage, directly can replace virtual machine snapshot according to the system disk snapshot path of virtual machine.
4. a kind of virtual machine according to claim 2 can carry out the method for system reducing according to mirror image, it is characterized in that: described virtual machine directly can carry out snapshot, no longer take the space of storage, directly can replace virtual machine snapshot according to the system disk snapshot path of virtual machine.
5. a kind of virtual machine according to any one of Claims 1-4 can carry out the method for system reducing according to mirror image, it is characterized in that: the reduction of described mirror image can at virtual machine due to poisoning or caused the machine of delaying and operating system collapse by reasons such as malicious attacks after, by selecting or not selecting mirror image to reduce dummy machine system to initial state, the time that application and service is stopped shortens as far as possible.
CN201510789206.1A 2015-11-17 2015-11-17 Method for performing system restoring on virtual machine according to mirror image Pending CN105279011A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510789206.1A CN105279011A (en) 2015-11-17 2015-11-17 Method for performing system restoring on virtual machine according to mirror image

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510789206.1A CN105279011A (en) 2015-11-17 2015-11-17 Method for performing system restoring on virtual machine according to mirror image

Publications (1)

Publication Number Publication Date
CN105279011A true CN105279011A (en) 2016-01-27

Family

ID=55148066

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510789206.1A Pending CN105279011A (en) 2015-11-17 2015-11-17 Method for performing system restoring on virtual machine according to mirror image

Country Status (1)

Country Link
CN (1) CN105279011A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107179934A (en) * 2016-03-10 2017-09-19 中标软件有限公司 The method and system of virtual machine automatic reduction in cloud computing environment
CN107463467A (en) * 2017-08-24 2017-12-12 浪潮(北京)电子信息产业有限公司 A kind of method and system that can quickly reduce virtual platform
CN107783816A (en) * 2016-08-31 2018-03-09 阿里巴巴集团控股有限公司 The method and device that creation method and device, the big data cluster of virtual machine create
CN110968399A (en) * 2019-12-18 2020-04-07 腾讯科技(深圳)有限公司 Virtual machine reloading method and device and computer readable storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102799522A (en) * 2012-06-28 2012-11-28 浪潮(北京)电子信息产业有限公司 Managing method and system for software version tracing test
CN103473065A (en) * 2013-09-18 2013-12-25 国云科技股份有限公司 Virtual machine creation method capable of rapidly restoring system disk
CN103729264A (en) * 2013-12-23 2014-04-16 国云科技股份有限公司 Method for backing up and restoring Windows virtual machine system disk
US20140365740A1 (en) * 2013-06-10 2014-12-11 Veeam Software Ag Virtual Machine Backup from Storage Snapshot
CN104407931A (en) * 2014-10-28 2015-03-11 国云科技股份有限公司 Method for obtaining mirror image of damaged system disk of virtual machine
US20150186044A1 (en) * 2013-12-30 2015-07-02 Symantec Corporation Systems and methods for improving snapshot performance

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102799522A (en) * 2012-06-28 2012-11-28 浪潮(北京)电子信息产业有限公司 Managing method and system for software version tracing test
US20140365740A1 (en) * 2013-06-10 2014-12-11 Veeam Software Ag Virtual Machine Backup from Storage Snapshot
CN103473065A (en) * 2013-09-18 2013-12-25 国云科技股份有限公司 Virtual machine creation method capable of rapidly restoring system disk
CN103729264A (en) * 2013-12-23 2014-04-16 国云科技股份有限公司 Method for backing up and restoring Windows virtual machine system disk
US20150186044A1 (en) * 2013-12-30 2015-07-02 Symantec Corporation Systems and methods for improving snapshot performance
CN104407931A (en) * 2014-10-28 2015-03-11 国云科技股份有限公司 Method for obtaining mirror image of damaged system disk of virtual machine

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107179934A (en) * 2016-03-10 2017-09-19 中标软件有限公司 The method and system of virtual machine automatic reduction in cloud computing environment
CN107179934B (en) * 2016-03-10 2021-03-05 中标软件有限公司 Method and system for automatically restoring virtual machine in cloud computing environment
CN107783816A (en) * 2016-08-31 2018-03-09 阿里巴巴集团控股有限公司 The method and device that creation method and device, the big data cluster of virtual machine create
CN107463467A (en) * 2017-08-24 2017-12-12 浪潮(北京)电子信息产业有限公司 A kind of method and system that can quickly reduce virtual platform
CN107463467B (en) * 2017-08-24 2020-10-02 浪潮(北京)电子信息产业有限公司 Method and system capable of quickly restoring virtualization platform
CN110968399A (en) * 2019-12-18 2020-04-07 腾讯科技(深圳)有限公司 Virtual machine reloading method and device and computer readable storage medium
CN110968399B (en) * 2019-12-18 2023-09-22 腾讯科技(深圳)有限公司 Virtual machine reloading method and device and computer readable storage medium

Similar Documents

Publication Publication Date Title
CN105138382B (en) A kind of method and terminal of android system upgrading
KR101673299B1 (en) Operating system recovery method and apparatus, and terminal device
CN105279011A (en) Method for performing system restoring on virtual machine according to mirror image
US8499202B2 (en) Method and system for recovery of a computing environment during pre-boot and runtime phases
CN103729264A (en) Method for backing up and restoring Windows virtual machine system disk
CN104205045A (en) Providing an immutable antivirus payload for internet ready compute nodes
CN107329792B (en) Docker container starting method and device
WO2016101519A1 (en) Method and device for realizing restart of operating system
US11875174B2 (en) Method and apparatus for virtual machine emulator upgrading virtualization emulator
CN105825131A (en) Computer security startup protection method on basis of UEFI (Unified Extensible Firmware Interface)
CN107707687A (en) A kind of method and apparatus of virtual machine IP address configuration
KR101284403B1 (en) System and method for customizing a scsi error response received from a scsi target in a storage network environment
EP3079057A1 (en) Method and device for realizing virtual machine introspection
US10915624B2 (en) Method and apparatus for determining behavior information corresponding to a dangerous file
CN102053848A (en) Automatic installation method for Linux operating system
CN102880478B (en) Oftware updating method
CN110688235B (en) System and method for sharing wireless connection information between UEFI firmware and OS
US20190068772A1 (en) Computer system and method thereof for bluetooth data sharing between uefi firmware and os
CN104346572A (en) Construction method of universal external intelligent terminal safety operation environment
CN102945193A (en) Recovery method of running data, and electronic device
WO2016145798A1 (en) Upgrading method and upgrading apparatus for application program of embedded system
EP2835737A1 (en) Data terminal running mode switching method, device, and data terminal
CN104461757A (en) Method and device for restoring virtual machines
CN107357682A (en) A kind of method and device for recovering to go back original system
WO2017020460A1 (en) Method and apparatus for integrating plugin

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
WD01 Invention patent application deemed withdrawn after publication
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20160127