AlmaLinux 9 伺服器作業系統安裝和設定
系統安裝
系統模式
使用 AlmaLinux 9 安裝檔開機會有下述三種模式:
- Install AlmaLinux 9.2:正常安裝系統流程。
- Test this media & install AlmaLinux 9.2:測試媒體後在進入安裝系統流程。
- Troubleshooting:進入【除錯模式】,能夠救授 AlmaLinux 系統和執行記憶體測試 (Run a memory test) ...。

選擇系統語言

選擇軟體
系統預設選擇安裝【含有 GUI 的伺服器】,也就是像 Windows 作業系統一樣有圖形使用者介面,但作為伺服器用途建議選擇【Server】的 CLI (命今列介面),而且少了 GUI 效率更佳 。

- 點選【Server】。
- 點擊【完成】。

磁碟分割與檔案系統
/home、swap 和 / 這三個【掛載點】將來容量有可能會變動,因此【裝置類型】設定為可以彈性增加和減少檔案系統容量的 LVM。
掛載點 | 裝置類型 | 檔案系統 | 建議容量 |
---|---|---|---|
biosboot | 標準分割區 | BIOS Boot | 2MB |
/boot | 標準分割區 | ext4 | 1GB |
/home | LVM | xfs | 5GB 以上 |
swap | LVM | swap | 參考 Red Hat swap 建議 |
/ | LVM | xfs | 剩餘容量 |
點選【安裝目標位置】,就是要將系統安裝到哪個磁碟。

- 勾選系統要安裝的磁碟。
- 點選【自動】或【自訂】方式來自行手動分割磁碟空間。
- 點擊【完成】。

Root 密碼與新增使用者
設定 Root 密碼。


建立使用者。


安裝
點擊【開始安裝】。



其它
安裝 Cockpit
Cockpit 是基於 Web 介面的應用程式,可用來管理伺服器並監視和調整系統資源。
設定 Cockpit 開機自動啟用 (enable) 且立即啟用 (--now):
systemctl enable --now cockpit.socket
firewall 預設已允許 cockpit (port 9090):
firewall-cmd --list-all
public (active) target: default icmp-block-inversion: no interfaces: enp0s3 sources: services: cockpit dhcpv6-client ssh ... 以下省略 ...
開啟瀏覽器輸入 IP:9090 即可連結到 Cockpit。


安裝 Cockpit 虛擬機
dnf install cockpit-machines
dnf install libvirt
systemctl enable --now libvirtd


本著作係採用創用 CC 姓名標示-相同方式分享 3.0 台灣 授權條款授權.