From: Ian Campbell Subject: Re: Re-reading domain configs on domain restart Date: Wed, 8 Feb 2012 16:32:02 +0000 Message-ID: <1328718722.6133.60.camel@zakaz.uk.xensource.com> References: <20120207170443.GN32046@bitfolk.com> <20273.24520.100024.694018@mariner.uk.xensource.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20273.24520.100024.694018@mariner.uk.xensource.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Ian Jackson Cc: Andy Smith , Xen-devel List-Id: xen-devel@lists.xenproject.org Hi Andy, Good to meet you over the w.e. On Tue, 2012-02-07 at 17:30 +0000, Ian Jackson wrote: > Andy Smith writes ("[Xen-devel] Re-reading domain configs on domain restart"): > > I understand this will never be fixed in xend/xm, but would it be > > possible to have xl re-read the domU's config when the domU > > restarts? > > Yes, this would certainly be possible. Straightforward, even. > There are two questions we need to answer first: > > Firstly, how should this be requested ? I think a command-line option > to xl would do the trick. Where would you give it? Giving it to create might be unhelpful if you only decide you need it when you come to reboot. Giving to reboot is tricky since then you need that xl to communicate with the one actually managing the reboots etc (we could deal with that though). Another option would be to allow it as an option to the on_FOO=bar in the configuration file. There's a bit of a combinatorial explosion going on there though (coredump & X, rename & X etc) and it has the same problem with being too late at reboot time to change your mind. > Secondly, should we change the default behaviour ? I'd be inclined > towards "yes" as the current arrangement is really rather perverse, > but I'm open to opinions. I lean that way too, although if higher level tools using xl are e.g. writing to a /tmp file which they delete after start up then might that be an issue? Eventually I'd like to see a libxl function which can reconstitute a libxl_domain_config from a running domains, such that it is sufficient to pass to libxl_domain_create to recreate that domain. That needn't block this functionality though. > In the longer term, in the spirit of xl, it might be a good idea to > give the user the option of running a hook script when the domain > dies/reboots/etc. This would simplify a number of things. Yes, hooks are a good idea.