mirror of
https://github.com/xcat2/xcat-core.git
synced 2026-09-05 12:37:54 +00:00
a6f77a9732
Boot the live installer correctly. Add boot=casper so casper actually processes netboot=nfs instead of scanning local disks and panicking, resolve the install server to a literal IP because casper mounts the live filesystem with klibc's nfsmount which has no resolver, and add toram so casper copies the squashfs into RAM and unmounts the NFS source. That last one is what lets the node reboot at all: with the NFS root still mounted, systemd-shutdown waits forever on an lvm/pvscan wedged in uninterruptible I/O on it and the node never power-cycles into the disk it just installed. casper has no cmdline knob for NFS mount options -- it parses only nfsroot= and takes the whole value as the path -- so toram is its supported way to avoid a network root. Write the installer's resolv.conf nameserver as an IP. glibc's resolver discards a hostname given on a nameserver line, so the xcatmaster name left the installer, and the in-target apt that inherits the file, with no DNS at all. Add the online archive through apt `sources:` on classic-sources releases, where Subiquity renders the target sources.list from the install media alone and in-target apt cannot find packages the ISO does not carry. Deb822 releases are excluded: their primary mirror already lands in ubuntu.sources, so legacy .list files would configure the same suites twice. Flip the node to local-disk boot from the live installer over bash's /dev/tcp instead of relying on updateflag.awk, which needs gawk's |& coprocess while Ubuntu's /usr/bin/awk is mawk. The exchange is checked, and a failure is recorded in the install log rather than silently PXE-looping into another install. Defer syncfiles to the postbootscripts on the diskful install path, so it runs on the booted node with sshd up rather than inside the in-target chroot where the MN cannot reach it. Make the test harness's provision wait overridable through WAIT_FOR_PROVISION; the default stays short so a boot loop still fails fast. Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>