aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBill Nottingham <notting@redhat.com>2001-03-08 03:21:17 +0000
committerBill Nottingham <notting@redhat.com>2001-03-08 03:21:17 +0000
commit9ccd339ac9079d30b3c58e8e5b1ff8b85e7808df (patch)
treee3bdea80710d45bbbf46495316a4b2862eba9201
parentfce030f14b119c69682b7b36875fc5880f1e2322 (diff)
downloadinitscripts-9ccd339ac9079d30b3c58e8e5b1ff8b85e7808df.tar
initscripts-9ccd339ac9079d30b3c58e8e5b1ff8b85e7808df.tar.gz
initscripts-9ccd339ac9079d30b3c58e8e5b1ff8b85e7808df.tar.bz2
initscripts-9ccd339ac9079d30b3c58e8e5b1ff8b85e7808df.tar.xz
initscripts-9ccd339ac9079d30b3c58e8e5b1ff8b85e7808df.zip
tweak raid startup slightly to deal with /etc/raitab but no raid in the kernel (#25291)
-rwxr-xr-xrc.d/rc.sysinit12
1 files changed, 6 insertions, 6 deletions
diff --git a/rc.d/rc.sysinit b/rc.d/rc.sysinit
index 699c1b10..8b27bcdc 100755
--- a/rc.d/rc.sysinit
+++ b/rc.d/rc.sysinit
@@ -409,7 +409,11 @@ if [ -f /etc/rc.modules ]; then
fi
# Add raid devices
-if [ -f /etc/raidtab ]; then
+if [ ! -f /proc/mdstat ]; then
+ modprobe md >/dev/null 2>&1
+fi
+
+if [ -f /proc/mdstat -f /etc/raidtab ]; then
echo -n $"Starting up RAID devices: "
rc=0
@@ -417,11 +421,7 @@ if [ -f /etc/raidtab ]; then
for i in `grep "^raiddev" /etc/raidtab | awk '{print $2}'`
do
RAIDDEV=`basename $i`
- if [ -f /proc/mdstat ]; then
- RAIDSTAT=`grep "^$RAIDDEV : active" /proc/mdstat`
- else
- RAIDSTAT=""
- fi
+ RAIDSTAT=`grep "^$RAIDDEV : active" /proc/mdstat`
if [ -z "$RAIDSTAT" ]; then
# Try raidstart first...if that fails then
# fall back to raidadd, raidrun. If that