]> git.ipfire.org Git - thirdparty/dracut-ng.git/commitdiff
fix(74nvmf): set root=nvmf main
authorTomas Bzatek <tbzatek@redhat.com>
Tue, 24 Jun 2025 14:50:31 +0000 (16:50 +0200)
committerLaszlo <laszlo.gombos@gmail.com>
Fri, 5 Sep 2025 22:40:41 +0000 (18:40 -0400)
In a restricted image like kdump the kernel commandline argument root=
is typically absent. However it is required by the 45net-lib/netroot.sh
module that fails with:

    [   23.599862] dracut: FATAL: No or empty root= argument
    [   23.604956] dracut: Refusing to continue

Inspired by the 74iscsi module, let's set it to root=nvmf if not set
before.

Signed-off-by: Tomas Bzatek <tbzatek@redhat.com>
modules.d/74nvmf/parse-nvmf-boot-connections.sh

index aad2a458da9cb846d4ad0bf32455ca8129c5b206..5288553fe2f1007f1aa84412d7936d34680abec6 100755 (executable)
@@ -326,3 +326,7 @@ fi
 
 /sbin/initqueue --settled --onetime --name nvmf-connect-settled /sbin/nvmf-autoconnect.sh settled
 /sbin/initqueue --timeout --onetime --name nvmf-connect-timeout /sbin/nvmf-autoconnect.sh timeout
+
+# shellcheck disable=SC2034
+rootok=1
+[ -z "$root" ] && root="nvmf"