Subject: Re: bug#54698: non-recursive GC marking [PATCH]

From: Po Lu <[email-masked]>
Date: Fri, 08 Apr 2022 15:41:07 +0800

Eli Zaretskii <[email-masked]> writes:

> AFAIK, it can be set by editing a file.  Details are here:
>
>   https://www.digitalocean.com/community/questions/how-can-i-disable-overcommit_memory
>   https://serverfault.com/questions/485798/cent-os-how-do-i-turn-off-or-reduce-memory-overcommitment-and-is-it-safe-to-do

Yes, but typically you have to be root to write to that file.

How about adding this in the Memory Full node in the Emacs manual?

On GNU/Linux systems, the system does not normally report running out of
memory to Emacs, and can instead randomly kill processes when they run
out of memory.  We recommend that you turn this behavior off, so that
Emacs can respond correctly when it runs out of memory, by becoming the
super user, editing the file @code{/etc/sysctl.conf} to contain the
following lines, and then running the command @code{sysctl -p} as the
super user:

@indentedblock
vm.overcommit_memory=2
vm.overcommit_ratio=0
@end indentedblock

Thanks.