[Bug 1267242] Re: Running lxc-ls as non-root should provide a nicer error message

Stéphane Graber stgraber at stgraber.org
Wed Jan 8 21:45:52 UTC 2014


Most of the occurrences of that bug will disappear with the next LXC
milestone as lxc-ls will default to looking for user-owned containers
rather than system ones.

However even with that change, it'll be technically possible to call list_containers on an unreadable directory and get that traceback. Sadly as this comes from liblxc, there isn't many ways to make the error prettier as the actual string is simply output on stderr...
What I could (and will eventually) do is have lxc-ls catch any exception raised by list_container and print a vague error saying "Unable to list containers" which is unfortunately as clear as I can make it...

** Changed in: lxc (Ubuntu)
       Status: New => Triaged

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

** Changed in: lxc (Ubuntu)
     Assignee: (unassigned) => Stéphane Graber (stgraber)

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

Title:
  Running lxc-ls as non-root should provide a nicer error message

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



More information about the Ubuntu-server-bugs mailing list