[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH v5 1/6] remus: don't do failover if we don't have an consistent state
We will have an consistent state when a CHECKPOINT_END record is received. After the first CHECKPOINT_END record is received, we will buffer all records until the next CHECKPOINT_END record is received. So if the checkpoint() callback returns XGR_CHECKPOINT_FAILOVER, we only can do failover if ctx->restore.buffer_all_records is true. Signed-off-by: Wen Congyang <wency@xxxxxxxxxxxxxx> --- tools/libxc/xc_sr_restore.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tools/libxc/xc_sr_restore.c b/tools/libxc/xc_sr_restore.c index 05159bb..9fe2829 100644 --- a/tools/libxc/xc_sr_restore.c +++ b/tools/libxc/xc_sr_restore.c @@ -493,7 +493,11 @@ static int handle_checkpoint(struct xc_sr_context *ctx) break; case XGR_CHECKPOINT_FAILOVER: - rc = BROKEN_CHANNEL; + if ( ctx->restore.buffer_all_records ) + rc = BROKEN_CHANNEL; + else + /* We don't have an consistent state */ + rc = -1; goto err; default: /* Other fatal error */ -- 2.5.0 _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |