How to get boot options for SDcard or USB drive to show up in BIOS

May 1, 2019 - 7:28 PM

  • Here is another quick tip to help people who haven't dealt much with UEFI BIOS and the quirks of devices and booting. I my self went on a learning experience over the past day or so trying to figure out something that is essentially quite silly that I overlooked.

    Any device you want to boot from MUST have a UEFI partition on the device related to the operating system you intend to boot. I made the mistake of thinking I could just 'dd' the eMMC over to an SDcard and boot that SDcard, I was wrong, there seems to be some magic there. Basically, unless the UEFI partition exists and things are setup correctly on the device (SDcard, USB stick, USB hard drive), the BIOS will not even show the device as an option to select to boot from.

    This seems backwards logic for me, as one would expect that even if the device isn't 'currently bootable' that you would still have the option to choose the device, be it 'USB device' or something similar and at least tell it to expect to boot from that location. Instead, this is not how it works and without the device being present with that UEFI partition in tact, you can't select to boot from the device and it will not show up as an option.

    To note: using 'dd' to write any of the provided .img files provided by AtomicPi to an SDcard or USB stick should write this UEFI partition for you. If now, there are some tools out there made to do this for you. Rufus ( https://rufus.ie/ ) or From Windows ( https://www.thomas-krenn.com/en/wiki/Creating_Windows_UEFI_Boot-Stick_in_Windows ). I am sure there are many other options if you Google for 'UEFI USB bootable'.

    Hope this helps someone!

    Cheers!

    This post was edited 2019-05-01 19:32:28 -0400
    0
  • There has to be an EFI partition somewhere that specifies the loaders for various OS's from various physical devices. One could have the EFI partition on one device and have it present a boot menu (in grub) that includes OS's on other devices. When you specify a device in BIOS to boot from, what you are actually telling it is which EFI partition to look at. If the BIOS doesn't see an EFI partition on a particular device, it isn't going to be listed. BIOS doesn't boot the OS directly per se, BIOS boots a loader of sorts located on the EFI partition (or in UEFI flash). A EFI partition can contain multiple of these loaders. Any given loader may have options for booting one of several OS's located on one of several drives, or it may be configured to always boot a single OS from a single location. This architecture is quite flexible, but confusing when coming from the old boot process.

    0
  • Ok well that explains why I couldn't get 'clear linux'to boot via USB stick.
    Can someone point me to an article that'll step me through the process?
    I'm a middle attacker whosoever dealing in questionable ideas just speculation. I'm an old bios guy so this is all pretty o me

    0
  • Ok, as the OP suggested, I used RUFUS to copy the image to my USB stick, but to no avail. Now I admitm I am probably missing something. When you say MUST have a UEFI partition on the device related to the operating system you intend to boot. can you explain that a little more, or tell me where THAT partition comes from? Here's what Im looking at, I wanted to give Intel's own Clear Linux a shot, and see how it was working. There have been some folks commenting that some opther SBCs have an advantage, and that may be true, but if clear Linux was specifically written for intel processors, I thought I'd give it a shot. Anyone? Thanks

    0
  • jerome hess, ideally you want an image that already has the EFI partition in it, so when you write the image, an EFI partition is created along with the OS partition(s). The EFI partition is usually the first partition and is FAT32 format, even on linux. After you have written your USB stick image, use partition software such as gparted on linux or on windows minitool partition wizard to see if there is a EFI partition. Sometimes even though a distribution sets up an EFI partition on the hard drive or SSD during installation, the bootable live USB flash drive only boots in legacy BIOS mode. Many live boot USB images these days will work in either mode, legacy BIOS or UEFI.

    0