mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-09 18:45:54 +02:00
Fix linux-xen install.sh root detection with UUID.
This commit is contained in:
@@ -25,11 +25,20 @@
|
||||
extract_files
|
||||
#
|
||||
KVER=2.6.32.24
|
||||
ROOT=`grep "root=" /boot/grub/grub.conf | cut -d"=" -f2 | cut -d" " -f1 | tail -n 1`
|
||||
ROOT=`mount | grep " / " | cut -d" " -f1`
|
||||
ROOTUUID=`blkid -c /dev/null -sUUID $ROOT | cut -d'"' -f2`
|
||||
if [ ! -z $ROOTUUID ]; then
|
||||
ROOT="UUID=$ROOTUUID"
|
||||
fi
|
||||
|
||||
MOUNT=`grep "kernel" /boot/grub/grub.conf | tail -n 1`
|
||||
# Nur den letzten Parameter verwenden
|
||||
echo $MOUNT > /dev/null
|
||||
MOUNT=$_
|
||||
if [ ! $MOUNT == "rw" ]; then
|
||||
MOUNT="ro"
|
||||
fi
|
||||
|
||||
ENTRY=`grep "savedefault" /boot/grub/grub.conf | tail -n 1`
|
||||
# Nur den letzten Parameter verwenden
|
||||
echo $ENTRY > /dev/null
|
||||
|
||||
Reference in New Issue
Block a user