X-Git-Url: http://xvm.mit.edu/gitweb/invirt/packages/invirt-autoinstaller.git/blobdiff_plain/2de427228fdfbf454002ebe61cd0530b58b34ebd..230a7c475907a824d3a51c989e8cb68571b2d52d:/common/usr/lib/xen-tools/debian.d/93-setup-grub diff --git a/common/usr/lib/xen-tools/debian.d/93-setup-grub b/common/usr/lib/xen-tools/debian.d/93-setup-grub index 7989591..071f61c 100755 --- a/common/usr/lib/xen-tools/debian.d/93-setup-grub +++ b/common/usr/lib/xen-tools/debian.d/93-setup-grub @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash # # This script sets up the ParaVM to use pygrub # @@ -85,9 +85,9 @@ for i in $(seq 1 "$NUMPARTITIONS"); do swap) SWAP_GUEST="$(echo ${!var} | cut -f8 -d:)";; esac done -sed -i -e "s#root=[^ ]*#root=UUID=$ROOT_UUID#" ${prefix}/boot/grub/menu.lst -sed -i -e "s#${ROOT_GUEST}#${ROOT_UUID}#" ${prefix}/etc/fstab -sed -i -e "s#${SWAP_GUEST}#${SWAP_UUID}#" ${prefix}/etc/fstab +sed -i -re "s%^([= ]root=)[^ ]*%\1UUID=$ROOT_UUID%" ${prefix}/boot/grub/menu.lst +sed -i -e "s%${ROOT_GUEST}%UUID=${ROOT_UUID}%" ${prefix}/etc/fstab +sed -i -e "s%${SWAP_GUEST}%UUID=${SWAP_UUID}%" ${prefix}/etc/fstab # # Regenerate automagic kernels list, saving our changes