Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Linux - Kernel This forum is for all discussion relating to the Linux kernel.


  Search this Thread
Old 01-05-2007, 12:38 AM   #1
LQ Newbie
Registered: Oct 2003
Location: INDIA-PUNE
Posts: 7

Rep: Reputation: 0
customize initrd to boot it from network

Im trying to create a customized initrd image for
either recovery or installing OS on bare-metal

I want to customize initrd so that I can run my
application once vmlinuz loads initrd. (similar to dos
booting - dos runs autoexec.bat)

I followed following steps, but could not succeede:-

- downloaded & built linux 2.4 kernel source code.
- Built initrd using mkinitrd.

Now I want to customize initrd - so that i can modify
linuxrc script inside it to run my custom application
once initrd gets loaded.

To modify initrd - i tried mounting initrd image
at /mnt/initrd folder,
but received error

[root@rhel40-junk pt]# mount initrd /mnt/initrd -t
ext2 -o
mount: wrong fs type, bad option, bad superblock on
or too many mounted file systems
(could this be the IDE device where you in fact
ide-scsi so that sr0 or sda or so is needed?)

I also tried network booting machine with built
bzImage & initrd, but
receives error:

Kernel panic: VFS: Unable to mount root fs on 08:01

- Then I searched for ready to download initrd
recovery images on net:-

when i try to mount the initrd image downloaded from
It does not give me errors.

Please advice.

Old 01-05-2007, 12:43 AM   #2
Senior Member
Registered: Jan 2006
Location: Charleston, SC, USA
Distribution: Debian, Gentoo, Ubuntu, RHEL
Posts: 1,148
Blog Entries: 1

Rep: Reputation: 48
I think mkinitrd no longer creates a compressed ext2, I think it's a cpio archive now.
Old 01-05-2007, 12:44 AM   #3
Registered: Nov 2004
Location: Novi Sad, Serbia
Distribution: Debian, Slackware, Gentoo, openSuSE
Posts: 254

Rep: Reputation: 31
[root@rhel40-junk pt]# mount initrd /mnt/initrd -t ext2 -o loop=/dev/loop0
mount: wrong fs type, bad option, bad superblock on /dev/loop0
Check that initrd is not compressed (file initrd). I just tried, and this mounted my old 2.4 initrd:

mount /boot/initrd-2.4 /mnt/hd -o loop


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
network install & initrd help please! Mr_C Slackware 2 05-15-2007 03:42 AM
Boot without initrd 3saul Linux - Software 3 11-07-2005 11:13 PM
SCSI boot without initrd spencerbray Linux - General 1 01-15-2005 06:29 AM
SCSI boot without initrd spencerbray Linux - Newbie 1 01-15-2005 05:48 AM
needs initrd.img for network installation? linuxozone Fedora - Installation 0 06-21-2004 08:27 AM > Forums > Linux Forums > Linux - Software > Linux - Kernel

All times are GMT -5. The time now is 06:46 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration