mirror of
https://github.com/xcat2/xcat-core.git
synced 2026-09-21 16:39:30 +00:00
1db2c7cde0
The nodeset_shell_incorrectmasterip case passed while "nodeset testnode shell" failed with "/tftpboot/boot/grub2/grub2.x86_64 does not exits". The grub2 sub-case asserted nothing. Every genesis case reported "After 30 iterations node status: powering-on" and passed anyway. check_destiny in xCAT-test/autotest/testcase/genesis/test.sh discarded the return value of runcmd and read the boot configuration file, which grub2.pm writes before it stops on the missing boot loader. xCAT builds no grub2 boot loader for x86_64, so the file is absent on a correctly built management node. wait_for_boot in genesistest.pl waited for nodelist.status "booted"; a Genesis node reports its destiny with getdestiny and xcatd writes "shell", "configuring" or "booting" from it. Every caller discarded the return value. The node did not reach even those statuses, because getdestiny makes its request file with mktemp and the dracut module never installed it. check_destiny now returns the status of nodeset, and the grub2 check stages an empty grub2.<arch> when the management node has none and removes it after. wait_for_node_status takes the status the destiny implies and each caller fails when the node does not reach it; the shell case moved into run_nodeset_shell_test so its result can be read. clearenv no longer waits, because "rinstall <node> boot" boots a disk with no operating system and reports nothing. The dracut modules install mktemp and verify-genesis-payload requires it. Tests: genesis_incorrectmasterip_check.t runs the check with a failing nodeset and reads whether the boot loader is present when nodeset runs; genesis_testcase_helpers.t drives the status wait and the shell case; genesis_payload_verification.t reads a payload without mktemp. Each fails on the parent commit. Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com> (cherry picked from commit 8ecf0a806785023aca0ea6d1b0e41810630816b2) The Release hunk of the original commit is dropped. buildrpms.pl writes Release from SOURCE_DATE_EPOCH at build time, so the committed snap stamp is build debris.