3 ms·
The standard is for EFI to look for that partition on all disks, even hard disks. If there are a few broken systems that do otherwise, they could use other meth
by Sanddancer 11y ago
The standard is for EFI to look for that partition on all disks, even hard disks. If there are a few broken systems that do otherwise, they could use other methods, but keeping things mostly standardized seems like the best way to go. It's how Windows does it, it's how FreeBSD does it, it's how OpenBSD does it, etc. Mucking around with it doing otherwise is just asking for problems.
- JoshTriplett 11y agoThe EFI standard specifically limits that to removable media. Windows installs itself via the EFI boot variable mechanism; Windows also installs itself to bootx64.efi, but even if you overwrite that, you can still boot Windows via its EFI boot entry. Having Linux systems install themselves only to bootx64.efi would produce a fragile installation (particularly in dual-boot configurations).
- Sanddancer 11y agoOkay, I read the standard and you're right, they are supposed to install to a vendor specific location, so my apologies. Boot's an additional place you can put it, but not the regular place. As an aside, goddamn is UEFI ugly. BIOS it was easy -- set the partition you want to boot as bootable, and away you go. here you have to copy the bootloader file, and then write to the firmware what file you want to boot, which feels even more fragile and confusing if you decide to wipe a hard drive to put a new OS on it unless you do everything just right.
- simoncion 11y ago> As an aside, goddamn is UEFI ugly. You're goddamn right it is. Matthew Garrett [0] used to do UEFI stuff for -IIRC- RedHat. He has MANY blog posts about fucked-up parts of the spec, and horrifyingly fucked-up implementations of the same. Sadly, it looks like most (if not all) of his posts are now tagged "advogato, fedora", so I can't point you specifically to the UEFI gore posts. [0] http://mjg59.dreamwidth.org/ http://mjg59.dreamwidth.org/
- yuhong 11y agoMy personal favorite is how http://lkml.org/lkml/2013/11/11/653 http://lkml.org/lkml/2013/11/11/653 is posted by @hp.com that also locked access to UEFI updates to paid customers not long after it was posted.
- JoshTriplett 11y agoAt least in theory, UEFI intended to avoid the current problem of OS bootloaders taking over (by writing to the MBR) and then needing to know how to boot other OSes. (Or, in practice, Linux bootloaders knowing how to boot everything and all other bootloaders only booting their own OS.) If you install your bootloader via the standard UEFI mechanism, you won't step on any other OS on the same system. And at boot time, you get a menu of OSes, with labels provided by those OSes. The problem comes in with the small handful of UEFI firmware implementations that get EFI variables so horribly wrong that attempting to write to them in the standard way will cause the EFI firmware to overwrite itself or otherwise brick the machine. Linux does attempt to work around some of those systems through very careful handling of EFI variable writes.
- toast0 11y agoIirc, bios just loads the first sector[1] of the disk into a specific place and jumps into it. Interpreting the partition table or not it's up to that code. [1] or maybe the first 512 bytes, if a sector is bigger
- prutschman 11y ago> As an aside, goddamn is UEFI ugly. I was installing a graphics card once and broke my EFI setup. Not because of the graphics card, but because I apparently bumped the CMOS battery enough to wipe settings.
- chris_wot 11y agoUh... don't do that?
- prutschman 11y agoSure, but historically something like that wouldn't render a system unable to boot an already installed operating system.