On Thu, Apr 02, 2015 at 02:29:28PM +0200, maximilian attems wrote: > On Wed, Apr 01, 2015 at 06:10:05PM -0700, Marc MERLIN wrote: > > Could I make a few suggestions while we're at it? > > 1) I sometimes build an initrd for a kernel I haven't installed yet. Yes, > > it's a mistake, but it happily succeeds and creates an initrd without any > > modules which then creates a non booting system. > > => initramfs should abort if its generated /lib/modules/kernel is empty > > I thought this was caught. I have multiple initrd images that show otherwise, including this bug :)
> > 2) initramfs creates a temporary directory where it puts everything, and > > then deletes it before you can inspect it for debugging. > > => Add a --debug that leaves that directory behind for inspection. > > Right now I have to unpack the initrd image which is more and more of a > > pain as it becomes a bundled binary of concatenated cpio images and god > > knows what. > > -k :P > as usual read the nice man mkinitramfs (; Argh. I need new eyes... Sorry. > > 3) document the binwalk method of unpacking initrd to debug if needed > > (somewhere in the manpage): > > http://unix.stackexchange.com/questions/163346/why-is-it-that-my-initrd-only-has-one-directory-namely-kernel > > . > > Or for the archives: > > legolas [mc]# binwalk initrd.img > > pick up the offset of the 2nd initrd image, and unpack like so: > > legolas [mc]# cd subdir; dd if=../initrd.img bs=21136 skip=1 | gunzip | > > cpio -idv > > lsinitramfs shows you the content. Yes, I found that, that's better, but sometimes you do want to actually unpack it to physically inspect the inside (like why is my modules.dep file 21 bytes, what's inside?). Marc -- "A mouse is a device used to point at the xterm you want to type in" - A.S.R. Microsoft is to operating systems .... .... what McDonalds is to gourmet cooking Home page: http://marc.merlins.org/ -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org