docker.io install fails when docker group exists

Bug #1769911 reported by Michał Denkiewicz on 2018-05-08
56
This bug affects 6 people
Affects Status Importance Assigned to Milestone
docker.io (Debian)
Fix Released
Unknown
docker.io (Ubuntu)
High
Unassigned
Xenial
Undecided
Unassigned
Bionic
Undecided
Unassigned

Bug Description

[impact]
installation of docker can fail trying to create the docker group if it already exists

[test case]
# addgroup docker
# apt install docker.io

[regression potential]
The change to fix this but is small and clear: https://github.com/tianon/debian-docker/commit/16b582b497a35324246fbb203f2e094d944445ec

Also we don't care much about regressions in docker.io! https://wiki.ubuntu.com/DockerUpdates

[original description]

After installing nvidia-docker

ProblemType: Package
DistroRelease: Ubuntu 18.04
Package: docker.io 17.12.1-0ubuntu1
ProcVersionSignature: Ubuntu 4.15.0-20.21-generic 4.15.17
Uname: Linux 4.15.0-20-generic x86_64
NonfreeKernelModules: nvidia_modeset nvidia
ApportVersion: 2.20.9-0ubuntu7
Architecture: amd64
Date: Tue May 8 16:22:53 2018
ErrorMessage: installed docker.io package post-installation script subprocess returned error exit status 1
InstallationDate: Installed on 2018-05-07 (0 days ago)
InstallationMedia: Ubuntu 18.04 LTS "Bionic Beaver" - Release amd64 (20180426)
Python3Details: /usr/bin/python3.6, Python 3.6.5, python3-minimal, 3.6.5-3
PythonDetails: /usr/bin/python2.7, Python 2.7.15rc1, python-minimal, 2.7.15~rc1-1
RelatedPackageVersions:
 dpkg 1.19.0.5ubuntu2
 apt 1.6.1
SourcePackage: docker.io
Title: package docker.io 17.12.1-0ubuntu1 failed to install/upgrade: installed docker.io package post-installation script subprocess returned error exit status 1
UpgradeStatus: No upgrade log present (probably fresh install)

Michał Denkiewicz (michade) wrote :
Joshua Powers (powersj) wrote :

From terminal log:

addgroup: The group `docker' already exists and is not a system group. Exiting.

Joshua Powers (powersj) wrote :

I've seen this come up a number of times and I do not recall what the original issue was that leaves a 'docker' group around that eventually collides with the install. If the group already exists, I would assume that the install should not die, but continue on.

Changed in docker.io (Ubuntu):
status: New → Confirmed
importance: Undecided → High
summary: - package docker.io 17.12.1-0ubuntu1 failed to install/upgrade: installed
- docker.io package post-installation script subprocess returned error
- exit status 1
+ docker.io install fails when docker group exists
Andreas Hasenack (ahasenack) wrote :

Probably caused by people aborting an installation attempt due to https://bugs.launchpad.net/ubuntu/+source/docker.io/+bug/1628053 and then trying again, but by then the group already exists. Just an idea, I haven't debugged it.

Steve Beattie (sbeattie) wrote :

Debian fixed this issue in 18.03.1+dfsg1-3 with the following: https://salsa.debian.org/docker-team/docker/commit/46b44b63332486dbd7b84e2be1029dc40e182410

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package docker.io - 18.06.1-0ubuntu1

---------------
docker.io (18.06.1-0ubuntu1) cosmic; urgency=medium

  * Update to 18.06.1 upstream release (LP: #1794396)
    - drop "fix-btrfs-constants.patch" (applied upstream)
  * Update debconf to prompt more aggressively (LP: #1784602)
    1. does not prompt on initial install (but does start the daemon)
    2. does prompt on every reinstall / upgrade (if the daemon is running)
    3. does prompt during "dpkg-reconfigure docker.io" (but does _not_
       [re]start the daemon)
    4. works properly with DEBIAN_FRONTEND=noninteractive -- user's
       previous/stored answer to the question automatically applies with no
       prompt
  * Check if "docker" group exists before creating it (LP: #1769911)

 -- Tianon Gravi <email address hidden> Mon, 24 Sep 2018 15:42:19 -0700

Changed in docker.io (Ubuntu):
status: Confirmed → Fix Released
Changed in docker.io (Ubuntu Xenial):
status: New → Triaged
Changed in docker.io (Ubuntu Bionic):
status: New → Fix Committed
description: updated
Changed in docker.io (Debian):
status: Unknown → Fix Released

Hello Michał, or anyone else affected,

Accepted docker.io into xenial-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/docker.io/18.06.1-0ubuntu1~16.04.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-xenial to verification-done-xenial. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-xenial. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in docker.io (Ubuntu Bionic):
status: Fix Committed → Fix Released
Changed in docker.io (Ubuntu Xenial):
status: Triaged → Fix Committed
tags: added: verification-needed verification-needed-xenial
tags: added: verification-done-xenial
removed: verification-needed verification-needed-xenial
Brian Murray (brian-murray) wrote :

Hello Michał, or anyone else affected,

Accepted docker.io into xenial-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/docker.io/18.06.1-0ubuntu1~16.04.2 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-xenial to verification-done-xenial. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-xenial. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

tags: added: verification-needed verification-needed-xenial
removed: verification-done-xenial
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

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