Payes Anand
2014-Dec-11 06:40 UTC
[libvirt-users] Freeze Windows Guests For Consistent Storage Snapshots
Hi, Is it possible to freeze windows guests for a consistent storage level snapshot. I am using openstack icehouse on centos 6.6 Hypervisor: KVM Libvirt: 0.10.2 Qemu: 0.10.2 Guest OS: Windows 7 and Windows Server 2008 I was able to freeze Centos guests by issuing the command: virsh qemu-agent-command <guest_ID> '{"execute":"guest-fsfreeze-freeze"}' For CentOS guests, I enabled access between compute nodes and guests through a socket by setting metadata parameter, hw_qemu_guest_agent=yes for the guest image. And then installing qemu-guest-agent inside the guest. What steps do i have to follow for windows ? Regars, Payes
Eric Blake
2014-Dec-11 15:29 UTC
Re: [libvirt-users] Freeze Windows Guests For Consistent Storage Snapshots
On 12/10/2014 11:40 PM, Payes Anand wrote:> Hi, > Is it possible to freeze windows guests for a consistent storage level > snapshot.Yes, if you install qemu-guest-agent in the guest, and wire up your libvirt XML to have the guest-agent channel available. Once you have done that, use the --quiesce flag as part of creating your snapshots.> I was able to freeze Centos guests by issuing the command: > virsh qemu-agent-command <guest_ID> '{"execute":"guest-fsfreeze-freeze"}'That is an unsupported backdoor, because it relies on libvirt-qemu.so. You should really prefer the libvirt commands from libvirt.so instead (the --quiesce flag to 'virsh snapshot-create[-as]'), because it is less likely to get libvirt out of sync by going behind libvirt's back. Also, libvirt 1.2.5 introduced 'virsh domfsfreeze' as the official way to do a guest-agent 'guest'fsfreeze-freeze' command, although since you are using older CentOS builds, your libvirt does not yet have that command supported.> > For CentOS guests, I enabled access between compute nodes and guests > through a socket by setting metadata parameter, hw_qemu_guest_agent=yes for > the guest image. > And then installing qemu-guest-agent inside the guest. > > What steps do i have to follow for windows ?The same steps - qemu-guest-agent is available for both Linux and Windows guests. -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
Payes Anand
2015-Jun-09 05:16 UTC
Re: [libvirt-users] Freeze Windows Guests For Consistent Storage Snapshots
Eric Blake <eblake@...> writes:> > On 12/10/2014 11:40 PM, Payes Anand wrote: > > Hi, > > Is it possible to freeze windows guests for a consistent storage level > > snapshot. > > Yes, if you install qemu-guest-agent in the guest, and wire up your > libvirt XML to have the guest-agent channel available. Once you have > done that, use the --quiesce flag as part of creating your snapshots. > > > I was able to freeze Centos guests by issuing the command: > > virsh qemu-agent-command <guest_ID> '{"execute":"guest-fsfreeze-freeze"}' > > That is an unsupported backdoor, because it relies on libvirt-qemu.so. > You should really prefer the libvirt commands from libvirt.so instead > (the --quiesce flag to 'virsh snapshot-create[-as]'), because it is less > likely to get libvirt out of sync by going behind libvirt's back. Also, > libvirt 1.2.5 introduced 'virsh domfsfreeze' as the official way to do a > guest-agent 'guest'fsfreeze-freeze' command, although since you are > using older CentOS builds, your libvirt does not yet have that command > supported. > > > > > For CentOS guests, I enabled access between compute nodes and guests > > through a socket by setting metadata parameter, hw_qemu_guest_agent=yes for > > the guest image. > > And then installing qemu-guest-agent inside the guest. > > > > What steps do i have to follow for windows ? > > The same steps - qemu-guest-agent is available for both Linux and > Windows guests. >I installed the qemu-guest-agent on windows but when i run -- virsh qemu-agent-command <guest_ID> '{"execute":"guest-fsfreeze-freeze"}' from my host machine, the guest windows VM doesn't freezing. Although the command returned successfully. value returned was 2. Is it possible to freeze NTFS filesystem using the above command ?? I had downloaded guest agent for windows from here-- https://fedorapeople.org/groups/virt/virtio-win/direct-downloads/ Am I missing something ??
Reasonably Related Threads
- Freeze Windows Guests For Consistent Storage Snapshots
- Re: guest-fsfreeze-freeze freezes all mounted block devices
- RE: guest-fsfreeze-freeze freezes all mounted block devices
- RE: guest-fsfreeze-freeze freezes all mounted block devices
- Re: guest-fsfreeze-freeze freezes all mounted block devices