Merge branch 'master' into kernel38

This commit is contained in:
Arne Fitzenreiter
2011-04-26 08:51:24 +02:00
10 changed files with 78 additions and 32 deletions

View File

@@ -1,6 +1,6 @@
#!/bin/sh
########################################################################
# Begin $rc_base/init.d/mdadmraid
# Begin $rc_base/init.d/mdadm
#
# Description : This script controls software Raid
#
@@ -17,28 +17,15 @@
case "${1}" in
start)
if [ -f /etc/mdadm.conf ]
then
boot_mesg "Starting Raid devices..."
modprobe md
modprobe raid0
modprobe raid1
modprobe raid5
sleep 1
mdadm --assemble --scan
else
boot_mesg "Skipping raid devices, no config found..."
exit 1
fi
boot_mesg "Scan/assemble mdadm raid devices..."
mdadm --assemble --scan
echo_ok
;;
stop)
boot_mesg "Stopping Raid devices..."
mdadm --stop --scan
echo_ok
;;
restart)
@@ -57,4 +44,4 @@ case "${1}" in
;;
esac
# End $rc_base/init.d/mdadmraid
# End $rc_base/init.d/mdadm

View File

@@ -26,11 +26,6 @@ check_drives () {
case "${1}" in
start)
if [ -e /sbin/mdadm ]; then
boot_mesg "Assemble mdadm managed raid-drives ..."
mdadm --assemble --scan
fi
drives=`grep "^UUID=" /etc/fstab | cut -f1 | cut -d" " -f1 | cut -d"=" -f2`;
check_drives;

View File

@@ -3,8 +3,8 @@
case "$1" in
ide)
/sbin/kudzu -qps -c HD | egrep "desc|device:" | awk -F': ' '{print $2}' | sed -e '/"$/a\\' -e "s/$/\;/g" | tr "\n" "XX" | sed -e "s/XX/\n/g" -e "s/\;X/\;/g" | grep '^"' -v > /var/ipfire/extrahd/scan
if [ -e /dev/md ]; then
echo 'md;"MDADM software-raid";' >> /var/ipfire/extrahd/scan
if [ -e /dev/.mdadm ]; then
echo 'md;"MD Software-Raid";' >> /var/ipfire/extrahd/scan
fi
if [ -e /dev/mmcblk0 ]; then
echo 'mmcblk0;"MMC/SD Cardreader";' >> /var/ipfire/extrahd/scan