小白制作Linux开机流程图(老司机勿喷,欢迎讨论和指正错误),谢谢
参考文献:鸟哥的Linux私房菜,维基百科。
注释①:各个运行模式的文件
[[email protected] ~]# ll -d /usr/lib/systemd/system/runlevel*.target | cut -c 28- May 4 17:52 /usr/lib/systemd/system/runlevel0.target -> poweroff.target May 4 17:52 /usr/lib/systemd/system/runlevel1.target -> rescue.target May 4 17:52 /usr/lib/systemd/system/runlevel2.target -> multi-user.target May 4 17:52 /usr/lib/systemd/system/runlevel3.target -> multi-user.target May 4 17:52 /usr/lib/systemd/system/runlevel4.target -> multi-user.target May 4 17:52 /usr/lib/systemd/system/runlevel5.target -> graphical.target May 4 17:52 /usr/lib/systemd/system/runlevel6.target -> reboot.target
注释②:/usr/lib/systemd/system/graphical.target
[[email protected] ~]# cat /usr/lib/systemd/system/graphical.target[Unit]Description=Graphical InterfaceDocumentation=man:systemd.special(7)Requires=multi-user.targetAfter=multi-user.targetConflicts=rescue.targetWants=display-manager.serviceAllowIsolate=yes[Install]Alias=default.target 这表示graphical.target 必须要完成multi-user.target 之后才能够进行,而进行完graphical.target 之后,还得要启动display-manager.service 才行的意思。 |
注释③:
#看看系统预设要载入的unit有哪些? [[email protected] ~]# ls /usr/lib/systemd/system/multi-user.target.wants brandbot.path plymouth-quit.service systemd-logind.servicedbus.service plymouth-quit-wait.service systemd-user-sessions.servicegetty.target systemd-ask-password-wall.path #使用者自订要载入的unit又有哪些呢? [[email protected] ~]# ls /etc/systemd/system/multi-user.target.wantsabrt-ccpp.service crond.service mdmonitor.service sshd.serviceabrtd.service hypervkvpd.service ModemManager.service sysstat.serviceabrt-oops.service hypervvssd.service NetworkManager.service tuned.serviceabrt-vmcore.service irqbalance.service postfix.service vmtoolsd.serviceabrt-xorg.service kdump.service remote-fs.target vsftpd2.service atd.service ksm.service rngd.service vsftpd.service auditd.service ksmtuned.service rsyslog.servicebackup2.timer libstoragemgmt.service smartd.servicebackup.timer libvirtd.service sshd2.service
时间: 2024-10-13 14:36:21