[arch-general] Single Drive Fresh Install (mbr/grub2) Fails to boot (can boot existing from .iso??)

David C. Rankin drankinatty at suddenlinkmail.com
Mon Nov 7 17:34:44 UTC 2016


On 11/05/2016 04:38 AM, Simon Brulhart wrote:
> I may be missing something, but is there a chance that the bios just
> doesn't wait long enough for the disk to turn on?
> On some laptops this sometimes happen to me when trying to boot an USB
> harddisk. The disk isn't detected at all by the bios, but generally
> rebooting with the disk already turned on fixes the issue.
> I've also seen an option on some BIOSes to wait for a few additional
> seconds at boot before enumerating drives, indicating that this may be a
> common issue.
> 
> Simon

Simon,

  Thanks, but no, I eliminated that by choosing the boot options menu
(e.g. F9) on boot which allowed 30 seconds or so as I pondered the
options for the drives to spin up, no it is something quirky with this
laptop that I have to figure out, but I'm totally stuck.

  I prepared a fresh summary of my ordeal in hopes of getting some
wisdom to help with this mystery. Here is the summary to date:

  I need a miracle (or just some good help) to find out why I can boot
from the .iso and "Choose existing OS" just fine, but cannot get this
laptop to find and boot grub otherwise. (UEFI is *completely* disabled
in the BIOS and it boots win10 in Legacy mode fine) I have now exhausted
all that I can figure out based on my decade and a half of Linux use and
based on the wikis:

https://wiki.archlinux.org/index.php/GRUB
https://wiki.archlinux.org/index.php/EFI_System_Partition
https://wiki.archlinux.org/index.php/HP_EliteBook_840_G1  (uses EFI mode)

  I have configured and tried simple MBR boot with the following setup:

 # fdisk -l /dev/sda
Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: dos
Disk identifier: 0xff7d45aa

Device     Boot      Start        End    Sectors   Size Id Type
/dev/sda1             2048 1953525167 1953523120 931.5G  5 Extended
/dev/sda5  *          4096    1028095    1024000   500M 83 Linux
/dev/sda6          1030144  105887743  104857600    50G 83 Linux
/dev/sda7        105889792 1951383551 1845493760   880G 83 Linux
/dev/sda8       1951385600 1953525167    2139568     1G 82 Linux swap /
Solaris

  grub isn't seen on boot, but popping the .iso on USB in, choosing
"Boot existing OS", hitting 'tab' and changing 'hd0 0' to 'hd1 0' boots
Arch fine.

  I next tried with GPT and a 'bios_boot' partition:

 # fdisk -l /dev/sda
Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: 00B6A48C-CBDB-4071-A1EC-97FA828A6C26

Device          Start        End    Sectors  Size Type
/dev/sda1        2048       4095       2048    1M BIOS boot
/dev/sda2        4096    1028095    1024000  500M Linux filesystem
/dev/sda3     1028096  105885695  104857600   50G Linux filesystem
/dev/sda4   105885696 1949282303 1843396608  879G Linux filesystem
/dev/sda5  1949282304 1951379455    2097152    1G Linux swap

  same result, grub not found on its own, but booting from USB works fine.

  Next, stranger things being possible, I decided to try a full UEFI
setup thinking maybe the Legacy mode for this laptop uses some contrived
boot scheme that requires the esp partition to be present. so I
re-partitioned the drive and went though the UEFI setup:

 # fdisk -l /dev/sda
Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: 00B6A48C-CBDB-4071-A1EC-97FA828A6C26

Device          Start        End    Sectors  Size Type
/dev/sda1        2048       4095       2048    1M BIOS boot
/dev/sda2        4096    1028095    1024000  500M EFI System
/dev/sda3     1028096  105885695  104857600   50G Linux filesystem
/dev/sda4   105885696 1949282303 1843396608  879G Linux filesystem
/dev/sda5  1949282304 1951379455    2097152    1G Linux swap

  Still, grub isn't seen on boot, but now "Choose existing OS" starts
grub, but then throws the error of "unrecognized partition type" (I
presume is due to the UEFI setup while UEFI is disabled in the BIOS)

  So I'm stuck. This box boots from the iso perfectly. After "Choose
existing OS", I pull the USB drive, and the machine works flawlessly.
(I've got a full plasma/KDE5 setup installed with wpa_supplicant WPA
wifi, bluetooth, synaptics touchpad, ieee-1394, all working just fine,
etc.., e.g. I drafted this on kwrite and sent it via thunderbird from
this same darn box) I just can't get this box to find grub to save my life.

  I need help figuring out how the .iso is booting in Legacy mode just
fine, while I can't do the same thing from the hard drive. If this box
can see and boot the .iso just fine, what could possibly explain it not
seeing grub on the hard drive? Anybody have any more ideas?

-- 
David C. Rankin, J.D.,P.E.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 163 bytes
Desc: OpenPGP digital signature
URL: <https://lists.archlinux.org/pipermail/arch-general/attachments/20161107/dc93d456/attachment.asc>


More information about the arch-general mailing list