LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora
User Name
Password
Fedora This forum is for the discussion of the Fedora Project.

Notices


Reply
  Search this Thread
Old 04-23-2006, 06:14 AM   #1
metagroboliser
LQ Newbie
 
Registered: Apr 2006
Posts: 6

Rep: Reputation: 0
trouble loopback mounting initrd.img -pls help


I'm unable to loopback mount the FC5 ramdisk image (initrd-2.6.16-1.2080_FC5.img) ... mount doesn't appear to recognise the filesystem type. I'm doing the following:
Code:
> cp /boot/initrd-2.6.16-1.2080_FC5.img /tmp/initrd.img.gz
> gunzip /tmp/initrd.img.gz  # creates /tmp/initrd.img
> mount -o loop /tmp/initrd.img /mnt
mount complains about the filesystem type. Speciying -t ext2/3/vfat/msdos yields the same complaint ... filesystem not recognised.

Whats the fstype for the ramdisk image? Is there something obvious I'm missing.

cheers.
 
Old 04-23-2006, 07:19 AM   #2
ilikejam
Senior Member
 
Registered: Aug 2003
Location: Glasgow
Distribution: Fedora / Solaris
Posts: 3,109

Rep: Reputation: 97
Hi.

initrd images are actually cpio archives.

Try
Code:
cpio -i -I /tmp/initrd.img
Dave
 
Old 04-23-2006, 07:20 AM   #3
homey
Senior Member
 
Registered: Oct 2003
Posts: 3,057

Rep: Reputation: 61
Quote:
Is there something obvious I'm missing.
It's not obvious and I had to google for abit before finding out to use cpio.
Here are my notes where I have the initrd.img in /home/isolinux
Code:
EXTRACT and EDIT INITRD.IMG (The Linux Filesystem)

# unpack the current initrd.img
mkdir /home/cdimgextract
cd /home/cdimgextract
gzip -dc < /home/isolinux/initrd.img | cpio -i
cd /home
# make any changes you need to the initrd.img in cdimgextract


REMAKE MODIFIED INITRD.IMG

cd /home/cdimgextract
# create the new initrd
rm -f /home/isolinux/initrd.img
find . | cpio -o -c | gzip -9 > /home/isolinux/initrd.img
# cleanup
cd /home
rm -rf cdimgextract
 
Old 04-23-2006, 07:15 PM   #4
metagroboliser
LQ Newbie
 
Registered: Apr 2006
Posts: 6

Original Poster
Rep: Reputation: 0
got it ... muchthanx.
 
  


Reply



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
Mounting boot/initrd.img Law1213 Linux - Software 10 01-25-2005 02:37 PM
Initrd.img spaguzz Slackware 4 12-16-2004 03:35 AM
Initrd.img spaguzz Linux - Software 1 12-09-2004 03:21 PM
What's an initrd.img? hotel-lima Linux - Newbie 2 06-11-2004 05:50 PM
initrd.img php_rocks Linux - Newbie 1 08-31-2003 11:20 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora

All times are GMT -5. The time now is 12:22 PM.

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