From b62087d4d06777ccde9eb9e7a97abc7b8945d5f5 Mon Sep 17 00:00:00 2001 From: Chris Down Date: Mon, 30 Sep 2019 14:23:32 +0100 Subject: [PATCH 1/2] cgroup: docs: Mention unbounded protection for memory.{low,min} I got asked why Memory{Low,Min} don't allow "infinity". They do, but the docs don't say that like they already do for Memory{High,Max}. --- man/systemd.resource-control.xml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/man/systemd.resource-control.xml b/man/systemd.resource-control.xml index 98a0741359a..a832587fa81 100644 --- a/man/systemd.resource-control.xml +++ b/man/systemd.resource-control.xml @@ -269,7 +269,9 @@ Takes a memory size in bytes. If the value is suffixed with K, M, G or T, the specified memory size is parsed as Kilobytes, Megabytes, Gigabytes, or Terabytes (with the base 1024), respectively. Alternatively, a percentage value may be specified, which is taken relative to the installed physical memory on the - system. This controls the memory.min control group attribute. For details about this + system. If assigned the special value infinity, all available memory is protected, which may be + useful in order to always inherit all of the protection afforded by ancestors. + This controls the memory.min control group attribute. For details about this control group attribute, see cgroup-v2.txt. @@ -293,7 +295,9 @@ Takes a memory size in bytes. If the value is suffixed with K, M, G or T, the specified memory size is parsed as Kilobytes, Megabytes, Gigabytes, or Terabytes (with the base 1024), respectively. Alternatively, a percentage value may be specified, which is taken relative to the installed physical memory on the - system. This controls the memory.low control group attribute. For details about this + system. If assigned the special value infinity, all available memory is protected, which may be + useful in order to always inherit all of the protection afforded by ancestors. + This controls the memory.low control group attribute. For details about this control group attribute, see cgroup-v2.txt. From ba79e19cb299623c9c0dd4c6a1ae80f795409b04 Mon Sep 17 00:00:00 2001 From: Chris Down Date: Mon, 30 Sep 2019 14:25:14 +0100 Subject: [PATCH 2/2] cgroup: docs: memory.high doc fixups The docs just tautologically call this the "high limit". Just call it throttling as we do in cgroup-v2.rst. --- man/systemd.resource-control.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/man/systemd.resource-control.xml b/man/systemd.resource-control.xml index a832587fa81..7daaba5074a 100644 --- a/man/systemd.resource-control.xml +++ b/man/systemd.resource-control.xml @@ -314,7 +314,7 @@ MemoryHigh=bytes - Specify the high limit on memory usage of the executed processes in this unit. Memory usage may go + Specify the throttling limit on memory usage of the executed processes in this unit. Memory usage may go above the limit if unavoidable, but the processes are heavily slowed down and memory is taken away aggressively in such cases. This is the main mechanism to control memory usage of a unit. @@ -322,7 +322,7 @@ parsed as Kilobytes, Megabytes, Gigabytes, or Terabytes (with the base 1024), respectively. Alternatively, a percentage value may be specified, which is taken relative to the installed physical memory on the system. If assigned the - special value infinity, no memory limit is applied. This controls the + special value infinity, no memory throttling is applied. This controls the memory.high control group attribute. For details about this control group attribute, see cgroup-v2.txt.