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

2012-08-17 Thread Launchpad Bug Tracker
This bug was fixed in the package lxc - 0.8.0~rc1-4ubuntu26

---
lxc (0.8.0~rc1-4ubuntu26) quantal; urgency=low

  * 0100-template-cleanup-cache: clean up template cache if interrupted
during build. (LP: #1037331)
  * 0101-template-empty-apt-cache: do an apt-cache clean after creating
a new cache.  (LP: #1037626)
  * 0102-lxc-start-d-check-privs: exit early (with failure) if starting a
daemonized container with insufficient privilege.  (LP: #918327)
  * 0103-make-rootfs-location-optional: allow custom location for a
container rootfs to be specified.  (LP: #1019398)
 -- Serge Hallyn serge.hal...@ubuntu.com   Fri, 17 Aug 2012 09:44:02 -0500

** Changed in: lxc (Ubuntu)
   Status: Confirmed = Fix Released

-- 
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 in daemon mode

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

-- 
Ubuntu-server-bugs mailing list
Ubuntu-server-bugs@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server-bugs


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

2012-08-16 Thread Serge Hallyn
** Summary changed:

- lxc-start exits success on failure when non-root
+ lxc-start exits success on failure when non-root in daemon mode

-- 
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 in daemon mode

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

-- 
Ubuntu-server-bugs mailing list
Ubuntu-server-bugs@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server-bugs


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

2012-01-25 Thread Serge Hallyn
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

-- 
Ubuntu-server-bugs mailing list
Ubuntu-server-bugs@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server-bugs


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

2012-01-18 Thread Scott Moser
-- 
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

-- 
Ubuntu-server-bugs mailing list
Ubuntu-server-bugs@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server-bugs


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

2012-01-18 Thread Scott Moser
Another (likely related) issue, after using sudo to start the container,
observe:

$ lxc-ls
lv1
$ sudo lxc-start -n lv1 -d
$ lxc-ls
lv1
/usr/bin/lxc-ls: line 35: cd: /sys/fs/cgroup/cpuset///lxc: Permission denied
ls: cannot access lv1: No such file or directory
$ sudo lxc-ls
lv1
lv1
$ sudo lxc-list
RUNNING
  lv1

STOPPED


So, as it is now after starting the container 'sudo lxxc-ls' shows 2 
containers, but 'lxc-ls' (without sudo) shows annoying messages.

-- 
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

-- 
Ubuntu-server-bugs mailing list
Ubuntu-server-bugs@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server-bugs


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

2012-01-18 Thread Serge Hallyn
Indeed that should be fixed.  Thanks for the bug report.

** Changed in: lxc (Ubuntu)
   Status: New = Confirmed

** Changed in: lxc (Ubuntu)
   Importance: Undecided = Low

-- 
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

-- 
Ubuntu-server-bugs mailing list
Ubuntu-server-bugs@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server-bugs