Re: [Libvir] [RFC] 4 of 4 Linux Container support - start container

2008-03-21 Thread Dave Leskovec
Dan Smith wrote: > DB> The patch I posted to make it use the state driver means all LXC > DB> driver calls go via the daemon. So nothing happens directly as a > DB> child of the calling application - its all in the context of the > DB> daemon. > > Yeah, just saw that. Even better :) > > It seems

Re: [Libvir] [RFC] 4 of 4 Linux Container support - start container

2008-03-21 Thread Daniel Veillard
On Fri, Mar 21, 2008 at 05:37:50PM +, Daniel P. Berrange wrote: > On Fri, Mar 21, 2008 at 01:33:55PM -0400, Daniel Veillard wrote: > > On Fri, Mar 21, 2008 at 10:30:36AM -0700, Dan Smith wrote: > > > DB> The patch I posted to make it use the state driver means all LXC > > > DB> driver calls go

Re: [Libvir] [RFC] 4 of 4 Linux Container support - start container

2008-03-21 Thread Daniel P. Berrange
On Fri, Mar 21, 2008 at 01:33:55PM -0400, Daniel Veillard wrote: > On Fri, Mar 21, 2008 at 10:30:36AM -0700, Dan Smith wrote: > > DB> The patch I posted to make it use the state driver means all LXC > > DB> driver calls go via the daemon. So nothing happens directly as a > > DB> child of the callin

Re: [Libvir] [RFC] 4 of 4 Linux Container support - start container

2008-03-21 Thread Daniel Veillard
On Fri, Mar 21, 2008 at 10:30:36AM -0700, Dan Smith wrote: > DB> The patch I posted to make it use the state driver means all LXC > DB> driver calls go via the daemon. So nothing happens directly as a > DB> child of the calling application - its all in the context of the > DB> daemon. > > Yeah, ju

Re: [Libvir] [RFC] 4 of 4 Linux Container support - start container

2008-03-21 Thread Dave Leskovec
Daniel P. Berrange wrote: > On Fri, Mar 21, 2008 at 10:21:48AM -0700, Dan Smith wrote: >> DB> IMHO there's too much forking going on here. With the stateful >> DB> driver we should have the daemon be the parent of the forked VM as >> DB> per the QEMU driver. This will avoid the need to unsafely re-

Re: [Libvir] [RFC] 4 of 4 Linux Container support - start container

2008-03-21 Thread Dan Smith
DB> The patch I posted to make it use the state driver means all LXC DB> driver calls go via the daemon. So nothing happens directly as a DB> child of the calling application - its all in the context of the DB> daemon. Yeah, just saw that. Even better :) It seems to me that always being in the d

Re: [Libvir] [RFC] 4 of 4 Linux Container support - start container

2008-03-21 Thread Daniel P. Berrange
On Fri, Mar 21, 2008 at 10:21:48AM -0700, Dan Smith wrote: > DB> IMHO there's too much forking going on here. With the stateful > DB> driver we should have the daemon be the parent of the forked VM as > DB> per the QEMU driver. This will avoid the need to unsafely re-write > DB> the config files.

Re: [Libvir] [RFC] 4 of 4 Linux Container support - start container

2008-03-21 Thread Dan Smith
DB> IMHO there's too much forking going on here. With the stateful DB> driver we should have the daemon be the parent of the forked VM as DB> per the QEMU driver. This will avoid the need to unsafely re-write DB> the config files. It will also enable errors during the domain DB> creation process t

Re: [Libvir] [RFC] 4 of 4 Linux Container support - start container

2008-03-21 Thread Daniel P. Berrange
On Wed, Mar 19, 2008 at 11:16:32PM -0700, Dave Leskovec wrote: > This patch adds the start container support. A couple new source files are > added - lxc_container.h and lxc_container.c These contain the setup code that > runs within the container namespace prior to exec'ing the user specified in

[Libvir] [RFC] 4 of 4 Linux Container support - start container

2008-03-19 Thread Dave Leskovec
This patch adds the start container support. A couple new source files are added - lxc_container.h and lxc_container.c These contain the setup code that runs within the container namespace prior to exec'ing the user specified init. This is a rough outline of the functions involved in starting a