View previous topic :: View next topic |
Author |
Message |
wr0x2 n00b
Joined: 04 Aug 2006 Posts: 19
|
Posted: Thu Aug 10, 2006 5:10 am Post subject: kernel panic when booting from kernel raid [SOLVED] |
|
|
Followed guide here, install is finished and I have installed grub onto my drive and booted my kernel... Everything goes well until md starts initializing my root drive...
Output:
starting 5 lines above the kernel panic notification:
Code: |
md: autodetecting RAID arrays.
md: autorun...
md: ... autorun DONE.
VFS: Cannot open root device "md3" or unknown-block(0.0)
please append a correct "root=" boot option
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown block (0,0)
|
My grub.conf has the line
Code: |
kernel /boot/MYKERNEL root=/dev/md3
|
in it, so I do not understand why this isn't working. Is my array not being initalized properly?
Here's my setup:
/boot - /dev/md1 (/dev/sda1 and /dev/sdb1 in raid1)
swap - /dev/md2 (/dev/sda2 and /dev/sdb2 in raid0)
/ - /dev/md3 (/dev/sda3 and /dev/sdb3 in raid0... I do backups)
I'm sure I have made a simple mistake somewhere, please help me spot it.
Last edited by wr0x2 on Mon Aug 14, 2006 5:36 pm; edited 1 time in total |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54300 Location: 56N 3W
|
Posted: Thu Aug 10, 2006 9:41 am Post subject: |
|
|
wr0x2,
Code: | md: autodetecting RAID arrays.
md: autorun...
md: ... autorun DONE. | shows the raid sets were not auto detected.
That normally means you didn't set the partition types to 0xfd.
will show you.
All partitions contributing to raid must be type 0xfd. Thats how the kernel knows to form the raid at boot time. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
wr0x2 n00b
Joined: 04 Aug 2006 Posts: 19
|
Posted: Thu Aug 10, 2006 1:24 pm Post subject: |
|
|
I am sure that I set all my partitions to type fd, but I will check again, thanks. |
|
Back to top |
|
|
troymc Guru
Joined: 22 Mar 2006 Posts: 553
|
Posted: Thu Aug 10, 2006 3:38 pm Post subject: |
|
|
Also, make sure you have your raid drivers built into the kernel.
You should see a line earlier where it loads the raid personalites.
troymc |
|
Back to top |
|
|
sageman Guru
Joined: 04 May 2005 Posts: 363 Location: New Hampshire
|
Posted: Thu Aug 10, 2006 3:48 pm Post subject: |
|
|
Are you sure they are md1, md2 and md3? Typically there is a md0, which, given the same order, would make your root directory /dev/md2.
As the previous poster mentions, all the raid stuff should be builtin, *not* modules. |
|
Back to top |
|
|
wr0x2 n00b
Joined: 04 Aug 2006 Posts: 19
|
Posted: Sun Aug 13, 2006 6:55 pm Post subject: |
|
|
I printed the partition tables for both of my drives (/dev/sda and /dev/sdb) and all partitions present are type fd. I compiled my kernel with built in raid support, and not as a module. Is there some special option other than that which I will need to enable?
edit: I followed the naming scheme followed in the guide that I linked to, and I began my nodes with a 1, not a 0.
Also, here is my grub.conf
Code: |
default 0
timeout 30
title=Gentoo Linux
root(hd1,0)
kernel /boot/MYKERNEL root=/dev/md3
|
hd1 is correct, because I have an older IDE drive in my system, and it takes the place of hd0. |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54300 Location: 56N 3W
|
Posted: Sun Aug 13, 2006 7:32 pm Post subject: |
|
|
wr0x2,
Did your form your raid sets with persistant superblocks ?
Thats needed to make them auto start.
Heres a snip from my dmesg, shown two raids starting Code: | [17179577.828000] md: considering sdb5 ...
[17179577.828000] md: adding sdb5 ...
[17179577.832000] md: sdb1 has different UUID to sdb5
[17179577.836000] md: adding sda5 ...
[17179577.840000] md: sda1 has different UUID to sdb5
[17179577.840000] md: created md1
[17179577.844000] md: bind<sda5>
[17179577.848000] md: bind<sdb5>
[17179577.852000] md: running: <sdb5><sda5>
[17179577.852000] md1: setting max_sectors to 32, segment boundary to 8191
[17179577.856000] raid0: looking at sdb5
[17179577.860000] raid0: comparing sdb5(4891648) with sdb5(4891648)
[17179577.860000] raid0: END
[17179577.864000] raid0: ==> UNIQUE
[17179577.868000] raid0: 1 zones
[17179577.872000] raid0: looking at sda5
[17179577.872000] raid0: comparing sda5(4891648) with sdb5(4891648)
[17179577.876000] raid0: EQUAL
[17179577.880000] raid0: FINAL 1 zones
[17179577.884000] raid0: done.
[17179577.884000] raid0 : md_size is 9783296 blocks.
[17179577.888000] raid0 : conf->hash_spacing is 9783296 blocks.
[17179577.892000] raid0 : nb_zone is 1.
[17179577.896000] raid0 : Allocating 4 bytes for hash.
[17179577.896000] md: considering sdb1 ...
[17179577.900000] md: adding sdb1 ...
[17179577.904000] md: adding sda1 ...
[17179577.908000] md: created md0
[17179577.908000] md: bind<sda1>
[17179577.912000] md: bind<sdb1>
[17179577.916000] md: running: <sdb1><sda1>
[17179577.920000] raid1: raid set md0 active with 2 out of 2 mirrors
[17179577.920000] md: ... autorun DONE. | Its a radi0 and a raid1. You should have some of that too, before the autorun DONE _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
wr0x2 n00b
Joined: 04 Aug 2006 Posts: 19
|
Posted: Sun Aug 13, 2006 9:05 pm Post subject: |
|
|
all this from the live minimal install cd:
mdadm -D /dev/md3 shows a persistant superblock. Again, are there any special options to select when configuring a kernel that I might have missed? |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54300 Location: 56N 3W
|
Posted: Sun Aug 13, 2006 9:30 pm Post subject: |
|
|
wr0x2
From the top, identify the partitions as type fd.
make the raid sets with mdadm or raidtools (I use the latter)
mkfs on the raid volumes /dev/mdX ..
Build a kernel with the high and low level hardware device drivers.
Not sure if you need Code: | RAID Transport Class | which is hidden at the top of SCSI, I have that.
Multi-device support (RAID and LVM) for your Raid levels all build in.
It all sounds good.
I can post my kernel .config if you like. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
cyrillic Watchman
Joined: 19 Feb 2003 Posts: 7313 Location: Groton, Massachusetts USA
|
Posted: Sun Aug 13, 2006 11:20 pm Post subject: |
|
|
wr0x2 wrote: | Again, are there any special options to select when configuring a kernel that I might have missed? |
How about the low level driver for your SCSI/SATA controller chipset ?
EDIT : Oops, neddy just mentioned that. |
|
Back to top |
|
|
cyrillic Watchman
Joined: 19 Feb 2003 Posts: 7313 Location: Groton, Massachusetts USA
|
Posted: Sun Aug 13, 2006 11:27 pm Post subject: |
|
|
NeddySeagoon wrote: | Not sure if you need Code: | RAID Transport Class | which is hidden at the top of SCSI, I have that. |
I don't have that, and MD RAID is still working for me.
I'm not sure what that option is for. The help text only says "Provides RAID" which is not very helpful. |
|
Back to top |
|
|
wr0x2 n00b
Joined: 04 Aug 2006 Posts: 19
|
Posted: Mon Aug 14, 2006 3:50 am Post subject: |
|
|
I have a silicon image 3112 chip, and this is not explicitly mentioned anywhere in the kernel config, but silicon image chipset support is, and I enabled it. I also have multidevice support enabled. All of these are built in, not modules. What else could have I left out? |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54300 Location: 56N 3W
|
Posted: Mon Aug 14, 2006 9:37 am Post subject: |
|
|
wr0x2,
I have a SATA 3112 too. Heres my kernel options, at least the ones needed for booting all must be built in.
Code: | Device Drivers
-> SCSI device support
-> RAID Transport Class (Cyrillic says its not needed)
-> SCSI device support
-> legacy /proc/scsi/ support
-> SCSI disk support
SCSI low-level drivers -> (menu)
-> Serial ATA (SATA) support
-> Silicon Image SATA support
-> Multi-device support (RAID and LVM)
-> RAID support
-> RAID-0 (striping) mode
-> RAID-1 (mirroring) mode |
... and under File systems ...
Choose your root filesystem
Code: | Partition Types
-> PC BIOS (MSDOS partition tables) support |
_________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
t00l n00b
Joined: 14 Aug 2006 Posts: 7 Location: Derbyshire, UK
|
Posted: Mon Aug 14, 2006 3:40 pm Post subject: |
|
|
Look up your model, I remember with my laptop I had the same problem because I had to enable very specific package for it to work. However, first I suggest playing about with Grub's boot options. |
|
Back to top |
|
|
wr0x2 n00b
Joined: 04 Aug 2006 Posts: 19
|
Posted: Mon Aug 14, 2006 5:36 pm Post subject: |
|
|
Thanks for the help, my system booted! It was the enabling of SATA support under SCSI low level drivers that did it... |
|
Back to top |
|
|
|