Bug 187116 - booting from /dev/md0 sw raid1 device panics
booting from /dev/md0 sw raid1 device panics
Status: CLOSED WONTFIX
Product: Fedora
Classification: Fedora
Component: kernel (Show other bugs)
8
i686 Linux
medium Severity medium
: ---
: ---
Assigned To: Kernel Maintainer List
Brian Brock
OldNeedsRetesting bzcl34nup
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2006-03-28 11:23 EST by David Komanek
Modified: 2009-01-09 01:56 EST (History)
7 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-01-09 01:56:39 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description David Komanek 2006-03-28 11:23:55 EST
Description of problem:

booting from /dev/md0 sw raid1 device panics with the following messages:
mount: could not find filesystem '/dev/root'
setuproot: moving /dev failed: No such file or directory
setuproot: error mounting /proc failed: No such file or directory
setuproot: error mounting /sys failed: No such file or directory
switchroot: mount failed: No such file or directory
Kernel panic: not syncing: Attempted to kill init!


Version-Release number of selected component (if applicable):

kernel 2.6.15-1.2054_FC5
mkinitrd: version 5.0.32
mdadm - v2.3.1 - 6 February 2006
grub (GNU GRUB 0.97)

How reproducible:

migrating boot+root partition from single-disk device to the software raid1

Steps to Reproduce:
1. booting sata-disk:
   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1       36970   296961493+  83  Linux     ==> /
/dev/sda2           36971       38390    11406150   83  Linux     ==> /test
/dev/sda3           38391       38913     4200997+  82  Linux swap / Solaris

2. second (identical) disk prepared for raid1
   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *           1       36970   296961493+  fd  Linux raid autodetect
/dev/sdb2           36971       38390    11406150   83  Linux
/dev/sdb3           38391       38913     4200997+  82  Linux swap / Solaris

3. creating array in degraded mode:
mdadm --create /dev/md0 -l 1 -n 2 missing /dev/sdb1
mkfs -t ext3 /dev/md0  # the same results I have for ext2
mount /dev/md0 /foo
tar c / | tar xvC /foo
adjusting /etc/fstab, /etc/grub.conf, running grub-install to be sure
optional (has no effect for me): using mkinitrd --preload=raid1 ....

4. reboot with root=/dev/md0
  
Actual results:

won't boot, produces following messages:

mount: could not find filesystem '/dev/root'
setuproot: moving /dev failed: No such file or directory
setuproot: error mounting /proc failed: No such file or directory
setuproot: error mounting /sys failed: No such file or directory
switchroot: mount failed: No such file or directory
Kernel panic: not syncing: Attempted to kill init!


Expected results:

working system

Additional info:

this procedure of migration to raid1 on boot device worked in FC4 without problems
Comment 1 Dave Jones 2006-10-16 15:54:49 EDT
A new kernel update has been released (Version: 2.6.18-1.2200.fc5)
based upon a new upstream kernel release.

Please retest against this new kernel, as a large number of patches
go into each upstream release, possibly including changes that
may address this problem.

This bug has been placed in NEEDINFO state.
Due to the large volume of inactive bugs in bugzilla, if this bug is
still in this state in two weeks time, it will be closed.

Should this bug still be relevant after this period, the reporter
can reopen the bug at any time. Any other users on the Cc: list
of this bug can request that the bug be reopened by adding a
comment to the bug.

In the last few updates, some users upgrading from FC4->FC5
have reported that installing a kernel update has left their
systems unbootable. If you have been affected by this problem
please check you only have one version of device-mapper & lvm2
installed.  See bug 207474 for further details.

If this bug is a problem preventing you from installing the
release this version is filed against, please see bug 169613.

If this bug has been fixed, but you are now experiencing a different
problem, please file a separate bug for the new problem.

Thank you.
Comment 2 Justin 2006-11-21 11:03:23 EST
I get the same error when trying to boot with root=/dev/md0 (Autodetect sw 
RAID5) using kernel-2.6.18-1.2239.fc5, but NOT with kernel-2.6.17-1.2187_FC5

To clarify, changing nothing but the kernel selection from the boot loader 
menu, kernel-2.6.17-1.2187_FC5 WILL boot and kernel-2.6.18-1.2239.fc5 WILL NOT 
boot with root=/dev/md0

Sorry for the sparse details.
Comment 3 paul.knowles 2007-05-18 06:08:08 EDT
I've had this problem for the past 6 months and I think I have found the source:
mkinitrd will sometimes forget to put /dev/md0 into the /dev of the initrd.

For me, this seems to be related to upgrade migrations moving from single disks
to raided  arrangements.  If mkinitrd is not run from a system with a mounted
running raided root partition, it refuses to put the /dev/md0 (or whichever)
into initrd's copy of /dev.  It also refuses to do this even when
MODULES="raid1" is explicitly specified.

NB: you can check your initrd contents quickly with a
gunzip -c initrd.img | cpio -it
to make sure the necessary files are there.

in /etc/sysconfig/mkinitrd we can specify things like:
   MODULES="raid1"
it would be nice to be able to have 
   DEVS="md0 <other_devs>"
to ensure that those devices get mknod'ed in the initrd.
A command line option would be acceptable (preferable?) too.

With some of machines having this problem, I made initrd's on another machine
and copied them over in rescue mode.  The boot then worked, and initrd then
generated a sane and happy initrd for the machine.
Comment 4 petrosyan 2008-03-13 19:30:54 EDT
Fedora Core 5 is no longer maintained. Is this bug still present in Fedora 7 or
Fedora 8?
Comment 5 Jon Stanley 2008-03-31 14:31:37 EDT
Removing NeedsRetesting from whiteboard so we can repurpose it.
Comment 6 Bug Zapper 2008-04-03 22:19:50 EDT
Fedora apologizes that these issues have not been resolved yet. We're
sorry it's taken so long for your bug to be properly triaged and acted
on. We appreciate the time you took to report this issue and want to
make sure no important bugs slip through the cracks.

If you're currently running a version of Fedora Core between 1 and 6,
please note that Fedora no longer maintains these releases. We strongly
encourage you to upgrade to a current Fedora release. In order to
refocus our efforts as a project we are flagging all of the open bugs
for releases which are no longer maintained and closing them.
http://fedoraproject.org/wiki/LifeCycle/EOL

If this bug is still open against Fedora Core 1 through 6, thirty days
from now, it will be closed 'WONTFIX'. If you can reporduce this bug in
the latest Fedora version, please change to the respective version. If
you are unable to do this, please add a comment to this bug requesting
the change.

Thanks for your help, and we apologize again that we haven't handled
these issues to this point.

The process we are following is outlined here:
http://fedoraproject.org/wiki/BugZappers/F9CleanUp

We will be following the process here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping to ensure this
doesn't happen again.

And if you'd like to join the bug triage team to help make things
better, check out http://fedoraproject.org/wiki/BugZappers
Comment 7 Benny Amorsen 2008-04-21 03:29:19 EDT
I have the exact same problem with Fedora 8 when creating initrd's while running
an older 2.6.22 kernel. (It's hard to switch to a newer kernel when the initrd's
are not correctly created.)

I can't change the version field to 8 since I'm not the submitter.
Comment 8 Chuck Ebbert 2008-04-22 08:52:50 EDT
(In reply to comment #0)
> 3. creating array in degraded mode:
> mdadm --create /dev/md0 -l 1 -n 2 missing /dev/sdb1
> mkfs -t ext3 /dev/md0  # the same results I have for ext2
> mount /dev/md0 /foo
> tar c / | tar xvC /foo
> adjusting /etc/fstab, /etc/grub.conf, running grub-install to be sure
> optional (has no effect for me): using mkinitrd --preload=raid1 ....
> 

mkinitrd looks at the current fstab. You probably needed to run "mkinitrd
--fstab=/foo/etc/fstab --preload=raid1 ..." after editing the new fstab.
Comment 9 John Poelstra 2008-05-03 00:07:15 EDT
Changing version to 8.  

Chuck-re: your last comment... is this not considered a bug? 
Comment 10 Chuck Ebbert 2008-05-06 23:54:02 EDT
(In reply to comment #9)
> Changing version to 8.  
> 
> Chuck-re: your last comment... is this not considered a bug? 

mkinitrd can't tell that when the system gets rebooted the fstab will be coming
from a filesystem that's currently mounted somewhere else. I guess it could be
made to do that but it would be very complicated to figure out, requiring a look
at the "root=" parameter in grub.conf and then trying to figure out if that is
mounted somewhere else currently.
Comment 11 Bug Zapper 2008-11-26 01:56:55 EST
This message is a reminder that Fedora 8 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 8.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '8'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 8's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 8 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Comment 12 Bug Zapper 2009-01-09 01:56:39 EST
Fedora 8 changed to end-of-life (EOL) status on 2009-01-07. Fedora 8 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.

Note You need to log in before you can comment on or make changes to this bug.