You are not logged in.
Hi
On a simple system, an initramfs fallback is about double the size of a shrunk one, but both are quite small (under 40M). On my slow computer both complete early userspace very swiftly.
So what is the advantage of shrinking the image? Are the some cases where the difference can be significant?
Thanks
Last edited by robotoid (2022-09-26 08:44:24)
Offline
So what is the advantage of shrinking the image? Are the some cases where the difference can be significant?
I think the main goal of separate normal and fallback initramfs is not a shrinking but possibility to customize normal boot on one hand and possibility to boot safe if something went wrong on other hand. Smaller normal initramfs size is just a side effect.
Offline
I think the main goal of separate normal and fallback initramfs is not a shrinking but possibility to customize normal boot...
The autodetect hook doesn't "customize" it in any way at all other than leaving out modules that do not appear to be needed resulting in a smaller size.
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
The autodetect hook doesn't "customize" it in any way at all other than leaving out modules that do not appear to be needed resulting in a smaller size.
Indeed, the question is specifically about autodetect hook. But mkinitcpio allows different configs for different images in a single preset, it confused me. Sorry for noise.
Offline
Hi
On a simple system, an initramfs fallback is about double the size of a shrunk one, but both are quite small (under 40M). On my slow computer both complete early userspace very swiftly.
So what is the advantage of shrinking the image? Are the some cases where the difference can be significant?
Thanks
As said, autodetect removes clutter that your system doesn't need, but if something changes in your system and it suddenly needs some of that removed clutter, BANG.
The fallback has all the bloat, and it will/should work regardless of what nonsense is done with the system, within reason.
If wanted, one could just yeet it all on the same initramfs full of bloat by changing the presets a bit, and done.
Offline
If wanted, one could just yeet it all on the same initramfs full of bloat by changing the presets a bit, and done.
I've done this and haven't run into any issues, that said it does feel like I've removed a worthwhile safeguard but I like to live dangerously.
Offline
If wanted, one could just yeet it all on the same initramfs full of bloat by changing the presets a bit, and done.
I've done this and haven't run into any issues, that said it does feel like I've removed a worthwhile safeguard but I like to live dangerously.
If you only have a single initramfs without autodetect, you technically don't have to worry about nothing, it will only be a liiiiiil bit slower than usual.
At the moment I have a regular initramfs for linux-zen and a fallback initramfs (no autodetect) for linux-lts, and I really can't notice time differences because of unlocking the luks2.
Offline
So it boils down to removing the bloat just because we can, but just in case the things that worked yesterday don't today...
Well sounds very obvious when I put it like that.
Offline