mirror of
https://salsa.debian.org/kernel-team/initramfs-tools.git
synced 2026-01-26 15:39:08 +00:00
Using 10% of RAM for /run is a good default, but not suitable for all systems. 10% might be too small for system with less memory (e.g. virtual machine with 160 MiB RAM) or too big (VM host with 256/512 GiB RAM). A too small /run partition leads to not enough space on it. If the /run partition is huge, systemd's journald will consume lot of memory, because it defaults to using at most 15% of the respective file system of /run/log/journal. Adjusting the size of /run via an entry in /etc/fstab is not sufficient since journald calculates it limits before systemd remounts /run with the small size. Therefore journald could occupy the full /run partition with its logs. Allow specifying the size of /run by adding a RUNSIZE configuration variable and a initramfs.ramsize= boot argument. Mounting /run must be done after reading the configuration. Closes: #862013 Signed-off-by: Benjamin Drung <benjamin.drung@profitbricks.com>