[arch-dev-public] mkinitcpio some improvements and question on how kernel modules should be treated

Tobias Powalowski tobias.powalowski at googlemail.com
Tue Feb 1 14:54:03 UTC 2022


Hi guys,
did some initcpio optimizing lately and implemented correct symlink
handling. This saves already some space.
https://bugs.archlinux.org/task/73439

Now one major problem left in recent initcpio, uncompressed modules:
https://github.com/archlinux/mkinitcpio/pull/25
https://bugs.archlinux.org/task/72882
At the moment modules are uncompressed during initcpio creation. This leads
to bigger RAM usage during boot, makes it a bit smaller on storage, due to
not recompress compressed modules. On small initrds for normal boot this is
not a big matter.

My measurement with all patches added:
Ramdisk size uncompressed modules: 13261677
Ramdisk size compressed modules: 13112083
(Note the compressed one is smaller due to the symlink patches added)
Unpacked initramfs uncompressed modules: 35 MB
Unpacked initramfs compressed modules:  26 MB
Using this on the biggest "initramfs testsuite" archboot shows the most
advantages.

If you like to test it on your own initramfs setup you can use:
https://gitlab.archlinux.org/tpowa/archboot/-/blob/master/usr/share/archboot/patches/31-initcpio.functions.fixed
for /usr/lib/initcpio/functions and recreate your initramdisk.

Now my question to the list, what should be the default how arch handles
modules in initramfs?
- Shall we leave the modules at compression level used during kernel build?
 --> This means the uncompression should be optional.
- Shall we still uncompress the modules always? (Status now)
--> Then using modules as is needs to be optional.

Thanks for you input.
greetings
tpowa
-- 
Tobias Powalowski
Archlinux Developer & Package Maintainer (tpowa)
https://www.archlinux.org <http://www.archlinux.org>
tpowa at archlinux.org

St. Martin-Apotheke
Herzog-Georg-Str. 25
89415 Lauingen
https://www.st-martin-apo.de
info at st-martin-apo.de


More information about the arch-dev-public mailing list