Mageia Bugzilla – Attachment 6740 Details for
Bug 16010
Mageia5 Final Lives & Classic on real EFI HW fail to install bootloader (ERROR: killing runaway process (process=update-grub2...)
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
New Account
|
Forgot Password
[patch]
limit timeout to 2m and rety w/o os-prober if needed
16010.diff (text/plain), 894 bytes, created by
Thierry Vignaud
on 2015-06-15 11:49:57 CEST
(
hide
)
Description:
limit timeout to 2m and rety w/o os-prober if needed
Filename:
MIME Type:
Creator:
Thierry Vignaud
Created:
2015-06-15 11:49:57 CEST
Size:
894 bytes
patch
obsolete
>diff -up ./bootloader.pm.tv8 ./bootloader.pm >--- ./bootloader.pm.tv8 2015-06-15 05:42:33.507171336 -0400 >+++ ./bootloader.pm 2015-06-15 05:48:29.051202680 -0400 >@@ -1809,7 +1809,17 @@ sub write_grub2 { > > my $f1 = "$::prefix/boot/grub2/grub.cfg"; > renamef($f1, $f1 . ($o_backup_extension || '.old')); >- run_program::rooted($::prefix, 'update-grub2', '2>', \$error) or die "update-grub2 failed: $error"; >+ my $timeout = 2*60 >+ my $time = time(); >+ my $res = run_program::raw({ root => $::prefix, timeout => $timeout}, 'update-grub2', '2>', \$error); >+ if (!$res) { >+ if (!$ENV{GRUB_DISABLE_OS_PROBER} && time() - $time >= $timeout) { >+ $ENV{GRUB_DISABLE_OS_PROBER} = 'true'; >+ log::l("Retrying with GRUB_DISABLE_OS_PROBER=true"); >+ } else { >+ die "update-grub2 failed: $error"; >+ } >+ } > log::l("update-grub2 logs: $error"); > > check_enough_space();
diff -up ./bootloader.pm.tv8 ./bootloader.pm --- ./bootloader.pm.tv8 2015-06-15 05:42:33.507171336 -0400 +++ ./bootloader.pm 2015-06-15 05:48:29.051202680 -0400 @@ -1809,7 +1809,17 @@ sub write_grub2 { my $f1 = "$::prefix/boot/grub2/grub.cfg"; renamef($f1, $f1 . ($o_backup_extension || '.old')); - run_program::rooted($::prefix, 'update-grub2', '2>', \$error) or die "update-grub2 failed: $error"; + my $timeout = 2*60 + my $time = time(); + my $res = run_program::raw({ root => $::prefix, timeout => $timeout}, 'update-grub2', '2>', \$error); + if (!$res) { + if (!$ENV{GRUB_DISABLE_OS_PROBER} && time() - $time >= $timeout) { + $ENV{GRUB_DISABLE_OS_PROBER} = 'true'; + log::l("Retrying with GRUB_DISABLE_OS_PROBER=true"); + } else { + die "update-grub2 failed: $error"; + } + } log::l("update-grub2 logs: $error"); check_enough_space();
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 16010
:
6609
|
6611
|
6665
|
6666
|
6667
| 6740