[Bug 918327] Re: lxc-start exits success on failure when non-root

Serge Hallyn 918327 at bugs.launchpad.net
Wed Jan 25 20:36:59 UTC 2012


Ok, I'm actually not sure what we should do about this.

'-d' doesn't just mean don't show a console, it means daemonize.  It
does this by calling daemon(3), which forks(), lets the child continue,
and exits success.

We could toss extra checks in before the call to daemon(3) to check for
privilege, but there are plenty of other reasons why the start could
fail.

So it seems we can do one of two things:

  1. rewrite lxc-start so that it manually forks and waits for a message
from the lxc monitor saying the container started, and only then exit

  2. tell users that 'lxc-start -d' provides no information about the
success of starting the container, and that if you care,  you should
call something like

        lxc-wait -n container -s RUNNING

     after the lxc-start to make sure it succeeded.

-- 
You received this bug notification because you are a member of Ubuntu
Server Team, which is subscribed to lxc in Ubuntu.
https://bugs.launchpad.net/bugs/918327

Title:
  lxc-start exits success on failure when non-root

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/lxc/+bug/918327/+subscriptions



More information about the Ubuntu-server-bugs mailing list