[one-users] how to change disk-snapshot from deferred to hot (--live) from CLI

Carlos Martín Sánchez cmartin at opennebula.org
Mon Oct 21 09:30:55 PDT 2013


Hi,

A snapshot procedure cannot be cancelled. But if you really need to save
the VM contents, you can edit the DB manually.

To do so, stop opennebula, and then look for the corresponding body column
in the vm_pool table.
You need to set the DISK/SAVE element text to NO, and delete the elements
DISK/SAVE_AS and DISK/SAVE_AS_SOURCE.

If this is a common problem, please open a feature request in our
development portal: http://dev.opennebula.org

Best regards.

--
Carlos Martín, MSc
Project Engineer
OpenNebula - Flexible Enterprise Cloud Made Simple
www.OpenNebula.org | cmartin at opennebula.org |
@OpenNebula<http://twitter.com/opennebula><cmartin at opennebula.org>


On Mon, Oct 21, 2013 at 5:11 PM, Fabella, Wesley <wfabella at novetta.com>wrote:

> I've recently started managing our virtual machines using OpenNebula in
> our environment.  It runs on top of our CentOS KVM servers.
>
> I have taken have already ran the cmd:
>
> onevm disk-snapshot 37 0 X-test-20131018
>
> which will take a deferred snapshot of the disk upon 'onevm shutdown' ...
> problem is I have decided I want to do a "hot" live snapshot and receive
> the following exception:
>
> *oneadmin at headnode:~ $ onevm disk-snapshot --live 37 0 X-test-20131018*
> *[VirtualMachineSaveDisk] Cannot use selected DISK. The DISK 0 is already
> going to be saved.*
>
> You will also see below VM no. 37 has deferred image to set to be no. 11.
>  I have also deleted image no. 11 in hopes of free'ing VM no. 37 from
> deferred image capture.  Turns out this wasn't the best option and I
> probably should have went the Sunstone GUI route.
>
> Any ideas here to free my VM no. 37 from wanting to save image as no. 11
> which now does not exist?  At several glances I don't see a clear cut way
> to back out of my situation in order to choose Hot (--live) snapshot.
>
> Thanks in advance, (see output below pertaining to this issue)
>
> oneadmin at headnode:~ $ onevm show 37
> VIRTUAL MACHINE 37 INFORMATION
> ID                  : 37
> NAME                : X
> USER                : oneadmin
> GROUP               : oneadmin
> STATE               : ACTIVE
> LCM_STATE           : RUNNING
> RESCHED             : No
> HOST                : headnode
> START TIME          : 10/16 17:30:16
> END TIME            : -
> DEPLOY ID           : one-37
>
> VIRTUAL MACHINE MONITORING
> NET_RX              : 533.4M
> USED CPU            : 2
> NET_TX              : 189M
> USED MEMORY         : 8G
>
> PERMISSIONS
> OWNER               : um-
> GROUP               : ---
> OTHER               : u--
>
> VM DISKS
>  ID TARGET IMAGE                               TYPE SAVE SAVE_AS
>   0 hda    X                          file  YES      11
>
> VM NICS
>  ID NETWORK              VLAN BRIDGE       IP              MAC
>   0 meganet                no br0          128.123.0.12    02
> :00:80:7b:00:0c
>                                             fe80::400:80ff:fe7b:c
>   1 tfbnet                 no br1          10.191.10.212
> 02:00:0a:bf:0a:d4
>                                            fe80::400:aff:febf:ad4
>
> VIRTUAL MACHINE HISTORY
> SEQ HOST            ACTION           REAS           START        TIME
> PROLOG
>   0 headnode        none             none  10/16 17:30:30   4d 15h19m
> 0h49m48s
>
> USER TEMPLATE
> ERROR="Fri Oct 18 11:32:14 2013 : Error creating new VM Snapshot: Could
> not create snapshot  for domain one-37."
> SAVE="NO"
> SAVE_AS="NO"
>
> VIRTUAL MACHINE TEMPLATE
> AUTOMATIC_REQUIREMENTS="CLUSTER_ID = 100"
> CPU="8"
> GRAPHICS=[
>   LISTEN="0.0.0.0",
>   PORT="5937",
>   TYPE="vnc" ]
> MEMORY="8192"
> OS=[
>   ARCH="x86_64" ]
> TEMPLATE_ID="11"
> VMID="37"
>
> oneadmin at headnode:~ $ oneimage list
>   ID USER       GROUP      NAME            DATASTORE     SIZE TYPE PER
> STAT RVMS
>    4 oneadmin   oneadmin   X       default       100G OS    No used    1
>    9 oneadmin   oneadmin   X      default       100G OS    No used    1
>   12 wfabella   oneadmin   X default       100G OS    No used    5
>   13 wfabella   oneadmin   ttylinux test   default        40M OS    No rdy
>     0
>
>
> *"As the shadow follows the body,*
> *As we think,*
> *so we become." -zen quote*
>
> --
> Wesley J. Fabella
> Novetta - DevOps Engineer
> (desk) 813.304.2936
> (cell) at request
>
> *"As the shadow follows the body,*
> *As we think,*
> *so we become." -zen quote*
> *
> *
> IMPORTANT NOTICE:
> This e-mail message is intended for the use of the addressee and may
> contain company proprietary and/or confidential information that is subject
> to disclosure agreements. If you are not the authorized recipient, your
> viewing of such information, as well as any disclosure, copying,
> distribution or use of any of the information contained in or attached
> therein, is strictly prohibited. If you received this e-mail in error,
> please reply to the sender and delete the original message.*
> *
>
> _______________________________________________
> Users mailing list
> Users at lists.opennebula.org
> http://lists.opennebula.org/listinfo.cgi/users-opennebula.org
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opennebula.org/pipermail/users-opennebula.org/attachments/20131021/fe94ce4e/attachment-0002.htm>


More information about the Users mailing list