1 <?xml version='1.0'?> <!--*-nxml-*-->
2 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
3 "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
6 This file is part of systemd.
8 Copyright 2010 Lennart Poettering
10 systemd is free software; you can redistribute it and/or modify it
11 under the terms of the GNU General Public License as published by
12 the Free Software Foundation; either version 2 of the License, or
13 (at your option) any later version.
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
18 General Public License for more details.
20 You should have received a copy of the GNU General Public License
21 along with systemd; If not, see <http://www.gnu.org/licenses/>.
24 <refentry id="systemd.special">
27 <title>systemd.special</title>
28 <productname>systemd</productname>
32 <contrib>Developer</contrib>
33 <firstname>Lennart</firstname>
34 <surname>Poettering</surname>
35 <email>lennart@poettering.net</email>
41 <refentrytitle>systemd.special</refentrytitle>
42 <manvolnum>7</manvolnum>
46 <refname>systemd.special</refname>
47 <refpurpose>special systemd units</refpurpose>
51 <para><filename>basic.target</filename>,
52 <filename>ctrl-alt-del.target</filename>,
53 <filename>dbus.service</filename>,
54 <filename>default.target</filename>,
55 <filename>display-manager.service</filename>,
56 <filename>emergency.target</filename>,
57 <filename>exit.service</filename>,
58 <filename>graphical.target</filename>,
59 <filename>halt.target</filename>,
60 <filename>kbrequest.target</filename>,
61 <filename>local-fs.target</filename>,
62 <filename>mail-transfer-agent.target</filename>,
63 <filename>multi-user.target</filename>,
64 <filename>network.target</filename>,
65 <filename>nss-lookup.target</filename>,
66 <filename>poweroff.target</filename>,
67 <filename>reboot.target</filename>,
68 <filename>remote-fs.target</filename>,
69 <filename>rescue.target</filename>,
70 <filename>rpcbind.target</filename>,
71 <filename>rtc-set.target</filename>,
72 <filename>runlevel2.target</filename>,
73 <filename>runlevel3.target</filename>,
74 <filename>runlevel4.target</filename>,
75 <filename>runlevel5.target</filename>,
76 <filename>shutdown.target</filename>,
77 <filename>sigpwr.target</filename>,
78 <filename>sockets.target</filename>,
79 <filename>swap.target</filename>,
80 <filename>sysinit.target</filename>,
81 <filename>@SPECIAL_SYSLOG_SERVICE@</filename>,
82 <filename>syslog.target</filename>,
83 <filename>systemd-initctl.service</filename>,
84 <filename>systemd-initctl.socket</filename>,
85 <filename>systemd-logger.service</filename>,
86 <filename>systemd-logger.socket</filename>,
87 <filename>umount.target</filename></para>
91 <title>Description</title>
93 <para>A few units are treated specially by
94 systemd. They have special internal semantics and
95 cannot be renamed.</para>
99 <title>Special System Units</title>
103 <term><filename>basic.target</filename></term>
105 <para>A special target unit
106 covering early boot-up.</para>
107 <para>systemd automatically
108 adds dependencies of the types
109 Requires and After for this
110 target unit to all SysV
111 service units configured for
112 runlevel 1 to 5.</para>
113 <para>Usually this should pull-in
114 all sockets, mount points,
115 swap devices and other basic
116 initialization necessary for
118 daemons. Most normal daemons
119 should have dependencies of
120 type After and Requires on
125 <term><filename>ctrl-alt-del.target</filename></term>
127 <para>systemd starts this
129 Control+Alt+Del is pressed on
130 the console. Usually this
131 should be aliased (symlinked)
133 <filename>reboot.target</filename>.</para>
137 <term><filename>dbus.service</filename></term>
139 <para>A special unit for the
140 D-Bus system bus. As soon as
141 this service is fully started
142 up systemd will connect to it
148 <term><filename>default.target</filename></term>
150 <para>The default unit systemd
151 starts at bootup. Usually this
152 should be aliased (symlinked)
154 <filename>multi-user.target</filename>
156 <filename>graphical.target</filename>.</para>
157 <para>The default unit systemd
158 starts at bootup can be
160 <varname>systemd.default=</varname>
161 kernel command line option.</para>
165 <term><filename>display-manager.service</filename></term>
167 <para>The display manager
168 service. Usually this should
169 be aliased (symlinked) to
170 <filename>xdm.service</filename>
171 or a similar display manager
173 <para>systemd automatically
174 adds dependencies of type
175 After for this target unit to
176 all SysV init script service
177 units with a LSB header
179 <literal>$x-display-manager</literal>
180 facility, for compatibility
185 <term><filename>emergency.target</filename></term>
187 <para>A special target unit
188 that starts an emergency
190 console. This unit is supposed
191 to be used with the kernel
193 <varname>systemd.default=</varname>
194 and has otherwise little use.
199 <term><filename>graphical.target</filename></term>
201 <para>A special target unit
202 for setting up a graphical
203 login screen. This pulls in
204 <filename>multi-user.target</filename>.</para>
206 <para>Units that are needed
207 for graphical login shall add
208 Wants dependencies for their
209 unit to this unit (or
210 <filename>multi-user.target</filename>)
211 during installation.</para>
215 <term><filename>halt.target</filename></term>
217 <para>A special target unit
218 for shutting down and halting the system.</para>
220 <para>Applications wanting to
221 halt the system should start
226 <term><filename>kbrequest.target</filename></term>
228 <para>systemd starts this
229 target whenever Alt+ArrowUp is
230 pressed on the console. This
231 is a good candidate to be
232 aliased (symlinked) to
233 <filename>rescue.target</filename>.</para>
237 <term><filename>local-fs.target</filename></term>
239 <para>systemd automatically
240 adds dependencies of type
241 After to all mount units that
242 refer to local mount points
243 for this target unit. In
244 addition, systemd adds
245 dependencies of type Wants to
246 this target unit for those
248 <filename>/etc/fstab</filename>
250 <option>auto</option> and
251 <option>comment=systemd.mount</option>
252 mount options set.</para>
254 <para>systemd automatically
255 adds dependencies of type
256 After for this target unit to
257 all SysV init script service
258 units with an LSB header
260 <literal>$local_fs</literal>
265 <term><filename>mail-transfer-agent.target</filename></term>
267 <para>The mail transfer agent
268 (MTA) service. Usually this
269 should pull-in all units
271 sending/receiving mails on the
274 <para>systemd automatically
275 adds dependencies of type
276 After for this target unit to
277 all SysV init script service
278 units with an LSB header
280 <literal>$mail-transfer-argent</literal>
282 <literal>$mail-transport-agent</literal>
283 facilities, for compatibility
288 <term><filename>multi-user.target</filename></term>
290 <para>A special target unit
291 for setting up a multi-user
292 system (non-graphical). This
294 <filename>graphical.target</filename>.</para>
296 <para>Units that are needed
297 for a multi-user system shall
298 add Wants dependencies to
299 this unit for their unit during
304 <term><filename>network.target</filename></term>
306 <para>systemd automatically
307 adds dependencies of type
308 After for this target unit to
309 all SysV init script service
310 units with an LSB header
312 <literal>$network</literal>
317 <term><filename>nss-lookup.target</filename></term>
319 <para>systemd automatically
320 adds dependencies of type
321 After for this target unit to
322 all SysV init script service
323 units with an LSB header
325 <literal>$named</literal>
330 <term><filename>poweroff.target</filename></term>
332 <para>A special target unit
333 for shutting down and powering off the system.</para>
335 <para>Applications wanting to
336 power off the system should start
339 <para><filename>runlevel0.target</filename>
340 is an alias for this target
341 unit, for compatibility with SysV.</para>
345 <term><filename>reboot.target</filename></term>
347 <para>A special target unit
348 for shutting down and rebooting the system.</para>
350 <para>Applications wanting to
351 reboot the system should start
354 <para><filename>runlevel6.target</filename>
355 is an alias for this target
356 unit, for compatibility with SysV.</para>
360 <term><filename>remote-fs.target</filename></term>
363 <filename>local-fs.target</filename>,
367 <para>systemd automatically
368 adds dependencies of type
369 After for this target unit to
370 all SysV init script service
371 units with an LSB header
373 <literal>$remote_fs</literal>
378 <term><filename>rescue.target</filename></term>
380 <para>A special target unit
381 for setting up the base system
382 and a rescue shell.</para>
384 <para><filename>runlevel1.target</filename>
385 is an alias for this target
386 unit, for compatibility with SysV.</para>
390 <term><filename>rpcbind.target</filename></term>
392 <para>systemd automatically
393 adds dependencies of type
394 After for this target unit to
395 all SysV init script service
396 units with an LSB header
398 <literal>$rpcbind</literal>
403 <term><filename>rtc-set.target</filename></term>
405 <para>systemd automatically
406 adds dependencies of type
407 After for this target unit to
408 all SysV init script service
409 units with an LSB header
411 <literal>$time</literal>
416 <term><filename>runlevel2.target</filename></term>
418 <para>This is a target that is
419 called whever the SysV
420 compatibility code asks for
421 runlevel 2. It is a good idea
422 to make this an alias for
424 <filename>multi-user.target</filename>.</para>
428 <term><filename>runlevel3.target</filename></term>
430 <para>This is a target that is
431 called whever the SysV
432 compatibility code asks for
433 runlevel 3. It is a good idea
434 to make this an alias for
436 <filename>multi-user.target</filename>
438 <filename>graphical.target</filename>.</para>
442 <term><filename>runlevel4.target</filename></term>
444 <para>This is a target that is
445 called whever the SysV
446 compatibility code asks for
447 runlevel 4. It is a good idea
448 to make this an alias for
450 <filename>multi-user.target</filename>
452 <filename>graphical.target</filename>.</para>
456 <term><filename>runlevel5.target</filename></term>
458 <para>This is a target that is
459 called whever the SysV
460 compatibility code asks for
461 runlevel 5. It is a good idea
462 to make this an alias for
464 <filename>multi-user.target</filename>
466 <filename>graphical.target</filename>.</para>
470 <term><filename>shutdown.target</filename></term>
472 <para>A special target unit
473 that terminates the services
474 on system shutdown.</para>
476 <para>Services that shall be
477 terminated on system shutdown
479 dependencies to this unit for
480 their service unit, which is
482 <varname>DefaultDependencies=yes</varname>
483 is set (the default).</para>
485 <para>systemd automatically
486 adds dependencies of type
487 Conflicts to this target unit
488 for all SysV init script
489 service units that shall be
490 terminated in SysV runlevels 0
495 <term><filename>sigpwr.target</filename></term>
497 <para>A special target that is
498 started when systemd receives
499 the SIGPWR process signal,
500 which is normally sent by the
501 kernel or UPS daemons when
506 <term><filename>sockets.target</filename></term>
508 <para>A special target unit
509 that sets up all service
512 <para>Services that can be
513 socket-activated shall add
514 Wants dependencies to this
515 unit for their socket unit
516 during installation.</para>
520 <term><filename>swap.target</filename></term>
523 <filename>local-fs.target</filename>, but for swap
529 <term><filename>sysinit.target</filename></term>
531 <para>A special target unit
532 covering early boot-up scripts.</para>
533 <para>systemd automatically
534 adds dependencies of the types
535 Wants and After for all
536 SysV service units configured
537 for runlevels that are not 0
538 to 6 to this target unit.
539 This covers the special
540 boot-up runlevels some
541 distributions have, such as S
546 <term><filename>@SPECIAL_SYSLOG_SERVICE@</filename></term>
548 <para>A special unit for the
549 syslog daemon. As soon as
550 this service is fully started
551 up systemd will connect to it
552 and use it for logging if it
553 has been configured for
556 <para>Units should generally
557 avoid depending on this unit
558 directly and instead refer to
560 <filename>syslog.target</filename>
561 unit instead, which pulls this
562 one in directly or indirectly
563 via socket-based activation.</para>
567 <term><filename>syslog.target</filename></term>
569 <para>systemd automatically
570 adds dependencies of type
571 After for this target unit to
572 all SysV init script service
573 units with an LSB header
575 <literal>$syslog</literal>
578 <para>Administrators should
579 ensure that this target pulls
580 in a service unit with the
582 <filename>@SPECIAL_SYSLOG_SERVICE@</filename>
583 (or a socket unit that
589 <term><filename>systemd-initctl.service</filename></term>
592 compatibility with the SysV
593 /dev/initctl file system FIFO
594 for communication with the
597 socket-activated service, see
598 <filename>system-initctl.socket</filename>.</para>
602 <term><filename>systemd-initctl.socket</filename></term>
604 <para>Socket activation unit
606 <filename>system-initctl.service</filename>.</para>
610 <term><filename>systemd-logger.service</filename></term>
612 <para>This is internally used
613 by systemd to provide syslog
614 logging to the processes it
617 socket-activated service, see
618 <filename>system-logger.socket</filename>.</para>
622 <term><filename>systemd-logger.socket</filename></term>
624 <para>Socket activation unit
626 <filename>system-logger.service</filename>. systemd
627 will automatically add
628 dependencies of types Requires
629 and After to all units that
630 have been configured for
631 stdout or stderr to be
632 connected to syslog or the
633 kernel log buffer.</para>
637 <term><filename>systemd-shutdownd.service</filename></term>
639 <para>This is internally used
641 <citerefentry><refentrytitle>shutdown</refentrytitle><manvolnum>8</manvolnum></citerefentry>
642 to implement delayed shutdowns.</para>
644 socket-activated service, see
645 <filename>system-shutdownd.socket</filename>.</para>
649 <term><filename>systemd-shutdownd.socket</filename></term>
651 <para>Socket activation unit
653 <filename>system-shutdownd.service</filename>.</para>
657 <term><filename>umount.target</filename></term>
659 <para>A special target unit
660 that umounts all mount and
661 automount points on system
664 <para>Mounts that shall be
665 unmounted on system shutdown
667 dependencies to this unit for
668 their mount unit, which is
670 <varname>DefaultDependencies=yes</varname>
671 is set (the default).</para>
678 <title>Special User Units</title>
680 <para>When systemd runs as a user instance, the
681 following special units are available, which have
682 similar definitions as their system counterparts:
683 <filename>default.target</filename>,
684 <filename>local-fs.target</filename>,
685 <filename>remote-fs.target</filename>,
686 <filename>shutdown.target</filename>,
687 <filename>sockets.target</filename>,
688 <filename>swap.target</filename>.</para>
690 <para>In addition the following special unit is
691 understood only when systemd runs as service instance:</para>
695 <term><filename>exit.service</filename></term>
697 <para>A special service unit
698 for shutting down the
699 user service manager.</para>
701 <para>Applications wanting to
702 terminate the user service
703 manager should start this
704 unit. If systemd receives
705 SIGTERM or SIGINT when running
706 as user service daemon it will
707 start this unit.</para>
709 <para>Normally, this pulls in
710 <filename>shutdown.target</filename>
711 which in turn should be
712 conflicted by all units that
713 want to be shut down on
714 user service manager exit.</para>
721 <title>See Also</title>
723 <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
724 <citerefentry><refentrytitle>systemd.service</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
725 <citerefentry><refentrytitle>systemd.socket</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
726 <citerefentry><refentrytitle>systemd.target</refentrytitle><manvolnum>5</manvolnum></citerefentry>