2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2026-10-02 08:51:44 +00:00
Commit Graph

28370 Commits

Author SHA1 Message Date
Daniel Hilst ad511ff0c4 fix(xcat-core): xcattest dies on Ubuntu without xCAT::Test::OS
xCAT-test/debian/install did not list lib/xCAT/Test/OS.pm, so the
Debian package shipped xcattest without the module it loads, and
xcattest stopped at startup with "Can't locate xCAT/Test/OS.pm in @INC".

Install the module to opt/xcat/lib/perl/xCAT/Test, as the RPM spec does.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-09-30 20:26:58 -03:00
Daniel Hilst 90813ba7d4 test(xcat-core): the Debian xCAT-test package misses xCAT::Test::OS
xcattest loads xCAT::Test::OS from /opt/xcat/lib/perl. xCAT-test.spec
installs it, but xCAT-test/debian/install does not, so xcattest on an
Ubuntu management node dies at startup with "Can't locate
xCAT/Test/OS.pm in @INC".

Check that the RPM spec and the Debian install list both ship every
module under xCAT-test/lib/xCAT. The Debian check fails.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-09-30 20:26:49 -03:00
Daniel Hilst 3582c6ab19 fix(xcat-core): xcattest runs no test case on an openEuler management node
xcattest reports "Test case <name> has an invalid OS option - Linux" and then
"There is no valid case to run", so every case is skipped on openEuler.
Recorded on an openEuler 24.03 LTS SP4 management node with xCAT 2.20.0: both
flat provisioning cases were rejected and the run measured nothing.

Two causes, both in the os: comparison in xCAT-test/xcattest. get_current_os
takes the /etc/os-release branch, finds no sles, and falls off the end of that
branch, so it returns the exit status of the failed grep, 256, which names no
distribution. And a case marked os:Linux expands to exactly rhels, sles and
ubuntu, so openEuler would be rejected even by a correct get_current_os.

Both halves move into xCAT::Test::OS. xcattest finds it beside itself and the
package installs it at <prefix>/lib/perl. current_os takes a path prefix, so a
test describes a system by writing release files into a scratch tree. openEuler
is named in both halves and nothing else changes.

xCAT-test/unit/xcattest_os_selection.t covers it. Removing openeuler from
linux_aliases fails two checks, and removing the openEuler branch from
current_os fails three. A further case gives a root both /etc/redhat-release
and an openEuler /etc/os-release and asserts rhels10, so the precedence is
named: openEuler ships neither that file nor /etc/lsb-release.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-09-30 19:59:41 -03:00
Daniel Hilst d20071a655 Merge pull request #7864 from xcat2/feature/openeuler-lts
feat(os): support openEuler LTS management, service and compute nodes
2026-09-30 18:54:26 -03:00
Daniel Hilst 056a57f087 Merge branch 'master' into feature/openeuler-lts 2026-09-30 17:50:25 -03:00
Daniel Hilst fae3e69d40 Merge pull request #7890 from VersatusHPC/fix/nodepurge-leaves-autoinst-directory
fix(xcat-core): nodepurge leaves the autoinstall directory of an Ubuntu node
2026-09-30 06:24:57 -03:00
Daniel Hilst 4b73175670 fix(xcat-core): nodepurge leaves the autoinstall directory of an Ubuntu node
After nodepurge removes a Subiquity node, /install/autoinst/<node> is still on
disk with meta-data, user-data and vendor-data in it. user-data carries the root
password hash of a node that no longer exists.

remove_node_config_files removed each path with unlink. unlink cannot remove a
directory, and mkinstall in debian.pm calls mkpath for a Subiquity node, so the
node configuration is a directory there and a plain file on the preseed and
kickstart paths. The routine now removes a directory with rmtree.

nodepurge_autoinst_cleanup.t fails without this change and passes with it.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-09-29 18:19:32 -03:00
Daniel Hilst 1fa9d1f6fc test(xcat-core): nodepurge leaves the autoinstall directory of an Ubuntu node
nodepurge removes the autoinstall configuration of each node it deletes. The
cleanup loop was inline in the nodepurge sub of profilednodes.pm, which no test
can load, so the loop moves to xCAT::ProfiledNodeUtils->remove_node_config_files
with its behaviour unchanged.

nodepurge_autoinst_cleanup.t drives that routine against a scratch directory. It
fails here: the Subiquity node keeps its directory, and the preseed file and the
.pre and .post scripts are removed.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-09-29 18:19:19 -03:00
Daniel Hilst 092d7ca702 Merge pull request #7887 from VersatusHPC/ci/install-rpm-for-spec-tests
ci(test): install rpm for the spec tests
2026-09-29 12:25:47 -03:00
Daniel Hilst 31c9f3bd26 Merge pull request #7824 from VersatusHPC/feat/support-matrix-distro-versions
docs(xcat-core): Specify distro vs arch versions in support matrix
2026-09-29 11:50:42 -03:00
Vinícius Ferrão 63cf366b96 Merge master into feature/openeuler-lts 2026-09-29 00:01:05 -03:00
Vinícius Ferrão f375080212 ci(test): install rpm for the spec tests
The GitHub check installs no rpm, so riscv64_packaging.t and
genesis_spec_target_arch.t skip every check that runs rpmspec. The
workflow now installs rpm, which provides rpmspec on Ubuntu.
2026-09-28 15:22:28 -03:00
Daniel Hilst a095259a01 Merge pull request #7868 from VersatusHPC/test/r26-otherpkgs-upgrade-behavior
test(otherpkgs): exercise repository-scoped upgrades
2026-09-28 13:47:30 -03:00
Daniel Hilst 679edbc0d3 Merge pull request #7886 from VersatusHPC/fix/ci-devel-xcat-dep
fix(ci): install xcat-dep from the devel channel
2026-09-27 19:27:42 -03:00
Vinícius Ferrão fad44f6281 fix(ci): install xcat-dep from the devel channel
The GitHub check of master installs the xcat-dep packages of the latest
channel, which serves the stable release. A master change that needs a
new xcat-dep package then fails the check until that package is in a
stable release. The check now reads the devel channel, which carries
the xcat-dep packages of the next release. The 2.19 branch keeps the
latest channel.
2026-09-27 18:46:26 -03:00
Daniel Hilst 1d3d083f49 Merge pull request #7883 from VersatusHPC/docs/master-docs-release
docs(xcat-core): the documentation title names 2.17.0, the checklist sends users to latest, and the release table stops at 2.18.0
2026-09-25 18:59:23 -03:00
Daniel Hilst 2c7a6f0786 docs(xcat-core): the release table stops at 2.18.0
The release information page lists every release up to 2.18.0. 2.18.2,
2.19.0 and 2.19.1 are published and absent from it, so a reader cannot
tell from the documentation which releases exist, when each one shipped,
or where its notes are.

docs/source/overview/_files/2.19.x.csv is new and holds the 2.19.0 and
2.19.1 rows, xcat2_release.rst gains its section above 2.18.x, and
2.18.x.csv gains the 2.18.2 row. Each date is the date of that release
on GitHub. 2.18.1 has no GitHub release of its own, so it has no row.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-09-25 18:15:17 -03:00
Daniel Hilst 4fa1f2545a docs(developers): published .repo files name their series
The release checklist said that the published .repo files point at
latest. latest is a link into the newest series, so a file that names
it gives the next series to users of this one as soon as that series
ships. Each file under repos/yum/X.Y/ now names repos/yum/X.Y/, and the
installation check uses the files as published.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-09-25 18:15:17 -03:00
Daniel Hilst 733bc3219c docs(xcat-core): the documentation title names 2.17.0
Read the Docs takes the version in the title of each page from release
in docs/source/conf.py, which was last set for 2.17.0. Every build
since, 2.18.x and 2.19.0 included, is titled "xCAT 2.17.0
documentation". Set it to 2.20.0, the Version of master.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-09-25 18:15:17 -03:00
Vinícius Ferrão afa6e05789 docs(test): document the BATS postscript sandbox 2026-09-25 12:49:09 -03:00
Vinícius Ferrão 76d8dfdd14 test(otherpkgs): move sandbox checks to BATS 2026-09-25 12:48:40 -03:00
Vinícius Ferrão 0c77d67aeb test(openeuler): require the expected failure diagnostics 2026-09-25 12:15:30 -03:00
Daniel Hilst 3c50aa6d37 Merge pull request #7858 from VersatusHPC/test/r26-syncfiles-request-behavior
test(syncfiles): verify emitted xdcp requests
2026-09-25 09:19:00 -03:00
Daniel Hilst 417d22e9c1 Merge pull request #7876 from VersatusHPC/fix/mknb-bootif-hexhyp
fix(mknb): pass the boot MAC to BIOS Genesis on stock iPXE
2026-09-25 09:03:46 -03:00
Daniel Hilst ba8233a605 docs(xcat-core): the support matrix omits openEuler
xcat2/xcat-core#7864 adds openEuler 20.03 LTS SP4, 22.03 LTS SP4 and
24.03 LTS SP4 on x86_64, for the management node, service nodes and
stateful and stateless compute nodes. The support matrix does not list
openEuler at all.

Add one row per release, x86_64 only, and say which node roles the
support covers. Widen the Version column to fit the release names.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-09-25 08:44:02 -03:00
Vinícius Ferrão 463eca19e5 Merge master into feature/openeuler-lts 2026-09-25 01:41:02 -03:00
Vinícius Ferrão 33af6d6d85 docs(tests): list the genimage boot-file integration test 2026-09-25 01:38:38 -03:00
Vinícius Ferrão 23e1c2c29c test(genimage): exercise boot publication and repositories directly 2026-09-25 01:38:38 -03:00
Vinícius Ferrão cc2e3e9635 refactor(genimage): share boot publication and repository setup 2026-09-25 01:31:14 -03:00
Vinícius Ferrão 8bc5bb4611 test(syslog): cover expanded configuration cleanup 2026-09-25 01:29:35 -03:00
Vinícius Ferrão 29ff3ab3f2 fix(syslog): guard expanded configuration cleanup 2026-09-25 01:29:34 -03:00
Vinícius Ferrão 5cd0424e28 test(syncfiles): characterize same-process copy overrides 2026-09-24 23:08:42 -03:00
Vinícius Ferrão fe0fc68af8 test(syncfiles): cover invalid-option rejection 2026-09-24 23:08:42 -03:00
Daniel Hilst 9bf6c8205d Merge pull request #7863 from VersatusHPC/test/r26-nodestat-request-behavior
test(nodestat): exercise request option handling
2026-09-24 23:02:05 -03:00
Daniel Hilst 27b855c8ad Merge pull request #7861 from VersatusHPC/test/r26-deprecated-request-behavior
test(provision): verify deprecated request rejection
2026-09-24 22:58:42 -03:00
Daniel Hilst 4dc08fb549 Merge pull request #7860 from VersatusHPC/test/r26-destiny-chain-behavior
test(destiny): verify chain updates and dispatch
2026-09-24 22:53:18 -03:00
Daniel Hilst b92e5910d6 Merge pull request #7859 from VersatusHPC/test/r26-dhcp-dispatch-behavior
test(dhcp): verify service-node dispatch requests
2026-09-24 22:50:18 -03:00
Daniel Hilst 4ed029ffce Merge pull request #7835 from VersatusHPC/fix/ubuntu-genesis-native-sbuild
fix(xcat-core): the Ubuntu Genesis image is built from the build host kernel
2026-09-24 19:24:23 -03:00
Daniel Hilst 888698e384 fix(xcat-core): the Genesis build-root and payload tests assert on source text and script output, not behaviour
genesis_ubuntu_build_root.t cut REQUIRED_PACKAGES out of
builddeb-genesis-base with a regex and evaluated it through bash -c. It
then matched the apt-cache fallback calls as text. Reformatting the
script broke it, and a wrong choice between renamed packages passed it.
genesis_payload_verification.t ran the verifier script and parsed its
stderr.

genesis_ubuntu_build_root.t now calls required_packages() with a chosen
set of carried packages and asserts the exact result: the amd64 extras,
the name picked for each renamed package, the order apt is asked,
tzdata-legacy, and the error for a release that carries neither name.
It reads the mandatory commands from XCAT::GenesisPayload, the code the
build uses. genesis_payload_verification.t calls the XCAT::GenesisPayload
functions with chosen payload trees and asserts the exact missing paths
and results.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-09-24 17:28:04 -03:00
Daniel Hilst eb30d2e92a fix(xcat-core): the Genesis build-root package list and payload check can only be read by evaluating shell
builddeb-genesis-base built its package list inline, between apt-get
update and apt-get install. A test could reach the list only by cutting
the REQUIRED_PACKAGES assignment out of the script and evaluating it.
It could not reach the choice between renamed packages (bind9-dnsutils
or dnsutils, util-linux-extra or util-linux) at all. The payload check
in verify-genesis-payload was bash, so a test could only run the script
and read its stderr.

XCAT::GenesisBuildRoot::required_packages() now returns the list for a
dpkg architecture. A code ref says which packages the release carries;
the default asks apt-cache. builddeb-genesis-base calls it at the same
point in the build and installs the same packages.

XCAT::GenesisPayload holds the mandatory-command list and the payload
check. verify-genesis-payload runs its main() and keeps the same
arguments, exit codes and messages. buildrpms.pl stages the module
beside the script. Both modules use core Perl only, because the build
root has perl-base and nothing more.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-09-24 17:28:04 -03:00
Daniel Hilst eb595c698c Merge pull request #7834 from VersatusHPC/fix/ubuntu-subiquity-ppc64le-grub-ieee1275
fix(xcat-core): the Ubuntu ppc64le diskful install stops without grub-ieee1275
2026-09-24 10:57:04 -03:00
Daniel Hilst a0dc423809 Merge pull request #7853 from VersatusHPC/fix/installmon-per-node-fork
fix(xcat-core): one node's request to the install monitor blocks every other node
2026-09-24 10:26:10 -03:00
Daniel Hilst f8618ce746 test(xcat-core): an assertion about /run could not tell who wrote there
The error-command test ended with

    [ ! -e /run/testnode-logs.tar ]

meant to show the archive had not gone to the default path. It cannot show that.
The file may exist for reasons that have nothing to do with this test, in which case
the assertion fails while nothing is wrong; and its absence would be equally true if
the override had never worked at all. It answers a question about the host, not
about the run.

The positive assertion above it already carries the proof: the tar shadow writes a
marker, and the test greps for that marker in the path it passed. The output being
there is what shows the redirection went there.

Removing it changes nothing about what the test catches. With the override taken out
of the template, so the archive path is hard-coded again, the remaining assertion
still fails.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-09-24 10:24:54 -03:00
Daniel Hilst b72fd46366 Merge pull request #7851 from VersatusHPC/fix/updatenode-xcatpost-cleanup
fix(xcatdsklspost): updatenode leaves /xcatpost populated when site.cleanupdiskfullxcatpost is set
2026-09-24 10:21:49 -03:00
Daniel Hilst ba49107db3 Merge pull request #7867 from VersatusHPC/fix/build-locks-on-shared-tree
fix(xcat-core): build locks the shared tree refuses to grant
2026-09-24 10:19:22 -03:00
Daniel Hilst 7f635afbd8 Merge pull request #7850 from VersatusHPC/fix/otherpkgs-postscript-defects
fix(otherpkgs): the postscript truncates its syslog output and logs a failed install as installed
2026-09-24 10:17:19 -03:00
Daniel Hilst ed28770532 Merge master into fix/build-locks-on-shared-tree
Brings in #7866, which removes --database from the createrepo call. Without it the
branch cannot index a repository on the shared build tree: createrepo_c tries to
write primary.sqlite there and the NFS re-export answers

    Cannot open .repodata/primary.sqlite: Can not create db_info table: disk I/O error

which failed every EL build in xcat-ci #44 while the Ubuntu builds, which do not use
createrepo, passed.
2026-09-24 06:31:16 -03:00
Daniel Hilst c8a57880d6 fix(xcat-core): cancelling a build left its workers writing the checkout
Killing the command is not killing the build. sh() ran the command through /bin/sh,
and cancellation signalled that shell alone -- but dpkg-buildpackage starts workers
of its own, and those survive their shell. The lock was then released while they
were still writing debian/changelog and debian/control, which is the state the lock
exists to prevent: the next build takes the checkout and the two rewrite it
together.

The command now runs in its own process group, so cancellation can take all of it.
Both sides call setpgid, so neither depends on which runs first, and INT and TERM
are blocked across the fork so cancellation cannot land in the window before the
group exists.

Cancellation escalates from the caught signal to KILL, and then CHECKS: a shell that
has exited is not a build that has stopped, so it waits for the whole group to
disappear rather than for the leader to be reaped. If the group is still there after
that, the locks are RETAINED and the process exits non-zero. Releasing a lock while
a worker may still be writing is worse than leaving a lock behind for a person to
clear -- the first corrupts a build, the second stops one.

cancel_build ignores INT and TERM while it runs, so a second Ctrl-C cannot interrupt
the cleanup half way and release the lock early.

sh() also reports a signalled command as 128+signal instead of 0. $? >> 8 is zero
for a child killed by a signal, so a build stopped mid-way looked to its caller like
one that had succeeded.

Two cases added to builddebs_lock_cancellation.t: a build whose worker is a
grandchild, and a command killed by a signal. Verified by signalling the pid instead
of the group, which leaves the worker running and turns the first red.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-09-24 06:02:12 -03:00
Vinícius Ferrão 43e008cf99 test(mknb): cover the BIOS Genesis BOOTIF format
Check both paths that write the script: mknb --configfileonly on an
installed Genesis, and a full mknb run from an x86_64 OpenEmbedded export.
2026-09-24 02:33:01 -03:00
Vinícius Ferrão b4eb93be86 fix(mknb): pass the boot MAC to BIOS Genesis on stock iPXE
mknb wrote BOOTIF=01-${netX/machyp} into the BIOS Genesis script.
machyp is an xNBA setting, and stock iPXE expands it to an empty string.
Without the boot MAC, the legacy Genesis stops with "Unable to find boot
device" after at least 10 minutes. The OpenEmbedded Genesis fails at once
with BOOT_INTERFACE_NOT_FOUND.

Use ${netX/mac:hexhyp}, as the UEFI Genesis script and xnba.pm do. xNBA
expands both settings to the same value, so boot with xNBA is unchanged.
2026-09-24 02:33:01 -03:00