Sumary:因為在Fedora中沒有/etc/initab文件我們不方便從這裡設置它的runlevel target,但是Linux又給我們提供了一個強悍的工具systemd,我們可以用system來鏈接默認的啟動級別,所以開始吧!
一、實現代碼
(1)刪除目標鏈接並創建新的符號鏈接(從命令行啟動)
ln -sf /lib/systemd/system/multi-user.target /etc/systemd/system/default.target
(2)從圖形界面啟動
把multi-user.target替換為graphical.target即可。
二、代碼解釋
ln命令
ln命令是一個在文件之間建立鏈接的命令,默認情況是硬鏈接(hard link),我們要用的是符號鏈接(symboli link),它可以為在不同文件系統中文件創建鏈接。
Options:
-s 創建符號鏈接
-f 刪除已經存在的同名鏈接
one of the Usages:ln [被鏈接目標] [鏈接文件或目錄]
Example:
ln -s xx yy
//為xx創建一個符號鏈接yy
搞定!
For more details,please google the key words
Linux 引導方式systemd upstart sysV http://www.linuxidc.com/Linux/2014-01/95555.htm
為什麼systemd會被如此迅速的采用? http://www.linuxidc.com/Linux/2014-08/105789.htm
systemd 與 sysVinit 彩版對照表 http://www.linuxidc.com/Linux/2014-09/106455.htm
Linux Systemd——在RHEL/CentOS 7中啟動/停止/重啟服務 http://www.linuxidc.com/Linux/2014-08/105975.htm
太有用了!用systemd命令來管理Linux系統! http://www.linuxidc.com/Linux/2014-09/106490.htm
淺析 Linux 初始化 init 系統,第 3 部分: Systemd http://www.linuxidc.com/Linux/2014-12/110383.htm
更多Fedora相關信息見Fedora 專題頁面 http://www.linuxidc.com/topicnews.aspx?tid=5