[libvirt-users] [libvirt] libvirt external disk-only snapshot will pause the VM?

Eric Blake eblake at redhat.com
Wed Aug 6 17:23:41 UTC 2014


On 08/06/2014 11:17 AM, Yuanzhen Gu wrote:

>> Guest freeze/thaw (virDomainFSFreeze) only works on a live guest.  So
>> what you will have to do is:
>>
>> virDomainFSFreeze(vm1, ...)
>> virDomainFSFreeze(vm2, ...)
>> virDomainSuspend(vm1)
>> virDomainSuspend(vm2)
>> virDomainSnapshotCreateXML(vm1, ...)
>> virDomainSnapshotCreateXML(vm2, ...)
>> virDomainResume(vm1)
>> virDomainResume(vm2)
>> virDomainFSThaw(vm1, ...)
>> virDOmainFSThaw(vm2, ...)
>>
> 
>     I see, thanks.
> 
>>
>> However, I honestly don't know why you think you need disk snapshots
>> from the same point in time across multiple VMs, though.
> 
> 
>    you suggested that external disk-only snapshot, libvirt will freeze/thaw
> before/after taking snapshot

For a single guest, yes, libvirt can handle both the freeze/thaw and any
necessary pause/resume of the guest automatically.  But as soon as you
are coordinating multiple guests, it is up to you do to the
coordination.  Libvirt handles the case of taking a snapshot when the
guest is already frozen and paused, but the burden of doing the three
steps in parallel across VMs is now up to you instead of all three steps
in a single API call for one VM.

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

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 539 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvirt-users/attachments/20140806/0716846c/attachment.sig>


More information about the libvirt-users mailing list