mirror of
https://github.com/utmapp/qemu.git
synced 2026-12-01 22:23:23 -10:00
migration: block incoming colo when capability is disabled
We generally require same set of capabilities on source and target. Let's require x-colo capability to use COLO on target. Signed-off-by: Vladimir Sementsov-Ogievskiy <[email protected]> Reviewed-by: Juan Quintela <[email protected]> Reviewed-by: Peter Xu <[email protected]> Reviewed-by: Lukas Straub <[email protected]> Reviewed-by: Zhang Chen <[email protected]> Message-Id: <[email protected]> Signed-off-by: Juan Quintela <[email protected]>
This commit is contained in:
1 parent
d70178a88f
commit
121ccedc2b
2 files changed
+7
No files matched your search
@@ -210,6 +210,7 @@ children.0=childs0 \
|
||||
|
||||
3. On Secondary VM's QEMU monitor, issue command
|
||||
{"execute":"qmp_capabilities"}
|
||||
{"execute": "migrate-set-capabilities", "arguments": {"capabilities": [ {"capability": "x-colo", "state": true } ] } }
|
||||
{"execute": "nbd-server-start", "arguments": {"addr": {"type": "inet", "data": {"host": "0.0.0.0", "port": "9999"} } } }
|
||||
{"execute": "nbd-server-add", "arguments": {"device": "parent0", "writable": true } }
|
||||
|
||||
|
||||
@@ -398,6 +398,12 @@ int migration_incoming_enable_colo(void)
|
||||
return -ENOTSUP;
|
||||
#endif
|
||||
|
||||
if (!migrate_colo()) {
|
||||
error_report("ENABLE_COLO command come in migration stream, but c-colo "
|
||||
"capability is not set");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
if (ram_block_discard_disable(true)) {
|
||||
error_report("COLO: cannot disable RAM discard");
|
||||
return -EBUSY;
|
||||
|
||||
Reference in new issue
Block a user