X-Git-Url: http://git.ozlabs.org/?a=blobdiff_plain;f=ybin%2Fyabootconfig;h=755e79cdfff89def6385cbd5facab682859f8b3e;hb=6a6a039f03909f5cdf62ef94522eb1a70b7e792d;hp=f343a7dad1f3ba74f9894bbac5849b6f2c14d4fc;hpb=8fe6242322e48ad34ae82d63b8a5a554aea987b3;p=yaboot.git diff --git a/ybin/yabootconfig b/ybin/yabootconfig index f343a7d..755e79c 100755 --- a/ybin/yabootconfig +++ b/ybin/yabootconfig @@ -390,6 +390,21 @@ if [ -z "$ROOT" ] ; then fi fi +## dereference label or uuid if necessary +case "$ROOT" in + LABEL=*|UUID=*) + if ! (command -v findfs > /dev/null 2>&1) ; then + echo 1>&2 "$PRG: Unable to locate findfs, aborting..." + exit 1 + fi + ROOT="$(findfs "$ROOT")" + if [ -z "$ROOT" -o $? != 0 ] ; then + echo 1>&2 "$PRG: Could not determine root partition, aborting..." + exit 1 + fi + ;; +esac + ## make sure root device exists if [ ! -e "$ROOT" ] ; then echo 1>&2 "$PRG: $ROOT: No such file or directory"