From 2b150830c97f155e997b017d88f3f3cddf648049 Mon Sep 17 00:00:00 2001 From: Daniel Hilst <392820+dhilst@users.noreply.github.com> Date: Fri, 11 Sep 2026 17:15:47 -0300 Subject: [PATCH 1/2] test(xcat-core): the Ubuntu ppc64el netboot image has no dig genimage stops with "Failed to find usr/bin/dig in /install/netboot/ubuntu24.04.4/ppc64el/compute/rootimg" and returns 2, so packimage writes no initrd.gz and nodeset reports "Did you run genimage before running packimg?". The diskless compute node never boots. xCAT-server/share/xcat/netboot/ubuntu ships a package list for ppc64el on 20.04 and on 26.04 only. imgutils::get_profile_def_filename finds no ppc64el list for 22.04 or 24.04 and falls back to compute.pkglist, which installs no dig. mkinitrd copies usr/bin/dig into the initrd and find_rootimg_file calls xdie when the file is absent. The test reads the four ppc64el package lists the pipeline provisions and asserts each one installs dig, a kernel and nfs-common. It fails on 22.04 and 24.04 and passes on 20.04 and 26.04. Evidence: reg_linux_diskless_installation_flat on ubuntu-24-ppc64le-devel in xcat-core-devel-ubuntu-cd build 120, xcattest.log.20260911175800 on xcat25-mn. Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com> --- xCAT-test/unit/ubuntu_ppc64el_pkglists.t | 46 ++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 xCAT-test/unit/ubuntu_ppc64el_pkglists.t diff --git a/xCAT-test/unit/ubuntu_ppc64el_pkglists.t b/xCAT-test/unit/ubuntu_ppc64el_pkglists.t new file mode 100644 index 000000000..af36e606b --- /dev/null +++ b/xCAT-test/unit/ubuntu_ppc64el_pkglists.t @@ -0,0 +1,46 @@ +#!/usr/bin/env perl +use strict; +use warnings; + +use FindBin; +use Test::More; + +# genimage builds the netboot initrd for ppc64el with mkinitrd, not dracut, and mkinitrd +# copies usr/bin/dig out of the rootimg. A release with no ppc64el package list falls back +# to compute.pkglist, which installs no dig, and genimage stops with +# "Failed to find usr/bin/dig". The package that holds dig changed name in 22.04. + +use lib "$FindBin::Bin/../lib"; +use XCAT::Test::File qw(repo_path); + +my $netboot = 'xCAT-server/share/xcat/netboot/ubuntu'; + +sub packages { + my ($path) = @_; + my $full = repo_path($path); + return unless -r $full; + open(my $fh, '<', $full) or die "cannot read $full: $!"; + my @packages = grep { length && !/^#/ } map { my $l = $_; chomp $l; $l =~ s/\s+//g; $l } <$fh>; + close($fh); + return \@packages; +} + +foreach my $release (qw(20.04 22.04 24.04 26.04)) { + my $list = packages("$netboot/compute.ubuntu$release.ppc64el.pkglist"); + ok($list, "$release has a ppc64el netboot package list"); + + SKIP: { + skip "no $release ppc64el package list to inspect", 4 unless $list; + + ok(scalar(grep { $_ eq 'dnsutils' || $_ eq 'bind9-dnsutils' } @{$list}), + "the $release ppc64el image installs the dig that mkinitrd copies"); + ok(scalar(grep { $_ eq 'linux-image-generic' } @{$list}), + "the $release ppc64el image installs a kernel"); + ok(scalar(grep { $_ eq 'nfs-common' } @{$list}), + "the $release ppc64el image can mount its root over NFS"); + is_deeply(packages("$netboot/compute.ubuntu$release.ppc64le.pkglist"), $list, + "the $release ppc64le list matches the ppc64el list"); + } +} + +done_testing(); From b7be80d45038835dac5340cc46cf7dc25b178831 Mon Sep 17 00:00:00 2001 From: Daniel Hilst <392820+dhilst@users.noreply.github.com> Date: Fri, 11 Sep 2026 17:17:55 -0300 Subject: [PATCH 2/2] fix(xcat-core): the Ubuntu ppc64el netboot image has no dig genimage returns 2 with "Failed to find usr/bin/dig" for ubuntu22.04 and ubuntu24.04 on ppc64el, so packimage writes no initrd.gz and the diskless compute node never boots. xCAT-server/share/xcat/netboot/ubuntu had a ppc64el package list for 20.04 and 26.04 only. imgutils::get_profile_def_filename then falls back to compute.pkglist, which installs no dig, no cpio and no chrony. Add the 22.04 and 24.04 ppc64el lists, and the ppc64le spelling each release already carries. Both take the content of the 26.04 ppc64el list: the ppc64el images build their initrd with mkinitrd, so they install bind9-dnsutils and leave out the dracut packages the x86_64 lists take. ubuntu_ppc64el_pkglists.t fails without these files. Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com> --- .../compute.ubuntu22.04.ppc64el.pkglist | 20 +++++++++++++++++++ .../compute.ubuntu22.04.ppc64le.pkglist | 20 +++++++++++++++++++ .../compute.ubuntu24.04.ppc64el.pkglist | 20 +++++++++++++++++++ .../compute.ubuntu24.04.ppc64le.pkglist | 20 +++++++++++++++++++ 4 files changed, 80 insertions(+) create mode 100644 xCAT-server/share/xcat/netboot/ubuntu/compute.ubuntu22.04.ppc64el.pkglist create mode 100644 xCAT-server/share/xcat/netboot/ubuntu/compute.ubuntu22.04.ppc64le.pkglist create mode 100644 xCAT-server/share/xcat/netboot/ubuntu/compute.ubuntu24.04.ppc64el.pkglist create mode 100644 xCAT-server/share/xcat/netboot/ubuntu/compute.ubuntu24.04.ppc64le.pkglist diff --git a/xCAT-server/share/xcat/netboot/ubuntu/compute.ubuntu22.04.ppc64el.pkglist b/xCAT-server/share/xcat/netboot/ubuntu/compute.ubuntu22.04.ppc64el.pkglist new file mode 100644 index 000000000..f8eaecec0 --- /dev/null +++ b/xCAT-server/share/xcat/netboot/ubuntu/compute.ubuntu22.04.ppc64el.pkglist @@ -0,0 +1,20 @@ +bash +ifupdown +nfs-common +openssl +isc-dhcp-client +libc-bin +linux-image-generic +openssh-server +openssh-client +wget +vim +rsync +busybox-static +gawk +bind9-dnsutils +tar +gzip +xz-utils +cpio +chrony diff --git a/xCAT-server/share/xcat/netboot/ubuntu/compute.ubuntu22.04.ppc64le.pkglist b/xCAT-server/share/xcat/netboot/ubuntu/compute.ubuntu22.04.ppc64le.pkglist new file mode 100644 index 000000000..f8eaecec0 --- /dev/null +++ b/xCAT-server/share/xcat/netboot/ubuntu/compute.ubuntu22.04.ppc64le.pkglist @@ -0,0 +1,20 @@ +bash +ifupdown +nfs-common +openssl +isc-dhcp-client +libc-bin +linux-image-generic +openssh-server +openssh-client +wget +vim +rsync +busybox-static +gawk +bind9-dnsutils +tar +gzip +xz-utils +cpio +chrony diff --git a/xCAT-server/share/xcat/netboot/ubuntu/compute.ubuntu24.04.ppc64el.pkglist b/xCAT-server/share/xcat/netboot/ubuntu/compute.ubuntu24.04.ppc64el.pkglist new file mode 100644 index 000000000..f8eaecec0 --- /dev/null +++ b/xCAT-server/share/xcat/netboot/ubuntu/compute.ubuntu24.04.ppc64el.pkglist @@ -0,0 +1,20 @@ +bash +ifupdown +nfs-common +openssl +isc-dhcp-client +libc-bin +linux-image-generic +openssh-server +openssh-client +wget +vim +rsync +busybox-static +gawk +bind9-dnsutils +tar +gzip +xz-utils +cpio +chrony diff --git a/xCAT-server/share/xcat/netboot/ubuntu/compute.ubuntu24.04.ppc64le.pkglist b/xCAT-server/share/xcat/netboot/ubuntu/compute.ubuntu24.04.ppc64le.pkglist new file mode 100644 index 000000000..f8eaecec0 --- /dev/null +++ b/xCAT-server/share/xcat/netboot/ubuntu/compute.ubuntu24.04.ppc64le.pkglist @@ -0,0 +1,20 @@ +bash +ifupdown +nfs-common +openssl +isc-dhcp-client +libc-bin +linux-image-generic +openssh-server +openssh-client +wget +vim +rsync +busybox-static +gawk +bind9-dnsutils +tar +gzip +xz-utils +cpio +chrony