Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Formatting USB drive for efi is broken #2680

Closed
bearpebble opened this issue Sep 27, 2021 · 7 comments
Closed

Formatting USB drive for efi is broken #2680

bearpebble opened this issue Sep 27, 2021 · 7 comments
Assignees
Labels
bug The code does not do what it is meant to do fixed / solved / done
Milestone

Comments

@bearpebble
Copy link

bearpebble commented Sep 27, 2021

Relax-and-Recover (ReaR) Issue Template

  • ReaR version ("/usr/sbin/rear -V"):
    Relax-and-Recover 2.6 / Git (7c42e2bd3e600d059f24bd0b46526700c1d8bda0)

  • Description of the issue (ideally so that others can reproduce it):
    Using usr/sbin/rear format -v -- --efi /dev/sd... does not create the layout required for EFI.

    The switch --efi is simply ignored, as it sets FORMAT_EFI=y, which is never used anywhere else in the code.

    (-e|--efi)
    FORMAT_EFI=y

  • Workaround, if any:
    Put the line EFI=$FORMAT_EFI right before the following line, since $EFI is never set anywhere.

    if is_true "$EFI" ; then
    LogPrint "The --efi toggle was used with format - making an EFI bootable device $RAW_USB_DEVICE"

@gozora
Copy link
Member

gozora commented Sep 27, 2021

Shouldn't it be usr/sbin/rear format -v -- --efi /dev/sd (with two dashes in front of efi) ?

V.

@bearpebble
Copy link
Author

@gozora you are right, that was a typo in the issue. Sorry about that.
Unfortunately that is not the problem. I used the correct command and it only worked after I applied the workaround, i.e. edited the code

@jsmeix jsmeix self-assigned this Sep 27, 2021
@jsmeix jsmeix added bug The code does not do what it is meant to do and removed support / question labels Sep 27, 2021
@jsmeix jsmeix added this to the ReaR v2.7 milestone Sep 27, 2021
@jsmeix
Copy link
Member

jsmeix commented Sep 27, 2021

@bearpebble
thank you for your issue report.
It is a bug caused by me from #2660

jsmeix added a commit that referenced this issue Sep 27, 2021
The "format" workflow '--efi' switch sets "FORMAT_EFI=y" so
format/USB/default/300_format_usb_disk.sh must check "$FORMAT_EFI"
see #2680
@jsmeix
Copy link
Member

jsmeix commented Sep 27, 2021

Should now be fixed via
d032145

@bearpebble
please test if our latest GitHub master code that contains
that above commit works for you, cf. the section
"Testing current ReaR upstream GitHub master code" in
https://en.opensuse.org/SDB:Disaster_Recovery

@bearpebble
Copy link
Author

The usr/sbin/rear format -v -- --efi /dev/sd... command works as expected using d032145.
Thanks for the quick fix @jsmeix

@jsmeix
Copy link
Member

jsmeix commented Sep 27, 2021

@bearpebble
thank you for your prompt test and feedback!

@jsmeix
Copy link
Member

jsmeix commented Sep 27, 2021

I think less than one hour from initial user bug report
to final user confirmation that the fix actually works
is probably our fastest case that we had here.
So - now it's time for my morning coffee and breakfast...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug The code does not do what it is meant to do fixed / solved / done
Projects
None yet
Development

No branches or pull requests

3 participants