Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] grub, /boot, and kernel panic
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
Zaventh
n00b
n00b


Joined: 30 Jan 2006
Posts: 16

PostPosted: Mon Jan 30, 2006 9:56 pm    Post subject: [SOLVED] grub, /boot, and kernel panic Reply with quote

Okay... I searched around and looked in many grub threads but couldn't find a solution to my exact problem so here goes....

FSTAB:
/dev/hdf1 /boot
/dev/hdf3 /
/dev/hdf2 none (swap)

kernel is "vmlinuz" under /boot

/boot/grub/menu.lst:
root (hd1,0)
kernel /boot/vmlinuz root=/dev/hdf3


This this setup, I get Error 15: File not found


Okay, so I tried removing the "/boot" part so

kernel /vmlinuz root=/dev/hdf3

This starts booting the kernel until it reaches:

VFS Cannot open root device "/dev/hdf3" 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)

The drive is IDE.

I have tried many permutations of configurations in menu.list but never get any farther than this...


Last edited by Zaventh on Wed Feb 01, 2006 4:45 pm; edited 1 time in total
Back to top
View user's profile Send private message
SinoTech
Advocate
Advocate


Joined: 20 Mar 2004
Posts: 2579
Location: Neunkirchen / Saarland / Germany

PostPosted: Mon Jan 30, 2006 10:50 pm    Post subject: Reply with quote

Did you have the filesystems driver compiled inside your kernel (NOT as module)? As far as I know you can have up to 4 drives using the onboard IDE connectors on the board. Did you have an additional controler to have your partition on hdF? If so, do you need an additional driver? If yes, is it installed?
The error message you get indicates that whether the filesystem is not recognized (e.g. if it is compiled as module and not inside the kernel) or the device doesn't exist.
Regards,

Sino
Back to top
View user's profile Send private message
Zaventh
n00b
n00b


Joined: 30 Jan 2006
Posts: 16

PostPosted: Tue Jan 31, 2006 2:14 am    Post subject: Reply with quote

Hey, thanks for the reply. Well I got it to work will a kernel I genmaked but I still had to drop the "/boot.." prefix on the grub config lines. Why is that? It's strange because I went back and double checked my kernel and everything I needed was there... My drive is on a hardware IDE RAID array which is controlled by my motherboard. No extra drivers needed as everything is taken care of in the RAID BIOS. I'm not too concerned about it at this point I guess but I am still interested in knowing.
Back to top
View user's profile Send private message
dpick
n00b
n00b


Joined: 27 Jan 2006
Posts: 25

PostPosted: Tue Jan 31, 2006 3:40 am    Post subject: Reply with quote

Hi Zaventh, I'm having the same error you were with VFS: cannot find root device. I was wondering if you could post your grub.conf and anything you may have needed to change to get it working. Thanks.
Back to top
View user's profile Send private message
Zaventh
n00b
n00b


Joined: 30 Jan 2006
Posts: 16

PostPosted: Tue Jan 31, 2006 1:34 pm    Post subject: Reply with quote

I first tried to compile my own kernel as per the Handbook default proceedure but I recieved the aforementioned problem. I ended up emerging the "genmake" tool and genmaking a kernel that way as per the Handbook. I then tried the grub.conf as outlined in the Handbook but it didn't work for. I had to drop the "/boot" prefix such as:

Code:
root (hd1,0)
kernel /kernel-genkernel-x86-2.6.15-gentoo-r1 root=/dev/ram0 init=/linuxrc ramdisk=8192 real_root=/dev/hdf3 udev
initrd /initramfs-genkernel-x86-2.6.15-gentoo-r1


All my other files (fstab, etc) are unchanged and listed in my first post.

So it seems the problem is indeed something missing in the kernel or not included properly. I think I've read somewhere you can "genmake menuconfig" the genkernel and customize it further so after I finish compiling KDE I am going to try that.
Back to top
View user's profile Send private message
Sainted_Trousers
n00b
n00b


Joined: 27 Nov 2005
Posts: 42

PostPosted: Tue Jan 31, 2006 7:07 pm    Post subject: Reply with quote

Zaventh wrote:
I still had to drop the "/boot.." prefix on the grub config lines. Why is that?

You have a separate partition on which your boot files reside. That partition, all by itself, does not have a subdirectory called /boot, so you
don't want to tell grub that it does. It's not until after the boot partition is mounted (after the kernel has been loaded and grub is gone from
memory) that your boot files appear under the /boot subdirectory.

Quote:
My drive is on a hardware IDE RAID array which is controlled by my motherboard. No extra drivers needed as everything is taken
care of in the RAID BIOS.

To be correct, there is hardware (a chip) and software (used by the BIOS) on your motherboard that can control the RAID. The linux kernel
does not use the BIOS, so the onboard RAID controller software is not used. You have to compile into the kernel the code appropriate for the
RAID chip that's on your motherboard so the kernel knows how to control hard drives attached to that chip.

One of Linux's shortcomings (?) is difficulty working with RAID hardware/software. You need special RAID hw/sw to work with Windows
because it has to be transparent to that OS. That is, it knows that there is RAID hw/sw on the system, but it relies on the BIOS + hardware
to take care of the details. For the Linux kernel, you have to compile RAID support into it - that's the downside. The upside is, you don't need
special RAID hw/sw on the motherboard at extra co$t - it works with standard IDE controllers.
Back to top
View user's profile Send private message
XenoTerraCide
Veteran
Veteran


Joined: 18 Jan 2004
Posts: 1418
Location: MI, USA

PostPosted: Wed Feb 01, 2006 4:13 am    Post subject: Reply with quote

4. Grub Error 15

Situation

This error can occur in two different stages of the GRUB configuration, either during the initial configuration (installing GRUB in the master boot record) or after booting the system and attempting to launch Linux (or any other entry).

Code Listing 4.1: Grub Output - Initial Configuration

grub> root (hd0,0)
Filesystem type is xfs, partition type 0x83

grub> setup (hd0)
Checking if "/boot/grub/stage1" exists... no
Checking if "/grub/stage1" exists... no

Error 15: File not found

Code Listing 4.2: Grub Output - Booting an Entry

Booting 'gentoo Linux'

root (hd0,0)
Filesystem type is ext2fs, partition type 0x83
kernel (hd0,0)/boot/kernel-2.4.20 root=/dev/hda3 vga=792

Error 15: File not found
Press any key to continue...

Solution - Initial Configuration

This error is returned if the specified file name cannot be found, but everything else (like the disk/partition info) is OK.

Frequently, the error notes a missing kernel image file. Make sure that the file it is referring to exists on your boot partition.

To find out the exact name of your kernel, boot from the installation cd, mount your root and (if applicable) boot partition. Next, chroot into your Gentoo system and do a listing of the available files to see what kernel images you have available:

Code Listing 4.3: Verifying kernel image existence

# cd /boot
# ls

This will list all the kernels that you've got on your boot partition. If your kernel is missing make sure that you compiled a kernel (using genkernel or manually):

Code Listing 4.4: Recompile the kernel

# cd /usr/src/linux/
# make menuconfig
# make

And that you copied it to your boot partition:

Code Listing 4.5: Copying the kernel

# cp /usr/src/linux/arch/i386/boot/bzImage /boot

Verify that the name of the kernel is exactly the same as the one mentioned in your grub.conf file. Also make sure that the kernel line in your grub.conf file is referring to that partition (either explicitly or implicitly).

Another reported mistake is to have the BIOS ignore the disk on which the kernel or grub stages reside. Also, the partition on which grub stores its stages should not use a software RAID-5 (or other striping technology) configuration.

Solution - Booting an Entry

First, verify that the root and setup lines you have used are correct.

If you are certain they are valid, then you might be using a flawed GRUB version (0.93.20031222). Upgrade your Portage tree or mask this version of grub:

Code Listing 4.6: Masking Grub

(Execute this from within the chrooted environment)
# echo "=sys-boot/grub-0.93.20031222" >> /etc/portage/package.mask
# emerge grub -p

You could also try to use the grub-install script as is recommended by the GRUB authors:

Code Listing 4.7: Using grub-install

(The --root-directory is needed if you are using a separate boot
partition,
otherwise you should leave it out)
# grub-install --root-directory=/boot /dev/hda

When all this fails, your boot partition may be corrupt. Check the partition for errors:

Code Listing 4.8: Checking a partition for errors

(Make sure the boot partition, /dev/hda1 in this case, is unmounted)
# fsck -y /dev/hda1
_________________
I don't hang out here anymore, try asking on http://unix.stackexchange.com/ if you want my help.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum