From f02cd4a4273f5cf4898df4feee7dcf0d08756029 Mon Sep 17 00:00:00 2001 From: Kir Kolyshkin Date: Mon, 8 Mar 2021 10:41:59 -0800 Subject: [PATCH] config-linux: mark memory.kernel[TCP] as NOT RECOMMENDED Per-cgroup kernel memory accounting (and explicit limiting) is problematic in the Linux kernel for too many reasons to quote here. Besides, cgroup v2 does not even have a kernel memory limit knob, and the one in cgroup v1 is made obsoleted in kernel v5.4 [1]. Mark memory.kernel and memory.kernelTCP as NOT RECOMMENDED, in additon to OPTIONAL. This is a way to say "we do not anyone (runtimes or users) to set those limits, unless they have good understanding and strong reasons to do so". [1] https://github.com/torvalds/linux/commit/0158115f702b0ba208ab0b Signed-off-by: Kir Kolyshkin --- config-linux.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/config-linux.md b/config-linux.md index 9a515fb..2fe80bc 100644 --- a/config-linux.md +++ b/config-linux.md @@ -264,8 +264,8 @@ Values for memory specify the limit in bytes, or `-1` for unlimited memory. * **`limit`** *(int64, OPTIONAL)* - sets limit of memory usage * **`reservation`** *(int64, OPTIONAL)* - sets soft limit of memory usage * **`swap`** *(int64, OPTIONAL)* - sets limit of memory+Swap usage -* **`kernel`** *(int64, OPTIONAL)* - sets hard limit for kernel memory -* **`kernelTCP`** *(int64, OPTIONAL)* - sets hard limit for kernel TCP buffer memory +* **`kernel`** *(int64, OPTIONAL, NOT RECOMMENDED)* - sets hard limit for kernel memory +* **`kernelTCP`** *(int64, OPTIONAL, NOT RECOMMENDED)* - sets hard limit for kernel TCP buffer memory The following properties do not specify memory limits, but are covered by the `memory` controller: