summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAaron Griffin <aaron@archlinux.org>2006-10-15 20:45:23 +0200
committerAaron Griffin <aaron@archlinux.org>2006-10-15 20:45:23 +0200
commitd57c0f96054aeb4d310d6e5af098b3a5d72a66ff (patch)
treefd015e0deb4e2b0732e6873af17683eee5e76a25
parent9760335102c3f14789864125aae1dc897285b4e2 (diff)
downloadmkinitcpio-d57c0f96054aeb4d310d6e5af098b3a5d72a66ff.tar.gz
mkinitcpio-d57c0f96054aeb4d310d6e5af098b3a5d72a66ff.tar.xz
Added disk group check for filesystem detection
git-svn-id: http://projects.archlinux.org/svn/initramfs/mkinitcpio@174 880c04e9-e011-0410-abf7-b926e227c9cd
-rw-r--r--install/autodetect19
1 files changed, 9 insertions, 10 deletions
diff --git a/install/autodetect b/install/autodetect
index 87f343c..01b4f48 100644
--- a/install/autodetect
+++ b/install/autodetect
@@ -20,22 +20,21 @@ install ()
done
}
- for fs in $(findfs | sort | uniq); do
- for mod in $(find "${MODULEDIR}" -type f -name "${fs}.ko"); do
- if [ "x${mod}" != "x" ]; then
- AUTODETECT="${AUTODETECT} ${mod}"
- fi
- done
- done
-
-
if [ -e /sbin/mdadm ]; then
if [ $UID -eq 0 -o "$(groups | grep disk)" != "" ]; then
+ for fs in $(findfs | sort | uniq); do
+ for mod in $(find "${MODULEDIR}" -type f -name "${fs}.ko"); do
+ if [ "x${mod}" != "x" ]; then
+ AUTODETECT="${AUTODETECT} ${mod}"
+ fi
+ done
+ done
+
AUTODETECT="$AUTODETECT
$(mdadm -E -s /dev/hd* /dev/sd* /dev/rd/* /dev/ida/* /dev/cciss/* /dev/ataraid/* \
| awk -Flevel= '{print $2}' | awk '{print $1}')"
else
- err "User does not have proper permissions to read superblocks, raid modules are not detected"
+ err "User does not have proper permissions to read superblocks, raid and filesystem modules are not detected"
fi
fi