aboutsummaryrefslogtreecommitdiff
path: root/handlers/sys.in
diff options
context:
space:
mode:
authorintrigeri <intrigeri@boum.org>2010-03-06 15:27:34 +0100
committerintrigeri <intrigeri@boum.org>2010-03-06 15:27:34 +0100
commit7dce2f1138796cfb78c22a402b6039bdf76d4220 (patch)
tree9fed26da8517079fb1879aced22ead9a593e7186 /handlers/sys.in
parent81921efa98093b5bab8d8d62b92120076bfc6810 (diff)
downloadbackupninja-7dce2f1138796cfb78c22a402b6039bdf76d4220.tar.gz
backupninja-7dce2f1138796cfb78c22a402b6039bdf76d4220.tar.bz2
sys: only run mdadm if RAID devices actually exist (Closes: #572450)
Diffstat (limited to 'handlers/sys.in')
-rwxr-xr-xhandlers/sys.in4
1 files changed, 3 insertions, 1 deletions
diff --git a/handlers/sys.in b/handlers/sys.in
index 69751ed..a92663e 100755
--- a/handlers/sys.in
+++ b/handlers/sys.in
@@ -462,7 +462,9 @@ STATUS="Collecting Software RAID information (/etc/mdadm.conf)"
catiffile "/etc/mdadm.conf"
STATUS="Collecting Software RAID information (/sbin/mdadm -Q)"
-catifexec "/sbin/mdadm" "-Q" "--detail" '/dev/md?*'
+if ls /dev/md?* >/dev/null 2>&1; then
+ catifexec "/sbin/mdadm" "-Q" "--detail" '/dev/md?*'
+fi
STATUS="Collecting Automount information (auto.master)"
catiffile "/etc/auto.master"