LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   First-time kernel compile woes... (https://www.linuxquestions.org/questions/slackware-14/first-time-kernel-compile-woes-132832/)

redkazan 01-08-2004 04:18 PM

First-time kernel compile woes...
 
Hey All:

I woke up this morning feeling brash, so I decided to try to compile a 2.6.0 kernel for my new Slackware laptop. You've gotta learn sometime, right? So after a bit of researching, I went through all of the motions, rebooted, and now I'm faced with:

VFS: Cannot open root device "305" or hda5
Please append a correct "root=" boot option
Kernel panic: VFS: Unable to mount root fs

I had absolutely no error messages at any other point in the process of compiling the new kernel.

I'm ashamed to say that I didn't read the guide that is up on these forums first. I didn't even think to check here (I just googled stuff like 'compiling a new kernel' etc.).

Can anybody help me troubleshoot this?

Thanks,

rk

Edit: to clarify, my linux partition *is* located on hda5.

ac1980 01-08-2004 04:39 PM

Looks like you need some modules to access the partition (fs supported as a module?) but you didn't include them in your initrd image...
Actually I never needed initrd, I've always statically included drivers for /, so I can't help you much...
Can you boot back in your 2.4 kernel (should be vmlinuz.old) to fix things or if needed recompile? With grub you'll have no problems, just go to command prompt ("c") and type
Quote:

root (hd0,4)
kernel /vmlinuz.old (should auto-complete the filename pressing tab)
boot
With lilo you may have to use a rescue floppy/cd, unless you prepared linux.old entry before.

redkazan 01-08-2004 04:42 PM

Hmm
 
ac1980:

Yep, I can boot back into 2.4.22 (I just added a lilo entry for the new kernel). Any idea as to what exactly is causing my problem? You alluded to initrd, but I'm completely lost, so you'll have to start from square 1. :)

rk

ac1980 01-08-2004 05:04 PM

Well, that's a sort of hen&egg problem: you may need kernel modules to access some filesystems, but the modules are on these filesystems...
There are 2 ways to get out of this:
1. (recommended) statically build into your kernel support for the filesystem you need (ext3? raisefs?)
2. make lilo "blindly" load into memory a chunk of data which actually is a disk image containing required modules
I never did the latter, you can find more info in the kernel-compile-howto

PS: I'm going to sleep now, I'll check for news tomorrow CET

redkazan 01-08-2004 05:20 PM

Hmm
 
ac:

I'm almost positive that I compiled in support for ext3. I can verify tomorrow by checking the .config file in my 2.6.0 src directory, right? I'll post the results tomorrow afternoon (I'm going out tonight -- EST here). So you're assuming I accidentally compiled ext3 support as a module, and the module can't be loaded, because the filesystem can't be loaded. Crap.

Any other takers on this one? With perhaps a more optimistic evaluation of the problem? :)



rk

EDIT: I checked my .config file. It turns out that I did build EXT3 and EXT2 support into the kernel (I think). Here are the relevant lines:

CONFIG_EXT3_FS=y
CONFIG_EXT3_FS_XATTR=y
CONFIG_EXT2_FS=y

So what the devil is the problem?

e1000 01-08-2004 05:53 PM

what kind of hard drive do you have? im not to sure about this judging by the error but it could be possable that you copiled the hard drive driver as a module.

It took me 5 compiles to finally get it down to a fully functional kernel, and two compiles to get a bootable kernel. a good idea for a starter is to use the default config file from slackware and just taylor it to your needs, it works better when going between 2.4 versions, but I sucessfully made a 2.6 kernel with my default slackware config file (after heavy modification, and I didnt use it cause I have a 2.4 winmodem driver)

lastly, if you dont know all your system specs, search around and try to find all your chipsets for all your hardware if you can.

redkazan 01-09-2004 01:13 PM

Toshiba
 
I have a Toshiba 60 gig IDE drive. I'm unsure what you mean when you say 'hard drive drivers'. The normal Slack kernel works fine (2.4).

I'm going to repost this problem in the general forum (which gets more traffic). Hopefully someone will have a solution.

rk


All times are GMT -5. The time now is 10:23 AM.