Daemon-suppression code in installer breaks new invoke-rc.d logic

Bug #1182540 reported by Para Siva
16
This bug affects 2 people
Affects Status Importance Assigned to Milestone
debian-installer-utils (Ubuntu)
Fix Released
Critical
Colin Watson
debootstrap (Ubuntu)
Fix Released
Critical
Colin Watson
ubiquity (Ubuntu)
Fix Released
Critical
Colin Watson

Bug Description

The root of the problem as pertains to lxc is that debootstrap is resulting in a udev being started as a child of debootstrap. In particular:

( flock -x 200; debootstrap saucy xxx; ) 200>/tmp/zzz
after this completes, /proc/locks will show that /tmp/zzz is still locked; udev will be running; and a subsequent
( flock -x 200 ) 200>/tmp/zzz
will hang.

========

The saucy smoke test for lxc test_lxc_apparmor appears to be hung with saucy installations of 20130521.

The following tests appear to have completed successfully.
- test: test_lxc_reboot
- test: test_lxc_simple
- test: test_lxc_api

Steps to reproduce:
1. Install a default saucy server on a vm (either manually or preseeded default installation) with either i386 or amd64 image using KVM, libvirt
2. Do the following to install utah inside the VM
   sudo apt-add-repository -y ppa:utah/stable
   sudo apt-get update
   sudo apt-get install utah
3. Run the lxc tests using
     sudo utah -r lp:ubuntu-test-cases/server/runlists/lxc.run

ProblemType: Bug
DistroRelease: Ubuntu 13.10
Package: lxc 0.9.0-0ubuntu7
ProcVersionSignature: Ubuntu 3.9.0-2.7-generic 3.9.3
Uname: Linux 3.9.0-2-generic x86_64
ApportVersion: 2.10.1-0ubuntu1
Architecture: amd64
Date: Tue May 21 11:30:55 2013
InstallationDate: Installed on 2013-05-21 (0 days ago)
InstallationMedia: Ubuntu-Server 13.10 "Saucy Salamander" - Alpha amd64 (20130521)
MarkForUpload: True
SourcePackage: lxc
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Para Siva (psivaa) wrote :
Paul Larson (pwlars)
tags: added: qa-daily-testing rls-s-incoming
Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

When I took a close look the first time, it appeared to be hung in the lxc-ubuntu template on flock.

If this is reproducible, and hangs again on flock, then it sounds like a kernel bug and we should mark as affecting linux.

I couldn't reproduce this on a saucy canonistack instance, but that may not have rebooted into the latest kernel.

Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

Marking incomplete until it is reproduced. If it happens again, then please mark it confirmed.

Changed in lxc (Ubuntu):
importance: Undecided → High
status: New → Incomplete
Revision history for this message
Para Siva (psivaa) wrote :

This is occurring in all the runs with today's image. The latest active one is on utah-9138-saucy-server-amd6. Marking as confirmed. Thanks

Changed in lxc (Ubuntu):
status: Incomplete → Confirmed
Para Siva (psivaa)
description: updated
description: updated
description: updated
Revision history for this message
Colin Watson (cjwatson) wrote :

This is also breaking all live filesystem builds, because udevd --daemon hangs around after debootstrap and eventually part of auto/build refuses to exit as a result.

affects: udev (Ubuntu) → systemd (Ubuntu)
Changed in systemd (Ubuntu):
importance: Undecided → Critical
no longer affects: lxc (Ubuntu)
Changed in systemd (Ubuntu):
status: New → Confirmed
Martin Pitt (pitti)
Changed in systemd (Ubuntu):
assignee: nobody → Martin Pitt (pitti)
status: Confirmed → In Progress
Revision history for this message
Colin Watson (cjwatson) wrote :

This turns out to be because debootstrap's fake initctl implementation doesn't pass through "version", so invoke-rc.d gets confused. debian-installer-utils and ubiquity share this bug.

Furthermore, debootstrap doesn't install a policy-rc.d script, which would otherwise act as a stopgap here. debian-installer-utils and ubiquity do not share this bug.

affects: systemd (Ubuntu) → debootstrap (Ubuntu)
Changed in debootstrap (Ubuntu):
assignee: Martin Pitt (pitti) → Colin Watson (cjwatson)
status: In Progress → Triaged
Colin Watson (cjwatson)
Changed in ubiquity (Ubuntu):
status: New → Triaged
importance: Undecided → Critical
assignee: nobody → Colin Watson (cjwatson)
Changed in debian-installer (Ubuntu):
status: New → Triaged
importance: Undecided → Critical
assignee: nobody → Colin Watson (cjwatson)
summary: - lxc smoke test, test_lxc_apparmor appears to hang on saucy VM
+ Daemon-suppression code in installer breaks new invoke-rc.d logic
Colin Watson (cjwatson)
Changed in debootstrap (Ubuntu):
status: Triaged → Fix Committed
Changed in ubiquity (Ubuntu):
status: Triaged → Fix Committed
Changed in debian-installer (Ubuntu):
status: Triaged → Fix Committed
affects: debian-installer (Ubuntu) → debian-installer-utils (Ubuntu)
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package debian-installer-utils - 1.97ubuntu1

---------------
debian-installer-utils (1.97ubuntu1) saucy; urgency=low

  * Resynchronise with Debian. Remaining changes:
    - user-params: Don't propagate vga=*, break=*, *-ubiquity, or
      noninteractive to installed system.
    - Use /proc/self/fd/4 rather than /dev/fd/4 in fetch-url-methods/http;
      the latter doesn't seem to exist in d-i.
    - list-devices:
      + New "mmc-partition" type for detecting partitions on MMC devices.
      + Make sure we also detect platform-omap MMCs.
      + Don't return entries for extended partitions.
    - Don't include the battery subsystem on calls to udevadm trigger.
    - log-output: Always install a no-op SIGCHLD handler, in case the
      subsidiary process starts a daemon which does not fully disconnect its
      standard file descriptors.

debian-installer-utils (1.97) unstable; urgency=low

  * chroot-setup.sh: Make the fake initctl pass through "initctl version"
    calls, used by such things as invoke-rc.d to figure out whether it's
    running under Upstart (LP: #1182540).

debian-installer-utils (1.96) unstable; urgency=low

  [ Samuel Thibault ]
  * Make iso-scan probing a lot faster on hurd-i386 by avoiding non-existing
    partitions.

  [ Updated translations ]
  * Croatian (hr.po) by Tomislav Krznar
  *
 -- Colin Watson <email address hidden> Wed, 22 May 2013 17:10:46 +0100

Changed in debian-installer-utils (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ubiquity - 2.15.5

---------------
ubiquity (2.15.5) saucy; urgency=low

  * ubiquity/install_misc.py: Make the fake initctl pass through "initctl
    version" calls, used by such things as invoke-rc.d to figure out whether
    it's running under Upstart (LP: #1182540).
  * Automatic update of included source packages: apt-setup 1:0.80ubuntu1,
    debian-installer-utils 1.97ubuntu1, partman-basicmethods 53,
    partman-btrfs 11ubuntu1, partman-jfs 39, partman-newworld 29,
    partman-reiserfs 54, partman-xfs 51, user-setup 1.48ubuntu1.
 -- Colin Watson <email address hidden> Wed, 22 May 2013 17:27:22 +0100

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

This bug was fixed in the package debootstrap - 1.0.52

---------------
debootstrap (1.0.52) unstable; urgency=low

  * scripts/gutsy: Make the fake initctl pass through "initctl version"
    calls, used by such things as invoke-rc.d to figure out whether it's
    running under Upstart (LP: #1182540).
  * scripts/sid, scripts/gutsy: Add a policy-rc.d, matching that in
    debian-installer-utils. This is the primary way to disable daemon
    startup.

 -- Colin Watson <email address hidden> Wed, 22 May 2013 16:55:59 +0100

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

Duplicates of this bug

Other bug subscribers

Remote bug watches

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