Mageia Bugzilla – Attachment 11565 Details for
Bug 22395
drakboot crashed: Installing grub configuration with the option "don't change MBR" (grub2-install: /boot/EFI/EFI/tmp/grubx64.efi can't be opened, file or directory not found)
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
New Account
|
Forgot Password
[patch]
rename /boot/EFI/efi as /boot/EFI/EFI if needed
0001-install_raw_grub2-rename-boot-efi-as-boot-EFI.patch (text/plain), 1.17 KB, created by
Thierry Vignaud
on 2020-03-23 18:20:01 CET
(
hide
)
Description:
rename /boot/EFI/efi as /boot/EFI/EFI if needed
Filename:
MIME Type:
Creator:
Thierry Vignaud
Created:
2020-03-23 18:20:01 CET
Size:
1.17 KB
patch
obsolete
>From b2564e617a8577476168cf8c8b73dc07bf9f8399 Mon Sep 17 00:00:00 2001 >From: Thierry Vignaud <thierry.vignaud@gmail.com> >Date: Mon, 23 Mar 2020 18:17:07 +0100 >Subject: [PATCH] (install_raw_grub2) rename /boot/efi as /boot/EFI > >Mageia mounts the ESP as /boot/EFI and thes grub2 looks at /boot/EFI/EFI >But some windows installation end in having /boot/EFI/efi (lowercase) >Rename the directory as upercase if needed so that grub2-install doesn't >fail (mga#22395) >--- > perl-install/bootloader.pm | 4 ++++ > 1 file changed, 4 insertions(+) > >diff --git a/perl-install/bootloader.pm b/perl-install/bootloader.pm >index fbb0abe92..4638a2c15 100644 >--- a/perl-install/bootloader.pm >+++ b/perl-install/bootloader.pm >@@ -2335,6 +2335,10 @@ sub install_grub2 { > sub install_raw_grub2() { > my $error; > my $f = '/boot/grub2/install.sh'; >+ my ($right_dir, $bad_dir) = ("$::prefix/boot/EFI/EFI/", "$::prefix/boot/EFI/efi/"); >+ if (-e $bad_dir && ! -e $right_dir) { >+ renamef($bad_dir, $right_dir); >+ } > if (!run_program::rooted($::prefix, "sh", "2>", \$error, $f)) { > log::explanations("grub2-install failed:\n(" . cat_($f) . ")\nError: <$error>"); > die "grub2-install failed: $error"; >-- >2.25.2 >
From b2564e617a8577476168cf8c8b73dc07bf9f8399 Mon Sep 17 00:00:00 2001 From: Thierry Vignaud <thierry.vignaud@gmail.com> Date: Mon, 23 Mar 2020 18:17:07 +0100 Subject: [PATCH] (install_raw_grub2) rename /boot/efi as /boot/EFI Mageia mounts the ESP as /boot/EFI and thes grub2 looks at /boot/EFI/EFI But some windows installation end in having /boot/EFI/efi (lowercase) Rename the directory as upercase if needed so that grub2-install doesn't fail (mga#22395) --- perl-install/bootloader.pm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/perl-install/bootloader.pm b/perl-install/bootloader.pm index fbb0abe92..4638a2c15 100644 --- a/perl-install/bootloader.pm +++ b/perl-install/bootloader.pm @@ -2335,6 +2335,10 @@ sub install_grub2 { sub install_raw_grub2() { my $error; my $f = '/boot/grub2/install.sh'; + my ($right_dir, $bad_dir) = ("$::prefix/boot/EFI/EFI/", "$::prefix/boot/EFI/efi/"); + if (-e $bad_dir && ! -e $right_dir) { + renamef($bad_dir, $right_dir); + } if (!run_program::rooted($::prefix, "sh", "2>", \$error, $f)) { log::explanations("grub2-install failed:\n(" . cat_($f) . ")\nError: <$error>"); die "grub2-install failed: $error"; -- 2.25.2
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 22395
:
9914
| 11565