lxd fails to install

Bug #1672100 reported by James Troup
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
lxd (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

On a box I just upgraded from 12.04 to 16.04 (via 14.04), I tried to install lxd and got the following:

| /var/lib/dpkg/tmp.ci/preinst: 11: /var/lib/dpkg/tmp.ci/preinst: cannot open /etc/subuid: No such file
| usermod: unrecognised option '--add-subuids'

apt history.log:

Start-Date: 2017-03-11 23:45:03
Commandline: apt-get install lxd
Install: lxc-common:amd64 (2.0.7-0ubuntu1~16.04.2, automatic), dnsmasq-base:amd64 (2.75-1ubuntu0.16.04.1, automatic), lxd:amd64 (2.0.9-0ubuntu1~16.04.2), liblxc1:amd64 (2.0.7-0ubuntu1~16.04.2, automatic), lxd-client:amd64 (2.0.9-0ubuntu1~16.04.2, automatic), uidmap:amd64 (1:4.2-3.1ubuntu5, automatic), lxcfs:amd64 (2.0.6-0ubuntu1~16.04.1, automatic)
Error: Sub-process /usr/bin/dpkg returned an error code (1)
End-Date: 2017-03-11 23:45:05

apt term.log: http://paste.ubuntu.com/24160887/

Revision history for this message
James Troup (elmo) wrote :

root@habrok:~# apt-cache madison passwd lxd
    passwd | 1:4.2-3.1ubuntu5 | http://archive.ubuntu.com/ubuntu xenial/main amd64 Packages
       lxd | 2.0.9-0ubuntu1~16.04.2 | http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 Packages
       lxd | 2.0.2-0ubuntu1~16.04.1 | http://security.ubuntu.com/ubuntu xenial-security/main amd64 Packages
       lxd | 2.0.0-0ubuntu4 | http://archive.ubuntu.com/ubuntu xenial/main amd64 Packages
root@habrok:~#

Revision history for this message
Stéphane Graber (stgraber) wrote :

Hmm, that's odd.

Trusty definitely has the --add-subuids argument as we make use of it in LXC in the archive and LXD for the backport.

It looks like your system wasn't fully on Ubuntu 14.04 before you upgraded to 16.04 and ended up still using 12.04's version of passwd which lacks the option.

```
root@trusty:~# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 14.04.5 LTS
Release: 14.04
Codename: trusty

root@trusty:~# dpkg -l passwd
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Architecture Description
+++-=======================-================-================-====================================================
ii passwd 1:4.1.5.1-1ubunt amd64 change and administer password and group data

root@trusty:~# usermod --help | grep subuid
  -v, --add-subuids FIRST-LAST add range of subordinate uids
  -V, --del-subuids FIRST-LAST remvoe range of subordinate uids
root@trusty:~#
```

Changed in lxd (Ubuntu):
status: New → Incomplete
Revision history for this message
James Troup (elmo) wrote : Re: [Bug 1672100] Re: lxd fails to install

Stéphane Graber <email address hidden> writes:

> It looks like your system wasn't fully on Ubuntu 14.04 before you
> upgraded to 16.04 and ended up still using 12.04's version of passwd
> which lacks the option.

Yeah, sorry - I got misled by the output of 'apt-cache madison'.
Although, shouldn't you have a Depends on the specific version of
passwd whose functionality lxd is relying on?

--
James

Revision history for this message
Stéphane Graber (stgraber) wrote :

Certainly wouldn't hurt to add. I didn't bother do so in the first place since all Ubuntu releases capable of running LXD also have a version of shadow which suports uid maps.

Changed in lxd (Ubuntu):
status: Incomplete → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package lxd - 2.11-0ubuntu4

---------------
lxd (2.11-0ubuntu4) zesty; urgency=medium

  * Add versioned dependency on passwd/uidmap. (LP: #1672100)

 -- Stéphane Graber <email address hidden> Mon, 13 Mar 2017 14:44:21 +0000

Changed in lxd (Ubuntu):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.