diff options
author | Lennart Poettering <lennart@poettering.net> | 2022-11-29 14:40:18 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-29 14:40:18 +0100 |
commit | 04613753260cf1df47c6c1fbed9b02efd4f8af48 (patch) | |
tree | 6f72fea1aca5672be4a0e7a669af5023a636a8df /src/login | |
parent | 0ccfd3564b2532a4da6526a9e030362c4a142b77 (diff) | |
parent | 98b6c94b577205d31b019286c2a84cc9af244ea0 (diff) | |
download | systemd-04613753260cf1df47c6c1fbed9b02efd4f8af48.tar.gz |
Merge pull request #25385 from drvink/main
systemd: Support OOMPolicy in scope units
Diffstat (limited to 'src/login')
-rw-r--r-- | src/login/logind-dbus.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/login/logind-dbus.c b/src/login/logind-dbus.c index 86a5decf3f..2ab26b9c6d 100644 --- a/src/login/logind-dbus.c +++ b/src/login/logind-dbus.c @@ -3970,6 +3970,12 @@ int manager_start_scope( if (r < 0) return r; + /* For login session scopes, if a process is OOM killed by the kernel, *don't* terminate the rest of + the scope */ + r = sd_bus_message_append(m, "(sv)", "OOMPolicy", "s", "continue"); + if (r < 0) + return r; + /* disable TasksMax= for the session scope, rely on the slice setting for it */ r = sd_bus_message_append(m, "(sv)", "TasksMax", "t", UINT64_MAX); if (r < 0) |