From e671c3a06a7e58461d4e9c9f3546cf6eac809300 Mon Sep 17 00:00:00 2001 From: Harald Hoyer Date: Tue, 4 Dec 2018 10:27:17 +0100 Subject: [PATCH] 95iscsi/module-setup.sh: do not require 'hostname' anymore (cherry picked from commit ebe1821635dd99f07c817179ee5358d27aab53c5) [lkundrak@v3.sk: fixes TEST-30 that fails with: dracut: dracut module 'iscsi' will not be installed, because command 'hostname' could not be found!] --- modules.d/40network/netroot.sh | 2 +- modules.d/95iscsi/module-setup.sh | 4 ++-- modules.d/98dracut-systemd/dracut-cmdline.sh | 2 +- modules.d/99base/init.sh | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/modules.d/40network/netroot.sh b/modules.d/40network/netroot.sh index 207364cd..654cfc72 100755 --- a/modules.d/40network/netroot.sh +++ b/modules.d/40network/netroot.sh @@ -66,7 +66,7 @@ if [ -z "$2" ]; then # Check: do we really know how to handle (net)root? [ -z "$root" ] && die "No or empty root= argument" - [ -z "$rootok" ] && die "Don't know how to handle 'root=$root'" + [ -z "$rootok" ] && die "X2 Don't know how to handle 'root=$root'" handler=${netroot%%:*} handler=${handler%%4} diff --git a/modules.d/95iscsi/module-setup.sh b/modules.d/95iscsi/module-setup.sh index 79af4a47..f6f3520d 100755 --- a/modules.d/95iscsi/module-setup.sh +++ b/modules.d/95iscsi/module-setup.sh @@ -4,7 +4,7 @@ check() { local _rootdev # If our prerequisites are not met, fail anyways. - require_binaries hostname iscsi-iname iscsiadm iscsid || return 1 + require_binaries iscsi-iname iscsiadm iscsid || return 1 # If hostonly was requested, fail the check if we are not actually # booting from root. @@ -206,7 +206,7 @@ cmdline() { install() { inst_multiple -o iscsiuio inst_libdir_file 'libgcc_s.so*' - inst_multiple umount hostname iscsi-iname iscsiadm iscsid + inst_multiple umount iscsi-iname iscsiadm iscsid inst_multiple -o \ $systemdsystemunitdir/iscsid.socket \ diff --git a/modules.d/98dracut-systemd/dracut-cmdline.sh b/modules.d/98dracut-systemd/dracut-cmdline.sh index bff9435a..89c52d13 100755 --- a/modules.d/98dracut-systemd/dracut-cmdline.sh +++ b/modules.d/98dracut-systemd/dracut-cmdline.sh @@ -76,7 +76,7 @@ case "${root}${root_unset}" in esac [ -z "${root}${root_unset}" ] && die "Empty root= argument" -[ -z "$rootok" ] && die "Don't know how to handle 'root=$root'" +[ -z "$rootok" ] && die "X1 Don't know how to handle 'root=$root'" export root rflags fstype netroot NEWROOT diff --git a/modules.d/99base/init.sh b/modules.d/99base/init.sh index e4f7cff1..3e20069f 100755 --- a/modules.d/99base/init.sh +++ b/modules.d/99base/init.sh @@ -136,7 +136,7 @@ getarg 'rd.break=cmdline' -d 'rdbreak=cmdline' && emergency_shell -n cmdline "Br source_hook cmdline [ -z "$root" ] && die "No or empty root= argument" -[ -z "$rootok" ] && die "Don't know how to handle 'root=$root'" +[ -z "$rootok" ] && die "X0 Don't know how to handle 'root=$root'" export root rflags fstype netroot NEWROOT