From 754eced171d0c5ab7c82e984ab72f3f35af7d27f Mon Sep 17 00:00:00 2001 From: Audiobuzz Date: Sun, 14 Jun 2026 10:26:23 +0000 Subject: [PATCH] Disable lz4 compression as the kernel doesnt support it --- docs/TODO.md | 9 +++++++++ scripts/extract-artifacts.sh | 14 ++++++++++---- 2 files changed, 19 insertions(+), 4 deletions(-) diff --git a/docs/TODO.md b/docs/TODO.md index 73c023b..441b9fa 100644 --- a/docs/TODO.md +++ b/docs/TODO.md @@ -128,6 +128,15 @@ boot LAN. - `nvme_tcp`/`nvme_fabrics` must be loaded before `/dev/nvme-fabrics` exists (dracut's `nvmf` module does this in a normal boot; at `rd.break` modprobe manually). + - The target Rocky 9 kernel's erofs is built **without + `CONFIG_EROFS_FS_ZIP`** — mounting a compressed image fails `erofs: lz4 + algorithm isn't enabled`, which silently blocks the root mount. **Fixed:** + `extract-artifacts.sh` now builds the erofs **uncompressed** (`mkfs.erofs` + without `-z`). Tradeoff: larger rootfs namespace + more NVMe/TCP bandwidth + per read. Re-enable compression only against a kernel verified to have + `EROFS_FS_ZIP` (`grep CONFIG_EROFS /boot/config-$(uname -r)`). This is the + CLAUDE.md bench-verify item ("erofs module availability on the target RHEL + kernel"). Larger image size also feeds the "shrink the rootfs" angle of #7. - SPDK: add the listener to the discovery subsystem explicitly (`nqn.2014-08.org.nvmexpress.discovery`) to silence the deprecation warning. diff --git a/scripts/extract-artifacts.sh b/scripts/extract-artifacts.sh index 0ad5ea0..f083e13 100755 --- a/scripts/extract-artifacts.sh +++ b/scripts/extract-artifacts.sh @@ -56,11 +56,17 @@ tar -C "$WORK/root" --numeric-owner -xpf "$WORK/rootfs.tar" rm -rf "$WORK/root/boot/"* "$WORK/rootfs.tar" # diskless hosts don't need /boot echo "==> Building reproducible erofs image" -# -T0 + fixed UUID => deterministic output => stable dm-verity root hash -# for identical input trees. lz4hc: good ratio, cheap decompress; saves -# fabric bandwidth (and MACsec cycles) on every read. +# UNCOMPRESSED on purpose: the target Rocky 9 kernel's erofs is built without +# CONFIG_EROFS_FS_ZIP, so mounting a compressed image fails at boot with +# "erofs: lz4 algorithm isn't enabled" (verified on the bench — the root mount +# never completes). An uncompressed image mounts with base CONFIG_EROFS_FS +# alone. Tradeoff: larger namespace + more NVMe/TCP bandwidth per read than the +# old `-z lz4hc`. Re-add compression (`-z lz4hc`, or zstd/deflate) ONLY against +# a kernel you've confirmed has EROFS_FS_ZIP (grep CONFIG_EROFS /boot/config-*). +# -T0 + fixed UUID keep output deterministic => stable dm-verity root hash for +# identical input trees. FIXED_UUID="6c10a7f0-1d2e-4f5a-9b3c-000000000001" -mkfs.erofs -z lz4hc -T 0 -U "$FIXED_UUID" --all-root \ +mkfs.erofs -T 0 -U "$FIXED_UUID" --all-root \ "$WORK/rootfs.erofs" "$WORK/root" echo "==> Appending dm-verity hash tree (single-file / single-namespace layout)"