On Tue, Mar 6, 2018 at 7:54 PM, Yaniv Kaul <yk...@redhat.com> wrote:

> On Mar 6, 2018 7:02 PM, "Gianluca Cecchi" <gianluca.cec...@gmail.com>
> wrote:
> Hello,
> this thread last year (started by me... ;-) was very useful in different
> aspects involved
> http://lists.ovirt.org/pipermail/users/2017-March/080322.html
> We did cover memory save or not and fsfreeze automatically done by guest
> agent if installed inside the VM.
> What about pre-snapshot scripts/operations to run inside guest, to have
> application consistency?
> Eg if I have a database inside the VM and I have scripted my backup job
> involving live-snapshot (eg with the backup.py utility of the thread)
> https://github.com/guillon/qemu-plugins/blob/master/scripts/
> qemu-guest-agent/fsfreeze-hook.d/mysql-flush.sh.sample
Hello Yaniv,
thanks for the information and the example file link.
So I have understood that the freeze-hook script is run with the "freeze"
option before snapshot and again but with the "thaw" option after the
So I can manage what to do, parsing the argument given
So far so good.
I have tested with a Fedora 27 guest and all is ok there.

Now I would like to do something similar for a Windows 2008 R2 x64 VM.
I see that the qemu-guest-agent has been installed under
C:\Programs\qemu-ga and that the "QEMU Guest Agent" service is run as
"C:\Program Files\qemu-ga\qemu-ga.exe" -d

In fact I see I have a registry key in


with the same value above for ImagePath ;
"C:\Program Files\qemu-ga\qemu-ga.exe" -d

What should I do to enable a freeze-hook script on Windows now?

BTW: searching around while trying to understand more, I found that:

on hypervisor running the VM I have

# vdsClient -s 0 getVmStats vm_guid

that works and gives me information that confirms agent seems to
communicate and I get also
appsList = [.... , 'QEMU guest agent', ...]

Also, the dump of the dynamic xml for the guest contains

# virsh -r dumpxml VM_NAME

    <channel type='unix'>
      <source mode='bind'
      <target type='virtio' name='org.qemu.guest_agent.0'
      <alias name='channel1'/>
      <address type='virtio-serial' controller='0' bus='0' port='2'/>

I tried to get its settings from qemu guest agent using socat and unix
domain sockets but I don't receive answer

# socat unix-connect:/

and then in the interactive prompt


to get and verify information about fsfreeze, something like
...., {"enabled": true, "name": "guest-fsfreeze-freeze"}, ... ....,
{"enabled": true, "name": "guest-fsfreeze-thaw"}, ...

But I didn't get any line....
Is this communication from OS disabled by design out of oVirt mgmt?

Thanks again for any info to configure freeze-hook in Windows guest.

Users mailing list

Reply via email to