Boot hangs waiting for local filesystems if / isn't in fstab and / is only mounted ro

Bug #527216 reported by Loïc Minier
12
This bug affects 1 person
Affects Status Importance Assigned to Milestone
mountall (Ubuntu)
Fix Released
Medium
Scott James Remnant (Canonical)

Bug Description

Binary package hint: mountall

Hi

If you boot a lucid kernel with no fstab (or specifically without "/" in fstab), with no initrd, and without "rw" on the kernel cmdline, the boot hangs waiting for local filesystems.

If however one passes "rw" on the kernel cmdline, the boot proceeds; it also works if one has / in fstab.

I'm not sure what actually blocks mountall from remounting / rw when it's not listed in fstab; perhaps /dev/root is mising?

This is a low priority use case though; people should have / in their fstab.

Bye,

ProblemType: Bug
Architecture: amd64
Date: Wed Feb 24 18:23:29 2010
DistroRelease: Ubuntu 10.04
Package: mountall 2.5
ProcEnviron:
 LANGUAGE=fr_FR.UTF-8
 PATH=(custom, user)
 LANG=fr_FR.UTF-8
 SHELL=/bin/zsh
ProcVersionSignature: Ubuntu 2.6.32-14.20-generic
SourcePackage: mountall
Uname: Linux 2.6.32-14-generic x86_64

Revision history for this message
Loïc Minier (lool) wrote :
Changed in mountall (Ubuntu):
importance: Undecided → Low
Revision history for this message
Loïc Minier (lool) wrote :

NB: I tried with the linux armel/versatile kernel and qemu with a lucid rootfs; I actually had a fstab myself, but a lot of people using rootstock do not in fact have / in their fstab; I've mentioned this issue to Oliver for fixing in rootstock/documentation.

Changed in mountall (Ubuntu):
status: New → Triaged
Revision history for this message
Oliver Grawert (ogra) wrote :

creating a file /etc/udev/rules.d/root.rules with the content for the root device as found in /proc/self/mountinfo similar to the following fixes the bug:

SUBSYSTEM=="block", ENV{MAJOR}=="8", ENV{MINOR}=="0", SYMLINK+="root"

Changed in mountall (Ubuntu):
assignee: nobody → Scott James Remnant (scott)
Revision history for this message
Scott James Remnant (Canonical) (canonical-scott) wrote :

We've triaged this on #ubuntu-devel today, the problem is that the kernel doesn't pass the device specified by root= to userspace, e.g. by naming it in /proc/self/mountinfo, and instead passes /dev/root. mountall will wait for that device to appear, which it never does, because nothing creates it.

(The kernel doesn't create it in devtmpfs either)

The right fix would be to have udev create /dev/root as a symlink to the device named by MAJOR:MINOR in /proc/self/mountinfo - it makes most sense for this to be a dynamic rule written out by mountall, since it has parsed mountall

We'll need to make sure it's written to /dev/.udev/rules.d - and not written until /dev is actually mounted/remounted (before emitting virtual-filesystems seems like a good place)

Changed in mountall (Ubuntu):
milestone: none → ubuntu-10.04-beta-1
importance: Low → Medium
Changed in mountall (Ubuntu):
status: Triaged → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package mountall - 2.10

---------------
mountall (2.10) lucid; urgency=low

  * Rework the Plymouth connection logic; one needs to attach the client to
    the event loop *after* connection otherwise you don't get disconnection
    notification, and one needs to actually actively disconnect in the
    disconnection handler.
  * For safety and sanity reasons it becomes much simpler to create the
    ply_boot_client when we connect, and free it on disconnection. Thus the
    presence or not of this struct tells us whether we're connected or not.
    LP: #524708.
  * Flush the plymouth connection before closing it and exiting, otherwise
    updates may be pending and the screen have messages that confuse people
    while X is starting (like fsck at 90%). LP: #487744.

  * Replace the modal plymouth prompt for error conditions with code that
    continues working in the background while prompting. This most benefits
    the old "Waiting for" message, which can now allow you to continue to
    wait and it can solve itself. LP: #527666, #545435.
  * Integrate fsck progress updates into the same mechanism.
  * Allow fsck messages to be translated. LP: #390740.
  * Change fsck message to be a little less alarming. LP: #545267.
  * Add hard dependency on Plymouth; without it running, mountall will
    ignore any filesystem which doesn't show up within a few seconds or that
    fails to fsck or mount. If you don't want graphical splash, you simply
    need not install themes.

  * Improve set of messages seen with --verbose, and ensure all visible
    messages are marked for translation. LP: #446592.
  * Reduce priority of failed to mount error for remote filesystems since
    we try again, and this just spams the console. LP: #504224.

  * Keep hold of the dev_t when parsing /proc/self/mountinfo, then after
    mounting /dev (or seeing that it's mounted) create a quick udev rules
    file that adds the /dev/root symlink to this device. LP: #527216.
  * Do not try and update /etc/mtab when it's a symbolic link. LP: #529993.
  * Remove odd -a option from mount calls, probably a C&P error from the
    fsck code long ago. LP: #537135.
  * Wait for Upstart to acknowledge receipt of events, even if we don't
    hang around for them to be handled.
  * Always run through try_mounts() at least once. LP: #537136.
  * Don't keep mountall running if the only remaining unmounted filesystems
  *
 -- Scott James Remnant <email address hidden> Wed, 31 Mar 2010 19:37:31 +0100

Changed in mountall (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.