[lxc-users] LXD: error: open /etc/subuid: no such file or directory

Tycho Andersen tycho.andersen at canonical.com
Wed Nov 12 19:42:23 UTC 2014


On Wed, Nov 12, 2014 at 06:55:22PM +0000, Serge Hallyn wrote:
> Make sure no other lxd is running
> 
> sudo killall -9 lxd
> 
> and remove the sock by hand
> 
> sudo rm /var/lib/lxd/unix.socket
> 
> Now it should start fine.
> 
> If we are leaving that socket around when we error out bc of no
> availalbe subuids, then that is definately a bug.

Yes, I've seen this before. I'll look into it and send a patch.

Tycho

> Quoting Kunal Kushwaha (kunalkushwahaoss at gmail.com):
> > Hi
> > 
> > Thanks for your quick reply.
> > It has resolved the issue, but now I am facing another issue.
> > 
> > 
> > $sudo ./lxd --tcp 10.0.3.1:8888
> > error: cannot listen on unix socket: listen unix
> > /var/lib/lxd/unix.socket: bind: address already in use
> > 
> > I confirmed these port are not used, and have tried other ports too.
> > 
> > Regards,
> > Kunal Kushwaha
> > 
> > 
> > 
> > On Wed, Nov 12, 2014 at 11:40 PM, Tycho Andersen
> > <tycho.andersen at canonical.com> wrote:
> > > On Wed, Nov 12, 2014 at 11:38:17PM +0530, Kunal Kushwaha wrote:
> > >> Hi Stéphane,
> > >>
> > >> I am now setting up  my dev environment in ubuntu-trusty-32 with
> > >> kernel 3.13.0-39-generic.
> > >> Now I am getting problem
> > >>
> > >> root at vagrant-ubuntu-trusty-32:/home/vagrant/go/src/github.com/lxc/lxd/lxd# ./lxd
> > >> error: User "root" has no subuids.
> > >>
> > >>
> > >> Basically I am creating  dev environment in vagrant.
> > >
> > > You can fix this by adding a root to /etc/subuid and /etc/subgid,
> > > something like:
> > >
> > > root:100000:65536
> > >
> > > should work. (Of course, you want to be sure that root's range doesn't
> > > overlap with anything that already exists.)
> > >
> > > Tycho
> > >
> > >>
> > >> Regards,
> > >> Kunal Kushwaha
> > >>
> > >>
> > >>
> > >>
> > >> On Tue, Nov 11, 2014 at 11:53 PM, Stéphane Graber <stgraber at ubuntu.com> wrote:
> > >> > On Tue, Nov 11, 2014 at 11:51:01PM +0530, Kunal Kushwaha wrote:
> > >> >> Hi,
> > >> >>
> > >> >> I am trying setup development environment for lxd.
> > >> >> But I am facing issue of "error: open /etc/subuid: no such file or directory"
> > >> >>
> > >> >> $sudo ./lxd --tcp 127.0.0.1:8080
> > >> >> error: open /etc/subuid: no such file or directory
> > >> >>
> > >> >> Please help to resolve this.
> > >> >>
> > >> >> Regards,
> > >> >> Kunal Kushwaha
> > >> >
> > >> > You need a system with unprivileged LXC support, which currently means a
> > >> > 3.12 or higher kernel and a recent enough version of shadow to get you
> > >> > /etc/subuid and /etc/subgid as well as newuidmap and newgidmap.
> > >> >
> > >> > You can read more about that requirement of lxd at:
> > >> >  - https://github.com/lxc/lxd/issues/19
> > >> >  - https://github.com/lxc/lxd/blob/master/specs/userns-idmap.md
> > >> >
> > >> > --
> > >> > Stéphane Graber
> > >> > Ubuntu developer
> > >> > http://www.ubuntu.com
> > >> >
> > >> > _______________________________________________
> > >> > lxc-users mailing list
> > >> > lxc-users at lists.linuxcontainers.org
> > >> > http://lists.linuxcontainers.org/listinfo/lxc-users
> > >> _______________________________________________
> > >> lxc-users mailing list
> > >> lxc-users at lists.linuxcontainers.org
> > >> http://lists.linuxcontainers.org/listinfo/lxc-users
> > > _______________________________________________
> > > lxc-users mailing list
> > > lxc-users at lists.linuxcontainers.org
> > > http://lists.linuxcontainers.org/listinfo/lxc-users
> > _______________________________________________
> > lxc-users mailing list
> > lxc-users at lists.linuxcontainers.org
> > http://lists.linuxcontainers.org/listinfo/lxc-users
> _______________________________________________
> 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