]> git.proxmox.com Git - mirror_qemu.git/commit - qga/commands-posix.c
qemu-ga: improve recovery options for fsfreeze
authorMichael Roth <mdroth@linux.vnet.ibm.com>
Tue, 17 Apr 2012 00:52:17 +0000 (19:52 -0500)
committerMichael Roth <mdroth@linux.vnet.ibm.com>
Mon, 30 Apr 2012 13:41:40 +0000 (08:41 -0500)
commit9e8aded432884477bcd4fa1c7e849a196412bcc4
tree6b0f98e3297c88596055642be15e3178fbb5f409
parenta8b69b8e2431edfcb6c4cfb069787e9071d6235b
qemu-ga: improve recovery options for fsfreeze

guest-fsfreeze-thaw relies on state information obtained from
guest-fsfreeze-freeze to determine what filesystems to unfreeze.
This is unreliable due to the fact that that state does not account
for FIFREEZE being issued by other processes, or previous instances
of qemu-ga. This means in certain situations we cannot thaw
filesystems even with a responsive qemu-ga instance at our disposal.

This patch allows guest-fsfreeze-thaw to be issued unconditionally.
It also adds some additional logic to allow us to thaw filesystems
regardless of how many times the filesystem's "frozen" refcount has
been incremented by any guest processes.

Also, guest-fsfreeze-freeze now operates atomically: on success all
freezable filesystems are frozen, and on error all filesystems are
thawed. The ambiguous "GUEST_FSFREEZE_STATUS_ERROR" state is no
longer entered.

Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
qapi-schema-guest.json
qga/commands-posix.c