#2391 Issue closed: Cleanup of the code for "Installing GRUB2 as recovery system UEFI bootloader"

Labels: enhancement, cleanup, no-issue-activity

jsmeix opened issue at 2020-05-08 12:41:

The code for "Installing GRUB2 as recovery system UEFI bootloader"
should be cleaned up and improved to be more fail-safe and to
provide final power to ther user (i.e. less hardcoded values).

  • Firmware: UEFI

  • Description of the issue:

See https://github.com/rear/rear/issues/2388

"rear mkrecue" does not error out when
required GRUB2 modules are missing

therein see in particular

https://github.com/rear/rear/issues/2388#issuecomment-625167827
that reads (excerpt):

In general we must much better care about
possible errors in ReaR and error out early
with a reasonable error message for the user
during "rear mkbackup/mkrescue" when things
cannot work later than to blindly proceed and
let the user find out later when it is too late
that things fail when booting the recovery system
or during "rear recover".

So for each GRUB2 module that will be
enforced loaded we must first and foremost
at least check during "rear mkrescue"
that the GRUB2 module is actually there
and made available for the GRUB2 bootloader
on the ReaR recovery system.

https://github.com/rear/rear/issues/2388#issuecomment-625180406

Our usual sufficiently clean way in ReaR would be
to have the list of enforced loaded GRUB2 modules
in a user config variable which we have already
as GRUB2_MODULES_LOAD.

So instead of hardcoded values in the scripts
we have to set the default list of enforced loaded
GRUB2 modules in default.conf so the user
knows about it and can adapt it if needed.

We have way too many hardcoded values
in our scripts that lead to a
"works magically right in most cases"
behaviour which leads to weird errors
that our users do not understand which
further leads to issue reports here
that are hard to debug for us

github-actions commented at 2020-07-08 01:36:

Stale issue message


[Export of Github issue for rear/rear.]