SHA256
1
0
forked from pool/mdadm

Accepting request 29763 from home:michal-m:branches:Base:System

Copy from home:michal-m:branches:Base:System/mdadm via accept of submit request 29763 revision 2.
Request was accepted with message:
Reviewed ok

OBS-URL: https://build.opensuse.org/request/show/29763
OBS-URL: https://build.opensuse.org/package/show/Base:System/mdadm?expand=0&rev=12
This commit is contained in:
Michal Marek
2010-01-15 16:44:42 +00:00
committed by Git OBS Bridge
parent b9f2c8ae10
commit b593e3099a
5 changed files with 81 additions and 45 deletions

View File

@@ -18,6 +18,11 @@
# load the necessary module before we initialize the raid system
load_modules
# put the mdmon socked and pid file to /dev/.mdadm
rm -rf /var/run/mdadm
mkdir -p /var/run
ln -s /dev/.mdadm /var/run/mdadm
mkdir -p /dev/.mdadm
[ "$mduuid" ] && md_uuid="$mduuid"
md_major=$(sed -ne 's/\s*\([0-9]\+\)\s*md$/\1/p' /proc/devices)
@@ -49,9 +54,19 @@ md_assemble()
else
mdconf="-c partitions"
fi
if test -n "$container"; then
case "$container" in
"")
;;
/dev/*)
mdadm -A $mdconf $container
;;
[0-9a-f]*[0-9a-f])
mdadm -A $mdconf --uuid="$container" /dev/md/container
fi
;;
*)
echo "unrecognized container for $dev: $container"
;;
esac
mdadm -A $mdconf $mdarg "$dev"
}