logo

bootstrap-initrd

Linux initrd to bootstrap from a small binary seed git clone https://hacktivis.me/git/bootstrap-initrd.git
commit: 0f0067b4e4044afa24be45bd38e5fefd9e67933e
parent bc09d8b5d5ce7630180a167f74177a97475cf5c2
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date:   Mon, 20 May 2024 22:38:02 +0200

Use pigz to compress the initrd instead of xz

Much faster compression for barely worse results (50M vs. 52M with x86_64)

Diffstat:

MREADME.md2+-
Mmake-initrd.sh2+-
2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/README.md b/README.md @@ -148,7 +148,7 @@ Meanwhile: * Combination of `panic=1` and `-no-reboot` allows to exit+relaunch ``` -$ ./make-initrd.sh && qemu-system-x86_64 -enable-kvm -m 512 -kernel /boot/vmlinuz-6.6.21-gentoo -initrd bootstrap-initrd/x86_64.cpio.xz -append 'init=/init console=ttyS0 panic=1' -nographic -no-reboot +$ ./make-initrd.sh && qemu-system-x86_64 -enable-kvm -m 512 -kernel /boot/vmlinuz-6.6.21-gentoo -initrd bootstrap-initrd/x86_64.cpio.gz -append 'init=/init console=ttyS0 panic=1' -nographic -no-reboot ``` ## Dev setup via bubblewrap diff --git a/make-initrd.sh b/make-initrd.sh @@ -22,6 +22,6 @@ cd "$out_base" || die "Failed: cd $out_base" deblob -n find . -print0 | cpio --null -o --format=newc > "${out_base}.cpio" -xz -9 --check=crc32 -f -k "${out_base}.cpio" +pigz --best -f -k "${out_base}.cpio" cd "${WORKDIR}"