ab92d3
From 5818f56e99aecca0664f779c29c569f116f907e4 Mon Sep 17 00:00:00 2001
ab92d3
From: Mariusz Tkaczyk <mariusz.tkaczyk@linux.intel.com>
ab92d3
Date: Thu, 26 Nov 2020 12:51:47 +0100
ab92d3
Subject: [PATCH] fix(mdraid): add grow continue service
ab92d3
ab92d3
During raid assembly mdadm will call mdadm-grow-continue.service if
ab92d3
reshape is in progress.
ab92d3
If service doesn't exist then it is done via fork and systemd will kill
ab92d3
it unconditionally after processing all events.
ab92d3
ab92d3
Add proper service to allow systemd to manage reshape correctly.
ab92d3
ab92d3
Signed-off-by: Mariusz Tkaczyk <mariusz.tkaczyk@linux.intel.com>
ab92d3
(cherry picked from commit 29e269a5225ad8f658a8d7ef64d77d0c02f8e31d)
ab92d3
ab92d3
Resolves: #1958899
ab92d3
---
ab92d3
 modules.d/90mdraid/module-setup.sh | 3 +++
ab92d3
 1 file changed, 3 insertions(+)
ab92d3
ab92d3
diff --git a/modules.d/90mdraid/module-setup.sh b/modules.d/90mdraid/module-setup.sh
ab92d3
index 98a4ef5d..2e043041 100755
ab92d3
--- a/modules.d/90mdraid/module-setup.sh
ab92d3
+++ b/modules.d/90mdraid/module-setup.sh
ab92d3
@@ -136,6 +136,9 @@ install() {
ab92d3
         if [ -e $systemdsystemunitdir/mdadm-last-resort@.timer ]; then
ab92d3
             inst_simple $systemdsystemunitdir/mdadm-last-resort@.timer
ab92d3
         fi
ab92d3
+        if [ -e $dracutsysrootdir$systemdsystemunitdir/mdadm-grow-continue@.service ]; then
ab92d3
+            inst_simple $systemdsystemunitdir/mdadm-grow-continue@.service
ab92d3
+        fi
ab92d3
     fi
ab92d3
     inst_hook pre-shutdown 30 "$moddir/mdmon-pre-shutdown.sh"
ab92d3
     dracut_need_initqueue
ab92d3