[plug] a bit more initrd confusion :-(

Denis Brown dsbrown at cyllene.uwa.edu.au
Wed Apr 21 05:37:32 WST 2004



On Tue, 20 Apr 2004 raven at themaw.net wrote:

> On Tue, 20 Apr 2004, Denis Brown wrote:
>
> I don't understand the problemh here but ...
> >
> > a) I have a mostly-non-modular kernel 2.4.25 so if I do uname -r I get
> > 2.4.25    uname -r is used in the mkinitrd script to deteremine the
> > location of modules for the fresh kernel.
>
> Does it?
>
Hmmm.   About 95% of the way through mkinitrd there is a line to define
MODULEDIR which uses uname -r   but your later point about needing the
final (2.4.26 in my case) parameter is the what I needed thanks.

> >
> > b) My new kernel is 2.4.26 and this time the scsi driver will be modular
> >
>
> So you need an initrd image, right?
>
Yes, for the RAID utilities to allow me to get individual drive status.
Otherwise I would have been happier with a compiled-in driver :-(

> > c) If I therefore do mkinitrd -o /boot/initrd.img /dev/sda3    how does
> > the mkinitrd process determine that it is the 2.4.26 kernel I want
> > initrd'ed and not the current 2.4.25 kernel??????
>
> Maybe initrd has changed but I would use (blindly):
>
> mkinitrd initrd-2.4.26.img 2.4.26
>
Bingo.   I found something on a RedHat site that told me about that final
parameter.   To be extra cautious I equipped the command with some
explicit switches, namely -o to define the output image location and -r to
define the root mount point.   In addition to defining the root mount
point in the mkinitrd.conf file.   Belt and braces?   Oh well :-)

> assuming that EXTRAVERSION in the kernel Makefile is blank.
>
> If a previous initrd image exists you also need a -f option.
>
Hmmm.  I cannot see an -f option listed in Debian's man pages for
mkinitrd, nor any mention of it in the mkinitrd script.   It would seem
logical (-f stands for "force", right?)   Perhaps this is a RH specific
option or perhaps Debian's version of mkinitrd is a little behind the
game?

> Ian
>
Thanks for your comments, Ian.

Cheers,
Denis




More information about the plug mailing list