General
cancel
Showing results for 
Search instead for 
Did you mean: 

Unable to mount root device 806

Todd Kennedy
Frequent Advisor

Unable to mount root device 806

Hello all, I am trying to compile and boot kernel version 2.4.18 on a Dell 2450 so I can use the Linux Virtual Server. The Dell 2450 has a build in hardware RAID controller. The two modules that I am loading for scsi support are aic7xxx and aacraid. I can compile the kernel just fine and I can create the initrd with no problems. It's when I reboot the server that the problems start happening.

When booting it's kind of hard to tell what's going on because the information is flying by on the screen. So what I can see when the kernel panics and halts is that it can't mount the root device 806, which is the scsi sda6 device. That's where the root filesystem is located.

what I've tried so far:
I've tried statically compiling in the scsi modules. That did not work. I tried renaming the scsi modules so that the aic7xxx driver loads before the aacraid driver. That did not work. (I am running out of options here). I also had both scsi drivers load as modules and that did not work.

Do I need to check the initrd and ensure that it has all the proper info for drivers and devices? How do I do this.

I've tried mounting it but I get an error that states, please specify a FileSystem Type. That's probably because I am doing mount -0 loop /boot/initrd-2.4.18.img /mnt/test

Does anyone have any ideas. I have been working on this for a few days and I can't seem to figure it out. Other (distro kernels work just fine, i.e. 2.4.2-2smp, 2.4.9-34smp.)

I think I am missing a step here but what step is the question?
16 REPLIES
I_M
Honored Contributor

Re: Unable to mount root device 806

Hi

# mkdir /mnt1
# cp /boot/yourinitrd.img /tmp
# cd /tmp
# mv yourinitrd.img yourinitrd.gz
# gzip -d yourinitrd.gz
# mount -o loop yourinitrd /mnt1
# cd /mnt1/lib
# ls

What you can find?

Good luck

K.C. Chan
Trusted Contributor

Re: Unable to mount root device 806

do what iida suggested, and check if your scsi modules is loaded in the initrd. If not you will have to copy it and mv your initrd back to /boot, then do lilo -v and re-boot
Reputation of a thousand years can be determined by the conduct of an hour
Todd Kennedy
Frequent Advisor

Re: Unable to mount root device 806

So far what I have found out is that scsi_mod and sd_mod where missing from the config as modules and thus didn't get loaded. Since then I have fixed that and am now working on determining why I get the error:

request_module[block-major-8]: Root fs not mounted

I also found out that I didn't have initrd in the kernel config.

I read a posting somewhere from someone with a similar problem.
---------posting-----------
> Kernel panic:VFS:Unable to mount root fs on 08:03
>
----Here is the reply-----
It seems you have compiled the driver for your root fs as a module and not
into the kernel.
--------------------------

Where in the kernel config do you specify rootfs as module or static. Is this the initrd option?

K.C. Chan
Trusted Contributor

Re: Unable to mount root device 806

I had similar problem, have a look a this link: http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0xdd647d4cf554d611abdb0090277a778c,00.html

after mounting your initrd make sure that dir lib contains the necessary modules for boot up and that linuxrc script actually calls the modules. here's an example from my linuxrc script in initrd:
echo "Loading sym53c8xx module"
insmod /lib/sym53c8xx.o
echo "Loading aic7xxx module"
insmod /lib/aic7xxx.o
echo "Loading jbd module"
insmod /lib/jbd.o
echo "Loading ext3 module"
insmod /lib/ext3.o

I hope this helps.
Reputation of a thousand years can be determined by the conduct of an hour
Todd Kennedy
Frequent Advisor

Re: Unable to mount root device 806

I have checked lib directory in initrd and it has the scsi mods in there. Should it also have the filesystem ones as well?

Also, in /etc/fstab the root device is defined as:

LABEL=/ ext2 defaults 1 1

Is LABEL passed from LILO? what is tell the kernel that the root device is 806 or /dev/sda6?
K.C. Chan
Trusted Contributor

Re: Unable to mount root device 806

Yes, if you're planning to use ext3. You also need to make sure that jbd.o is also in there bec. ext3 is dependent on it. You will also have to make sure that linuxrc file (in initrd offcourse) explicitly loads all modules in lib.

As for your inquery, your fstab files looks fine (assuming you are currently using ext2). I think the reason your err comes up during boot is that not all neccessary modules were loaded during boot up, so the kernel pukes when trying to mount root and kack "can't mount root fs 8:06 ... ". I hope this helps.
Reputation of a thousand years can be determined by the conduct of an hour
Todd Kennedy
Frequent Advisor

Re: Unable to mount root device 806

I agree, but how do I determine what module is not getting loaded? It's a catch 22.
K.C. Chan
Trusted Contributor

Re: Unable to mount root device 806

You should be seing what modules is being loaded during boot up, for example here's what's in linuxrc from initrd file:
echo "Loading sym53c8xx module"
insmod /lib/sym53c8xx.o
you should be seing "Loading sym... module" during boot up. Is there anything in your linuxrc file when you mount your initrd file?
Reputation of a thousand years can be determined by the conduct of an hour
Todd Kennedy
Frequent Advisor

Re: Unable to mount root device 806

ah ha!

I now see the loading of modules and it successfully detects the scsi raid controller and the array. But now I get a new error.

Creating Root Device
mkrootdev: mknod failed 17
Mounting Root Filesystem
mount: error 16 mounting ext2
pivotroot fails with error 2

It's last breath before death is:

Kernel Panic no init found. Try passing init= to kernel.

Well at least I have made some progress.
K.C. Chan
Trusted Contributor

Re: Unable to mount root device 806

Did you run "lilo -v" before rebooting?
Reputation of a thousand years can be determined by the conduct of an hour
K.C. Chan
Trusted Contributor

Re: Unable to mount root device 806

When you compiled this kernel did you also include support for ext2 filesystem?
Reputation of a thousand years can be determined by the conduct of an hour
Todd Kennedy
Frequent Advisor

Re: Unable to mount root device 806

Yes I did run lilo -v before rebooting and ext2 is compiled in staticlly.

Why would the mkrootdev fail? That's the real question here.
Todd Kennedy
Frequent Advisor

Re: Unable to mount root device 806

Ok I am past the point of mounting root. That part is working but it is getting mounted as read-only. So everything after that is failing. Does anyone know why this is?
K.C. Chan
Trusted Contributor

Re: Unable to mount root device 806

ok, that's great. What was causing the problem when your system tried to mount root fs during boot-up?

Lastly, what kind of error are you getting after mounting root? Are you getting [Fail] on ALL of your services as you startup?
Reputation of a thousand years can be determined by the conduct of an hour
Todd Kennedy
Frequent Advisor

Re: Unable to mount root device 806

The reason root wasn't able to mount was that I had devfs as auto starting at boot. I read an article online that said it mounts root and casues mknod to fail because root is already mounted. So by changing the config to not mount devfs at boot I got past that error.

The new error now is that root has been mounted as read-only. So all startup processses are failing because they can't write to disk. I thought the pivot_root is suppose to change root from read-only to read-write. What would cause this to not change?
Todd Kennedy
Frequent Advisor

Re: Unable to mount root device 806

Ok, I was able to boot into the new kernel with minimal problems. I think the devfs was causing some conflicts. So I disabled it and wala. It worked!! Funny how that (EXPERIMENTAL) label makes some things not work right..

So the only problem I have now is I didn't enable support for Extended real time clock module. So I have to recompile.

I think I've got it from here. Thanks for all your help!!!