diff --git a/base/mkinitrd/initrdinit.sh b/base/mkinitrd/initrdinit.sh index 47d180ac2..d31172bbf 100644 --- a/base/mkinitrd/initrdinit.sh +++ b/base/mkinitrd/initrdinit.sh @@ -58,6 +58,27 @@ filesystems=`disktype $root 2>/dev/null | mkdir /rootfs +if [ -x /sbin/mdadm ]; then + echo "Detecting possible RAID devices" + mdadm -Es > /etc/mdadm.conf 2> /dev/null + if [ -s /etc/mdadm.conf ]; then + echo "Activating RAID devices" + modprobe md-mod + mdadm -As --auto=yes + fi +fi + +if [ -x /sbin/lvm ]; then + echo "Detecting possible LVM devices" + lvm vgscan + + if [ -s /etc/lvm/cache/.cache ]; then + echo "Activating LVM devices" + modprobe dm_mod + lvm vgchange -ay + fi +fi + if [ "$root" ]; then i=0 while [ $i -le 9 ]; do