diff --git a/README b/README index bb0f126873b..e0b7fbf8bf7 100644 --- a/README +++ b/README @@ -126,6 +126,9 @@ REQUIREMENTS: Required for systemd-nspawn: CONFIG_DEVPTS_MULTIPLE_INSTANCES or Linux kernel >= 4.7 + Required for systemd-oomd: + CONFIG_PSI + Note that kernel auditing is broken when used with systemd's container code. When using systemd in conjunction with containers, please make sure to either turn off auditing at diff --git a/units/systemd-oomd.service.in b/units/systemd-oomd.service.in index fd7c8d213db..f264a1bef02 100644 --- a/units/systemd-oomd.service.in +++ b/units/systemd-oomd.service.in @@ -13,6 +13,10 @@ Documentation=man:systemd-oomd.service(8) DefaultDependencies=no Before=multi-user.target shutdown.target Conflicts=shutdown.target +ConditionControlGroupController=v2 +ConditionPathExists=/proc/pressure/cpu +ConditionPathExists=/proc/pressure/io +ConditionPathExists=/proc/pressure/memory [Service] AmbientCapabilities=CAP_KILL CAP_DAC_OVERRIDE