diff --git a/setup/README.md b/setup/README.md index 1115056..c15ce4b 100644 --- a/setup/README.md +++ b/setup/README.md @@ -247,3 +247,13 @@ reboot ``` Set `rc_cgroup_mode="unified` + +### memory overcommit + +https://redis.io/docs/latest/develop/get-started/faq/#background-saving-fails-with-a-fork-error-on-linux +https://www.kernel.org/doc/Documentation/vm/overcommit-accounting + +```sh +cd /etc/sysctl.d +ln -vs /opt/container-server/setup/sysctl.d/* . +``` diff --git a/setup/sysctl.d/redis-memory-overcommit.conf b/setup/sysctl.d/redis-memory-overcommit.conf new file mode 100644 index 0000000..0cf386f --- /dev/null +++ b/setup/sysctl.d/redis-memory-overcommit.conf @@ -0,0 +1 @@ +vm.overcommit_memory = 1