[lxc-users] local lxc commands stuck

Tycho Andersen tycho.andersen at canonical.com
Fri May 15 04:54:45 UTC 2015


Hi Tim,

On Fri, May 15, 2015 at 03:43:40PM +1200, Tim Penhey wrote:
> Hi All,
> 
> I was messing around with lxd/lxc the other day, and seem to have wedged
> my system somewhat.
> 
> Going blindly from documentation in a blog post, I did the following:
> 
> $ lxc launch images:ubuntu/trusty/amd64 trusty-lxd-test
> Creating container...done
> Starting container...error: setting config item for the container failed

That's no good. If you're running lxd 0.9 (our latest release as of
Tuesday), can you paste the output of:

lxc info trusty-lxd-test --show-log

> After seeing the error, I tried with sudo:
> 
> $ sudo lxc launch images:ubuntu/trusty/amd64 trusty-lxd-test
> Creating container...error: Container exists

sudo shouldn't make a difference here, since the client doesn't do
anything based on what uid it is run as.

> I then went looking for the list:
> 
> $ sudo lxc list
> error: setting config item for the container failed
> 
> I get the same error without the sudo on the 'lxc list'
> 
> 
> I can see the container directory in /var/lib/lxd/lxc, but not sure why
> the lxc command has gotten itself into this state.
> 
> Q) Should the default install be able to create unprivileged containers?

Yes, all containers are unprivileged by default.

> Q) How can I fix my local lxc command so it doesn't error?

Good question; at this point it looks like your db is probably wedged
and your best bet is to delete /var/lib/lxd (or at least the db) and
try again.

However, it would be useful to have a copy of the db so I could poke
around and see what happened. Also the log output above would be
useful.

Thanks,

Tycho

> Cheers,
> Tim
> _______________________________________________
> lxc-users mailing list
> lxc-users at lists.linuxcontainers.org
> http://lists.linuxcontainers.org/listinfo/lxc-users


More information about the lxc-users mailing list