linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Mounting /dev/md0 as root in 2.6.0-test7
@ 2003-10-19 16:58 Harold Martin
  2003-10-19 18:16 ` Michael Buesch
  2003-10-20  8:23 ` Helge Hafting
  0 siblings, 2 replies; 6+ messages in thread
From: Harold Martin @ 2003-10-19 16:58 UTC (permalink / raw)
  To: linux-kernel

First, is it possible to mount an md device as root (superblock is
present)?
If not then the rest of this doesn't really matter...

If so, I can't get it to work :(
I pass root=/dev/md0 to the kernl, but I get the "Kernel panic: VFS:
Unable to mount root fs on md0" error.
My setup:
kernel 2.6.0-test7
One drive on each of my two IDE channels (i810 chipset)
RAID 0, set up with raidtools
Using devfs
My FS type (ext2 and ext3), partition type (DOS), and RAID-0 support are
all compiled in (not as modules).

What else do I need to do to be able to mount /dev/md0 as root?

Thanks for your help,
Harold


^ permalink raw reply	[flat|nested] 6+ messages in thread
* Re: Mounting /dev/md0 as root in 2.6.0-test7
@ 2003-10-19 18:53 John Mock
  2003-10-19 19:12 ` Andre Tomt
  0 siblings, 1 reply; 6+ messages in thread
From: John Mock @ 2003-10-19 18:53 UTC (permalink / raw)
  To: linux-kernel

    > First, is it possible to mount an md device as root (superblock is
    > present)?

Yes, software RAID5 works for me on a PPC with 2.6.0-test7 (aside from other
video problems which make it hard for me to test adequately).  There is a
HOW-TO which explains how to do this (you want the >= 0.9 version, not the
0.4 version which is not relevant for modern kernels).

    > If so, I can't get it to work :(
    > I pass root=/dev/md0 to the kernl, but I get the "Kernel panic: VFS:
    > Unable to mount root fs on md0" error.

The basic problem here is that the kernel has no idea what disks comprise
your RAID when you just say "root=/dev/md0", e.g., it has no idea where to
start.  Here's an extract from my PPC's .config file:

    CONFIG_CMDLINE="root=/dev/md0 md=0,/dev/sda7,/dev/sdb7,/dev/sdc7"

Something like that could also be in /etc/lilo.conf if you use LILO (which
a PowerPC does not).

Thus the kernel has three disk to look at, to find out which partitions
make up /dev/md0.  Since i want the machine to work no matter which of my
three disk might fail, i have arranged my disks to have the root partition 
on the same partition number on each drive (even though they're not the 
same capacity or even organized in the same way otherwise).  If /dev/sda 
and /dev/sdb differ too much, then if /dev/sda fails sufficiently badly, 
then the drives get 'renumbered' (e.g. what was /dev/sdb because /dev/sda, 
/dev/sdc becomes /dev/sdb, etc.).

Write privately if you want to discuss this further (albeit i am hardly an
expert on this), as this mailing list is about maintaining the kernel rather
than about helping people get started with new configurations.  Yes, it can
work, and if it does with one recent kernel, but not another, then that's a
good hint that this may be an appropriate place to post (assuming a search 
of the archives doesn't already contain alot of discussion on your topic).
Good luck!
			         -- JM

^ permalink raw reply	[flat|nested] 6+ messages in thread
* Re: Mounting /dev/md0 as root in 2.6.0-test7
@ 2003-10-19 20:48 John Mock
  0 siblings, 0 replies; 6+ messages in thread
From: John Mock @ 2003-10-19 20:48 UTC (permalink / raw)
  To: Harold Martin; +Cc: linux-kernel

I have been corrected!  While /dev/md0 may not be correctly detected in
Macintosh (PPC) partitions, they should be recognized in MSDOS and SUN
partition tables.  You probably won't need a 'md0=...' command line for
most configurations.

I apologize for any confusion i may have created.  Thank you very much
for the correction, Andre.
				       -- JM


P.S.  I believe the relevant HOW-TO is:

    http://www.tldp.org/HOWTO/Boot+Root+Raid+LILO.html

    Boot+Root+Raid+LILO, Boot + Root + Raid + Lilo : Software Raid mini-HOWTO

    Updated: July 2000. A cookbook for setting up root raid using the 0.90
    raidtools for bootable raid mounted on root using standard LILO. 

Good luck!

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2003-10-20  8:13 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-10-19 16:58 Mounting /dev/md0 as root in 2.6.0-test7 Harold Martin
2003-10-19 18:16 ` Michael Buesch
2003-10-20  8:23 ` Helge Hafting
  -- strict thread matches above, loose matches on Subject: below --
2003-10-19 18:53 John Mock
2003-10-19 19:12 ` Andre Tomt
2003-10-19 20:48 John Mock

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).