Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   Ubuntu User (http://www.linux-archive.org/ubuntu-user/)
-   -   Write the grub.conf after setting up the new EFI bootloader (#741994)) (http://www.linux-archive.org/ubuntu-user/581250-write-grub-conf-after-setting-up-new-efi-bootloader-741994-a.html)

"Brian C. Lane" 09-28-2011 06:19 PM

Write the grub.conf after setting up the new EFI bootloader (#741994))
 
From: "Brian C. Lane" <bcl@redhat.com>

On EFI the grub.conf includes a device mapping line that ensures that
hd(x,y) points to the right device. This information is pulled from
efibootmgr -v, so the new entry needs to be made before writing
grub.conf on EFI, not after.

NOTE: Tested and confirmed via program.log and efibootmgr -v after install
---
pyanaconda/bootloader.py | 14 ++++++++++++++
1 files changed, 14 insertions(+), 0 deletions(-)

diff --git a/pyanaconda/bootloader.py b/pyanaconda/bootloader.py
index e6ce014..efbf115 100644
--- a/pyanaconda/bootloader.py
+++ b/pyanaconda/bootloader.py
@@ -1431,6 +1431,20 @@ class EFIGRUB(GRUB):
def update(self, install_root=""):
self.write(install_root=install_root)

+ #
+ # installation
+ #
+ def write(self, install_root=""):
+ """ Write the bootloader configuration and install the bootloader. """
+ if self.update_only:
+ self.update(install_root=install_root)
+ return
+
+ sync()
+ self.stage2_device.format.sync(root=install_root)
+ self.install(install_root=install_root)
+ self.write_config(install_root=install_root)
+
class GRUB2(GRUB):
""" GRUBv2

--
1.7.6

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


All times are GMT. The time now is 06:37 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.