ALT Linux Bugzilla
– Attachment 795 Details for
Bug 6397
rc.sysinit script should try not only raidtools but also mdadm for mounting md devices
New bug
|
Search
|
[?]
|
Help
Register
|
Log In
[x]
|
Forgot Password
Login:
[x]
|
EN
|
RU
[patch]
Support mdadm in addition to raidtools for mounting RAID devices
rc.sysinit-raid.patch (text/plain), 1.11 KB, created by
evseev
on 2005-04-04 03:28:07 MSD
(
hide
)
Description:
Support mdadm in addition to raidtools for mounting RAID devices
Filename:
MIME Type:
Creator:
evseev
Created:
2005-04-04 03:28:07 MSD
Size:
1.11 KB
patch
obsolete
>--- rc.sysinit.orig 2005-04-01 19:36:49 +0400 >+++ rc.sysinit 2005-04-04 03:01:09 +0400 >@@ -285,11 +285,22 @@ > fi > > # Add raid devices >-if [ -z "$EVMS_ACTIVE" ] && [ -f /proc/mdstat -a -s /etc/raidtab ] && ! grep -iwqs noraidtab /proc/cmdline; then >- echo -n "Starting up RAID devices: " > >- rc=0 >- >+raid_helpers_found() { >+ [ -s /etc/mdadm.conf ] && return 0 >+ [ -s /etc/raidtab ] && return 0 >+ return 1 >+} >+ >+mount_raid_using_mdadm() { >+ [ -s /etc/mdadm.conf ] || return 1 >+ [ -x /sbin/mdadm ] || return 1 >+ /sbin/mdadm --assemble --scan >+} >+ >+mount_raid_using_raidtools() { >+ local rc=0 >+ [ -s /etc/raidtab ] || return 1 > for i in `grep -s "^raiddev" /etc/raidtab | awk '{print $2}'`; do > RAIDDEV="${i##*/}" > RAIDSTAT=`grep -s "^$RAIDDEV : active" /proc/mdstat` >@@ -315,6 +326,14 @@ > fi > echo -n "$RAIDDEV " > done >+ return $rc >+} >+ >+if [ -z "$EVMS_ACTIVE" ] && [ -f /proc/mdstat ] && raid_helpers_found && ! grep -iwqs noraidtab /proc/cmdline; then >+ >+ echo -n "Starting up RAID devices: " >+ rc=0 >+ mount_raid_using_mdadm || mount_raid_using_raidtools || rc=1 > echo > > # A non-zero return means there were problems.
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 6397
:
795
|
796
|
802
|
836