[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [RFC PATCH v2 04/23] COLO migration: add a migration capabi
From: |
Yang Hongyang |
Subject: |
[Qemu-devel] [RFC PATCH v2 04/23] COLO migration: add a migration capability 'colo' |
Date: |
Tue, 23 Sep 2014 17:23:36 +0800 |
Add a migration capability 'colo'. If this capability is on,
The migration will never end, and the VM will be continuously
checkpointed.
Signed-off-by: Yang Hongyang <address@hidden>
---
migration.c | 8 ++++++++
qapi-schema.json | 5 ++++-
2 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/migration.c b/migration.c
index 8d675b3..5d28237 100644
--- a/migration.c
+++ b/migration.c
@@ -25,6 +25,7 @@
#include "qemu/thread.h"
#include "qmp-commands.h"
#include "trace.h"
+#include "migration/migration-colo.h"
enum {
MIG_STATE_ERROR = -1,
@@ -277,6 +278,13 @@ void
qmp_migrate_set_capabilities(MigrationCapabilityStatusList *params,
}
for (cap = params; cap; cap = cap->next) {
+ if (cap->value->capability == MIGRATION_CAPABILITY_COLO &&
+ cap->value->state && !colo_supported()) {
+ error_setg(errp, "COLO is not currently supported, please rerun"
+ " configure with --enable-colo option in order to"
+ " support COLO feature");
+ continue;
+ }
s->enabled_capabilities[cap->value->capability] = cap->value->state;
}
}
diff --git a/qapi-schema.json b/qapi-schema.json
index 689b548..8d58ef7 100644
--- a/qapi-schema.json
+++ b/qapi-schema.json
@@ -491,10 +491,13 @@
# @auto-converge: If enabled, QEMU will automatically throttle down the guest
# to speed up convergence of RAM migration. (since 1.6)
#
+# @colo: If enabled, the migration will never end, and the VM will instead be
+# continuously checkpointed. (since 2.2)
+#
# Since: 1.2
##
{ 'enum': 'MigrationCapability',
- 'data': ['xbzrle', 'rdma-pin-all', 'auto-converge', 'zero-blocks'] }
+ 'data': ['xbzrle', 'rdma-pin-all', 'auto-converge', 'zero-blocks', 'colo'] }
##
# @MigrationCapabilityStatus
--
1.9.1
- [Qemu-devel] [RFC PATCH v2 00/23] COarse-grain LOck-stepping(COLO) Virtual Machines for Non-stop Service, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 01/23] QEMUSizedBuffer/QEMUFile, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 02/23] configure: add CONFIG_COLO to switch COLO support, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 05/23] COLO info: use colo info to tell migration target colo is enabled, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 06/23] COLO save: integrate COLO checkpointed save into qemu migration, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 09/23] COLO ctl: implement API's that communicate with colo agent, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 07/23] COLO restore: integrate COLO checkpointed restore into qemu restore, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 08/23] COLO: disable qdev hotplug, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 10/23] COLO ctl: introduce is_slave() and is_master(), Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 03/23] COLO: introduce an api colo_supported() to indicate COLO support, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 04/23] COLO migration: add a migration capability 'colo',
Yang Hongyang <=
- [Qemu-devel] [RFC PATCH v2 11/23] COLO ctl: implement colo checkpoint protocol, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 12/23] COLO ctl: add a RunState RUN_STATE_COLO, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 13/23] COLO ctl: implement colo save, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 14/23] COLO ctl: implement colo restore, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 16/23] COLO ram cache: implement colo ram cache on slave, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 17/23] HACK: trigger checkpoint every 500ms, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 15/23] COLO save: reuse migration bitmap under colo checkpoint, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 18/23] COLO nic: add command line switch, Yang Hongyang, 2014/09/23
- [Qemu-devel] [RFC PATCH v2 19/23] COLO nic: init/remove colo nic devices when add/cleanup tap devices, Yang Hongyang, 2014/09/23