0

I found this text in a book (on linux) and i was wondering if there is an equivalent in MacOS.

"To determine if your system uses a BIOS or UEFI, run efibootmgr. If you get a list of boot targets, your system has UEFI. If instead you’re told that EFI variables aren’t supported, your system uses a BIOS. Alternatively, you can check to see that /sys/ firmware/efi exists; if so, your system uses UEFI."

I searched the web and SE but what i found is all about dual-boot things. (There is a post that looked promising (Efibootmgr command for OS X), but is nothing there. Just focusing on dual-boot, not on the command).

I just need a command-line option to check if a system uses BIOS or UEFI (and in any case, list the bootable targets).

  • 2
    macOS has neither BIOS nor UEFI. I t has EFI. – Tetsujin May 19 '23 at 06:58
  • @Tetsujin In that case. Is there any command (CLI) to list the bootable targets? – nostromo May 19 '23 at 07:08
  • 1
    I don't know, sorry, but there's a control panel - Startup Disk – Tetsujin May 19 '23 at 07:16
  • Macs use EFI but I don't know a command-line that would check that – Thinkr May 19 '23 at 07:21
  • @Tetsujin That's the point. I would like to do it avoiding any GUI. Perhaps there was this "system-control like command" that parses a file/log or querys the kernel. – nostromo May 19 '23 at 07:24
  • Apparently, running /usr/libexec/firmwarecheckers/eficheck/eficheck --integrity-check will check is your Mac's UEFI firmware is genuine and then print a report of your current EFI version (and Boot ROM). – Thinkr May 19 '23 at 07:26
  • 1
    I did that (i had to go to the folder as it was not executable from global. Perhaps because deprecated on (my) Monterrey?): ./eficheck --integrity-check ReadBinaryFromKernel: No matching services found. Either this system is not supported by eficheck, or you need to re-load the kext IntegrityCheck: couldn't get EFI contents from kext – nostromo May 19 '23 at 07:28
  • nostromo: There is a EFI specification which was renamed UEFI when updated to version 2.0 in 2006. All versions of OS X and macOS EFI/UEFI boot on Intel Macs. The degree to which a particular Mac adheres to any EFI/UEFI specification depends on the Mac's current firmware version. Firmware was originally manually updated. Starting with macOS, firmware updates are done during operating system installs. From 2006 through approximately 2014, Intel Mac models were also capable of BIOS booting other operating systems such as Windows. – David Anderson May 19 '23 at 11:07
  • Having a list of bootable targets stored in EFI/UEFI variables conflicts with the way OS X and macOS is designed to operate. Instead, the Mac Startup Manager (implemented in the firmware) and both OS X and macOS search the drives for bootable versions of Windows, OS X and macOS. When applicable, this include BIOS versions of Windows. The default operating system to boot is store in the EFI/UEFI variables. – David Anderson May 19 '23 at 11:29
  • @DavidAnderson Mmmm. So if i understood well: many people (i.e. me) erroneously think that there is always this equivalence between operating systems (os) and there will be always 'this or that' command with just a different name, doing likely an analogous task. The fact is that, if i understood well, some os by design provide totally different interfaces to the point that, for example, having "tables/variables" that could be canonical in most of os have no sense in os like this one or even the possibility to access through cli. Sometimes only exists the gui way? Is it so? – nostromo May 19 '23 at 11:39
  • You could use commands included with Linux to create to a list bootable targets stored in the EFI/UEFI variables. However, most likely this list would be erased by the Mac Startup Manager, OS X, macOS or the Boot Camp software installed in Windows. If you had to have a list of bootable targets, then you could install a third party boot manager such a rEFInd, which can store a list of bootable targets in a file. – David Anderson May 19 '23 at 11:41
  • @DavidAnderson rEFIdn is like a "GRUB" sort of thing then? The short answer is then: that, there is no such a thing in MacOS proprietary spec (meaning no 3rd party options as the one you mention) as "bootable targets" because the system is not designed (will not recognize, even it will erase) for that degree of freedom? My intention was not to boot anything alternative. Is just to tweak, better see parameters at that low level. I am experimenting with a Linux VM on my MacOS and i always try to replicate actions on my native machine (come to realize the huge differences). – nostromo May 19 '23 at 11:50

0 Answers0