Re: [LIP] Could not boot from 2.4.8 kernel

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




initrd stands for initial ram disk. Its absence may prevent your system from 
booting --- especially if important pieces of your kernel config (e.g. scsi 
driver) are built as modules. It's a chicken and egg thing really. In order 
to load a module (which normally reside under /lib/modules) the system must 
boot far enough to be able to mount your disk so the *.o module file can be 
located. If the module in question is required for mounting the disk in the 
first place; however, the module's object file can't very well be loaded from 
disk.

Linux gets around this by providing for the creation of a separate compressed 
filesystem that can be loaded and uncompressed into RAM early on in the boot 
process. This is the initrd-2.4.xxx-img file found in /boot and referenced in 
lilo.conf. You can examine its contents by uncompressing and mounting on the 
loopback device:

cd /tmp
gzip -c /boot/initrd-2.4.x.img /tmp/initrd-2.4.x.img
mkdir mpt
mount -o loop -t ext2 initrd-2.4.x.img mpt

Following this example, modules files would then be located in /tmp/mpt/lib.

See man mkinitrd for full details, but briefly to make an initrd for your new 
kernel all you have to do is:

mkinitrd /boot/initrd-2.4.x.img 2.4.x

*after* you make bzImage; make modules; make modules_install. The second 
argument to the command must correspond to a directory tree under 
/lib/modules.

I doubt the absence of an initrd is the cause of your problems, however, 
since usually the boot process proceeds further and the error is something 
like "Failed to mount root filesystem" if initrd is the cause.

Did you run lilo after building your new kernel? Also 2.4.8 is pretty old 
now, why not try 2.4.17? The steps I follow to install a new kernel are 
(assuming an upgrade from 2.4.16 to 2.4.17)

cp linux-2.4.17.tar.bz2 /usr/src
rm linux              # this is the old symbolic link
tar xvjf linux-2.4.17.tar.bz2
mv linux linux-2.4.17
ln -s linux-2.4.17 linux
cd linux
cp ../linux-2.4.16/.config . # this step sets all the config flags that were  
                            # in effect for the working 2.4.16 kernel
make oldconfig              # this step confirms previous config and prompts  
                            # for new options
make -j 2 bzImage
make -j 2 modules
make modules_install
cp arch/i386/boot/bzImage /boot/vmlinuz-2.4.17
cp System.map /boot/System.map-2.4.17
mkinitd /boot/initrd-2.4.17.img 2.4.17

Then I edit lilo.conf to add an entry for the new kernel --- being careful to 
leave the old kernel's entry in case something goes wrong. The final step is 
running lilo:

/sbin/lilo 

Without this last step I believe booting will stall at the "uncompressing 
linux kernel ..." stage.

HTH,
Marvin Justice



On Thursday 03 January 2002 03:34 am, Vanitha wrote:
> Hi
>
> Check for the correct processor family you have selected during the
> menuconfig selection
>
> What is initrd used for at boot time?
> initrd provides the capability to load a RAM disk by the boot loader
>
> Regards
> Vanitha
>
> ----- Original Message -----
> From: "SATHISH.J" <sathish.j@tatainfotech.com>
> To: "kernelnewbies" <kernelnewbies@nl.linux.org>
> Cc: "linux india programming"
> <linux-india-programmers@lists.sourceforge.net>
> Sent: Thursday, January 03, 2002 4:21 AM
> Subject: [LIP] Could not boot from 2.4.8 kernel
>
> > Hi,
> > I downloaded 2.4.8 kernel from "www.kernel.org" and did the regular
> > kernel make to get the bzImage. Then I tried to boot from the same  by
> > altering the lilo.conf. The booting stops with the message "uncompressing
> > linux kernel". I did not add initrd path for this new kernel in
> > lilo.conf. Is it because of that? What is initrd used for at boot time?
> >
> > Thanks in advance,
> >
> > Warm regards,
> > Sathish.J
> > Systems Engineer
> > Tata Infotech Limited
> > 80 Feet Road
> > Indra Nagar
> > Bangalore-560 038.
> >
> >
> > _______________________________________________
> > linux-india-programmers mailing list
> > linux-india-programmers@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/linux-india-programmers
>
> _________________________________________________________
> Do You Yahoo!?
> Get your free @yahoo.com address at http://mail.yahoo.com
--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
IRC Channel:   irc.openprojects.net / #kernelnewbies
Web Page:      http://www.kernelnewbies.org/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux