2005-04-16 16:20:36 -06:00
|
|
|
#!/bin/sh
|
|
|
|
# set aoe to autoload by installing the
|
2012-03-30 14:37:16 -06:00
|
|
|
# aliases in /etc/modprobe.d/
|
2005-04-16 16:20:36 -06:00
|
|
|
|
2012-03-30 14:37:16 -06:00
|
|
|
f=/etc/modprobe.d/aoe.conf
|
2005-04-16 16:20:36 -06:00
|
|
|
|
|
|
|
if test ! -r $f || test ! -w $f; then
|
|
|
|
echo "cannot configure $f for module autoloading" 1>&2
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
grep major-152 $f >/dev/null
|
|
|
|
if [ $? = 1 ]; then
|
|
|
|
echo alias block-major-152 aoe >> $f
|
|
|
|
echo alias char-major-152 aoe >> $f
|
|
|
|
fi
|
|
|
|
|