[Bug 2036886] Re: please add api to repack initramfs
Benjamin Drung
2036886 at bugs.launchpad.net
Thu Sep 21 19:45:03 UTC 2023
** Changed in: initramfs-tools (Ubuntu)
Status: New => Triaged
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to initramfs-tools in Ubuntu.
https://bugs.launchpad.net/bugs/2036886
Title:
please add api to repack initramfs
Status in initramfs-tools package in Ubuntu:
Triaged
Bug description:
please add api to repack initramfs
from the results of unpackinitramfs, including all early & main dirs.
Userstory: i want to tweak my initrd in-place by replacing broken
libc.so.6 with a patched one, I want to use unmkinitramfs, modify
files in main, repack it and boot it.
CLI:
$ unmkinitramfs /boot/initrd.img unpacked-initrd
$ ls unpacked-initrd/
early early2 main
$ (edit things in unpacked-initrd/main/)
$ remkinitramfs unpacked-initrd patched-initrd.img
Where patched-initrd.img is now similar to /boot/initrd.img, apart
from the changed things.
I expect remkinitramfs like functionality that will take the output of
unmkinitramfs (e.g. unpacked-initrd/) directory as input, do
uncompressed cpio archives out of all the subdirs, make compressed
cpio archive out of main, and produce a patched-initrd.img that is
ready for booting.
It is very close to what mkinitramfs does, but skip calling all the
hooks to create things a fresh, and just do the final assembly step of
cpio and compression.
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/initramfs-tools/+bug/2036886/+subscriptions
More information about the foundations-bugs
mailing list