我在 preseed.cfg 文件中编写了以下几行,用于无人值守的 Ubuntu 18.04 桌面安装。
# Packages, Mirrors, Image
d-i base-installer/kernel/override-image string linux-server
d-i base-installer/kernel/override-image string linux-image-amd64
d-i mirror/country string US
d-i mirror/http/proxy string
d-i apt-setup/restricted boolean true
d-i apt-setup/universe boolean true
d-i pkgsel/install-language-support boolean false
d-i pkgsel/include string openssh-server build-essential
tasksel tasksel/first multiselect ubuntu-desktop
安装后,我运行dpkg -l | grep ssh
后只看到libssh-4
和openssh-client
包。我没有发现d-i
命令有什么问题。有什么办法可以解决这个问题吗?
答案1
如果您使用 Ubiquity 安装程序(桌面图像),那么 wiki 指出pkgsel
,tasksel
预置设置将被忽略。
从https://wiki.ubuntu.com/UbiquityAutomation
Preseeding keys for the following installer components will not be used in Ubiquity, usually because they do not fit with Ubiquity's mode of operation:
netcfg
LVM and RAID partitioning
base-installer
pkgsel/tasksel
finish-install