Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)
There are some similar threads on this already, but I haven't found a resolution
I have a system installed from the Gentoo 2008.0 live CD. It works fine. However, I downloaded (emerge) the newest source and compiled a new kernel and I am unable to boot using it. I can still boot using old kernel. If I try to boot via new kernel I get this error: Code:
VFS: Cannot open root device "sda3" or unknown-block(2,0) I have a single ATA drive in this system, but fstab generated by liveCD install looks like this: Code:
/dev/sda1 /boot ext2 defaults 1 2 Grub.conf looks like this: Code:
default 0 Code:
fsck.ext3: No such file of directory while trying to open /dev/sda3 -Mats |
Will try and help.
The first thing i would recommend checking is that you have ext3 support enabled in the new kernel.
|
You have forgotten to include path of initial ramdisk (initrd )image for newly compiled kernel in grub.conf
|
Thanks for the replies.
I just double checked my .config file and EXT2 and EXT3 are included (see code below). Next I'll try adding an initrd image. Code:
# File systems |
Creating initrd didn't help, but at least I get a new error. :-)
Code:
mount: error 6 mounting ext3 I created initrd file and changed grub.conf to read: Code:
default 0 thanks again for the help. |
Just an update on my (lack of progress). I added 'init=3' to the kernel line in grub.conf, but no dice. I also researched more about initrd and it seems like I shouldn't need it if I have the correct drivers compiled into the kernel. So I think I may be back to square one.
-Mats |
Just an update on my (lack of progress). I added 'init=3' to the kernel line in grub.conf, but no dice. I also researched more about initrd and it seems like I shouldn't need it if I have the correct drivers compiled into the kernel. So I think I may be back to square one.
-Mats |
Solved!
The new kernel wanted to mount /dev/hda3 as root rather than /dev/sda3. fstab as created by original install looked like this:
Code:
/dev/sda1 /boot ext2 defaults 1 2 Code:
/dev/hda1 /boot ext2 defaults 1 2 Code:
default 0 Also, thanks for the responses. While they didn't solve the issue directly, your responses led me down paths I hadn't thought of so I was eventually able to figure it out. Now that I understand the problem, it seems painfully obvious. Ironically, the original genkernel now fails to boot due to the change in fstab. :-) |
That's weird that your new kernel would want to mount to /dev/hda3 instead of /dev/sda3. hda is for IDE devices while sda is for SCSC/SATA devices. Have you done a file <kernel file> on both your old and new kernels and see what's the root_dev of them? I suspect they may be different. To the best of my knowledge, if your drive is a SATA drive, it should be sdX instead of hdX(unless you have AHCI disabled and IDE emulation enabled in your system BIOS).
|
I thought it was odd too and that was part of the reason why it took me so long to edit the fstab file. The drive is an ATA drive, but the controller can handle SATA drives as well and that was initially enabled on the motherboard. I toggled the setting off and on during trouble shooting, but it made no difference with the new kernel or original kernel. I'm still pretty new at this so it's totally possible that I've missed something.
|
title=linux 2.6.25-gentoo-r9 custom
root (hd0,0) kernel /kernel-2.6.25-gentoo-r9 root=/dev/hda3 I think you should change root (hd0,0) into (hd0,2) |
Quote:
-Mats |
Additional info re: Kernel panic - not syncing: VFS: Unable to mount root fs ...
I had roughly the same issue. Just installed Unbuntu 8.10 (my first Linux install) using WUBI on dual boot system with XP and 30GB SATA harddrive.
After initial install, I had a ton of updates (295, I think) to install. During install, I had some processes hang. On reboot, I got the kernel panic with unknown-block(0,0) for kernel 2.6.27-11-generic. After googling the issue, I finally used the previous kernel 2.6.27-7-generic to boot. Older kernel booted fine, and I went into Synaptic to continue updates. Synaptic told me to run "dpkg --configure -a" to clear up issues it had. I did so, and dpkg found and cleaned up the 2.6.27-11-generic kernel issue. Sorry, it was a couple days ago, so I don't remember the exact messages. Rebooted normally, and things have been fine since. I'm a Linux newby, so please ask if I've not provided all the information you need. I'm not posting for help, but to provide additional information for debugging and to let folks know what worked for me. |
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)
i got the same error while booting set top box... pls gve me a solution for this
Root-NFS: Server returned error -5 while mounting /home/...../target VFS: Unable to mount root fs via NFS, trying floppy. VFS: Cannot open root device "nfs" or unknown-block(2,0) Please append a correct "root=" boot option; here are the available partitions: Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0) |
Quote:
|
All times are GMT -5. The time now is 10:50 AM. |