Re: [libvirt] [PATCH 3/4] lxc: validate container process during load config

2008-05-30 Thread Dave Leskovec
Daniel P. Berrange wrote: > On Fri, May 30, 2008 at 11:40:00AM -0700, Dave Leskovec wrote: >> Daniel P. Berrange wrote: >>> On Fri, May 30, 2008 at 02:28:46AM -0400, Daniel Veillard wrote: On Thu, May 29, 2008 at 03:20:15PM -0700, Dave Leskovec wrote: > +if (ESRCH == errno) { >

Re: [libvirt] [PATCH 3/4] lxc: validate container process during load config

2008-05-30 Thread Daniel P. Berrange
On Fri, May 30, 2008 at 11:40:00AM -0700, Dave Leskovec wrote: > Daniel P. Berrange wrote: > > On Fri, May 30, 2008 at 02:28:46AM -0400, Daniel Veillard wrote: > >> On Thu, May 29, 2008 at 03:20:15PM -0700, Dave Leskovec wrote: > >>> +if (ESRCH == errno) { > >>> +rc = 0;

Re: [libvirt] [PATCH 3/4] lxc: validate container process during load config

2008-05-30 Thread Dave Leskovec
Daniel P. Berrange wrote: > On Fri, May 30, 2008 at 02:28:46AM -0400, Daniel Veillard wrote: >> On Thu, May 29, 2008 at 03:20:15PM -0700, Dave Leskovec wrote: >>> +if (ESRCH == errno) { >>> +rc = 0; >>> +DEBUG("pid %d no longer exists", def->id); >>> +

Re: [libvirt] [PATCH 3/4] lxc: validate container process during load config

2008-05-30 Thread Daniel P. Berrange
On Fri, May 30, 2008 at 02:28:46AM -0400, Daniel Veillard wrote: > On Thu, May 29, 2008 at 03:20:15PM -0700, Dave Leskovec wrote: > > +if (ESRCH == errno) { > > +rc = 0; > > +DEBUG("pid %d no longer exists", def->id); > > +goto done; > > +

Re: [libvirt] [PATCH 3/4] lxc: validate container process during load config

2008-05-29 Thread Daniel Veillard
On Thu, May 29, 2008 at 03:20:15PM -0700, Dave Leskovec wrote: > This patch adds a check that validates that the container process pid still > exists. This should catch cases where the container exits while libvirtd is > down. sounds fine, > +/** > + * lxcCheckContainerProcess: > + * @def: Pt

[libvirt] [PATCH 3/4] lxc: validate container process during load config

2008-05-29 Thread Dave Leskovec
This patch adds a check that validates that the container process pid still exists. This should catch cases where the container exits while libvirtd is down. -- Best Regards, Dave Leskovec IBM Linux Technology Center Open Virtualization --- src/lxc_conf.c | 46 ++