i-t: let rootdelay= set $ZFS_INITRD_PRE_MOUNTROOT_SLEEP

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Ref: https://github.com/openzfs/zfs/issues/11420#issuecomment-850338673
Closes #11663
Closes #12148
This commit is contained in:
наб 2021-05-28 13:55:12 +02:00 committed by Brian Behlendorf
parent d484a7255b
commit 7b5bf4758b

View File

@ -273,6 +273,8 @@ import_pool()
# with more logging etc. # with more logging etc.
load_module_initrd() load_module_initrd()
{ {
[ -n "$ROOTDELAY" ] && ZFS_INITRD_PRE_MOUNTROOT_SLEEP="$ROOTDELAY"
if [ "$ZFS_INITRD_PRE_MOUNTROOT_SLEEP" -gt 0 ] 2>/dev/null if [ "$ZFS_INITRD_PRE_MOUNTROOT_SLEEP" -gt 0 ] 2>/dev/null
then then
if [ "$quiet" != "y" ]; then if [ "$quiet" != "y" ]; then