Re: [PATCH] Add some more logging of bootloader installation.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ack.

Regards,

Hans


On 11/13/2009 02:05 PM, Radek Vykydal wrote:
driveorder was only available in anaconda-ks.cfg, device.map could have been
overwritten by user fixing grub in rescue.

---
  bootloader.py |    2 ++
  booty/x86.py  |   10 ++++++++++
  2 files changed, 12 insertions(+), 0 deletions(-)

diff --git a/bootloader.py b/bootloader.py
index 729fe2c..5e17955 100644
--- a/bootloader.py
+++ b/bootloader.py
@@ -141,6 +141,8 @@ def writeBootloader(anaconda):

      justConfigFile = not flags.setupFilesystems

+    log.info("bootloader driveorder: %s" % anaconda.id.bootloader.drivelist)
+
      if anaconda.id.bootloader.defaultDevice == -1:
          return

diff --git a/booty/x86.py b/booty/x86.py
index 40ec7f2..0439ecd 100644
--- a/booty/x86.py
+++ b/booty/x86.py
@@ -8,6 +8,9 @@ from flags import flags
  import checkbootloader
  import iutil

+import logging
+log = logging.getLogger("anaconda")
+
  class x86BootloaderInfo(efiBootloaderInfo):
      def setPassword(self, val, isCrypted = 1):
          if not val:
@@ -225,6 +228,11 @@ class x86BootloaderInfo(efiBootloaderInfo):
          usedDevs.update(self.getPhysicalDevices(bootDev.name))
          usedDevs.update([dev for (label, longlabel, dev) in chainList if longlabel])

+        log.info("booty grubTarget: %s" % grubTarget)
+        log.info("booty bootDev: %s" % bootDev)
+        log.info("booty rootDev: %s" % rootDev)
+        log.info("booty chainList: %s" % chainList)
+
          if not justConfigFile or not upgrade:
              self.writeDeviceMap(instRoot, usedDevs, upgrade)
              self.writeSysconfig(instRoot, grubTarget, upgrade)
@@ -421,6 +429,8 @@ class x86BootloaderInfo(efiBootloaderInfo):
              dev = self.storage.devicetree.getDeviceByName(drive)
              if not dev.type == "mdarray":
                  f.write("(%s)     %s\n" % (self.grubbyDiskName(drive), dev.path))
+                log.info("booty device.map (%s) %s" %
+                         (self.grubbyDiskName(drive), dev.path))
          f.close()

      def writeSysconfig(self, instRoot, grubTarget, upgrade):

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux