SETTING UP KICKSTART

WITHOUT HTTP_PROXY as it prevents from loading ks.cfg and WITHOUT DOUBLE QUOTES

vi /tftpboot/pxelinux.cfg/default

label ubuntu/bionic kickstart (erase everything)
        kernel ../bionic/linux
        initrd ../bionic/initrd.gz
        append net.ifnames=0 biosdevname=0 vga=788 ks=http://x.x.x.x/bionic/ks.cfg ksdevice=bootif

WITH HTTP_PROXY against apt-cacher-ng

vi /tftpboot/bionic/ks.cfg

install
text
mouse
url --url http://MIRROR.archive.ubuntu.com/ubuntu/
preseed mirror/http/proxy string http://x.x.x.x:3142/
preseed passwd/make-user boolean false
preseed pkgsel/update-policy select unattended-upgrades

lang en_US
langsupport en_US
keyboard us
timezone Europe/Moscow

network --bootproto=dhcp --device=eth0
firewall --disabled

auth --useshadow --enablemd5
#at least eight chars
rootpw PASSWORD

zerombr
#even for GPT?
bootloader --location=mbr --append="netcfg/do_not_use_netplan=true net.ifnames=0 biosdevname=0 mitigations=0"

#we put an 250MB partition there just in case we need to switch to EFI
clearpart --all --initlabel
part /boot/efi --fstype=efi --size=250 --asprimary
part / --fstype ext4 --size 1 --grow --asprimary
part swap --size 2048 --asprimary

skipx
#reboot

note: the bootloader appends did not seem to work. postinstall fix was required.

READY TO GO

on the pxe server

tail -F /var/log/thttpd.log /var/log/apt-cacher-ng/*

RESOURCES

KickstartCompatibility https://help.ubuntu.com/community/KickstartCompatibility

4.6. Automatic Installation https://help.ubuntu.com/lts/installation-guide/i386/ch04s06.html

26.3. Kickstart Syntax Reference https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/installation_guide/sect-kickstart-syntax

5.3. Boot Parameters https://help.ubuntu.com/lts/installation-guide/i386/ch05s03.html

Ubuntu 14 and PXE - Variable to pass to specify install path? https://askubuntu.com/questions/679533/ubuntu-14-and-pxe-variable-to-pass-to-specify-install-path

bootloader

A.2.2. bootloader (required) - Configure Boot Loader https://docs.fedoraproject.org/en-US/Fedora/23/html/Installation_Guide/sect-kickstart-commands-bootloader.html

efi

4.3.1. Kickstart file example for installing on EFI-based systems https://docs.openvz.org/openvz_installation_using_pxe_guide.webhelp/_kickstart_file_example_for_installing_on_efi_based_systems.html

rootpw

Why does a plaintext password with rootpw parameter of Kickstart doesn’t interpret password containing # (hash) character? https://access.redhat.com/solutions/2148361

A.5.5. rootpw (required) - Set Root Password https://docs.fedoraproject.org/en-US/Fedora/html/Installation_Guide/sect-kickstart-commands-rootpw.html


HOME | GUIDES | LECTURES | LAB | SMTP HEALTH | HTML5 | CONTACT
Copyright © 2024 Pierre-Philipp Braun