UEFI/"BIOS" booting, was Re: USB Install Fails, Complains about CD-ROM
On Fri 11 May 2018 at 15:13:04 (-0500), Kent West wrote:
> On Fri, May 11, 2018 at 2:59 PM, Pascal Hambourg <email@example.com>
> > Le 11/05/2018 à 20:33, Kent West a écrit :
> >> I learned that EFI boot drives need to have a GPT partition table. On a
> > This is not correct. The UEFI specification supports boot from a drive
> > with an MSDOS partition table. Otherwise why would there be an "EFI system
> > partition" type identifier (0xef) for MSDOS partition tables ? The Debian
> > installer hybrid image has an MSDOS partition table. (It also has Apple and
> > GPT partition tables, but they are bogus)
> That's good to know. I guess my source material (
> is wrong. Or I misunderstood it.
While a lot of the detail on that long page might be correct, there
are also statements there that don't seem to agree with reality.
It does make a statement that agrees with Pascal's:
"and the UEFI spec requires that UEFI-compliant firmwares be
capable of interpreting GPT (it also requires them to be capable
of interpreting MBR, for backwards compatibility)." (under "The
GPT (GUID partition table) format").
That said, there are other statements that are odd:
"I really can’t recommend strongly enough that you do not attempt
to mix UEFI-native and BIOS-compatible booting of
permanently-installed operating systems on the same computer, and
especially not on the same disk. It is a terrible terrible idea
and will cause you heartache and pain. If you decide to do it,
don’t come crying to me." (under "UEFI booting: background").
"Disk formats (MBR vs. GPT)
Here’s another very important consideration:
If you want to do a ‘BIOS compatibility’ type installation, you
probably want to install to an MBR formatted disk. If you want to
do a UEFI native installation, you probably want to install to a
GPT formatted disk."
"A specific example
To boil down the above: if you bought a Windows 8 or later system,
you almost certainly have a UEFI native install of Windows to a
GPT-formatted disk. This means that if you want to install another
OS alongside that Windows install, you almost certainly want to do
a UEFI-native installation of your other OS. If you don’t like all
this UEFI nonsense and want to go back to the good old world
you’re familiar with, you will, I’m afraid, have to blow away the
UEFI-native Windows installation, and it would be a good idea to
reformat the disk to MBR."
I can't reconcile that with the system here, a Windows 8→10 UEFI laptop
and GPT disk running linux in BIOS compatibility mode (here called
Legacy mode by Lenovo) booting from an MBR on an ATA disk:
# gdisk -l /dev/sda
GPT fdisk (gdisk) version 1.0.1
Partition table scan:
BSD: not present
APM: not present
Found valid GPT with protective MBR; using GPT.
Disk /dev/sda: 976773168 sectors, 465.8 GiB
Logical sector size: 512 bytes
Disk identifier (GUID): 2653F13F-2CD0-406F-B004-6AFFDBE18127
Partition table holds up to 128 entries
First usable sector is 34, last usable sector is 976773134
Partitions will be aligned on 2048-sector boundaries
Total free space is 4077 sectors (2.0 MiB)
Number Start (sector) End (sector) Size Code Name
1 2048 2050047 1000.0 MiB 2700 Basic data partition
2 2050048 2582527 260.0 MiB EF00 EFI system partition
3 2582528 4630527 1000.0 MiB ED01 Basic data partition
4 4630528 4892671 128.0 MiB 0C01 Microsoft reserved ...
5 4892672 347348991 163.3 GiB 0700 Basic data partition
6 347348992 429268991 39.1 GiB 8300 Linux-A
7 429268992 511188991 39.1 GiB 8300 Linux-B
8 511188992 883275775 177.4 GiB 8300 Linux-Home
9 883275776 883292159 8.0 MiB EF02 Linux-BIOS-Boot
10 883292160 892084223 4.2 GiB 8200 Linux-Swap
11 892086272 892803071 350.0 MiB 2700
12 892803072 894900223 1024.0 MiB 0700 Basic data partition
13 894900224 947329023 25.0 GiB 0700 Basic data partition
14 947329024 976773119 14.0 GiB 2700 Basic data partition
=> Grub2 (v1.99) is installed in the MBR of /dev/sda and looks at sector
883275776 of the same hard drive for core.img. core.img is at this
location and looks in partition 85 for . [from bootinfoscript].
The original sda5 was shrunk, and five new partitions added, all by
windows. Then the machine was booted in compatibility mode and linux
was installed. Finally, I told windows not to assign a drive letter
to the linux partitions (so that it does not keep offering to reformat
them at every encounter).
The result is a laptop that boots windows in UEFI Boot Mode and
linux in Legacy Mode. Windows knows nothing about the linux
installation except to ignore those partitions. Linux mounts
what it can of the windows installation, but in readonly mode.
Switching over involves going through the "BIOS Setup", reached
by a separate button (almost recessed).
All this makes me treat the information on that page with suspicion.
Perhaps the statement quoted here is self-referential (but lower than
95%, I hope): "You’ve probably read a lot of stuff on the internet
about UEFI. Here is something important you should understand: 95% of
it was probably garbage."