debootstrap fails to install libc6 installing oneiric from natty

Bug #807974 reported by Leonardo Robol
44
This bug affects 5 people
Affects Status Importance Assigned to Milestone
base-files (Ubuntu)
Fix Released
Undecided
Canonical Foundations Team
Oneiric
Fix Released
Undecided
Canonical Foundations Team
debootstrap (Ubuntu)
Invalid
High
Unassigned
Oneiric
Invalid
High
Unassigned
mountall (Ubuntu)
Fix Released
Critical
Steve Langasek
Oneiric
Fix Released
Critical
Steve Langasek
sysvinit (Ubuntu)
Fix Released
Critical
Steve Langasek
Oneiric
Fix Released
Critical
Steve Langasek

Bug Description

When trying to create a minimal oneiric install from a natty release, I get this error:

leonardo@debby: sudo debootstrap oneiric oneiric
[ ... lots of Extracting here ... ]
I: Extracting xz-utils...
I: Extracting zlib1g...
I: Installing core packages...
W: Failure trying to run: chroot /home/leonardo/oneiric dpkg --force-depends --install /var/cache/apt/archives/libc6_2.13-9ubuntu2_amd64.deb

If i try to chroot and execute the dpkg command line I get:

root@debby:/# dpkg --force-depends --install /var/cache/apt/archives/libc6_2.13-9ubuntu2_amd64.deb
(Reading database ... 668 files and directories currently installed.)
Preparing to replace libc6 2.13-9ubuntu2 (using .../libc6_2.13-9ubuntu2_amd64.deb) ...
debconf: unable to initialize frontend: Dialog
debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 75.)
debconf: falling back to frontend: Readline
debconf: unable to initialize frontend: Readline
debconf: (Can't locate Term/ReadLine.pm in @INC (@INC contains: /etc/perl /usr/local/lib/perl/5.12.4 /usr/local/share/perl/5.12.4 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.12 /usr/share/perl/5.12 /usr/local/lib/site_perl .) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.)
debconf: falling back to frontend: Teletype
Unpacking replacement libc6 ...
dpkg: libc6: dependency problems, but configuring anyway as you requested:
 libc6 depends on libc-bin (= 2.13-9ubuntu2); however:
  Package libc-bin is not installed.
 libc6 depends on libgcc1; however:
  Package libgcc1 is not installed.
 libc6 depends on tzdata; however:
  Package tzdata is not installed.
Setting up libc6 (2.13-9ubuntu2) ...
debconf: unable to initialize frontend: Dialog
debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 75.)
debconf: falling back to frontend: Readline
debconf: unable to initialize frontend: Readline
debconf: (Can't locate Term/ReadLine.pm in @INC (@INC contains: /etc/perl /usr/local/lib/perl/5.12.4 /usr/local/share/perl/5.12.4 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.12 /usr/share/perl/5.12 /usr/local/lib/site_perl .) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.)
debconf: falling back to frontend: Teletype
touch: cannot touch `/var/run/init.upgraded': No such file or directory
dpkg: error processing libc6 (--install):
 subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
 libc6

And it seems that /var/run is missing:

root@debby:/# ls /var
backups cache lib local log mail opt spool tmp

 If I "mkdir /var/run" then I am able to install
libc6 and finish oneiric installation with dpkg.

ProblemType: Bug
DistroRelease: Ubuntu 11.04
Package: debootstrap 1.0.29ubuntu1
ProcVersionSignature: Ubuntu 2.6.38-8.42-generic 2.6.38.2
Uname: Linux 2.6.38-8-generic x86_64
Architecture: amd64
Date: Sat Jul 9 14:38:42 2011
InstallationMedia: Ubuntu 10.10 "Maverick Meerkat" - Alpha amd64 (20100803.1)
PackageArchitecture: all
ProcEnviron:
 LANGUAGE=it_IT:en
 PATH=(custom, user)
 LANG=it_IT.UTF-8
 SHELL=/bin/bash
SourcePackage: debootstrap
UpgradeStatus: Upgraded to natty on 2011-04-21 (78 days ago)

Revision history for this message
Leonardo Robol (leo.robol) wrote :
Revision history for this message
Ricardo Salveti (rsalveti) wrote :

The problem at this bug is that libc6 postinst script is currently broken, breaking debootstrap, so marking the debootstrap bugtask as invalid

Setting up libc6 (2.13-9ubuntu2) ...
touch: cannot touch `/var/run/init.upgraded': No such file or directory
dpkg: error processing libc6 (--install):
 subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
 libc6

Changed in debootstrap (Ubuntu):
status: New → Confirmed
importance: Undecided → High
status: Confirmed → Invalid
Changed in eglibc (Ubuntu):
status: New → Confirmed
importance: Undecided → High
Revision history for this message
Ricardo Salveti (rsalveti) wrote :

From eglibc-2.13/debian/debhelper.in/libc.postinst:
...
    # Upstart cannot be restarted without losing all of its state, so
    # umountroot will run 'telinit u' on reboot if this file exists
    touch /var/run/init.upgraded
...

I believe this is now a problem as the directory /var/run is not created anymore by base-files, as changed by http://bazaar.launchpad.net/~ubuntu-branches/ubuntu/oneiric/base-files/oneiric/revision/75 (6.3ubuntu3 update).

Revision history for this message
Ricardo Salveti (rsalveti) wrote :

Also linking to base-files as it seems the problem is happening because of the /run transition.

In theory /run should be the tmpfs run directory, replacing /var/run. To be compatible with packages using /var/run directly, the transition should still make /var/run available to the system, but bind mounted to /run.

The problem here is that the directory /var/run is not being created anymore, as a side effect of base-files 6.3ubuntu3 package update. As this directory should still exist anyway (to be used while bind mounting to run), I believe it makes sense to still create it at base-files, so it's not going to break packages like libc6 and upstart.

Revision history for this message
Martin Pitt (pitti) wrote :

Breaks all CD builds at the moment, thus milestone blocker.

Changed in eglibc (Ubuntu):
assignee: nobody → Canonical Foundations Team (canonical-foundations)
Changed in eglibc (Ubuntu Oneiric):
importance: High → Critical
milestone: none → oneiric-alpha-3
status: Confirmed → Triaged
Revision history for this message
Steve Langasek (vorlon) wrote :

Yes, this was a botched transition in base-files. /var/run needs to be restored as a symlink to /run, but picking up the code from Debian to do this in base-files entangles us with related code changes in the sysvinit package, and that's a very hairy merge. I've started working on said merge the end of last week, but it's not going to be done quickly.

I think an appropriate stopgap might be to readd /var/run and /var/lock directories to base-files.

Revision history for this message
Steve Langasek (vorlon) wrote :

not actually a bug in eglibc at all; reassigning to the responsible packages.

affects: eglibc (Ubuntu Oneiric) → sysvinit (Ubuntu Oneiric)
Changed in sysvinit (Ubuntu Oneiric):
assignee: Canonical Foundations Team (canonical-foundations) → Steve Langasek (vorlon)
Changed in mountall (Ubuntu Oneiric):
assignee: nobody → Steve Langasek (vorlon)
Changed in base-files (Ubuntu Oneiric):
assignee: nobody → Canonical Foundations Team (canonical-foundations)
Changed in mountall (Ubuntu Oneiric):
importance: Undecided → Critical
Revision history for this message
Barry Warsaw (barry) wrote :

Breaks pbuilder too.

Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (32.8 KiB)

This bug was fixed in the package sysvinit - 2.88dsf-13.10ubuntu1

---------------
sysvinit (2.88dsf-13.10ubuntu1) oneiric; urgency=low

  * Merge from Debian unstable (LP: #807974), remaining changes:
    - Support Cell processor:
      + debian/initscripts.postinst: Create spu system group and /spu mount
        point if we are running on a Cell processor.
      + debian/control: Add initscripts dependency 'passwd' for groupadd.
      (Forwarded to Debian #483399)
    - Disable bootlogd by default.
    - debian/patches/91_sulogin_lockedpw.dpatch: Disable "root account is
      locked" warning, since this is the default in Ubuntu. Document this in
      sulogin.8.
    - debian/control: Drop Essential: yes from packages since we use Upstart.
    - debian/control: Do not build the sysvinit binary package any more. It
      conflicts with upstart, which is required, so it is uninstallable.
    - debian/src/initscripts/etc/init.d/ondemand: Sleep for 60 seconds, then
      set CPU Frequency Scaling governor to "ondemand". LP: #341573.
    - debian/rules: Compat symlink from /usr/bin/service to
      /usr/sbin/service
    - debian/control: sysvinit-utils recommends the upstart that provides
      the reload action
    - Remove various initscripts (and an ifupdown hook) that have been
      replaced by upstart jobs shipped in other packages.
    - debian/sysv-rc.postinst: Don't use insserv by default
    - debian/src/initscripts/man/rcS.5: drop mention of /etc/default/tmpfs,
      which doesn't do anything on Ubuntu.
    - Remove RAMLOCK, RAMSHM, and RAMTMP settings from default rcS script to
      avoid confusion, remove from /etc/default/rcS on upgrade too; and remove
      mention of all of these plus RAMRUN from the manual pages.
    - Always skip these when unmounting filesystems.
    - Fix documentation for other things handled by mountall instead of
      initscripts: tmpfs, /sys (mountall lets you specify options in
      /etc/fstab), and ASYNCMOUNTNFS.
    - If /var/run/init.upgraded exists, call telinit u before unmounting
      the root filesystem.
    - Create /lib/init/rw as a symlink to /var/run on new installations,
      and fix it up in /etc/init.d/umountroot on upgrade, as it's difficult
      to do this at any other time
    - debian/initscripts.postinst:
      + do not create motd.tail from motd on systems using update-motd.
      + clean up incorrectly created motd.tail from upgrade to Maverick.
    - debian/src/initscripts/etc/init.d/sendsigs:
      + sendsigs: OMITPIDS needs to be reinitalized for every loop iteration
        before concatenating pids of upstart jobs to it.
      + handle the possibility of upstart jobs being started after the
        script starts running, to avoid unnecessary 10 second delays on
        shutdown.
      + only omit jobs that are in the 'start' goal. Those that are destined
        for 'stop' are waited on and killed like all other processes.
      + make report_unkillable use apport instead of echoing to console; but
        disable this reporting by default.
    - debian/patches/92_sulogin_support_static_sh.patch: add support for
      /bin/static-sh as fallback if the regular shell fails...

Changed in sysvinit (Ubuntu Oneiric):
status: Triaged → Fix Released
Revision history for this message
Steve Langasek (vorlon) wrote :

The mountall side was fixed with 2.28. Changelog:

mountall (2.28) oneiric; urgency=low

  [ Colin Watson ]
  * Mount /run, /run/lock, and /run/shm rather than /var/run, /var/lock, and
    /var/shm. Handle migration of the old locations to symlinks.

Changed in mountall (Ubuntu Oneiric):
status: New → Fix Released
Revision history for this message
Steve Langasek (vorlon) wrote :

The base-files side of this was fixed in base-files 6.4ubuntu1. Changelog:

base-files (6.4ubuntu1) oneiric; urgency=low

  * Merge from Debian unstable, remaining changes:
    - Branding changes.
    - Add /etc/lsb-release file.
    - Add lsb-release-udeb package.
    - Record md5sums of unmodified /etc/profile versions so that we can
      upgrade it automatically.
    - Various bashrc extensions.
    - Do not install /usr/local dirs with staff group writeability, as there
      are cases where somebody can become any user but root (like NFS).
    - Update the motd upgrade handling to know about /etc/motd.tail.
    - Add default /etc/networks file.
    - Added information about the docs web page.
    - Restore order line in /etc/host.conf with a comment.
    - Ship /root mode 700 by default.
  * Dropped changes:
    - drop versioned dependency on libpam-modules, satisfied in all versions
      since hardy (and earlier)
    - remove /var/lock and /var/run: this is handled differently in Debian,
      no reason to diverge
    - fixing up permissions of files copied by ubiquity: transition completed
      in lucid.
    - debian/postinst.in: replace references to /var/run with /run: /run is
      still a draft standard for the time being and should only be used for
      those parts of the system that were being placed *other* than in
      /var/run for various reasons (e.g., /dev/.udev, /lib/init/rw).
      /var/run must continue to exist and be functional, and initscripts
      guarantees a smooth transition from /var/run to /run once we are ready
      to start doing away with /var/run (once the FHS officially ratifies
      /run as its replacement), so there's no reason to diverge from Debian
      here.

base-files (6.4) unstable; urgency=low

  * Added /run. Closes: #620157.
  * On new installs:
    - Create /run/lock (debian-installer will remove it but this will
    ensure that it exists even on chroot environments).
    - Symlink /var/run to /run.
    - Symlink /var/lock to /run/lock.
  * On upgraded systems, initscripts will handle the transition to /run.
  * Added "Breaks: initscripts << (2.88dsf-13.3)" to ensure that initscripts
    is upgraded first, as otherwise udev would break.
  * Thanks a lot to Roger Leigh.

Changed in base-files (Ubuntu Oneiric):
status: New → Fix Released
Revision history for this message
dj_palindrome (dj.palindrome) wrote :

Excuse me if it is inappropriate to say this here, but a seemingly related series of breaking changes still persists. First, X lost all input devices. Then, there was a hang on boot. The Plymouth logo stopped spinning and the system just croaked; the login screen never appeared. The latest breaking change occurred while upgrading *one* package only (base-files) to 6.4ubuntu2. Supposedly that was expressly intended to fix other devastating bugs. After that, I gave up and reverted to a stable snapshot.

I'm all for stealing from Debian Unstable, but when this is done in a piecemeal and uncoordinated manner, and Oneiric is orders of magnitude more unstable than Sid, something is wrong. Really, this is getting to be too much. I'm not talking about an ugly screen or a few missing icons. We are approaching total unusability. More often than not, dpkg receives a segfault during routine upgrades.

Revision history for this message
Steve Langasek (vorlon) wrote : Re: [Bug 807974] Re: debootstrap fails to install libc6 installing oneiric from natty

On Fri, Jul 15, 2011 at 10:50:37PM -0000, dj_palindrome wrote:
> Excuse me if it is inappropriate to say this here, but a seemingly
> related series of breaking changes still persists. First, X lost all
> input devices.

This was a bug in initramfs-tools.

> Then, there was a hang on boot. The Plymouth logo stopped spinning and
> the system just croaked; the login screen never appeared.

This may have been another bug in initramfs-tools (one which was fixed
today).

> Really, this is getting to be too much. I'm not talking about an ugly
> screen or a few missing icons. We are approaching total unusability.

Oneiric is a development release which is currently in the alpha stage of
its development cycle. Total unusability is a very real and ordinary risk
of running the software at this stage.

> More often than not, dpkg receives a segfault during routine upgrades.

Sorry, that's unrelated to any of the above changes and no one else is
reporting such a problem. The more likely culprit here would be some kind
of disk corruption or hardware failure.

--
Steve Langasek Give me a lever long enough and a Free OS
Debian Developer to set it on, and I can move the world.
Ubuntu Developer http://www.debian.org/
<email address hidden> <email address hidden>

Revision history for this message
dj_palindrome (dj.palindrome) wrote :

On Fri, Jul 15, 2011, Steve Langasek wrote:
> Oneiric is a development release which is currently in the alpha stage of
> its development cycle. Total unusability is a very real and ordinary risk
> of running the software at this stage.

I'm not complaining, since I'm not one of your developers, and therefore do not have to eat your dog food unless I choose to.

> Sorry, that's unrelated to any of the above changes and no one else is
> reporting such a problem. The more likely culprit here would be some kind
> of disk corruption or hardware failure.

How odd, when the "hardware" in question is completely virtualized, and, whenever it did occur, it would occur simultaneously in two parallel, but physically distinct and independent virtualization environments, both of which emulate completely different hardware, and use distinct virtual-disk formats.

In fairness, though, this has not happened in quite a while now. I'm only reminded because it surface for me again today, although the system was nice enough to recover itself gracefully (on previous occasions, dpkg --configure -a sufficed):

E: Sub-process /usr/bin/dpkg received a segmentation fault.
A package failed to install. Trying to recover:
Processing triggers for initramfs-tools ...
update-initramfs: Generating /boot/initrd.img-3.0.0-8-generic
Processing triggers for libc-bin ...
ldconfig deferred processing now taking place
Setting up libstdc++6-4.5-dev (4.5.3-6ubuntu1) ...
Setting up g++-4.5 (4.5.3-6ubuntu1) ...

Revision history for this message
Steve Langasek (vorlon) wrote :

Perhaps you have a buggy virtualization environment (which would qualify as a "hardware problem")? Or maybe you have some library being LD_PRELOADed in your environment which breaks things? Honestly, *no one* else is reporting such dpkg segfaults, so this is not a widespread problem. You've pointed out some differences between the two systems where you encounter the issue; I think it's time for you to look for what's the same between your two systems but different from a typical install / environment.

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.