SYSTEMD(1) systemd SYSTEMD(1) NAME systemd, init - systemd SYNOPSIS systemd [OPTIONS...] init [OPTIONS...] {COMMAND} systemd Linux (PID=1) SysV systemd init "PID!=1" telinit init telinit telinit(8) systemd system.conf system.conf.d systemd user.conf user.conf.d systemd-system.conf(5) --test --dump-configuration-items (unit) "unit" --unit= (unit) default.target --system, --user --system ("PID!=1") --user ("PID=1") --system --test --dump-core systemd.dump_core= ("") --crash-vt=VT (VT) 1-63 yes no systemd.crash_vt= ("") --crash-shell shell systemd.crash_shell= ("") --crash-reboot systemd.crash_reboot= ("") --confirm-spawn --show-status= yes --log-target= console, journal, kmsg, journal-or-kmsg, null () --log-level= syslog(3) emerg, alert, crit, err, warning, notice, info, debug () --log-color= yes --log-location= yes --default-standard-output=, --default-standard-error= service socket StandardOutput= StandardError= ( systemd.exec(5) ) inherit, null, tty, journal, journal+console, syslog, syslog+console, kmsg, kmsg+console () --default-standard-output= journal --default-standard-error= inherit --machine-id= machine-id -h, --help --version systemd (unit) ( systemd.unit(5) ) () (active)(inactive) (activating)(deactivating) (failed) () (failed) "" 1. service systemd.service(5) 2. socket (UNIX)(INET/INET6)FIFO "" systemd.socket(5) daemon(7) 3. target systemd.target(5) 4. device device udev device systemd.device(5) 5. mount ( /etc/fstab ) systemd.mount(5) 6. automount autofs systemd.automount(5) 7. timer atd, crond systemd.timer(5) 8. swap mount systemd.swap(5) 9. path systemd.path(5) 10. slice CGroup ( service scope ) systemd.slice(5) 11. scope service systemd D-bus systemd.scope(5) systemd.special(7) systemd ( Requires= Conflicts= ) ( After= Before= ) ()() foo.service (Requires) bar.service systemd () systemd ""(job)"" systemd default.target graphical.target () multi-user.target ( graphical.target ) systemd.special(7) systemd cgroups[1] cgroups /sys/fs/cgroup/systemd/ systemd-cgls(1) ps(1) (ps xawf -eo pid,user,cgroup,args) systemd SysV init SysV init SysV /dev/initctl SysV /etc/fstab utmp Unix systemd systemd (want) systemd systemd hostname loopback /sys /proc systemctl reload ... systemd systemd.generator(7) systemd Container Interface[2] initrd systemd initrd Interface[3] systemd pkg-config systemd --variable=systemdsystemunitdir ( /usr/lib/systemd/system) systemd /usr/local/lib/systemd/system /usr/lib/systemd/system pkg-config systemd --variable=systemdsystemconfdir ( /etc/systemd/system) systemctl(1) enable disable systemd.unit(5) pkg-config systemd --variable=systemduserunitdir (/usr/lib/systemd/user) XDG Base Directory specification[4] systemd $XDG_DATA_HOME/systemd/user( $XDG_DATA_HOME ) ~/.local/share/systemd/user( $XDG_DATA_HOME ) () pkg-config systemd --variable=systemduserconfdir (/etc/systemd/user) systemctl(1) enable disable ()() systemd.unit(5) SysV() systemd SysV ( .service ) SysV() systemd SysV SIGTERM systemd systemctl daemon-reexec systemd exit.target systemctl --user start exit.target SIGINT systemd ctrl-alt-del.target systemctl start ctl-alt-del.target Ctrl-Alt-Del 27 7 Ctrl-Alt-Del systemd SIGTERM SIGWINCH systemd kbrequest.target systemctl start kbrequest.target systemd SIGPWR systemd sigpwr.target systemctl start sigpwr.target SIGUSR1 systemd D-Bus SIGUSR2 systemd systemd-analyze dump SIGHUP systemctl daemon-reload SIGRTMIN+0 default.target systemctl start default.target SIGRTMIN+1 rescue.target systemctl isolate rescue.target SIGRTMIN+2 emergency.target systemctl isolate emergency.target SIGRTMIN+3 halt.target systemctl start halt.target SIGRTMIN+4 poweroff.target systemctl start poweroff.target SIGRTMIN+5 reboot.target systemctl start reboot.target SIGRTMIN+6 kexec kexec.target systemctl start kexec.target SIGRTMIN+13 SIGRTMIN+14 SIGRTMIN+15 SIGRTMIN+16 kexec SIGRTMIN+20 systemd.show_status=1 SIGRTMIN+21 systemd.show_status=0 SIGRTMIN+22, SIGRTMIN+23 "debug"(22) "info"(23) systemd.log_level=debug systemd.log_level=info SIGRTMIN+24 systemd ( --user ) SIGRTMIN+26, SIGRTMIN+27, SIGRTMIN+28 "journal-or-kmsg"(26) "console"(27) "kmsg"(28) systemd.log_target=journal-or-kmsg systemd.log_target=console systemd.log_target=kmsg $SYSTEMD_LOG_LEVEL systemd --log-level= $SYSTEMD_LOG_TARGET systemd --log-target= $SYSTEMD_LOG_COLOR systemd --log-color= $SYSTEMD_LOG_LOCATION systemd (code location) --log-location= $XDG_CONFIG_HOME, $XDG_DATA_HOME systemd XDG Base Directory specification[4] .{d,wants,requires}/ $SYSTEMD_UNIT_PATH $SYSTEMD_SYSVINIT_PATH SysV $SYSTEMD_SYSVRCND_PATH SysV $SYSTEMD_COLORS $LISTEN_PID, $LISTEN_FDS, $LISTEN_FDNAMES systemd sd_listen_fds(3) $NOTIFY_SOCKET systemd sd_notify(3) systemd [5] systemd.unit=, rd.systemd.unit= default.target ( rescue.target emergency.target ) systemd.special(7) "rd." initrd(initial RAM disk) systemd.dump_core= yes systemd(PID=1) systemd.crash_chvt= 1-63 systemd(PID=1) yes no() systemd.crash_shell= yes systemd(PID=1) 10 shell no shell shell systemd.crash_reboot= yes systemd(PID=1) 10 no () systemd.crash_shell=yes shell systemd.confirm_spawn= yes systemd(PID=1) no systemd.show_status= yes(), no(), auto() auto no quiet auto yes systemd.log_target=, systemd.log_level=, systemd.log_color=, systemd.log_location= $SYSTEMD_LOG_TARGET, $SYSTEMD_LOG_LEVEL, $SYSTEMD_LOG_COLOR, $SYSTEMD_LOG_LOCATION systemd.default_standard_output=, systemd.default_standard_error= --default-standard-output= --default-standard-error= systemd.setenv= "VARIABLE=VALUE" systemd.machine_id= 3216 machine-id machine-id quiet systemd.show_status=no systemd debug systemd.log_level=debug systemd emergency, rd.emergency, -b systemd.unit=emergency.target rd.systemd.unit=emergency.target rescue, rd.rescue, single, s, S, 1 systemd.unit=rescue.target rd.systemd.unit=rescue.target 2, 3, 4, 5 SysV systemd.unit=runlevel2.target, systemd.unit=runlevel3.target, systemd.unit=runlevel4.target, systemd.unit=runlevel5.target, locale.LANG=, locale.LANGUAGE=, locale.LC_CTYPE=, locale.LC_NUMERIC=, locale.LC_TIME=, locale.LC_COLLATE=, locale.LC_MONETARY=, locale.LC_MESSAGES=, locale.LC_PAPER=, locale.LC_NAME=, locale.LC_ADDRESS=, locale.LC_TELEPHONE=, locale.LC_MEASUREMENT=, locale.LC_IDENTIFICATION= locale /etc/locale.conf locale.conf(5) locale(7) kernel-command-line(7) SOCKETS FIFOS /run/systemd/notify UNIX socket sd_notify(3) /run/systemd/private systemctl(1) systemd UNIX socket /dev/initctl systemd-initctl.service SysV (FIFO) systemd Homepage[6], systemd-system.conf(5), locale.conf(5), systemctl(1), journalctl(1), systemd-notify(1), daemon(7), sd- daemon(3), systemd.unit(5), systemd.special(5), pkg-config(1), kernel- command-line(7), bootup(7), systemd.directives(7) NOTES 1. cgroups https://www.kernel.org/doc/Documentation/cgroups/cgroups.txt 2. Container Interface http://www.freedesktop.org/wiki/Software/systemd/ContainerInterface 3. initrd Interface http://www.freedesktop.org/wiki/Software/systemd/InitrdInterface 4. XDG Base Directory specification http://standards.freedesktop.org/basedir-spec/basedir-spec- latest.html 5. systemd Linux systemd () systemd Linux /proc/cmdline 6. systemd Homepage http://www.freedesktop.org/wiki/Software/systemd/ man http://www.jinbuguo.com man https://github.com/man-pages-zh/manpages- zh systemd 231 SYSTEMD(1)