1SYSTEMD-SYSTEM.CONF(5)        systemd-system.conf       SYSTEMD-SYSTEM.CONF(5)
2
3
4

NAME

6       systemd-system.conf, system.conf.d, systemd-user.conf, user.conf.d -
7       System and session service manager configuration files
8

SYNOPSIS

10       /etc/systemd/system.conf, /etc/systemd/system.conf.d/*.conf,
11       /run/systemd/system.conf.d/*.conf,
12       /usr/lib/systemd/system.conf.d/*.conf
13
14       ~/.config/systemd/user.conf, /etc/systemd/user.conf,
15       /etc/systemd/user.conf.d/*.conf, /run/systemd/user.conf.d/*.conf,
16       /usr/lib/systemd/user.conf.d/*.conf
17

DESCRIPTION

19       When run as a system instance, systemd interprets the configuration
20       file system.conf and the files in system.conf.d directories; when run
21       as a user instance, it interprets the configuration file user.conf
22       (either in the home directory of the user, or if not found, under
23       /etc/systemd/) and the files in user.conf.d directories. These
24       configuration files contain a few settings controlling basic manager
25       operations.
26
27       See systemd.syntax(7) for a general description of the syntax.
28

CONFIGURATION DIRECTORIES AND PRECEDENCE

30       The default configuration is set during compilation, so configuration
31       is only needed when it is necessary to deviate from those defaults.
32       Initially, the main configuration file in /etc/systemd/ contains
33       commented out entries showing the defaults as a guide to the
34       administrator. Local overrides can be created by editing this file or
35       by creating drop-ins, as described below. Using drop-ins for local
36       configuration is recommended over modifications to the main
37       configuration file.
38
39       In addition to the "main" configuration file, drop-in configuration
40       snippets are read from /usr/lib/systemd/*.conf.d/,
41       /usr/local/lib/systemd/*.conf.d/, and /etc/systemd/*.conf.d/. Those
42       drop-ins have higher precedence and override the main configuration
43       file. Files in the *.conf.d/ configuration subdirectories are sorted by
44       their filename in lexicographic order, regardless of in which of the
45       subdirectories they reside. When multiple files specify the same
46       option, for options which accept just a single value, the entry in the
47       file sorted last takes precedence, and for options which accept a list
48       of values, entries are collected as they occur in the sorted files.
49
50       When packages need to customize the configuration, they can install
51       drop-ins under /usr/. Files in /etc/ are reserved for the local
52       administrator, who may use this logic to override the configuration
53       files installed by vendor packages. Drop-ins have to be used to
54       override package drop-ins, since the main configuration file has lower
55       precedence. It is recommended to prefix all filenames in those
56       subdirectories with a two-digit number and a dash, to simplify the
57       ordering of the files.
58
59       To disable a configuration file supplied by the vendor, the recommended
60       way is to place a symlink to /dev/null in the configuration directory
61       in /etc/, with the same filename as the vendor configuration file.
62

OPTIONS

64       All options are configured in the [Manager] section:
65
66       LogColor=, LogLevel=, LogLocation=, LogTarget=, LogTime=, DumpCore=yes,
67       CrashChangeVT=no, CrashShell=no, CrashReboot=no, ShowStatus=yes,
68       DefaultStandardOutput=journal, DefaultStandardError=inherit
69           Configures various parameters of basic manager operation. These
70           options may be overridden by the respective process and kernel
71           command line arguments. See systemd(1) for details.
72
73       CtrlAltDelBurstAction=
74           Defines what action will be performed if user presses
75           Ctrl-Alt-Delete more than 7 times in 2s. Can be set to
76           "reboot-force", "poweroff-force", "reboot-immediate",
77           "poweroff-immediate" or disabled with "none". Defaults to
78           "reboot-force".
79
80       CPUAffinity=
81           Configures the CPU affinity for the service manager as well as the
82           default CPU affinity for all forked off processes. Takes a list of
83           CPU indices or ranges separated by either whitespace or commas. CPU
84           ranges are specified by the lower and upper CPU indices separated
85           by a dash. This option may be specified more than once, in which
86           case the specified CPU affinity masks are merged. If the empty
87           string is assigned, the mask is reset, all assignments prior to
88           this will have no effect. Individual services may override the CPU
89           affinity for their processes with the CPUAffinity= setting in unit
90           files, see systemd.exec(5).
91
92       NUMAPolicy=
93           Configures the NUMA memory policy for the service manager and the
94           default NUMA memory policy for all forked off processes. Individual
95           services may override the default policy with the NUMAPolicy=
96           setting in unit files, see systemd.exec(5).
97
98       NUMAMask=
99           Configures the NUMA node mask that will be associated with the
100           selected NUMA policy. Note that default and local NUMA policies
101           don't require explicit NUMA node mask and value of the option can
102           be empty. Similarly to NUMAPolicy=, value can be overridden by
103           individual services in unit files, see systemd.exec(5).
104
105       RuntimeWatchdogSec=, RebootWatchdogSec=, KExecWatchdogSec=
106           Configure the hardware watchdog at runtime and at reboot. Takes a
107           timeout value in seconds (or in other time units if suffixed with
108           "ms", "min", "h", "d", "w"), or the special strings "off" or
109           "default". If set to "off" (alternatively: "0") the watchdog logic
110           is disabled: no watchdog device is opened, configured, or pinged.
111           If set to the special string "default" the watchdog is opened and
112           pinged in regular intervals, but the timeout is not changed from
113           the default. If set to any other time value the watchdog timeout is
114           configured to the specified value (or a value close to it,
115           depending on hardware capabilities).
116
117           If RuntimeWatchdogSec= is set to a non-zero value, the watchdog
118           hardware (/dev/watchdog0 or the path specified with WatchdogDevice=
119           or the kernel option systemd.watchdog-device=) will be programmed
120           to automatically reboot the system if it is not contacted within
121           the specified timeout interval. The system manager will ensure to
122           contact it at least once in half the specified timeout interval.
123           This feature requires a hardware watchdog device to be present, as
124           it is commonly the case in embedded and server systems. Not all
125           hardware watchdogs allow configuration of all possible reboot
126           timeout values, in which case the closest available timeout is
127           picked.
128
129           RebootWatchdogSec= may be used to configure the hardware watchdog
130           when the system is asked to reboot. It works as a safety net to
131           ensure that the reboot takes place even if a clean reboot attempt
132           times out. Note that the RebootWatchdogSec= timeout applies only to
133           the second phase of the reboot, i.e. after all regular services are
134           already terminated, and after the system and service manager
135           process (PID 1) got replaced by the systemd-shutdown binary, see
136           system bootup(7) for details. During the first phase of the
137           shutdown operation the system and service manager remains running
138           and hence RuntimeWatchdogSec= is still honoured. In order to define
139           a timeout on this first phase of system shutdown, configure
140           JobTimeoutSec= and JobTimeoutAction= in the [Unit] section of the
141           shutdown.target unit. By default RuntimeWatchdogSec= defaults to 0
142           (off), and RebootWatchdogSec= to 10min.
143
144           KExecWatchdogSec= may be used to additionally enable the watchdog
145           when kexec is being executed rather than when rebooting. Note that
146           if the kernel does not reset the watchdog on kexec (depending on
147           the specific hardware and/or driver), in this case the watchdog
148           might not get disabled after kexec succeeds and thus the system
149           might get rebooted, unless RuntimeWatchdogSec= is also enabled at
150           the same time. For this reason it is recommended to enable
151           KExecWatchdogSec= only if RuntimeWatchdogSec= is also enabled.
152
153           These settings have no effect if a hardware watchdog is not
154           available.
155
156       WatchdogDevice=
157           Configure the hardware watchdog device that the runtime and
158           shutdown watchdog timers will open and use. Defaults to
159           /dev/watchdog0. This setting has no effect if a hardware watchdog
160           is not available.
161
162       CapabilityBoundingSet=
163           Controls which capabilities to include in the capability bounding
164           set for PID 1 and its children. See capabilities(7) for details.
165           Takes a whitespace-separated list of capability names as read by
166           cap_from_name(3). Capabilities listed will be included in the
167           bounding set, all others are removed. If the list of capabilities
168           is prefixed with ~, all but the listed capabilities will be
169           included, the effect of the assignment inverted. Note that this
170           option also affects the respective capabilities in the effective,
171           permitted and inheritable capability sets. The capability bounding
172           set may also be individually configured for units using the
173           CapabilityBoundingSet= directive for units, but note that
174           capabilities dropped for PID 1 cannot be regained in individual
175           units, they are lost for good.
176
177       NoNewPrivileges=
178           Takes a boolean argument. If true, ensures that PID 1 and all its
179           children can never gain new privileges through execve(2) (e.g. via
180           setuid or setgid bits, or filesystem capabilities). Defaults to
181           false. General purpose distributions commonly rely on executables
182           with setuid or setgid bits and will thus not function properly with
183           this option enabled. Individual units cannot disable this option.
184           Also see No New Privileges Flag[1].
185
186       SystemCallArchitectures=
187           Takes a space-separated list of architecture identifiers. Selects
188           from which architectures system calls may be invoked on this
189           system. This may be used as an effective way to disable invocation
190           of non-native binaries system-wide, for example to prohibit
191           execution of 32-bit x86 binaries on 64-bit x86-64 systems. This
192           option operates system-wide, and acts similar to the
193           SystemCallArchitectures= setting of unit files, see systemd.exec(5)
194           for details. This setting defaults to the empty list, in which case
195           no filtering of system calls based on architecture is applied.
196           Known architecture identifiers are "x86", "x86-64", "x32", "arm"
197           and the special identifier "native". The latter implicitly maps to
198           the native architecture of the system (or more specifically, the
199           architecture the system manager was compiled for). Set this setting
200           to "native" to prohibit execution of any non-native binaries. When
201           a binary executes a system call of an architecture that is not
202           listed in this setting, it will be immediately terminated with the
203           SIGSYS signal.
204
205       TimerSlackNSec=
206           Sets the timer slack in nanoseconds for PID 1, which is inherited
207           by all executed processes, unless overridden individually, for
208           example with the TimerSlackNSec= setting in service units (for
209           details see systemd.exec(5)). The timer slack controls the accuracy
210           of wake-ups triggered by system timers. See prctl(2) for more
211           information. Note that in contrast to most other time span
212           definitions this parameter takes an integer value in nano-seconds
213           if no unit is specified. The usual time units are understood too.
214
215       StatusUnitFormat=
216           Takes name, description or combined as the value. If name, the
217           system manager will use unit names in status messages (e.g.
218           "systemd-journald.service"), instead of the longer and more
219           informative descriptions set with Description= (e.g.  "Journal
220           Logging Service"). If combined, the system manager will use both
221           unit names and descriptions in status messages (e.g.
222           "systemd-journald.service - Journal Logging Service").
223
224           See systemd.unit(5) for details about unit names and Description=.
225
226       DefaultTimerAccuracySec=
227           Sets the default accuracy of timer units. This controls the global
228           default for the AccuracySec= setting of timer units, see
229           systemd.timer(5) for details.  AccuracySec= set in individual units
230           override the global default for the specific unit. Defaults to
231           1min. Note that the accuracy of timer units is also affected by the
232           configured timer slack for PID 1, see TimerSlackNSec= above.
233
234       DefaultTimeoutStartSec=, DefaultTimeoutStopSec=,
235       DefaultTimeoutAbortSec=, DefaultRestartSec=
236           Configures the default timeouts for starting, stopping and aborting
237           of units, as well as the default time to sleep between automatic
238           restarts of units, as configured per-unit in TimeoutStartSec=,
239           TimeoutStopSec=, TimeoutAbortSec= and RestartSec= (for services,
240           see systemd.service(5) for details on the per-unit settings).
241           Disabled by default, when service with Type=oneshot is used. For
242           non-service units, DefaultTimeoutStartSec= sets the default
243           TimeoutSec= value.  DefaultTimeoutStartSec= and
244           DefaultTimeoutStopSec= default to 90s.  DefaultTimeoutAbortSec= is
245           not set by default so that all units fall back to TimeoutStopSec=.
246           DefaultRestartSec= defaults to 100ms.
247
248       DefaultStartLimitIntervalSec=, DefaultStartLimitBurst=
249           Configure the default unit start rate limiting, as configured
250           per-service by StartLimitIntervalSec= and StartLimitBurst=. See
251           systemd.service(5) for details on the per-service settings.
252           DefaultStartLimitIntervalSec= defaults to 10s.
253           DefaultStartLimitBurst= defaults to 5.
254
255       DefaultEnvironment=
256           Configures environment variables passed to all executed processes.
257           Takes a space-separated list of variable assignments. See
258           environ(7) for details about environment variables.
259
260           Simple "%"-specifier expansion is supported, see below for a list
261           of supported specifiers.
262
263           Example:
264
265               DefaultEnvironment="VAR1=word1 word2" VAR2=word3 "VAR3=word 5 6"
266
267           Sets three variables "VAR1", "VAR2", "VAR3".
268
269       ManagerEnvironment=
270           Takes the same arguments as DefaultEnvironment=, see above. Sets
271           environment variables just for the manager process itself. In
272           contrast to user managers, these variables are not inherited by
273           processes spawned by the system manager, use DefaultEnvironment=
274           for that. Note that these variables are merged into the existing
275           environment block. In particular, in case of the system manager,
276           this includes variables set by the kernel based on the kernel
277           command line.
278
279           Setting environment variables for the manager process may be useful
280           to modify its behaviour. See ENVIRONMENT[2] for a descriptions of
281           some variables understood by systemd.
282
283           Simple "%"-specifier expansion is supported, see below for a list
284           of supported specifiers.
285
286       DefaultCPUAccounting=, DefaultBlockIOAccounting=,
287       DefaultMemoryAccounting=, DefaultTasksAccounting=,
288       DefaultIOAccounting=, DefaultIPAccounting=
289           Configure the default resource accounting settings, as configured
290           per-unit by CPUAccounting=, BlockIOAccounting=, MemoryAccounting=,
291           TasksAccounting=, IOAccounting= and IPAccounting=. See
292           systemd.resource-control(5) for details on the per-unit settings.
293           DefaultTasksAccounting= defaults to yes, DefaultMemoryAccounting=
294           to yes.  DefaultCPUAccounting= defaults to yes if enabling CPU
295           accounting doesn't require the CPU controller to be enabled (Linux
296           4.15+ using the unified hierarchy for resource control), otherwise
297           it defaults to no. The other three settings default to no.
298
299       DefaultTasksMax=
300           Configure the default value for the per-unit TasksMax= setting. See
301           systemd.resource-control(5) for details. This setting applies to
302           all unit types that support resource control settings, with the
303           exception of slice units. Defaults to 15% of the minimum of
304           kernel.pid_max=, kernel.threads-max= and root cgroup pids.max.
305           Kernel has a default value for kernel.pid_max= and an algorithm of
306           counting in case of more than 32 cores. For example with the
307           default kernel.pid_max=, DefaultTasksMax= defaults to 4915, but
308           might be greater in other systems or smaller in OS containers.
309
310       DefaultLimitCPU=, DefaultLimitFSIZE=, DefaultLimitDATA=,
311       DefaultLimitSTACK=, DefaultLimitCORE=, DefaultLimitRSS=,
312       DefaultLimitNOFILE=, DefaultLimitAS=, DefaultLimitNPROC=,
313       DefaultLimitMEMLOCK=, DefaultLimitLOCKS=, DefaultLimitSIGPENDING=,
314       DefaultLimitMSGQUEUE=, DefaultLimitNICE=, DefaultLimitRTPRIO=,
315       DefaultLimitRTTIME=
316           These settings control various default resource limits for
317           processes executed by units. See setrlimit(2) for details. These
318           settings may be overridden in individual units using the
319           corresponding LimitXXX= directives and they accept the same
320           parameter syntax, see systemd.exec(5) for details. Note that these
321           resource limits are only defaults for units, they are not applied
322           to the service manager process (i.e. PID 1) itself.
323
324           Most of these settings are unset, which means the resource limits
325           are inherited from the kernel or, if invoked in a container, from
326           the container manager. However, the following have defaults:
327
328DefaultLimitNOFILE= defaults to "1024:524288".
329
330DefaultLimitCORE= does not have a default but it is worth
331               mentioning that RLIMIT_CORE is set to "infinity" by PID 1 which
332               is inherited by its children.
333
334           •   Note that the service manager internally increases
335               RLIMIT_MEMLOCK for itself, however the limit is reverted to the
336               original value for child processes forked off.
337
338       DefaultOOMPolicy=
339           Configure the default policy for reacting to processes being killed
340           by the Linux Out-Of-Memory (OOM) killer. This may be used to pick a
341           global default for the per-unit OOMPolicy= setting. See
342           systemd.service(5) for details. Note that this default is not used
343           for services that have Delegate= turned on.
344
345       DefaultOOMScoreAdjust=
346           Configures the default OOM score adjustments of processes run by
347           the service manager. This defaults to unset (meaning the forked off
348           processes inherit the service manager's OOM score adjustment
349           value), except if the service manager is run for an unprivileged
350           user, in which case this defaults to the service manager's OOM
351           adjustment value plus 100 (this makes service processes slightly
352           more likely to be killed under memory pressure than the manager
353           itself). This may be used to pick a global default for the per-unit
354           OOMScoreAdjust= setting. See systemd.exec(5) for details. Note that
355           this setting has no effect on the OOM score adjustment value of the
356           service manager process itself, it retains the original value set
357           during its invocation.
358

SPECIFIERS

360       Specifiers may be used in the DefaultEnvironment= and
361       ManagerEnvironment= settings. The following expansions are understood:
362
363       Table 1. Specifiers available
364       ┌──────────┬─────────────────────┬────────────────────────┐
365Specifier Meaning             Details                
366       ├──────────┼─────────────────────┼────────────────────────┤
367       │"%a"      │ Architecture        │ A short string         │
368       │          │                     │ identifying the        │
369       │          │                     │ architecture of the    │
370       │          │                     │ local system. A        │
371       │          │                     │ string such as x86,    │
372       │          │                     │ x86-64 or arm64.       │
373       │          │                     │ See the                │
374       │          │                     │ architectures          │
375       │          │                     │ defined for            │
376       │          │                     │ ConditionArchitecture=
377       │          │                     │ in systemd.unit(5)
378       │          │                     │ for a full list.       │
379       ├──────────┼─────────────────────┼────────────────────────┤
380       │"%A"      │ Operating system    │ The operating system   │
381       │          │ image version       │ image version          │
382       │          │                     │ identifier of the      │
383       │          │                     │ running system, as     │
384       │          │                     │ read from the          │
385       │          │                     │ IMAGE_VERSION= field   │
386       │          │                     │ of /etc/os-release. If │
387       │          │                     │ not set, resolves to   │
388       │          │                     │ an empty string. See   │
389       │          │                     │ os-release(5) for more │
390       │          │                     │ information.           │
391       ├──────────┼─────────────────────┼────────────────────────┤
392       │"%b"      │ Boot ID             │ The boot ID of the     │
393       │          │                     │ running system,        │
394       │          │                     │ formatted as string.   │
395       │          │                     │ See random(4) for more │
396       │          │                     │ information.           │
397       ├──────────┼─────────────────────┼────────────────────────┤
398       │"%B"      │ Operating system    │ The operating system   │
399       │          │ build ID            │ build identifier of    │
400       │          │                     │ the running system, as │
401       │          │                     │ read from the          │
402       │          │                     │ BUILD_ID= field of     │
403       │          │                     │ /etc/os-release. If    │
404       │          │                     │ not set, resolves to   │
405       │          │                     │ an empty string. See   │
406       │          │                     │ os-release(5) for more │
407       │          │                     │ information.           │
408       ├──────────┼─────────────────────┼────────────────────────┤
409       │"%H"      │ Host name           │ The hostname of the    │
410       │          │                     │ running system.        │
411       ├──────────┼─────────────────────┼────────────────────────┤
412       │"%l"      │ Short host name     │ The hostname of the    │
413       │          │                     │ running system,        │
414       │          │                     │ truncated at the first │
415       │          │                     │ dot to remove any      │
416       │          │                     │ domain component.      │
417       ├──────────┼─────────────────────┼────────────────────────┤
418       │"%m"      │ Machine ID          │ The machine ID of the  │
419       │          │                     │ running system,        │
420       │          │                     │ formatted as string.   │
421       │          │                     │ See machine-id(5) for  │
422       │          │                     │ more information.      │
423       ├──────────┼─────────────────────┼────────────────────────┤
424       │"%M"      │ Operating system    │ The operating system   │
425       │          │ image identifier    │ image identifier of    │
426       │          │                     │ the running system, as │
427       │          │                     │ read from the          │
428       │          │                     │ IMAGE_ID= field of     │
429       │          │                     │ /etc/os-release. If    │
430       │          │                     │ not set, resolves to   │
431       │          │                     │ an empty string. See   │
432       │          │                     │ os-release(5) for more │
433       │          │                     │ information.           │
434       ├──────────┼─────────────────────┼────────────────────────┤
435       │"%o"      │ Operating system ID │ The operating system   │
436       │          │                     │ identifier of the      │
437       │          │                     │ running system, as     │
438       │          │                     │ read from the ID=
439       │          │                     │ field of               │
440       │          │                     │ /etc/os-release. See   │
441       │          │                     │ os-release(5) for more │
442       │          │                     │ information.           │
443       ├──────────┼─────────────────────┼────────────────────────┤
444       │"%v"      │ Kernel release      │ Identical to uname -r  
445       │          │                     │ output.                │
446       ├──────────┼─────────────────────┼────────────────────────┤
447       │"%w"      │ Operating system    │ The operating system   │
448       │          │ version ID          │ version identifier of  │
449       │          │                     │ the running system, as │
450       │          │                     │ read from the          │
451       │          │                     │ VERSION_ID= field of   │
452       │          │                     │ /etc/os-release. If    │
453       │          │                     │ not set, resolves to   │
454       │          │                     │ an empty string. See   │
455       │          │                     │ os-release(5) for more │
456       │          │                     │ information.           │
457       ├──────────┼─────────────────────┼────────────────────────┤
458       │"%W"      │ Operating system    │ The operating system   │
459       │          │ variant ID          │ variant identifier of  │
460       │          │                     │ the running system, as │
461       │          │                     │ read from the          │
462       │          │                     │ VARIANT_ID= field of   │
463       │          │                     │ /etc/os-release. If    │
464       │          │                     │ not set, resolves to   │
465       │          │                     │ an empty string. See   │
466       │          │                     │ os-release(5) for more │
467       │          │                     │ information.           │
468       ├──────────┼─────────────────────┼────────────────────────┤
469       │"%T"      │ Directory for       │ This is either /tmp or │
470       │          │ temporary files     │ the path "$TMPDIR",    │
471       │          │                     │ "$TEMP" or "$TMP" are  │
472       │          │                     │ set to. (Note that the │
473       │          │                     │ directory may be       │
474       │          │                     │ specified without a    │
475       │          │                     │ trailing slash.)       │
476       ├──────────┼─────────────────────┼────────────────────────┤
477       │"%V"      │ Directory for       │ This is either         │
478       │          │ larger and          │ /var/tmp or the path   │
479       │          │ persistent          │ "$TMPDIR", "$TEMP" or  │
480       │          │ temporary files     │ "$TMP" are set to.     │
481       │          │                     │ (Note that the         │
482       │          │                     │ directory may be       │
483       │          │                     │ specified without a    │
484       │          │                     │ trailing slash.)       │
485       ├──────────┼─────────────────────┼────────────────────────┤
486       │"%%"      │ Single percent sign │ Use "%%" in place of   │
487       │          │                     │ "%" to specify a       │
488       │          │                     │ single percent sign.   │
489       └──────────┴─────────────────────┴────────────────────────┘
490

SEE ALSO

492       systemd(1), systemd.directives(7), systemd.exec(5), systemd.service(5),
493       environ(7), capabilities(7)
494

NOTES

496        1. No New Privileges Flag
497           https://www.kernel.org/doc/html/latest/userspace-api/no_new_privs.html
498
499        2. ENVIRONMENT
500           https://systemd.io/ENVIRONMENT
501
502
503
504systemd 250                                             SYSTEMD-SYSTEM.CONF(5)
Impressum