LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 01-26-2011, 02:03 PM   #1
robertjinx
Member
 
Registered: Oct 2007
Location: Prague, CZ
Distribution: RedHat / CentOS / Ubuntu / SUSE / Debian
Posts: 749

Rep: Reputation: 73
How to create a initrd image without using mkfs, but cpio


Hello, does anyone know how to create an initrd image using cpio, instead of mkfs?

Now im doing it like this:

Code:
dd if=/dev/zero of=initrd bs=1024 count=10000
mkfs -t ext2 -F -m 0 -b 1024 -i 1024 initrd
But i would like to move to cpio, because with dd, if you add something new, you might need to change the count. Also cpio is used in distro's like Fedora and Ubuntu.

So, if anyone know please give me a small how-to.

Thanks in advance!
 
Old 01-26-2011, 06:43 PM   #2
Blue_Ice
Member
 
Registered: Jul 2006
Location: Belgium
Distribution: Debian, Fedora, CentOS, Windows
Posts: 361

Rep: Reputation: Disabled
Run the following command in the directory where you have the files for your initrd:
Code:
find ./ | cpio -H newc -o > /your/location/initrd
 
Old 01-27-2011, 03:41 AM   #3
robertjinx
Member
 
Registered: Oct 2007
Location: Prague, CZ
Distribution: RedHat / CentOS / Ubuntu / SUSE / Debian
Posts: 749

Original Poster
Rep: Reputation: 73
Thanks, that works.
 
  


Reply


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
How to create new initrd image in sles10.2? venkatesh710 Linux - General 1 08-13-2010 03:38 AM
create bootable floppy image with only kernel and initrd ta0kira Slackware 1 04-02-2009 10:26 PM
Trying to create PXE server and can't mount initrd image Nylex Slackware 6 07-08-2007 02:10 PM
Trouble using initrd : no cpio magic Linux.tar.gz Slackware 10 04-17-2007 09:43 AM
why bootsplash can't work with cpio-typed initrd kyven zhang Linux - Software 0 01-13-2005 08:47 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 11:09 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