Bug#1079670: systemd: should restrict size of /dev tmpfs
Luca Boccassi
bluca at debian.org
Tue Oct 8 21:52:06 BST 2024
Control: close -1
On Mon, 26 Aug 2024 15:22:47 +1000 Russell Coker <russell at coker.com.au>
wrote:
> Package: systemd
> Version: 256.5-1
> Severity: minor
>
> https://current.workingdirectory.net/posts/2024/who-ate-my-ram/
>
> The above blog post from Planet Debian shows an issue that isn't that
uncommon
> of running out of RAM due to writing to the wrong name under /dev (eg
writing
> to /dev/nul).
>
> While the script in question shouldn't do that it would be good to
have the
> result of doing so not involve making a server unusable.
>
> The command "mount -o remount,size=10m /dev" reduces the size and
potential
> wasted RAM to 10M which prevents this sort of thing from becoming a
serious
> problem and has no downsides that I can imagine. 10M should be more
than
> enough for the systems with the largest numbers of devices.
>
> I'm filing this bug report against systemd because it's related to
boot
> scripts and I can't think of a better target.
This already happens in systemd and has been for a long time, but in
debina it is initramfs-tools that mounts /dev, not systemd, so there's
nothing that can be done here.
More information about the Pkg-systemd-maintainers
mailing list