[node-patches] Change in ovirt-node[node-3.0]: Fix EFI boot entry shown "fedora" issue

fabiand at fedoraproject.org fabiand at fedoraproject.org
Thu Sep 19 10:36:53 UTC 2013


Hello hadong,

I'd like you to do a code review.  Please visit

    http://gerrit.ovirt.org/19386

to review the following change.

Change subject: Fix EFI boot entry shown "fedora" issue
......................................................................

Fix EFI boot entry shown "fedora" issue

Actually the EFI boot entry should show "oVirt Node Hypervisor",not
"fedora" value.
Also this patch fixed using wrong loader_filename issue.
(For fedora, the loader_filename should be "grubx64.efi."
 For rhel, the loader_filename should be "grub.efi")

Change-Id: Ia326f049cbea64e646a974105f265a22c45f315f
Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1004120
Signed-off-by: hadong <hadong0720 at gmail.com>
---
M src/ovirtnode/install.py
1 file changed, 11 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-node refs/changes/86/19386/1

diff --git a/src/ovirtnode/install.py b/src/ovirtnode/install.py
index 3cd0354..783cd8b 100755
--- a/src/ovirtnode/install.py
+++ b/src/ovirtnode/install.py
@@ -271,7 +271,7 @@
                 efi_grub_conf.write(GRUB2_BACKUP_TEMPLATE % self.grub_dict)
                 efi_grub_conf.close()
             _functions.system("umount /liveos")
-            _functions.remove_efi_entry(_functions.PRODUCT_SHORT)
+            _functions.remove_efi_entry(self.efi_dir_name)
             logger.info("Grub2 Install Completed")
             return True
         return True
@@ -462,10 +462,16 @@
                 # generate grub legacy config for efi partition
                 #remove existing efi entries
                 _functions.remove_efi_entry(_functions.PRODUCT_SHORT)
-                _functions.add_efi_entry(_functions.PRODUCT_SHORT,
-                                         ("\\EFI\\%s\\grub.efi" %
-                                          self.efi_dir_name),
-                                         efi_disk)
+                if self.efi_dir_name == "fedora":
+                    _functions.add_efi_entry(_functions.PRODUCT_SHORT,
+                                             ("\\EFI\\%s\\grubx64.efi" %
+                                              self.efi_dir_name),
+                                             efi_disk)
+                else:
+                    _functions.add_efi_entry(_functions.PRODUCT_SHORT,
+                                             ("\\EFI\\%s\\grub.efi" %
+                                              self.efi_dir_name),
+                                             efi_disk)
         self.kernel_image_copy()
 
         # reorder tty0 to allow both serial and phys console after installation


-- 
To view, visit http://gerrit.ovirt.org/19386
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia326f049cbea64e646a974105f265a22c45f315f
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-node
Gerrit-Branch: node-3.0
Gerrit-Owner: Fabian Deutsch <fabiand at fedoraproject.org>
Gerrit-Reviewer: hadong <hadong0720 at gmail.com>



More information about the node-patches mailing list