#41 - libxl_ctx_alloc should have dummy mode which does not require a Xen host

Owner: Ian Campbell <Ian.Campbell@citrix.com>

Date: Mon Jun 2 13:15:02 2014

Last Update: Mon Jun 2 13:15:02 2014

Severity: wishlist

Affects:

State: Open

[ Retrieve as mbox ]


From: Ian Campbell <Ian.Campbell@citrix.com>
To: "Daniel P. Berrange" <berrange@redhat.com>
Cc: Jim Fehlig <jfehlig@suse.com>, libvir-list@redhat.com, xen-devel@lists.xensource.com
Subject: Re: [Xen-devel] [PATCH 0/5] Testing libvirt XML -> libxl_domain_config conversion
Date: Mon, 2 Jun 2014 13:57:55 +0100
Message-ID: <1401713875.19553.9.camel@kazak.uk.xensource.com>

[ Reply to this message; Retrieve Raw Message; Archives: marc.info, gmane ]

create !
title it libxl_ctx_alloc should have dummy mode which does not require a Xen host
severity it wishlist
thanks
(just creating a bug for this issue)

On Mon, 2014-06-02 at 13:41 +0100, Ian Campbell wrote:
> On Fri, 2014-05-30 at 18:24 +0100, Daniel P. Berrange wrote:
> > I hit a couple of small issues with libxl, which I worked around, when
> > writing this test which I why I'm copying xen-devel
> > 
> >  - libxl_ctx_alloc() will call xs_daemon_open and xc_interface_open,
> >    and stat /var/run/xenstored.pid to see if Xen is actually running.
> >    This fails when run on non-Xen hosts (and also possibly if run
> >    unprivileged).
> > 
> >    I used an evil LD_PRELOAD hack to stub out xs_daemon_open and
> >    xc_interface_open to return (void*)0x1, and also turn
> >    xc_interface_close and xs_daemon_close to no-ops, and make
> >    stat() always return success for xenstored.pid.
> > 
> >    This works (evidenced by the fact that if something was needing
> >    these xs/xc handles they would have crashed referencing 0x1), 
> >    but at the same time it might be an idea to have an officially
> >    supported  "non live" mode for libxl_ctx_alloc() turned on by a
> >    flag of some sort.
> 
> Yes, we absolutely should have this.



_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel