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

Re: building an initrd

On Fri, 08 Aug 2003 09:50:09 +0200, Benedict Verheyen wrote:

> Hi,
> some time ago i built my first kernel with initrd support. Now all i
> know from initrd is that it is first loaded by the kernel in memory and
> that i have to specify --initrd with the make-kpkg command.
> Can you specify what goes in initrd? For instance if i want to add a
> module and have that loaded before the file system is mounted? For
> instance LVM support.
An initrd contains a file called linuxrc. It's the first program the
kernel executes. Normally it's a shell script which insmods some
modules.(don't forget to include a shell). Then you need insmod and some
modules necessary to boot (disk drivers, fs drivers ...). Further
information can be found in initrd(4).

Debian has the command mkinitrd which does all this.
> Also, in case you would need to load several modules, isn't there a
> danger the initrd image would become to big?

AFAIK this isn't a problem to load some modules. An initrd is normally
> Is it possible to make boot floppies from a kernel and it's accompanying
> initrd?
In some cases you don't get both the kernel and the initrd on one floppy.
> I know in the case of LVM that it has it's own command to make an initrd
> but i would like some info on how to create my own or at least really
> understand what it does :)
> Any links or info appreciated
> Benedict

Reply to: