Skip to content

Commit 3471f60

Browse files
committed
test: skip TEST-84-STORAGETM if running with bugged libnvme
libnvme 1.11 appears to require a kernel built with NVME TLS kconfigs, and fails hard if it is not, as the expected privileged keyring '.nvme' is not present. We cannot just create it from userspace, as privileged keyrings can only be created by the kernel itself (those starting with '.'). Skip the test if the library exactly matches this version. linux-nvme/nvme-cli#2573 Fixes systemd/systemd#35130 (cherry picked from commit 893aa45) (cherry picked from commit d8ec277)
1 parent 45b39f9 commit 3471f60

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

test/units/testsuite-84.sh

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,14 @@
33
set -eux
44
set -o pipefail
55

6+
if systemd-analyze compare-versions "$(nvme --version | grep libnvme | awk '{print $3}')" eq 1.11; then
7+
if grep -q "CONFIG_NVME_TCP_TLS is not set" "/boot/config-$(uname -r)" 2>/dev/null || grep -q "CONFIG_NVME_TCP_TLS is not set" "/usr/lib/modules/$(uname -r)/config" 2>/dev/null; then
8+
# See: https://github.com/linux-nvme/nvme-cli/issues/2573
9+
echo "nvme-cli is broken and requires TLS support in the kernel" >/skipped
10+
exit 77
11+
fi
12+
fi
13+
614
modprobe -v nvmet-tcp
715
modprobe -v nvme-tcp
816

0 commit comments

Comments
 (0)