qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH V12 06/18] block: add check for VM snapshot in b


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH V12 06/18] block: add check for VM snapshot in bdrv_query_snapshot_info_list()
Date: Wed, 17 Apr 2013 14:52:48 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130402 Thunderbird/17.0.5

On 04/13/2013 02:56 AM, Wenchao Xia wrote:
>   This patch adds a parameter to tell whether return valid snapshots
> for whole VM only.
>   Note that the snapshot check logic is copied from do_info_snapshots(),
> which is different with load_vmstate() and will be changed in next patch.
> 
> Signed-off-by: Wenchao Xia <address@hidden>
> Reviewed-by: Eric Blake <address@hidden>
> Reviewed-by: Kevin Wolf <address@hidden>
> ---

> +
> +    /* Check logic is connected with load_vmstate():
> +       Only check the devices that can snapshot, other devices that can't
> +       take snapshot, for example, readonly ones, will be ignored in
> +       load_vmstate(). */
> +    while ((bs1 = bdrv_next(bs1))) {
> +        if (bs1 != bs && bdrv_can_snapshot(bs1)) {
> +            ret = bdrv_snapshot_find(bs1, sn_info, sn->id_str, NULL);

This says for a snapshot to be consistent, all block devices must share
the same id but can have different names.  Is that really true?  Or is
it backwards from reality?  If snapshot ids allocated incrementally per
block device, can I use hotplug to create a situation where I have a VM
with two disks

disk a has snapshot id 1 named 'A', id 2 named 'B'
disk b has snapshot id 1 named 'B'

where the existing HMP 'loadvm B' should load the snapshot named 'B'
from both disks, regardless of the different number, and where snapshot
'A' is inconsistent unless disk b is hot-unplugged?

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]