mirror of
https://github.com/systemd/systemd-stable.git
synced 2025-02-01 05:47:04 +03:00
dce229df23
The user manager connects to oomd over varlink. Currently, during shutdown, if oomd is stopped before any user manager, the user manager will try to reconnect to the socket, leading to a warning from pid 1 about a conflicting transaction. Let's fix this by ordering user@.service after systemd-oomd.service, so that user sessions are stopped before systemd-oomd is stopped, which makes sure that the user sessions won't try to start oomd via its socket after systemd-oomd is stopped. (cherry picked from commit cafd2c0be404cb8879f91d15e05cc8b695b32629) (cherry picked from commit c4848032f132e0cb82c7967e5434378c98111a8c) (cherry picked from commit 603d8402de93d7ed716dca0ce531deb06928cfc0)
29 lines
802 B
SYSTEMD
29 lines
802 B
SYSTEMD
# SPDX-License-Identifier: LGPL-2.1-or-later
|
|
#
|
|
# This file is part of systemd.
|
|
#
|
|
# systemd is free software; you can redistribute it and/or modify it
|
|
# under the terms of the GNU Lesser General Public License as published by
|
|
# the Free Software Foundation; either version 2.1 of the License, or
|
|
# (at your option) any later version.
|
|
|
|
[Unit]
|
|
Description=User Manager for UID %i
|
|
Documentation=man:user@.service(5)
|
|
After=systemd-user-sessions.service user-runtime-dir@%i.service dbus.service systemd-oomd.service
|
|
Requires=user-runtime-dir@%i.service
|
|
IgnoreOnIsolate=yes
|
|
|
|
[Service]
|
|
User=%i
|
|
PAMName=systemd-user
|
|
Type=notify
|
|
ExecStart={{ROOTLIBEXECDIR}}/systemd --user
|
|
Slice=user-%i.slice
|
|
KillMode=mixed
|
|
Delegate=pids memory
|
|
TasksMax=infinity
|
|
TimeoutStopSec=120s
|
|
KeyringMode=inherit
|
|
OOMScoreAdjust=100
|