From: Ian Campbell Subject: Re: [PATCH 2 of 2] libxl: Remus - xl remus command Date: Tue, 31 Jan 2012 11:00:38 +0000 Message-ID: <1328007638.26983.350.camel@zakaz.uk.xensource.com> References: <070f78ba4244cf8239de.1327972926@athos.nss.cs.ubc.ca> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <070f78ba4244cf8239de.1327972926@athos.nss.cs.ubc.ca> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: "rshriram@cs.ubc.ca" Cc: "brendan@cs.ubc.ca" , "xen-devel@lists.xensource.com" , Ian Jackson List-Id: xen-devel@lists.xenproject.org On Tue, 2012-01-31 at 01:22 +0000, rshriram@cs.ubc.ca wrote: > # HG changeset patch > # User Shriram Rajagopalan > # Date 1327972788 28800 > # Node ID 070f78ba4244cf8239ded3a69ccd54ac6e1bd24d > # Parent 0129989da2cda789f86f2bc83d9c642a0bcebe60 > libxl: Remus - xl remus command > > xl remus acts as a frontend to enable remus for a given domain. > * At the moment, only memory checkpointing and blackhole replication is > supported. Support for disk checkpointing and network buffering will > be added in future. > * Replication is done over ssh connection currently (like live migration > with xl). Future versions will have an option to use simple tcp socket > based replication channel (for both Remus & live migration). > > Signed-off-by: Shriram Rajagopalan > > diff -r 0129989da2cd -r 070f78ba4244 tools/libxl/libxl.c > --- a/tools/libxl/libxl.c Mon Jan 30 17:19:46 2012 -0800 > +++ b/tools/libxl/libxl.c Mon Jan 30 17:19:48 2012 -0800 > @@ -471,6 +471,40 @@ libxl_vminfo * libxl_list_vm(libxl_ctx * > return ptr; > } > > +int libxl_domain_remus_start(libxl_ctx *ctx, libxl_domain_remus_info *info, > + uint32_t domid, int fd) This new function probably belongs in patch 1/2 with the other libxl changes. > +{ > + GC_INIT(ctx); > + libxl_domain_type type = libxl__domain_type(gc, domid); > + int rc = 0; > + > + if (info == NULL) { > + LIBXL__LOG(ctx, LIBXL__LOG_ERROR, > + "No remus_info structure supplied for domain %d", domid); > + rc = -1; libxl functions should return one of ERROR_* not -1 one. In this case ERROR_INVAL I suppose. [...] > diff -r 0129989da2cd -r 070f78ba4244 tools/libxl/xl_cmdtable.c > --- a/tools/libxl/xl_cmdtable.c Mon Jan 30 17:19:46 2012 -0800 > +++ b/tools/libxl/xl_cmdtable.c Mon Jan 30 17:19:48 2012 -0800 > @@ -412,6 +412,20 @@ struct cmd_spec cmd_table[] = { > "Loads a new policy int the Flask Xen security module", > "", > }, > + { "remus", Please also add this command to docs/man/xl.pod.1. Otherwise this patch looks good, thanks. Ian.