openEuler publishes RVA20 and RVA23 builds of each riscv64 release. Both
carry the same .treeinfo identity, so copycds copies the second one into
the directory of the first, and the result is a repository with packages
of two builds.
copycds now compares the .discinfo description, RVA23 or empty, with the
copy already in the target directory, and refuses a different build. Media
of the same build, and every other architecture, copy as before.
The rendered compute and service %post, run in a sandbox through the
downloaded postscript, must leave the kdump.service drop-in that stateless
images get. A system without kdump.service must get none.
On riscv64, an installed openEuler node reserves no dump memory, so
kdump.service fails and the node boots degraded.
The openEuler kickstart %post adds the kdump.service drop-in that
stateless images get. It runs before post.rhels8, which ends the %post
script with exit 0. A node whose command line carries crashkernel= or
fadump= still starts kdump.
An image with kdump.service must get the dump-memory drop-in, once, next
to any site drop-in, and an image without it must get none. systemd itself
must start kdump.service with crashkernel= or fadump= on the command line,
and skip it with neither.
openEuler diskless images enable kdump.service, which @core brings in. A
stateless command line reserves dump memory only through linuximage.dump
or addkcmdline, so on every other node kdump.service fails and the node
boots degraded.
genimage adds a kdump.service drop-in with triggering conditions on
crashkernel and fadump, so the service is skipped when the command line
has neither. POWER firmware-assisted dumps, which xCAT configures with
fadump= and no crashkernel=, still start. An image without kdump.service
is unchanged.
List openEuler 24.03 LTS SP4 on riscv64 in the openEuler guide, the
riscv64 guide and the support matrix. The scope is installed and stateless
compute nodes from the RVA23 media. riscv64 management and service nodes
stay out, because xCAT publishes no openEuler riscv64 packages.
The openEuler guide also says to import the openEuler key on the genimage
build host. A new installation has no key in its RPM keyring.
genimage must dispatch an openeuler24.03sp3 riscv64 image to the native
openEuler builder. packimage must pack it, and still refuse it as a
StateLite image.
genimage and packimage admit openEuler images only for x86_64 and
ppc64le. For the riscv64 osimage that copycds creates, genimage stops with
"Unsupported openEuler release or architecture" and packimage with
"Unsupported openEuler image release or architecture".
Admit riscv64 in both commands.
copycds looks for EFI/BOOT/grubriscv64.efi on riscv64 media. openEuler
media carry the same image as EFI/BOOT/grubriscv64.EFI, so copycds
publishes no grub2.riscv64. A management node with only openEuler media
then has no riscv64 network boot loader.
Match the image name case-insensitively, as UEFI does.
openEuler publishes 24.03 LTS installation media for riscv64, but the
openEuler media check admits only x86_64 and ppc64le. copycds stops with
"Unsupported openEuler architecture in .treeinfo".
Admit riscv64 as well. aarch64 stays refused.
python3-scapy was the only Depends of xcat-test that pulled in
python3. With scapy moved to Recommends, apt-get install
--no-install-recommends xcat-test can leave python3 absent, and every
blackboxtest command fails before it starts, not only the DHCP steps.
Add python3 to Depends. xcat_test_scapy_optional.t checks that python3
is a hard Depends, and fails without this change.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
With nodeauthentication off and no peer name, getpostscript used
_xcat_authname as the client identity and expanded it with noderange.
becomeuser and tokens set _xcat_authname to an account name, so a user
named after a node group received the postscripts of the first node in
that group.
xcatd now records the CN of the validated client certificate as
_xcat_certname, and only while no becomeuser or token replaced it. It
deletes any _xcat_certname the client sent. getpostscript uses that
name only when it names exactly one node, with no group or range
expansion. _xcat_authname is no longer a candidate.
getpostscript_client_identity.t drives the plugin with these requests.
On the previous head the group and node login checks fail, and
dropping the exact match fails the group and range checks.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
xCAT-server now asks for the perl(DB_File) capability on openSUSE,
because no openSUSE release ships a package named perl-DB_File. The
native package relation test still counted perl-DB_File in the SLES12
and SLES15 requirements, so both checks failed in xcat_pr_test.
Expect perl(DB_File) on the SLES platforms and keep perl-DB_File for
the others. The test fails against the upstream master spec and
passes with this branch.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
Shared image utilities must not require the Debian source directory.
Keep the profile helper beside imgutils and materialize the Debian copy
when building RPM and DEB packages. Source-only Debian copies must follow
symlinks; installed Debian directories stay self-contained.
xCAT installs on the leap15.6 node and the install gate still fails:
GATE FAIL: xcatd not active
GATE FAIL: lsdef cannot reach xcatd
GATE FAIL: site.xcatdport not seeded
journalctl for xcatd has no entries, and loading the library by hand on the
node says why:
Can't locate JSON.pm in @INC ... (@INC contains: /opt/xcat/lib/perl ...)
openSUSE has no perl-generators. Nothing generates a perl(...) requirement for
any xCAT package there, so no spec installs the modules its code loads, and
perl-xCAT names no Requires at all. Measured on xcat20-mn against the 85
external modules the EL build auto-requires: five are absent -- Date::Parse,
Expect, HTML::Form, JSON and SNMP -- and the other 80 are present.
Each openSUSE branch now names the modules EL's generator emits for that
package, as capabilities, so the same core build serves the sles15 and sles12
cells: both Leap releases provide all five, from perl-TimeDate, perl-Expect,
perl-HTML-Form, perl-JSON and perl-SNMP.
Verified with rpmspec that only openSUSE gets these; EL and openEuler are
unchanged and keep generating them.
xCAT-test/unit/opensuse_mn_requires.t fails on the commit before this one.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
current_os reads /etc/os-release and returns undef for openSUSE. The word sles
appears nowhere in Leap's os-release -- ID is opensuse-leap on 15.x and
opensuse on 42.3 -- and Leap ships none of /etc/redhat-release,
/etc/lsb-release or /etc/SuSE-release, so no other arm is reached. xcattest
rejects every case on the resulting undef, and 328 of the shipped cases declare
os:Linux.
openSUSE now answers with the SLE family whose package set it shares, which is
the answer decided on 2026-09-18 for the same bug: sles.pm claims leap15 and
xcat.org publishes the Leap dependencies under sles15. It also lets the 18
cases written os:sles select a Leap node, which a name of its own would not.
current_os has one consumer -- the os: comparison at xcattest:1052 -- so the
answer affects nothing else.
The match is on the whole file rather than on ID alone, because Leap 42.3
spells its ID opensuse and Tumbleweed opensuse-tumbleweed. It is placed after
the sles test, so a real SLES node is unaffected.
xcattest_os_selection.t passes, 19 of 19. Reverting this file alone fails its
five openSUSE assertions and nothing else.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
With the install dependencies resolved, xCAT installs on the leap15.6 node and
the install gate still fails:
[install] GATE: xcatd running + reachable with NO xcatconfig
GATE FAIL: xcatd not active
GATE FAIL: lsdef cannot reach xcatd
GATE FAIL: site.xcatdport not seeded
journalctl for xcatd has no entries at all, and loading the library by hand on
the node says why:
Can't locate JSON.pm in @INC ... (@INC contains: /opt/xcat/lib/perl ...)
openSUSE has no perl-generators, so no perl(...) requirement is generated for
any xCAT package and nothing installs the modules the code loads. Measured on
xcat20-mn against the 85 external modules the EL build auto-requires: five are
absent -- Date::Parse, Expect, HTML::Form, JSON and SNMP -- and the other 80
are present.
The test names, per spec, the modules that package's openSUSE branch must ask
for, mirroring what EL's generator emits for it. Nine assertions fail because
no spec names them yet.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
xCAT::Test::OS::current_os returns undef on openSUSE. /etc/os-release carries
ID="opensuse-leap" and the word sles appears nowhere in it, so the os-release
arm falls through to its own return undef, and Leap ships none of
/etc/redhat-release, /etc/lsb-release or /etc/SuSE-release to reach another arm.
xcattest then warns "Use of uninitialized value $currentos" four times per case
and rejects all of them: "Test case reg_linux_diskfull_installation_flat has an
invalid OS option - Linux" and "There is no valid case to run". 328 of the
shipped cases declare os:Linux, so an openSUSE management node runs none of
them. The message blames the case, and the cases are skipped rather than
failed, which reports no result at all.
Measured 2026-10-24 on xcat20-mn, an openSUSE Leap 15.6 management node:
current_os answered UNDEF, /etc/os-release holds ID="opensuse-leap" and
VERSION_ID="15.6", and none of the three fallback files exist.
Five assertions fail on this commit: Leap is recognised, at any Leap version,
the older ID="opensuse" spelling, Tumbleweed, and a Leap node matching an
os:Linux case. The fourteen that already existed pass, including the one that
holds the change down -- a distribution whose os-release names neither sles nor
openSUSE is still not recognised.
The same bug was fixed on 2026-09-18 in f7be54a1b, against the chain of greps
xcattest carried before xCAT::Test::OS existed. That branch was never merged,
3582c6ab1 rewrote the routine as a module without it, and its test lifted the
routine out of xcattest with a regex. This test loads the module instead.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
Both openSUSE test cells fail the install step:
leap15.6: nothing provides 'perl-DB_File' needed by xCAT-server
sles12: nothing provides (/usr/sbin/dhcpd if openEuler-release else
((kea and kea-hooks) if (system-release >= 10) else
/usr/sbin/dhcpd)) needed by xCAT
Two requirements are written for EL and have no answer on openSUSE.
xCAT-server asks for perl-DB_File. No package of that name exists on Leap
15.6 or 42.3: 15.6 calls it perl-core-DB_File and 42.3 has neither. Both
provide the capability perl(DB_File), so openSUSE asks for the capability.
xCAT and xCATsn ask for dhcpd through a rich dependency. The sles12 cell is
an openSUSE 42.3 management node whose rpm is 4.11, which has no rich
dependencies and reports the whole expression as an unprovided capability.
Neither Leap release carries kea and both carry chrony and ISC dhcpd, so
openSUSE takes the plain names the expressions resolve to there anyway. One
core build serves both openSUSE cells, so the openSUSE branch must emit no
rich dependency at all.
Verified per platform with rpmspec. openSUSE now gets perl(DB_File),
/usr/sbin/dhcpd and chrony; EL9 keeps perl-DB_File and both expressions; EL10
keeps perl-DB_File as a Recommends; openEuler keeps both expressions.
xCAT-test/unit/opensuse_mn_requires.t fails on the commit before this one.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
Both openSUSE test cells fail the install step:
leap15.6: nothing provides 'perl-DB_File' needed by xCAT-server
sles12: nothing provides (/usr/sbin/dhcpd if openEuler-release else
((kea and kea-hooks) if (system-release >= 10) else
/usr/sbin/dhcpd)) needed by xCAT
Both requirements are written for EL and have no answer on openSUSE. No
package named perl-DB_File exists on Leap 15.6 or 42.3. The dhcpd expression
is a rich dependency, and the sles12 management node is openSUSE 42.3 with
rpm 4.11, which has none.
The test states what the openSUSE branch of each spec must ask for, and that
no rich dependency reaches an openSUSE build. It also holds down that EL and
openEuler keep the expressions they have. Four of its nine assertions fail
because no spec has an openSUSE branch for these requirements yet.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
The comment carried a date, a node, and the request counts from one run. The code
standard keeps bug history out of source comments: the fact a reader needs is that
the peer host is a reverse lookup and can be empty, which the remaining two sentences
state.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
openssl req reads the config file at OPENSSLDIR/openssl.cnf and exits 1 when it is
absent. install() in xCAT-genesis-base/dracut_105/{ubuntu,el}/module-setup.sh runs
dracut_install openssl, which copies the program and its shared libraries and nothing
else. OPENSSLDIR is /usr/lib/ssl on Ubuntu and /etc/pki/tls on EL, so the one file
doxcat writes serves EL alone, and getcert loops on openssl req until it gives up.
Measured on an Ubuntu compute node: /usr/lib/ssl did not exist, the image carried
/etc/pki/tls/openssl.cnf, and the key verified "RSA key ok". Supplying a config turned
the same command into a 1602 byte certificate request.
Each module now installs the config file that its own openssl names, and the image
build stops when that file is absent. getcert reports what openssl printed beside the
key it used, and reads the file with bash builtins so it needs no external command.
Two mutations, each failing only the cases that name it: dropping the install call
fails both module cases and keeps the other four; restoring the old message fails the
message case alone.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
A node boots Genesis, prints "Getting initial certificate --> MN:3001" and goes no
further. xcatd records no credential request, the node status stays at powering-on,
and every case that waits for the node fails.
genesis_openssl_config.bats drives each dracut module's install() with the dracut
helpers replaced by a recorder, so it reads what the module asks the payload to carry.
genesis_getcert_missing_openssl.bats gains one case: the give up message must repeat
what openssl printed, because a message naming only certkey.pem sends the reader to a
key that is intact.
Three of the six cases fail on this commit: both module cases, and the message case.
stub_dir defaulted count to the empty string, which left "{ ; exit 1; }" in the
openssl stub. That is a syntax error, so the stub failed for the wrong reason and
reported bash's message instead of openssl's. The default is now a no-op command.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
selinux_avc_classify matched the entries of XCAT_AVC_PATH as string prefixes,
with [^"]* before the alternation and no boundary after it. A directory name
is not a string prefix: /var/lib/xcat-cluster-test is not /var/lib/xcat, and
/installer is not /install.
The CI writes its regnotif notification hook to
/var/lib/xcat-cluster-test/event-notify.pl. xcatd executes it, the file
carries var_lib_t, and xcat_t has no execute_no_trans on it, so the audit log
holds the record. The classifier kept it on the strength of the prefix, the
count read XCAT_AVC=1, and selinux_cn_diskful_enforcing failed on a file the
product does not ship. The policy was confining xcat_t correctly.
The path half of the pattern now starts at the opening quote and ends at a /
or at the closing quote, so a listed directory matches itself and the files
under it, and nothing else. The subject half is unchanged: a denial by an
xCAT program is still kept whatever the path.
selinux_avc_check.bats covers it. Reverting the boundary group fails the
sibling-path test alone; requiring a trailing / fails the bare-directory test
alone.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
A compute node booted into legacy Genesis on Ubuntu refuses every ssh connection:
[xcat100-mn]: xcat100-cn: ssh: connect to host xcat100-cn port 22: Connection refused
and on the node's own console, once per boot:
Missing privilege separation directory
Debian and Ubuntu build sshd with --with-privsep-path=/run/sshd. The payload's own sshd
carries that path and the format string "Missing privilege separation directory: %s", and the
image ships /run holding only rpcbind. So sshd exits at startup and the node is unreachable.
nodeset_shell, nodeset_cmdline, nodeset_runimg and genesis_boot_proof_legacy all fail on it,
while seq_discovery, which needs no ssh, passes.
doxcat already does this for the other family: it creates /usr/share/empty.sshd, the EL
privsep path, with the comment "On some systems /usr/share/empty.sshd needs to be created
before calling sshd". The Debian path was never added, although the tree knows about it twice
-- remoteshell says "prepare the /var/run/sshd for ubuntu" and etc/init.d/functions creates
it. This adds the same lines for /run/sshd and /var/run/sshd.
Created immediately before sshd starts, not baked into the image: /run is a tmpfs on a
running system, so a directory under it does not survive the mount. The mode is set whether
or not the directory had to be created, because sshd refuses a group or world writable
privsep directory with the SAME message as an absent one, so a wrong mode is
indistinguishable from this bug.
genesis_sshd_privsep.bats asserts what sshd imposes -- the path is a directory, owned by the
user that will run sshd, and not group or world writable -- read at the moment sshd runs. The
recorder is bound over /usr/sbin/sshd because doxcat calls that absolute path, and because
recording from a later command cannot see the ORDER: with the recorder on a PATH command
instead, moving the directories after the sshd line still passed.
Five mutations, each red: removing the loop fails 2, never setting the mode fails 1, dropping
/var/run/sshd fails 2, a group-writable mode fails 2, and creating the directories after sshd
starts fails 2. The whole bats suite goes from 21 failures to 19 with this change, the
difference being these two tests; the other 19 are unrelated and fail on the base.
doxcat_sandbox.bash gains chmod, and a third test keeps the next one from being missed. The
sandbox curates PATH without /usr/bin, so a command it does not copy resolves to nothing and
fails SILENTLY: doxcat's chmod did nothing under test for as long as this sandbox has
existed, and any assertion about a mode could never pass. The guard installs bash's
command_not_found_handle through BASH_ENV and fails naming whatever doxcat invoked and could
not resolve, so it needs no list to keep current. With chmod removed again it reports exactly
"chmod". Its reach is the commands doxcat runs on the path the test drives, which is a floor
rather than a completeness check on the helper's list.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
selinux_avc_check.sh decides which SELinux denials xCAT answers for by
matching the audit record's path against XCAT_AVC_PATH. The match treats each
entry as a string prefix, so a sibling directory whose name merely starts with
one of them is kept. On build 2 of xcat-test-el10-x86_64-selinux the one
denial the run attributed to xCAT was xcatd executing the CI's own
notification hook under /var/lib/xcat-cluster-test, and
selinux_cn_diskful_enforcing failed on it.
The new bats test classifies that record and asserts nothing is kept. Two
more assert the directories themselves and a file under one are still kept,
so an over-anchored match does not pass silently.
Without the fix 1 of 18 fails, and it is the sibling-path test. The other two
pass before and after.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
node_pingable asks ICMP up to PING_TRIES times and stops at the first answer,
so a few seconds of loss after a node boots no longer forces a second full
rinstall. A node that never answers still reports non-pingable, and the caller
still vetoes it: the signal is kept, not removed.
The probe is lifted into a function with a main-guard rather than left inline,
so a bats test can drive it without running a provisioning loop or needing an
xCAT database. Nothing sources this script -- all nine callers execute it -- so
the guard changes no caller.
The happy path is unchanged at one ask. A node that never answers now costs
PING_TRIES asks before the verdict, which is under a minute against the six
minutes of the reinstall it decides.
retry_install_transient_icmp.bats passes 5 of 5. Removing the bounded retry
fails assertions 2 and 4, which are the retry properties, and leaves assertion 3
passing -- a node that never answers is still not pingable. That assertion is
the discriminator: without it the change could not be told apart from deleting
the check, which would turn a flaky probe into one that cannot fail.
xCAT-test/bats is 596 passed, 19 failed. All 19 are
xcatroot_rootimg_checksum.bats, which reports 0 passed and 19 failed on
upstream master with none of this branch applied.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
retry_install.sh declares a provision successful only when tobooted, pingable
and canruncmd are all 0. pingable came from a single `ping -c 2`, and ICMP to a
node is lossy for a few seconds after it finishes booting.
Measured on an openSUSE Leap 15.6 cluster: one sample reported "2 packets
transmitted, 0 received" while `xdsh <node> date` returned the node's own clock
a second later, so the node was up and answering SSH. The conjunction failed on
ICMP alone, the case ran a second full rinstall, and that cost 401 of the 404
seconds between two runs of the same cell. The second run lost 2 of 3 packets at
a moment that was not the decision point and passed first try. The difference
between the two runs was which side of a two-packet sample landed, not the state
of either node.
The probe is tested in bats, because it is shell. It is driven with a stubbed
ping, so what is measured is how many times the probe asks and what it answers,
not whether the build host can reach anything.
All five assertions fail on this commit, because node_pingable does not exist
yet and sourcing the script still runs lsdef. The graded evidence is the
mutation recorded in the fix commit.
`run` is used rather than a bare call: bats fails a test on any non-zero command
in its body and `set +e` does not suppress that, so asserting on a non-zero
return without `run` aborts the test instead of measuring it.
Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>