]>
Commit | Line | Data |
---|---|---|
0af20ea2 | 1 | <?xml version='1.0'?> <!--*- Mode: nxml; nxml-child-indent: 2; indent-tabs-mode: nil -*--> |
f3e219a2 | 2 | <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" |
12b42c76 | 3 | "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"> |
f3e219a2 LP |
4 | |
5 | <!-- | |
6 | This file is part of systemd. | |
7 | ||
8 | Copyright 2010 Lennart Poettering | |
9 | ||
10 | systemd is free software; you can redistribute it and/or modify it | |
5430f7f2 LP |
11 | under the terms of the GNU Lesser General Public License as published by |
12 | the Free Software Foundation; either version 2.1 of the License, or | |
f3e219a2 LP |
13 | (at your option) any later version. |
14 | ||
15 | systemd is distributed in the hope that it will be useful, but | |
16 | WITHOUT ANY WARRANTY; without even the implied warranty of | |
17 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
5430f7f2 | 18 | Lesser General Public License for more details. |
f3e219a2 | 19 | |
5430f7f2 | 20 | You should have received a copy of the GNU Lesser General Public License |
f3e219a2 LP |
21 | along with systemd; If not, see <http://www.gnu.org/licenses/>. |
22 | --> | |
23 | ||
1b907b5c | 24 | <refentry id="systemd-system.conf" |
798d3a52 ZJS |
25 | xmlns:xi="http://www.w3.org/2001/XInclude"> |
26 | <refentryinfo> | |
27 | <title>systemd-system.conf</title> | |
28 | <productname>systemd</productname> | |
29 | ||
30 | <authorgroup> | |
31 | <author> | |
32 | <contrib>Developer</contrib> | |
33 | <firstname>Lennart</firstname> | |
34 | <surname>Poettering</surname> | |
35 | <email>lennart@poettering.net</email> | |
36 | </author> | |
37 | </authorgroup> | |
38 | </refentryinfo> | |
39 | ||
40 | <refmeta> | |
41 | <refentrytitle>systemd-system.conf</refentrytitle> | |
42 | <manvolnum>5</manvolnum> | |
43 | </refmeta> | |
44 | ||
45 | <refnamediv> | |
46 | <refname>systemd-system.conf</refname> | |
47 | <refname>system.conf.d</refname> | |
48 | <refname>systemd-user.conf</refname> | |
49 | <refname>user.conf.d</refname> | |
50 | <refpurpose>System and session service manager configuration files</refpurpose> | |
51 | </refnamediv> | |
52 | ||
53 | <refsynopsisdiv> | |
03a7b521 LP |
54 | <para><filename>/etc/systemd/system.conf</filename>, |
55 | <filename>/etc/systemd/system.conf.d/*.conf</filename>, | |
56 | <filename>/run/systemd/system.conf.d/*.conf</filename>, | |
57 | <filename>/usr/lib/systemd/system.conf.d/*.conf</filename></para> | |
58 | <para><filename>/etc/systemd/user.conf</filename>, | |
59 | <filename>/etc/systemd/user.conf.d/*.conf</filename>, | |
60 | <filename>/run/systemd/user.conf.d/*.conf</filename>, | |
61 | <filename>/usr/lib/systemd/user.conf.d/*.conf</filename></para> | |
798d3a52 ZJS |
62 | </refsynopsisdiv> |
63 | ||
64 | <refsect1> | |
65 | <title>Description</title> | |
66 | ||
67 | <para>When run as a system instance, systemd interprets the | |
68 | configuration file <filename>system.conf</filename> and the files | |
69 | in <filename>system.conf.d</filename> directories; when run as a | |
70 | user instance, systemd interprets the configuration file | |
71 | <filename>user.conf</filename> and the files in | |
72 | <filename>user.conf.d</filename> directories. These configuration | |
73 | files contain a few settings controlling basic manager | |
74 | operations.</para> | |
75 | </refsect1> | |
76 | ||
e93549ef | 77 | <xi:include href="standard-conf.xml" xpointer="main-conf" /> |
798d3a52 ZJS |
78 | |
79 | <refsect1> | |
80 | <title>Options</title> | |
81 | ||
82 | <para>All options are configured in the | |
83 | <literal>[Manager]</literal> section:</para> | |
84 | ||
85 | <variablelist class='systemd-directives'> | |
86 | ||
87 | <varlistentry> | |
88 | <term><varname>LogLevel=</varname></term> | |
89 | <term><varname>LogTarget=</varname></term> | |
90 | <term><varname>LogColor=</varname></term> | |
91 | <term><varname>LogLocation=</varname></term> | |
92 | <term><varname>DumpCore=yes</varname></term> | |
b9e74c39 | 93 | <term><varname>CrashChangeVT=no</varname></term> |
798d3a52 | 94 | <term><varname>CrashShell=no</varname></term> |
b9e74c39 | 95 | <term><varname>CrashReboot=no</varname></term> |
798d3a52 | 96 | <term><varname>ShowStatus=yes</varname></term> |
798d3a52 ZJS |
97 | <term><varname>DefaultStandardOutput=journal</varname></term> |
98 | <term><varname>DefaultStandardError=inherit</varname></term> | |
99 | ||
100 | <listitem><para>Configures various parameters of basic manager | |
101 | operation. These options may be overridden by the respective | |
102 | command line arguments. See | |
103 | <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry> | |
104 | for details about these command line | |
105 | arguments.</para></listitem> | |
106 | </varlistentry> | |
107 | ||
24dd31c1 LN |
108 | <varlistentry> |
109 | <term><varname>CtrlAltDelBurstAction=</varname></term> | |
110 | ||
111 | <listitem><para>Defines what action will be performed | |
112 | if user presses Ctr-Alt-Delete more than 7 times in 2s. | |
113 | Can be set to <literal>reboot-force</literal>, <literal>poweroff-force</literal> | |
114 | or disabled with <literal>ignore</literal>. Defaults to | |
115 | <literal>reboot-force</literal>. | |
116 | </para></listitem> | |
117 | </varlistentry> | |
118 | ||
798d3a52 ZJS |
119 | <varlistentry> |
120 | <term><varname>CPUAffinity=</varname></term> | |
121 | ||
122 | <listitem><para>Configures the initial CPU affinity for the | |
71b1c27a FB |
123 | init process. Takes a list of CPU indices or ranges separated |
124 | by either whitespace or commas. CPU ranges are specified by | |
125 | the lower and upper CPU indices separated by a | |
126 | dash.</para></listitem> | |
798d3a52 ZJS |
127 | </varlistentry> |
128 | ||
129 | <varlistentry> | |
130 | <term><varname>JoinControllers=cpu,cpuacct net_cls,netprio</varname></term> | |
131 | ||
132 | <listitem><para>Configures controllers that shall be mounted | |
133 | in a single hierarchy. By default, systemd will mount all | |
134 | controllers which are enabled in the kernel in individual | |
135 | hierarchies, with the exception of those listed in this | |
136 | setting. Takes a space-separated list of comma-separated | |
137 | controller names, in order to allow multiple joined | |
138 | hierarchies. Defaults to 'cpu,cpuacct'. Pass an empty string | |
139 | to ensure that systemd mounts all controllers in separate | |
140 | hierarchies.</para> | |
141 | ||
142 | <para>Note that this option is only applied once, at very | |
143 | early boot. If you use an initial RAM disk (initrd) that uses | |
144 | systemd, it might hence be necessary to rebuild the initrd if | |
145 | this option is changed, and make sure the new configuration | |
146 | file is included in it. Otherwise, the initrd might mount the | |
147 | controller hierarchies in a different configuration than | |
148 | intended, and the main system cannot remount them | |
149 | anymore.</para></listitem> | |
150 | </varlistentry> | |
151 | ||
152 | <varlistentry> | |
153 | <term><varname>RuntimeWatchdogSec=</varname></term> | |
154 | <term><varname>ShutdownWatchdogSec=</varname></term> | |
155 | ||
156 | <listitem><para>Configure the hardware watchdog at runtime and | |
157 | at reboot. Takes a timeout value in seconds (or in other time | |
158 | units if suffixed with <literal>ms</literal>, | |
159 | <literal>min</literal>, <literal>h</literal>, | |
160 | <literal>d</literal>, <literal>w</literal>). If | |
161 | <varname>RuntimeWatchdogSec=</varname> is set to a non-zero | |
162 | value, the watchdog hardware | |
163 | (<filename>/dev/watchdog</filename>) will be programmed to | |
164 | automatically reboot the system if it is not contacted within | |
165 | the specified timeout interval. The system manager will ensure | |
166 | to contact it at least once in half the specified timeout | |
167 | interval. This feature requires a hardware watchdog device to | |
168 | be present, as it is commonly the case in embedded and server | |
169 | systems. Not all hardware watchdogs allow configuration of the | |
170 | reboot timeout, in which case the closest available timeout is | |
171 | picked. <varname>ShutdownWatchdogSec=</varname> may be used to | |
172 | configure the hardware watchdog when the system is asked to | |
173 | reboot. It works as a safety net to ensure that the reboot | |
174 | takes place even if a clean reboot attempt times out. By | |
175 | default <varname>RuntimeWatchdogSec=</varname> defaults to 0 | |
176 | (off), and <varname>ShutdownWatchdogSec=</varname> to 10min. | |
177 | These settings have no effect if a hardware watchdog is not | |
178 | available.</para></listitem> | |
179 | </varlistentry> | |
180 | ||
181 | <varlistentry> | |
182 | <term><varname>CapabilityBoundingSet=</varname></term> | |
183 | ||
184 | <listitem><para>Controls which capabilities to include in the | |
185 | capability bounding set for PID 1 and its children. See | |
186 | <citerefentry project='man-pages'><refentrytitle>capabilities</refentrytitle><manvolnum>7</manvolnum></citerefentry> | |
187 | for details. Takes a whitespace-separated list of capability | |
188 | names as read by | |
3ba3a79d | 189 | <citerefentry project='mankier'><refentrytitle>cap_from_name</refentrytitle><manvolnum>3</manvolnum></citerefentry>. |
798d3a52 ZJS |
190 | Capabilities listed will be included in the bounding set, all |
191 | others are removed. If the list of capabilities is prefixed | |
192 | with ~, all but the listed capabilities will be included, the | |
193 | effect of the assignment inverted. Note that this option also | |
194 | affects the respective capabilities in the effective, | |
195 | permitted and inheritable capability sets. The capability | |
196 | bounding set may also be individually configured for units | |
197 | using the <varname>CapabilityBoundingSet=</varname> directive | |
198 | for units, but note that capabilities dropped for PID 1 cannot | |
199 | be regained in individual units, they are lost for | |
200 | good.</para></listitem> | |
201 | </varlistentry> | |
202 | ||
203 | <varlistentry> | |
204 | <term><varname>SystemCallArchitectures=</varname></term> | |
205 | ||
206 | <listitem><para>Takes a space-separated list of architecture | |
207 | identifiers. Selects from which architectures system calls may | |
208 | be invoked on this system. This may be used as an effective | |
209 | way to disable invocation of non-native binaries system-wide, | |
210 | for example to prohibit execution of 32-bit x86 binaries on | |
211 | 64-bit x86-64 systems. This option operates system-wide, and | |
212 | acts similar to the | |
213 | <varname>SystemCallArchitectures=</varname> setting of unit | |
214 | files, see | |
215 | <citerefentry><refentrytitle>systemd.exec</refentrytitle><manvolnum>5</manvolnum></citerefentry> | |
216 | for details. This setting defaults to the empty list, in which | |
217 | case no filtering of system calls based on architecture is | |
218 | applied. Known architecture identifiers are | |
219 | <literal>x86</literal>, <literal>x86-64</literal>, | |
220 | <literal>x32</literal>, <literal>arm</literal> and the special | |
221 | identifier <literal>native</literal>. The latter implicitly | |
222 | maps to the native architecture of the system (or more | |
223 | specifically, the architecture the system manager was compiled | |
224 | for). Set this setting to <literal>native</literal> to | |
225 | prohibit execution of any non-native binaries. When a binary | |
226 | executes a system call of an architecture that is not listed | |
227 | in this setting, it will be immediately terminated with the | |
228 | SIGSYS signal.</para></listitem> | |
229 | </varlistentry> | |
230 | ||
231 | <varlistentry> | |
232 | <term><varname>TimerSlackNSec=</varname></term> | |
233 | ||
234 | <listitem><para>Sets the timer slack in nanoseconds for PID 1, | |
235 | which is inherited by all executed processes, unless | |
236 | overridden individually, for example with the | |
237 | <varname>TimerSlackNSec=</varname> setting in service units | |
238 | (for details see | |
239 | <citerefentry><refentrytitle>systemd.exec</refentrytitle><manvolnum>5</manvolnum></citerefentry>). | |
240 | The timer slack controls the accuracy of wake-ups triggered by | |
241 | system timers. See | |
242 | <citerefentry><refentrytitle>prctl</refentrytitle><manvolnum>2</manvolnum></citerefentry> | |
243 | for more information. Note that in contrast to most other time | |
244 | span definitions this parameter takes an integer value in | |
245 | nano-seconds if no unit is specified. The usual time units are | |
246 | understood too.</para></listitem> | |
247 | </varlistentry> | |
248 | ||
249 | <varlistentry> | |
250 | <term><varname>DefaultTimerAccuracySec=</varname></term> | |
251 | ||
252 | <listitem><para>Sets the default accuracy of timer units. This | |
253 | controls the global default for the | |
254 | <varname>AccuracySec=</varname> setting of timer units, see | |
255 | <citerefentry><refentrytitle>systemd.timer</refentrytitle><manvolnum>5</manvolnum></citerefentry> | |
256 | for details. <varname>AccuracySec=</varname> set in individual | |
257 | units override the global default for the specific unit. | |
258 | Defaults to 1min. Note that the accuracy of timer units is | |
259 | also affected by the configured timer slack for PID 1, see | |
260 | <varname>TimerSlackNSec=</varname> above.</para></listitem> | |
261 | </varlistentry> | |
262 | ||
263 | <varlistentry> | |
264 | <term><varname>DefaultTimeoutStartSec=</varname></term> | |
265 | <term><varname>DefaultTimeoutStopSec=</varname></term> | |
266 | <term><varname>DefaultRestartSec=</varname></term> | |
267 | ||
268 | <listitem><para>Configures the default timeouts for starting | |
269 | and stopping of units, as well as the default time to sleep | |
270 | between automatic restarts of units, as configured per-unit in | |
271 | <varname>TimeoutStartSec=</varname>, | |
272 | <varname>TimeoutStopSec=</varname> and | |
273 | <varname>RestartSec=</varname> (for services, see | |
274 | <citerefentry><refentrytitle>systemd.service</refentrytitle><manvolnum>5</manvolnum></citerefentry> | |
275 | for details on the per-unit settings). For non-service units, | |
276 | <varname>DefaultTimeoutStartSec=</varname> sets the default | |
f5a05fb5 LP |
277 | <varname>TimeoutSec=</varname> |
278 | value. <varname>DefaultTimeoutStartSec=</varname> and | |
279 | <varname>DefaultTimeoutStopSec=</varname> default to | |
280 | 90s. <varname>DefaultRestartSec=</varname> defaults to | |
281 | 100ms.</para></listitem> | |
798d3a52 ZJS |
282 | </varlistentry> |
283 | ||
284 | <varlistentry> | |
f0367da7 | 285 | <term><varname>DefaultStartLimitIntervalSec=</varname></term> |
798d3a52 ZJS |
286 | <term><varname>DefaultStartLimitBurst=</varname></term> |
287 | ||
288 | <listitem><para>Configure the default unit start rate | |
289 | limiting, as configured per-service by | |
f0367da7 | 290 | <varname>StartLimitIntervalSec=</varname> and |
798d3a52 ZJS |
291 | <varname>StartLimitBurst=</varname>. See |
292 | <citerefentry><refentrytitle>systemd.service</refentrytitle><manvolnum>5</manvolnum></citerefentry> | |
f5a05fb5 | 293 | for details on the per-service settings. |
f0367da7 | 294 | <varname>DefaultStartLimitIntervalSec=</varname> defaults to |
f5a05fb5 LP |
295 | 10s. <varname>DefaultStartLimitBurst=</varname> defaults to |
296 | 5.</para></listitem> | |
798d3a52 ZJS |
297 | </varlistentry> |
298 | ||
299 | <varlistentry> | |
300 | <term><varname>DefaultEnvironment=</varname></term> | |
301 | ||
302 | <listitem><para>Sets manager environment variables passed to | |
303 | all executed processes. Takes a space-separated list of | |
304 | variable assignments. See | |
305 | <citerefentry project='man-pages'><refentrytitle>environ</refentrytitle><manvolnum>7</manvolnum></citerefentry> | |
306 | for details about environment variables.</para> | |
307 | ||
308 | <para>Example: | |
309 | ||
310 | <programlisting>DefaultEnvironment="VAR1=word1 word2" VAR2=word3 "VAR3=word 5 6"</programlisting> | |
311 | ||
312 | Sets three variables | |
313 | <literal>VAR1</literal>, | |
314 | <literal>VAR2</literal>, | |
315 | <literal>VAR3</literal>.</para></listitem> | |
316 | </varlistentry> | |
317 | ||
318 | <varlistentry> | |
319 | <term><varname>DefaultCPUAccounting=</varname></term> | |
320 | <term><varname>DefaultBlockIOAccounting=</varname></term> | |
321 | <term><varname>DefaultMemoryAccounting=</varname></term> | |
03a7b521 | 322 | <term><varname>DefaultTasksAccounting=</varname></term> |
798d3a52 ZJS |
323 | |
324 | <listitem><para>Configure the default resource accounting | |
325 | settings, as configured per-unit by | |
326 | <varname>CPUAccounting=</varname>, | |
03a7b521 LP |
327 | <varname>BlockIOAccounting=</varname>, |
328 | <varname>MemoryAccounting=</varname> and | |
329 | <varname>TasksAccounting=</varname>. See | |
798d3a52 | 330 | <citerefentry><refentrytitle>systemd.resource-control</refentrytitle><manvolnum>5</manvolnum></citerefentry> |
9ded9cd1 LP |
331 | for details on the per-unit |
332 | settings. <varname>DefaulTasksAccounting=</varname> defaults | |
333 | to on, the other three settings to off.</para></listitem> | |
798d3a52 ZJS |
334 | </varlistentry> |
335 | ||
0af20ea2 LP |
336 | <varlistentry> |
337 | <term><varname>DefaultTasksMax=</varname></term> | |
338 | ||
79baeeb9 | 339 | <listitem><para>Configure the default value for the per-unit <varname>TasksMax=</varname> setting. See |
0af20ea2 | 340 | <citerefentry><refentrytitle>systemd.resource-control</refentrytitle><manvolnum>5</manvolnum></citerefentry> |
79baeeb9 LP |
341 | for details. This setting applies to all unit types that support resource control settings, with the exception |
342 | of slice units. Defaults to 15%, which equals 4915 with the kernel's defaults on the host, but might be smaller | |
343 | in OS containers.</para></listitem> | |
0af20ea2 LP |
344 | </varlistentry> |
345 | ||
798d3a52 ZJS |
346 | <varlistentry> |
347 | <term><varname>DefaultLimitCPU=</varname></term> | |
348 | <term><varname>DefaultLimitFSIZE=</varname></term> | |
349 | <term><varname>DefaultLimitDATA=</varname></term> | |
350 | <term><varname>DefaultLimitSTACK=</varname></term> | |
351 | <term><varname>DefaultLimitCORE=</varname></term> | |
352 | <term><varname>DefaultLimitRSS=</varname></term> | |
353 | <term><varname>DefaultLimitNOFILE=</varname></term> | |
354 | <term><varname>DefaultLimitAS=</varname></term> | |
355 | <term><varname>DefaultLimitNPROC=</varname></term> | |
356 | <term><varname>DefaultLimitMEMLOCK=</varname></term> | |
357 | <term><varname>DefaultLimitLOCKS=</varname></term> | |
358 | <term><varname>DefaultLimitSIGPENDING=</varname></term> | |
359 | <term><varname>DefaultLimitMSGQUEUE=</varname></term> | |
360 | <term><varname>DefaultLimitNICE=</varname></term> | |
361 | <term><varname>DefaultLimitRTPRIO=</varname></term> | |
362 | <term><varname>DefaultLimitRTTIME=</varname></term> | |
363 | ||
364 | <listitem><para>These settings control various default | |
365 | resource limits for units. See | |
366 | <citerefentry><refentrytitle>setrlimit</refentrytitle><manvolnum>2</manvolnum></citerefentry> | |
91518d20 KZ |
367 | for details. The resource limit is possible to specify in two formats, |
368 | <option>value</option> to set soft and hard limits to the same value, | |
369 | or <option>soft:hard</option> to set both limits individually (e.g. DefaultLimitAS=4G:16G). | |
370 | Use the string <varname>infinity</varname> to | |
371 | configure no limit on a specific resource. The multiplicative | |
372 | suffixes K (=1024), M (=1024*1024) and so on for G, T, P and E | |
373 | may be used for resource limits measured in bytes | |
374 | (e.g. DefaultLimitAS=16G). For the limits referring to time values, | |
375 | the usual time units ms, s, min, h and so on may be used (see | |
376 | <citerefentry><refentrytitle>systemd.time</refentrytitle><manvolnum>7</manvolnum></citerefentry> | |
377 | for details). Note that if no time unit is specified for | |
378 | <varname>DefaultLimitCPU=</varname> the default unit of seconds is | |
379 | implied, while for <varname>DefaultLimitRTTIME=</varname> the default | |
380 | unit of microseconds is implied. Also, note that the effective | |
381 | granularity of the limits might influence their | |
382 | enforcement. For example, time limits specified for | |
383 | <varname>DefaultLimitCPU=</varname> will be rounded up implicitly to | |
384 | multiples of 1s. These settings may be overridden in individual units | |
385 | using the corresponding LimitXXX= directives. Note that these resource | |
386 | limits are only defaults for units, they are not applied to PID 1 | |
798d3a52 ZJS |
387 | itself.</para></listitem> |
388 | </varlistentry> | |
389 | </variablelist> | |
390 | </refsect1> | |
391 | ||
392 | <refsect1> | |
393 | <title>See Also</title> | |
394 | <para> | |
395 | <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>, | |
396 | <citerefentry><refentrytitle>systemd.directives</refentrytitle><manvolnum>7</manvolnum></citerefentry>, | |
397 | <citerefentry><refentrytitle>systemd.exec</refentrytitle><manvolnum>5</manvolnum></citerefentry>, | |
398 | <citerefentry><refentrytitle>systemd.service</refentrytitle><manvolnum>5</manvolnum></citerefentry>, | |
399 | <citerefentry project='man-pages'><refentrytitle>environ</refentrytitle><manvolnum>7</manvolnum></citerefentry>, | |
400 | <citerefentry project='man-pages'><refentrytitle>capabilities</refentrytitle><manvolnum>7</manvolnum></citerefentry> | |
401 | </para> | |
402 | </refsect1> | |
f3e219a2 LP |
403 | |
404 | </refentry> |