You may have occasion to edit the contents of an initrd.img file. If so, here is how:
Extract the contents of the image
gunzip < your-initrd.img | cpio -i --make-directories
Now make your edits and then repackage the initrd
find . | cpio -o -H newc | gzip -9 > your-new-initrd.img
Something that just about no one out there seems to be doing (yet) is trying to install Debian directly onto network block devices. The Debian installer doesnt support it (yet), grub doesnt support it (usually), and its just generally not an easy thing to do.
Now, there are quite a few ways around this problem. You can install to a ‘real’ computer and migrate the installation to a network block device. You can use debootstrap in place of the actual Debian installation system. You can use a combination of these two methods, NFS root filesystems, TFTP hacks, etc. All of these solutions are lacking in my opinion. I want to run the ‘real’ debian installer against a network block device and boot my physical hardware using only the built in PXE booting capability of the BIOS.
Taking all these issues as a personal challenge, I’ve outlined below how to go about using the regular old Debian Lenny installer directly against an AoE block device.
Continue reading install debian directly onto an AoE root filesystem