LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 03-21-2004, 05:06 PM   #1
smehi
LQ Newbie
 
Registered: Nov 2003
Posts: 25

Rep: Reputation: 15
Grub w/ Gentoo 2.6.3 - Kernel Panic


So I installed Gentoo yesterday, using their guide from www.gentoo.org.
I followed the instructions, and everything seems to be setup fine. I did my own kernel compile (as opposed to using genkernel), which I have had no problems doing before (on slackware 9.1, 2.6.3).

I ensured the things the manual told me to enable, were in fact enabled.
Anyway, here's my problem =)

I setup grub.conf for dual booting (win2000/gentoo).
I can boot into windows fine, but when I try to boot into Gentoo, it loads the kernel, goes into Framebuffer mode, and stops when it tried to find the root (/) partition.

Here is the error:

VFS: Cannot open root device "hda4" or hda4
Please append a correct "root=" boot option
kernel panic: VFS: Unable to mount rootfs on hda4

Now, I'm used to lilo, and I guess I could still be considerd fairly newbie, but here is my partition table, and grub.conf. What's wrong?
(remember, /boot mounts fine so it isnt a HD or controller issue?)

-----------------------------------------------------------------------------------------------
Partition Table from CFDISK:

hda1 boot Primary NTFS 48241
hda2 Primary Linux ext2 65.81 (dont ask me why 65 heh)
hda5 Logical Linux Swap 1019
hda4 Primary Linux ext3 30721

-----------------------------------------------------------------------------------------------

Grub.conf

default 0

timeout 5

splashimage=(hd0,1)/grub/splash.xpm.gz


title=Gentoo Linux 2.6.3
root (hd0,1)
kernel /kernel-2.6.3-gentoo-r1 root=/dev/hda4 vga=791


title=Windows 2000
root (hd0,0)
chainloader +1

-----------------------------------------------------------------------------------------------


I have also tried
title=Gentoo Linux 2.6.3
root (hd0,1)
kernel /boot/kernel-2.6.3-gentoo-r1 root=/dev/hda4 vga=791

(and slight variatons)
and renaming the kernel.


I have DISALED initrd support in the kernel build.
I DO have a System.map-2.6.3-gentoo-r1, and a config-2.6.3-gentoo-r1 in /boot

When setting up grub I did:

grub> root (hd0,1)
grub> setup (hd0)
grub> quit

IDE support IS enabled, because grub can decompress the kernel, and access /boot/
/dev/hda4 IS there
When using TAB completion in Grub, I can see that it knows that /boot, is there as well as my root partition (I can see whats in /).

Is this a simple typo? Have I made a mistake in compiling the kernel?

PLEASE help, it's pretty annoying to get stuck on such a (seemingly) minor error.

Thanks,
Trevor
 
Old 03-21-2004, 06:40 PM   #2
ilikejam
Senior Member
 
Registered: Aug 2003
Location: Glasgow
Distribution: Fedora / Solaris
Posts: 3,109

Rep: Reputation: 96
Hi.

I'm not entirely sure how this works, but I couldn't boot my custom kernel (2.4.25) until I removed root=xxxx

My grub.conf looks like:
default=0
timeout=10
title GNU/Linux-2.4.25/ILikeJam
root (hd0,0)
kernel /bzImage hdc=ide-scsi hdd=ide-scsi

This worked with 2.6.2 as well.

I'd actually like to know how my kernel knows where / is, but I can't be bothered finding out at the moment.

Dave
 
Old 03-22-2004, 12:31 AM   #3
Demonbane
Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47
Do you see your harddrives getting detected by the kernel when the debugging messages scrolls by?


Quote:
Hi.

I'm not entirely sure how this works, but I couldn't boot my custom kernel (2.4.25) until I removed root=xxxx

My grub.conf looks like:
default=0
timeout=10
title GNU/Linux-2.4.25/ILikeJam
root (hd0,0)
kernel /bzImage hdc=ide-scsi hdd=ide-scsi

This worked with 2.6.2 as well.

I'd actually like to know how my kernel knows where / is, but I can't be bothered finding out at the moment.

Dave
The kernel actually has a built-in mechanism for detecting the root device, and it's utilized when root= parameter isn't passed to the kernel. You can modify it using the rdev command, eg. "rdev <kernel image> <root device>"
I would say its automatically set to your current root device when you compile the kernel.

Last edited by Demonbane; 03-22-2004 at 12:32 AM.
 
Old 03-22-2004, 12:39 AM   #4
ilikejam
Senior Member
 
Registered: Aug 2003
Location: Glasgow
Distribution: Fedora / Solaris
Posts: 3,109

Rep: Reputation: 96
Cool.

Cheers Demonbane. That's been irritating me slightly for ages.

Dave
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Gentoo Kernel panic - not syncing... patrickclay Linux - Distributions 2 03-10-2005 02:53 PM
Kernel Panic in Gentoo palmem Linux - General 1 11-06-2004 02:16 PM
Grub w/ Gentoo 2.6.3 - Kernel Panic - typo? smehi Linux - General 1 03-29-2004 02:24 AM
Gentoo install trouble - Kernel Panic ! hornokplease Linux - Newbie 2 09-02-2003 06:50 PM
LVM on root: Kernel Panic: Gentoo Sutekh Linux - General 2 08-17-2003 09:22 PM


All times are GMT -5. The time now is 12:45 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration