Fix pre trigger stage by replacing exit with return 0 and 95fcoe default rd.nofcoe to false

This commit is contained in:
hanzj0122_admin 2020-05-15 23:13:07 +08:00
parent 65e19688b9
commit b59a966f49
3 changed files with 75 additions and 2 deletions

View File

@ -0,0 +1,28 @@
From 7fb8f939a52a904b1860e303a6a7fe69ba0d2ceb Mon Sep 17 00:00:00 2001
From: Radek Vykydal <rvykydal@redhat.com>
Date: Tue, 10 Mar 2020 10:48:21 +0100
Subject: [PATCH 2/2] Fix pre-trigger stage by replacing exit with return in
lldpad.sh
Using exit makes the pre-trigger stage finish after running 03-lldpad.sh
pre-trigger hook.
---
modules.d/95fcoe/lldpad.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/modules.d/95fcoe/lldpad.sh b/modules.d/95fcoe/lldpad.sh
index c32feee..444c943 100755
--- a/modules.d/95fcoe/lldpad.sh
+++ b/modules.d/95fcoe/lldpad.sh
@@ -2,7 +2,7 @@
if ! getargbool 0 rd.nofcoe ; then
info "rd.nofcoe=0: skipping lldpad activation"
- exit 0
+ return 0
fi
# Note lldpad will stay running after switchroot, the system initscripts
--
1.8.3.1

View File

@ -0,0 +1,41 @@
From 8446c8f9deefcc6c47d96a128b1e9b23d8855a96 Mon Sep 17 00:00:00 2001
From: Thomas Blume <Thomas.Blume@suse.com>
Date: Mon, 24 Feb 2020 12:11:25 +0100
Subject: [PATCH] 95fcoe: default rd.nofcoe to false
rd.nofcoe should default to false, e.g. fcoe should be enabled unless
overwritten from the command line.
The same applies for lldapd.sh.
---
modules.d/95fcoe/lldpad.sh | 2 +-
modules.d/95fcoe/parse-fcoe.sh | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/modules.d/95fcoe/lldpad.sh b/modules.d/95fcoe/lldpad.sh
index 444c943..7faa2e1 100755
--- a/modules.d/95fcoe/lldpad.sh
+++ b/modules.d/95fcoe/lldpad.sh
@@ -1,6 +1,6 @@
#!/bin/bash
-if ! getargbool 0 rd.nofcoe ; then
+if getargbool 0 rd.nofcoe ; then
info "rd.nofcoe=0: skipping lldpad activation"
return 0
fi
diff --git a/modules.d/95fcoe/parse-fcoe.sh b/modules.d/95fcoe/parse-fcoe.sh
index 8bb55c6..86f4331 100755
--- a/modules.d/95fcoe/parse-fcoe.sh
+++ b/modules.d/95fcoe/parse-fcoe.sh
@@ -13,7 +13,7 @@
# fcoe=eth0:nodcb:vn2vn
# fcoe=4a:3f:4c:04:f8:d7:nodcb:fabric
-if ! getargbool 0 rd.nofcoe ; then
+if getargbool 0 rd.nofcoe ; then
info "rd.nofcoe=0: skipping fcoe"
return 0
fi
--
1.8.3.1

View File

@ -9,7 +9,7 @@
Name: dracut
Version: 050
Release: 1
Release: 2
Summary: Initramfs generator using udev
@ -28,7 +28,8 @@ Patch0000: systemd-skip-dependency-add-for-non-existent-units.patch
Patch0001: dracut-network-fixed-net-rules-issue-hence-systemd-r.patch
Patch0002: skip-the-broken-sd-in-initqueue.patch
Patch0003: use-sleep-replace-check-sys-block.patch
Patch0004: 0001-Fix-pre-trigger-stage-by-replacing-exit-with-return.patch
Patch0005: 0002-95fcoe-default-rd.nofcoe-to-false.patch
Source1: https://www.gnu.org/licenses/lgpl-2.1.txt
Source2: openEuler.conf.example
@ -478,6 +479,9 @@ install -m 0755 51-dracut-rescue-postinst.sh $RPM_BUILD_ROOT%{_sysconfdir}/kerne
%endif
%changelog
* Fri May 15 2020 openEuler Buildteam <buildteam@openeuler.org> - 050-2
- Fix pre trigger stage by replacing exit with return 0 and 95fcoe default rd.nofcoe to false
* Mon May 11 2020 openEuler Buildteam <buildteam@openeuler.org> - 050-1
- Upgrade to 050