From d380c8d630d40ea6aaf513e3f0941f44b0334394 Mon Sep 17 00:00:00 2001 From: Hans de Goede Date: Wed, 18 Mar 2009 16:26:59 +0100 Subject: Do not write LV uuid to grub.conf, but the filesystem uuid When re-using an existing LV for /, and thus one which has uuid set in its representing Device, we would write the LV uuid to grub.conf as root= parameter, resulting in a non booting system. Also we no longer keep labels anywhere, so don't look for a label. Note that we are only hitting this with pre-existing LV's because we are not setting / updating the LVDevice's uuid when creating a new one (something which we ought to fix). --- booty/bootloaderInfo.py | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'booty/bootloaderInfo.py') diff --git a/booty/bootloaderInfo.py b/booty/bootloaderInfo.py index 0c1ec5b5b..90073e279 100644 --- a/booty/bootloaderInfo.py +++ b/booty/bootloaderInfo.py @@ -89,14 +89,12 @@ def getRootDevName(initrd, rootDevice): return rootDevice.path try: - if rootDevice.uuid: - return "UUID=%s" % rootDevice.uuid - elif rootDevice.label: - return "LABEL=%s" % rootDevice.label - - return rootDevice.path + if rootDevice.format.uuid: + return "UUID=%s" % rootDevice.format.uuid except: - return rootDevice.path + pass + + return rootDevice.path class KernelArguments: -- cgit