Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
I'm trying to build the 2.4.27 kernel, with the PaX patch applied. Everything compiles and installs fine, but when I try to boot off of it, it gives me an error with modprobe, and tells me it can't mount (or find? sorry; I'm not by the machine right now) the root fs. This is, of course, a kernel panic error.
Now, I've tried reconfiguring and recompiling several times. I don't have devfs enabled, and I've mirrored all the lines in modules.dep that I believe are related to the hard drive I use (a SCSI HDD). And, GRUB is indeed pointing at all the same things that the working kernel's entry does, only with the new initrd and kernel.
I'm new to compiling Linux kernels, so I'm hoping there's just some oversight I'm not realizing. Does anyone have any hints?
I know I included SCSI support as a module, since that's what the old modules.dep shows, and I'm pretty confident that I have all the disk drivers that I need. I built the initrd with just "mkinitrd /boot/initrd-whatever.img 2.4.27-pax" -- is there anything special I need to do? I know when I was first starting out, mkinitrd failed because it didn't find the disk driver that it needed. I'm puzzled!
Here are the last few lines of what is displayed at boot:
ds: no socket drivers loaded!
kmod: failed to exec /sbin/modprobe -s -k block-major-8, errno = 2
VFS: Cannot open root device "sda2" or 08:02
Please append a correct "root=" boot option
Kernel panic: VFS: Unable to mount root fs on 08:02
Now, the entry in GRUB is identical to my working entry, save for the edits I made to point at the new initrd and kernel bzImage. So, the "root=" option should be fine.
I compiled SCSI support as a module, since that is how it appears to have been done for the working kernel. Some IDE initialization was done before those last lines, and they all seemed to go fine (e.g. the information for the CD-ROM drive was printed) Does the fix seem obvious to anyone?
I think I have found the solution to this problem. For future reference, I'll outline it below:
Browsing for clues on Google whilst reading the help messages for various kernel configuration options, I noticed an interesting imperative in the help for minix file system support: it said that you must compile support for your root file system into the kernel itself; it cannot be a module. So, I compiled ext3 support into the kernel rather than leaving it a module, and, after rebuilding the kernel, it booted!
I haven't tried this fix on the original computer (this problem replicated on another machine), but I suspect it will work. I think it's valuable to have this solution archived, as I did not find it on the net.
It feels very good to have overcome this obstacle under my own steam. It bugged the heck out of me that I had to use the default RedHat configs to build my new kernel. I want to know why something is; not just have a fix for it. So, I'm very happy now.