martin f. krafft: Scan arrays every day to prevent missing failed arrays

Martin F. Krafft madduck at alioth.debian.org
Sat Apr 25 17:45:11 UTC 2009


Module: mdadm
Branch: master
Commit: 474c51d734e670ea2af0eed200f29677d5f33f6f
URL:    http://git.debian.org/?p=pkg-mdadm/mdadm.git;a=commit;h=474c51d734e670ea2af0eed200f29677d5f33f6f

Author: martin f. krafft <madduck at debian.org>
Date:   Sat Apr 25 17:55:59 2009 +0200

Scan arrays every day to prevent missing failed arrays

Adds cron.daily snippet from Paul Slootman to run one-shot scans every day to
ensure that failed arrays don't go unnoticed.

Debian bug: 497949

Signed-off-by: martin f. krafft <madduck at debian.org>

---

 debian/changelog        |    2 ++
 debian/mdadm.cron.daily |   18 ++++++++++++++++++
 2 files changed, 20 insertions(+), 0 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index eb497b7..88120e0 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -15,6 +15,8 @@ mdadm (2.6.9-1) unstable; urgency=low
     this is not the case (closes: #519328).
   * Make checkarray skip over arrays still marked auto-read-only
     (closes: #510641).
+  * Add cron.daily snippet from Paul Slootman to run one-shot scans every day
+    to ensure that failed arrays don't go unnoticed (closes: #497949).
 
  -- martin f. krafft <madduck at debian.org>  Thu, 12 Mar 2009 13:08:43 +0100
 
diff --git a/debian/mdadm.cron.daily b/debian/mdadm.cron.daily
new file mode 100644
index 0000000..d5ac1ae
--- /dev/null
+++ b/debian/mdadm.cron.daily
@@ -0,0 +1,18 @@
+#!/bin/sh
+#
+# cron.daily/mdadm -- daily check that MD devices are functional
+#
+# Copyright © 2008 Paul Slootman <paul at debian.org>
+# distributed under the terms of the Artistic Licence 2.0
+
+# As recommended by the manpage, run
+#      mdadm --monitor --scan --oneshot
+# every day to ensure that any degraded MD devices don't go unnoticed.
+# Email will go to the address specified in /etc/mdadm/mdadm.conf .
+#
+set -eu
+
+MDADM=/sbin/mdadm
+[ -x $MDADM ] || exit 0 # package may be removed but not purged
+
+exec $MDADM --monitor --scan --oneshot




More information about the pkg-mdadm-commits mailing list