Ubuntu 服务器 14.04 安装的 PXE 设置产生问题
PXE setup for Ubuntu server 14.04 installation creates issue
我知道 Whosebug 上已经有人问过这个问题,但我对提供的答案不满意。
PXE use part of my kickstart file
我的设置:
Ubuntu 桌面 14.04 LTS (x86) 与 PXE (TFTP + Apache) 设置。
已安装 Ubuntu 服务器映像 14.04.2 并使用 ks.cfg
和 preseed.cfg
创建了完全无人值守的安装
ks.cfg的配置:
#Generated by Kickstart Configurator
preseed/url=http://10.10.2.199/ubuntu/preseed.cfg
#platform=x86
#System language
lang en_US
#Language modules to install
langsupport en_US
#System keyboard
keyboard us
#System mouse
mouse
#System timezone
timezone Asia/Kolkata
#Root password
rootpw --disabled
#Initial user
user uadmin --fullname "uadmin" --iscrypted --password $SoMF.HMn$AIG0ecMNwJ4SU2D1/CRg6/
#Reboot after installation
reboot
#Use text mode install
text
#Install OS instead of upgrade
install
#Use Web installation
url --url http://10.10.2.199/ubuntu
#System bootloader configuration
bootloader --location=mbr
#Clear the Master Boot Record
zerombr yes
#Partition clearing information
clearpart --all --initlabel
#Disk partitioning information
clearpart --all
#part swap --size 4098
#ignoredisk --only-use=sda
#clearpart --all --linux --drives=sda
#part / --fstype ext4 --size 1 --grow
#System authorization infomation
auth --useshadow --enablemd5
#Network information
network --bootproto=dhcp --device=eth0
#Firewall configuration
firewall --disabled
#Do not configure the X Window System
skipx
%packages
# Since I don't install recommended it leaves out some things that should
# probably be installed like openssl and python 2.7
ca-certificates
openssl
python
wget
tcpd
# End all the recommended packages that are still useful
openssh-server
#open-vm-tools --no-install-recommends
curl
screen
vim
#copy contents to /etc/apt/sources.list
echo " #
# deb cdrom:[Ubuntu-Server 12.04.4 LTS _Precise Pangolin_ - Release amd64 (20140204)]/ dists/precise/main/binary-i386/
# deb cdrom:[Ubuntu-Server 12.04.4 LTS _Precise Pangolin_ - Release amd64 (20140204)]/ dists/precise/restricted/binary-i386/
# deb cdrom:[Ubuntu-Server 12.04.4 LTS _Precise Pangolin_ - Release amd64 (20140204)]/ precise main restricted
# deb cdrom:[Ubuntu-Server 12.04.4 LTS _Precise Pangolin_ - Release amd64 (20140204)]/ dists/precise/main/binary-i386/
# deb cdrom:[Ubuntu-Server 12.04.4 LTS _Precise Pangolin_ - Release amd64 (20140204)]/ dists/precise/restricted/binary-i386/
# deb cdrom:[Ubuntu-Server 12.04.4 LTS _Precise Pangolin_ - Release amd64 (20140204)]/ precise main restricted
# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://in.archive.ubuntu.com/ubuntu/ trusty main restricted
deb-src http://in.archive.ubuntu.com/ubuntu/ trusty main restricted
## Major bug fix updates produced after the final release of the
## distribution.
deb http://in.archive.ubuntu.com/ubuntu/ trusty-updates main restricted
deb-src http://in.archive.ubuntu.com/ubuntu/ trusty-updates main restricted
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team. Also, please note that software in universe WILL NOT receive any
## review or updates from the Ubuntu security team.
deb http://in.archive.ubuntu.com/ubuntu/ trusty universe
deb-src http://in.archive.ubuntu.com/ubuntu/ trusty universe
deb http://in.archive.ubuntu.com/ubuntu/ trusty-updates universe
deb-src http://in.archive.ubuntu.com/ubuntu/ trusty-updates universe
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team, and may not be under a free licence. Please satisfy yourself as to
## your rights to use the software. Also, please note that software in
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.
deb http://in.archive.ubuntu.com/ubuntu/ trusty multiverse
deb-src http://in.archive.ubuntu.com/ubuntu/ trusty multiverse
deb http://in.archive.ubuntu.com/ubuntu/ trusty-updates multiverse
deb-src http://in.archive.ubuntu.com/ubuntu/ trusty-updates multiverse
## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
deb http://in.archive.ubuntu.com/ubuntu/ trusty-backports main restricted universe multiverse
deb-src http://in.archive.ubuntu.com/ubuntu/ trusty-backports main restricted universe multiverse
deb http://security.ubuntu.com/ubuntu trusty-security main restricted
deb-src http://security.ubuntu.com/ubuntu trusty-security main restricted
deb http://security.ubuntu.com/ubuntu trusty-security universe
deb-src http://security.ubuntu.com/ubuntu trusty-security universe
deb http://security.ubuntu.com/ubuntu trusty-security multiverse
deb-src http://security.ubuntu.com/ubuntu trusty-security multiverse
## Uncomment the following two lines to add software from Canonical's
## 'partner' repository.
## This software is not part of Ubuntu, but is offered by Canonical and the
## respective vendors as a service to Ubuntu users.
# deb http://archive.canonical.com/ubuntu precise partner
# deb-src http://archive.canonical.com/ubuntu precise partner
## Uncomment the following two lines to add software from Ubuntu's
## 'extras' repository.
## This software is not part of Ubuntu, but is offered by third-party
## developers who want to ship their latest software.
# deb http://extras.ubuntu.com/ubuntu precise main
# deb-src http://extras.ubuntu.com/ubuntu precise main "
> /etc/apt/sources.list
preseed.cfg
配置:
Options to set on the command line
#preseed/url=http://10.10.2.199/ubuntu/preseed.cfg
#onsole-setup/ask_detect=false
#console-setup/layoutcode=us
#netcfg/get_hostname=dh5
#netcfg/get_domain=wb.com
#initrd=/install/initrd.gz quiet --
#d-i ubuntu-installer/locale string en_US
#d-i console-setup/ask_detect boolean false
#d-i console-setup/layoutcode string us
#d-i netcfg/get_hostname string dh5
#d-i netcfg/get_domain string wb.com
#d-i netcfg/choose_interface select auto
#d-i netcfg/wireless_wep string
#d-i base-installer/kernel/override-image string linux-server
#d-i clock-setup/utc-auto boolean true
#d-i clock-setup/utc boolean true
#d-i time/zone string US/Pacific
#d-i clock-setup/ntp boolean true
#d-i mirror/country string US
#d-i mirror/http/proxy string
#d-i pkgsel/install-language-support boolean false
#tasksel tasksel/first multiselect standard, ubuntu-server
#d-i partman-auto/method string regular
#d-i partman-auto/purge_lvm_from_device boolean true
#d-i partman-lvm/confirm boolean true
#d-i partman-auto/choose_recipe select atomic
#d-i partman/confirm_write_new_label boolean true
#d-i partman/choose_partition select finish
#d-i partman/confirm boolean true
#d-i partman/confirm_write_new_label boolean true
#d-i partman/choose_partition select \
# Finish partitioning and write changes to disk
#d-i partman/confirm boolean true
#d-i passwd/user-fullname string uadmin User
#d-i passwd/username string uadmin
#d-i passwd/user-password password password
#d-i passwd/user-password-again password password
#d-i partman/unmount_active boolean true
#d-i preseed/early_command string umount /media
#d-i grub-installer/only_debian boolean true
#d-i grub-installer/with_other_os boolean true
#d-i finish-install/reboot_in_progress note
# No pop-up for partitioning confirmation
#d-i partman/confirm_write_new_label boolean true
#d-i partman/choose_partition select finish
#d-i partman/confirm boolean true
#d-i partman/confirm_nooverwrite boolean true
#d-i apt-setup/security_host string 10.10.2.199
#d-i apt-setup/security_path string /ubuntu
d-i pkgsel/update-policy select none
#d-i apt-setup/use_mirror boolean false
#
#d-i apt-setup/security boolean false
#d-i apt-setup/security-updates boolean false
#d-i apt-setup/use_mirror boolean false
#d-i apt-setup/services-select multiselect
#base-config apt-setup/security-updates boolean false
#d-i apt-setup/security-updates boolean false
#d-i base-installer/kernel/image string linux-image-3.16.0-30-generic
#d-i pkgsel/upgrade select node
#d-i pkgsel/update-policy select none
#d-i pkgsel/updatedb boolean false
#d-i apt-setup/security-updates boolean false
#d-i apt-setup/services-select multiselect none
d-i pkgsel/update-policy select none
d-i preseed/early_command string umount /media
d-i partman/unmount_active boolean true
d-i partman-auto/expert_recipe string boot-root :: \
20 50 100 ext4 $primary{ } $bootable{ } method{ format } format{ } \
use_filesystem{ } filesystem{ ext4 } mountpoint{ /boot } . \
500 10000 1000000000 ext4 method{ format } format{ } \
use_filesystem{ } filesystem{ ext4 } mountpoint{ / } . \
64 512 300% linux-swap method{ swap } format{ } .
# This makes partman automatically partition without confirmation, provided
# that you told it what to do using one of the methods above.
d-i partman-partitioning/confirm_write_new_label boolean true
d-i partman/choose_partition select finish
d-i partman/confirm boolean true
d-i partman/confirm_nooverwrite boolean true
# Resolves installation error
d-i live-installer/net-image string http://10.10.2.199/ubuntu/install/filesystem.squashfs
一切正常,没有任何问题,完全无人值守安装。
但是在安装系统步骤中它开始从 Internet 进行安全更新,即使我在 preseed.cfg 文件中提到 没有自动更新 d-i pkgsel/update-policy select none
并在 linux-image-3.14.0.34-generic 步骤失败,因为它没有从 http://security.ubuntu.com 获取该包,因为我的设置中没有互联网。
如何解决该错误并在不出现此错误的情况下继续完全无人值守安装。
注意: preseed.cfg
和 ks.cfg
文件中注释的选项,我已经尝试和测试但没有任何作用。
在此先感谢您。
d-i pkgsel/update-policy select none
在安装的 pkgsel 阶段工作,现在尝试取消注释
d-i apt-setup/security-updates boolean false
另请参阅您的 preseed.cfg 包括
d-i pkgsel/update-policy select none
不止一次
我知道 Whosebug 上已经有人问过这个问题,但我对提供的答案不满意。
PXE use part of my kickstart file
我的设置:
Ubuntu 桌面 14.04 LTS (x86) 与 PXE (TFTP + Apache) 设置。
已安装 Ubuntu 服务器映像 14.04.2 并使用
ks.cfg
和preseed.cfg
创建了完全无人值守的安装
ks.cfg的配置:
#Generated by Kickstart Configurator
preseed/url=http://10.10.2.199/ubuntu/preseed.cfg
#platform=x86
#System language
lang en_US
#Language modules to install
langsupport en_US
#System keyboard
keyboard us
#System mouse
mouse
#System timezone
timezone Asia/Kolkata
#Root password
rootpw --disabled
#Initial user
user uadmin --fullname "uadmin" --iscrypted --password $SoMF.HMn$AIG0ecMNwJ4SU2D1/CRg6/
#Reboot after installation
reboot
#Use text mode install
text
#Install OS instead of upgrade
install
#Use Web installation
url --url http://10.10.2.199/ubuntu
#System bootloader configuration
bootloader --location=mbr
#Clear the Master Boot Record
zerombr yes
#Partition clearing information
clearpart --all --initlabel
#Disk partitioning information
clearpart --all
#part swap --size 4098
#ignoredisk --only-use=sda
#clearpart --all --linux --drives=sda
#part / --fstype ext4 --size 1 --grow
#System authorization infomation
auth --useshadow --enablemd5
#Network information
network --bootproto=dhcp --device=eth0
#Firewall configuration
firewall --disabled
#Do not configure the X Window System
skipx
%packages
# Since I don't install recommended it leaves out some things that should
# probably be installed like openssl and python 2.7
ca-certificates
openssl
python
wget
tcpd
# End all the recommended packages that are still useful
openssh-server
#open-vm-tools --no-install-recommends
curl
screen
vim
#copy contents to /etc/apt/sources.list
echo " #
# deb cdrom:[Ubuntu-Server 12.04.4 LTS _Precise Pangolin_ - Release amd64 (20140204)]/ dists/precise/main/binary-i386/
# deb cdrom:[Ubuntu-Server 12.04.4 LTS _Precise Pangolin_ - Release amd64 (20140204)]/ dists/precise/restricted/binary-i386/
# deb cdrom:[Ubuntu-Server 12.04.4 LTS _Precise Pangolin_ - Release amd64 (20140204)]/ precise main restricted
# deb cdrom:[Ubuntu-Server 12.04.4 LTS _Precise Pangolin_ - Release amd64 (20140204)]/ dists/precise/main/binary-i386/
# deb cdrom:[Ubuntu-Server 12.04.4 LTS _Precise Pangolin_ - Release amd64 (20140204)]/ dists/precise/restricted/binary-i386/
# deb cdrom:[Ubuntu-Server 12.04.4 LTS _Precise Pangolin_ - Release amd64 (20140204)]/ precise main restricted
# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://in.archive.ubuntu.com/ubuntu/ trusty main restricted
deb-src http://in.archive.ubuntu.com/ubuntu/ trusty main restricted
## Major bug fix updates produced after the final release of the
## distribution.
deb http://in.archive.ubuntu.com/ubuntu/ trusty-updates main restricted
deb-src http://in.archive.ubuntu.com/ubuntu/ trusty-updates main restricted
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team. Also, please note that software in universe WILL NOT receive any
## review or updates from the Ubuntu security team.
deb http://in.archive.ubuntu.com/ubuntu/ trusty universe
deb-src http://in.archive.ubuntu.com/ubuntu/ trusty universe
deb http://in.archive.ubuntu.com/ubuntu/ trusty-updates universe
deb-src http://in.archive.ubuntu.com/ubuntu/ trusty-updates universe
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team, and may not be under a free licence. Please satisfy yourself as to
## your rights to use the software. Also, please note that software in
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.
deb http://in.archive.ubuntu.com/ubuntu/ trusty multiverse
deb-src http://in.archive.ubuntu.com/ubuntu/ trusty multiverse
deb http://in.archive.ubuntu.com/ubuntu/ trusty-updates multiverse
deb-src http://in.archive.ubuntu.com/ubuntu/ trusty-updates multiverse
## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
deb http://in.archive.ubuntu.com/ubuntu/ trusty-backports main restricted universe multiverse
deb-src http://in.archive.ubuntu.com/ubuntu/ trusty-backports main restricted universe multiverse
deb http://security.ubuntu.com/ubuntu trusty-security main restricted
deb-src http://security.ubuntu.com/ubuntu trusty-security main restricted
deb http://security.ubuntu.com/ubuntu trusty-security universe
deb-src http://security.ubuntu.com/ubuntu trusty-security universe
deb http://security.ubuntu.com/ubuntu trusty-security multiverse
deb-src http://security.ubuntu.com/ubuntu trusty-security multiverse
## Uncomment the following two lines to add software from Canonical's
## 'partner' repository.
## This software is not part of Ubuntu, but is offered by Canonical and the
## respective vendors as a service to Ubuntu users.
# deb http://archive.canonical.com/ubuntu precise partner
# deb-src http://archive.canonical.com/ubuntu precise partner
## Uncomment the following two lines to add software from Ubuntu's
## 'extras' repository.
## This software is not part of Ubuntu, but is offered by third-party
## developers who want to ship their latest software.
# deb http://extras.ubuntu.com/ubuntu precise main
# deb-src http://extras.ubuntu.com/ubuntu precise main "
> /etc/apt/sources.list
preseed.cfg
配置:
Options to set on the command line
#preseed/url=http://10.10.2.199/ubuntu/preseed.cfg
#onsole-setup/ask_detect=false
#console-setup/layoutcode=us
#netcfg/get_hostname=dh5
#netcfg/get_domain=wb.com
#initrd=/install/initrd.gz quiet --
#d-i ubuntu-installer/locale string en_US
#d-i console-setup/ask_detect boolean false
#d-i console-setup/layoutcode string us
#d-i netcfg/get_hostname string dh5
#d-i netcfg/get_domain string wb.com
#d-i netcfg/choose_interface select auto
#d-i netcfg/wireless_wep string
#d-i base-installer/kernel/override-image string linux-server
#d-i clock-setup/utc-auto boolean true
#d-i clock-setup/utc boolean true
#d-i time/zone string US/Pacific
#d-i clock-setup/ntp boolean true
#d-i mirror/country string US
#d-i mirror/http/proxy string
#d-i pkgsel/install-language-support boolean false
#tasksel tasksel/first multiselect standard, ubuntu-server
#d-i partman-auto/method string regular
#d-i partman-auto/purge_lvm_from_device boolean true
#d-i partman-lvm/confirm boolean true
#d-i partman-auto/choose_recipe select atomic
#d-i partman/confirm_write_new_label boolean true
#d-i partman/choose_partition select finish
#d-i partman/confirm boolean true
#d-i partman/confirm_write_new_label boolean true
#d-i partman/choose_partition select \
# Finish partitioning and write changes to disk
#d-i partman/confirm boolean true
#d-i passwd/user-fullname string uadmin User
#d-i passwd/username string uadmin
#d-i passwd/user-password password password
#d-i passwd/user-password-again password password
#d-i partman/unmount_active boolean true
#d-i preseed/early_command string umount /media
#d-i grub-installer/only_debian boolean true
#d-i grub-installer/with_other_os boolean true
#d-i finish-install/reboot_in_progress note
# No pop-up for partitioning confirmation
#d-i partman/confirm_write_new_label boolean true
#d-i partman/choose_partition select finish
#d-i partman/confirm boolean true
#d-i partman/confirm_nooverwrite boolean true
#d-i apt-setup/security_host string 10.10.2.199
#d-i apt-setup/security_path string /ubuntu
d-i pkgsel/update-policy select none
#d-i apt-setup/use_mirror boolean false
#
#d-i apt-setup/security boolean false
#d-i apt-setup/security-updates boolean false
#d-i apt-setup/use_mirror boolean false
#d-i apt-setup/services-select multiselect
#base-config apt-setup/security-updates boolean false
#d-i apt-setup/security-updates boolean false
#d-i base-installer/kernel/image string linux-image-3.16.0-30-generic
#d-i pkgsel/upgrade select node
#d-i pkgsel/update-policy select none
#d-i pkgsel/updatedb boolean false
#d-i apt-setup/security-updates boolean false
#d-i apt-setup/services-select multiselect none
d-i pkgsel/update-policy select none
d-i preseed/early_command string umount /media
d-i partman/unmount_active boolean true
d-i partman-auto/expert_recipe string boot-root :: \
20 50 100 ext4 $primary{ } $bootable{ } method{ format } format{ } \
use_filesystem{ } filesystem{ ext4 } mountpoint{ /boot } . \
500 10000 1000000000 ext4 method{ format } format{ } \
use_filesystem{ } filesystem{ ext4 } mountpoint{ / } . \
64 512 300% linux-swap method{ swap } format{ } .
# This makes partman automatically partition without confirmation, provided
# that you told it what to do using one of the methods above.
d-i partman-partitioning/confirm_write_new_label boolean true
d-i partman/choose_partition select finish
d-i partman/confirm boolean true
d-i partman/confirm_nooverwrite boolean true
# Resolves installation error
d-i live-installer/net-image string http://10.10.2.199/ubuntu/install/filesystem.squashfs
一切正常,没有任何问题,完全无人值守安装。
但是在安装系统步骤中它开始从 Internet 进行安全更新,即使我在 preseed.cfg 文件中提到 没有自动更新 d-i pkgsel/update-policy select none
并在 linux-image-3.14.0.34-generic 步骤失败,因为它没有从 http://security.ubuntu.com 获取该包,因为我的设置中没有互联网。
如何解决该错误并在不出现此错误的情况下继续完全无人值守安装。
注意: preseed.cfg
和 ks.cfg
文件中注释的选项,我已经尝试和测试但没有任何作用。
在此先感谢您。
d-i pkgsel/update-policy select none
在安装的 pkgsel 阶段工作,现在尝试取消注释
d-i apt-setup/security-updates boolean false
另请参阅您的 preseed.cfg 包括
d-i pkgsel/update-policy select none
不止一次