dracut/0008-90mdraid-md-shutdown.sh-put-shutdown-in-function.patch

31 lines
941 B
Diff
Raw Normal View History

From 8e448cadf9fe979ac951b3ca6b5d3a5eecc150c2 Mon Sep 17 00:00:00 2001
From: Harald Hoyer <harald@redhat.com>
Date: Wed, 20 Jul 2011 19:06:26 +0200
Subject: [PATCH] 90mdraid/md-shutdown.sh: put shutdown in function
---
modules.d/90mdraid/md-shutdown.sh | 16 ++++++++++++++--
1 files changed, 14 insertions(+), 2 deletions(-)
diff --git a/modules.d/90mdraid/md-shutdown.sh b/modules.d/90mdraid/md-shutdown.sh
index f07f621..aa89bf6 100644
--- a/modules.d/90mdraid/md-shutdown.sh
+++ b/modules.d/90mdraid/md-shutdown.sh
@@ -1,2 +1,14 @@
-echo "Disassembling mdraid devices."
-mdadm -v --stop --scan
+#!/bin/sh
+# -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*-
+# ex: ts=8 sw=4 sts=4 et filetype=sh
+_do_md_shutdown() {
+ local ret
+ info "Disassembling mdraid devices."
+ mdadm -v --stop --scan
+ ret=$?
+#info "cat /proc/mdstat"
+# cat /proc/mdstat | vinfo
+ return $ret
+}
+
+_do_md_shutdown