On 08/06/2014 11:17 AM, Yuanzhen Gu wrote:For a single guest, yes, libvirt can handle both the freeze/thaw and any
>> 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
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.