Commit a42ae961 authored by David Johnson's avatar David Johnson
Browse files

Add support for GRUB as the bootloader in disk images. Just whacks the

root=/dev/XXX param in /boot/grub/grub.conf, since grub.conf gets read at
boot by the bootloader.
parent 08ed10cb
...@@ -294,6 +294,17 @@ dolinux() { ...@@ -294,6 +294,17 @@ dolinux() {
return 1 return 1
} }
#
# If there's a GRUB config file, update all root=X kernel params.
#
gconf=/mnt/boot/grub/grub.conf
if [ -r $gconf ]; then
echo " updating /boot/grub/grub.conf"
sed -i .orig -e "s;\([br]oot=/dev\)/[hs]d.\([0-7]\);\1/${ldisk}\2;" $gconf || {
echo "Failed to update /boot/boot/grub/grub.conf"
}
fi
# #
# If using lilo, update lilo.conf and set indicator to tell Emulab # If using lilo, update lilo.conf and set indicator to tell Emulab
# to rerun lilo. # to rerun lilo.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment