From 99e52e22a47427e2deff1b67052ae60236999ce4 Mon Sep 17 00:00:00 2001 From: Florian La Roche Date: Fri, 5 Jul 2002 09:08:34 +0000 Subject: - rc.sysinit: do not load raid modules unless /etc/raidtab exists --- rc.d/rc.sysinit | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'rc.d/rc.sysinit') diff --git a/rc.d/rc.sysinit b/rc.d/rc.sysinit index 684808e5..69800905 100755 --- a/rc.d/rc.sysinit +++ b/rc.d/rc.sysinit @@ -341,7 +341,8 @@ mount -f /proc -# The root filesystem is now read-write, so we can now log via syslog() directly.. +# The root filesystem is now read-write, so we can now log +# via syslog() directly.. if [ -n "$IN_INITLOG" ]; then IN_INITLOG= fi @@ -354,8 +355,7 @@ fi # Our modutils don't support it anymore, so we might as well remove # the preferred link. -rm -f /lib/modules/preferred -rm -f /lib/modules/default +rm -f /lib/modules/preferred /lib/modules/default if [ -x /sbin/depmod -a -n "$USEMODULES" ]; then # If they aren't using a recent sane kernel, make a link for them if [ ! -n "`uname -r | grep -- "-"`" ]; then @@ -411,12 +411,12 @@ if [ -f /etc/rc.modules ]; then /etc/rc.modules fi -# Add raid devices -if [ ! -f /proc/mdstat ]; then - modprobe md >/dev/null 2>&1 -fi +if [ -f /etc/raidtab ]; then + # Add raid devices + [ -f /proc/mdstat ] || modprobe md >/dev/null 2>&1 +fi +if [ -f /etc/raidtab -a -f /proc/mdstat ]; then -if [ -f /proc/mdstat -a -f /etc/raidtab ]; then echo -n $"Starting up RAID devices: " rc=0 -- cgit v1.2.1