diff options
author | Ian Campbell <ian.campbell@citrix.com> | 2010-10-28 12:19:43 +0100 |
---|---|---|
committer | Ian Campbell <ian.campbell@citrix.com> | 2010-10-28 12:19:43 +0100 |
commit | 2526ff6cc98fc971041442e63bfe43bdc8bed9d2 (patch) | |
tree | e3b4af37eb7f696b4cee9b7bebe3225f6aac3ef9 /tools/libxc/xg_save_restore.h | |
parent | 7134cbcc19fc72720338009ef2e93c96f9ba2963 (diff) | |
download | xen-2526ff6cc98fc971041442e63bfe43bdc8bed9d2.tar.gz xen-2526ff6cc98fc971041442e63bfe43bdc8bed9d2.tar.bz2 xen-2526ff6cc98fc971041442e63bfe43bdc8bed9d2.zip |
libxl: Fix migration of HVM guests
In the default "QemuDeviceModelRecord"-style HVM tail of the migration
protocol the size of the qemu save record is unknown at the receiver
and therefore it must read until EOF. This is not compatible with the
xl migration protocol which contains a post-migration handshake and
therefore cannot close the socket on the sending end.
What is required is an explicit length field for the save record,
which the "RemusDeviceModelState"-style HVM tail includes.
Rather than overload the "RemusDeviceModelState" name for a non-Remus
use case (on off chance that they need to diverge for some reason in
the future) introduce a third style called "DeviceModelRecord0002"
which is identical to current "RemusDeviceModelState"-style.
Hopefully the inclusion of a number here will allow easier extension
in the future without needing to come up with increasingly less
helpful names!
Also propagate errors from xc_domain_save and
libxl__domain_suspend_common to callers.
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
Diffstat (limited to 'tools/libxc/xg_save_restore.h')
-rw-r--r-- | tools/libxc/xg_save_restore.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/libxc/xg_save_restore.h b/tools/libxc/xg_save_restore.h index 2c82ce7404..b13bdef649 100644 --- a/tools/libxc/xg_save_restore.h +++ b/tools/libxc/xg_save_restore.h @@ -104,8 +104,9 @@ * Qemu context: * char[21] : Signature: * "QemuDeviceModelRecord" : Read Qemu save data until EOF - * "RemusDeviceModelState" : uint32_t length field followed by that many + * "DeviceModelRecord0002" : uint32_t length field followed by that many * bytes of Qemu save data + * "RemusDeviceModelState" : Currently the same as "DeviceModelRecord0002". * * PV TAIL: * |