You are not logged in.

#26 2014-08-14 18:04:50

philomathean
Member
Registered: 2013-09-17
Posts: 17

Re: [SOLVED] How do I Auto-boot Gummiboot Instead of Windows?

Meaning both sda1 & sda2 are both being treated as the System Partitions? How can I gain access to editing/viewing files on sda2? Can both sda1 & sda2 be mounted as /boot at least temporarily while I can clean things up?

Offline

#27 2014-08-14 18:07:07

Head_on_a_Stick
Member
From: London
Registered: 2014-02-20
Posts: 7,732
Website

Re: [SOLVED] How do I Auto-boot Gummiboot Instead of Windows?

# mount /dev/sda2 /mnt
ls /mnt

wink

Offline

#28 2014-08-14 18:21:25

loqs
Member
Registered: 2014-03-06
Posts: 17,427

Re: [SOLVED] How do I Auto-boot Gummiboot Instead of Windows?

As the bios seems to prefer sda2 and Windows booting using sda2 is working might be safer to make sda2 /boot

#umount /boot
#mount /dev/sda2 /boot
#mount /dev/sda1 /mnt

reinstall gummiboot on the new /boot
create an updated gummiboot configuration
reinstall the linux kernel package to put the kernel and ramdisk on the new /boot (or copy them across from /mnt)
move everything left on /mnt to a holding location somewhere else on the filesystem just incase it is needed
update /etc/fstab to reflect /boot is now a different partition

#mkdir /root/oldboot
#mv /mnt/* /root/oldboot

This would leave the excess partition which hopefully the bios will ignore until you decide what to do about it and excess EFI boot entries

Last edited by loqs (2014-08-14 18:58:47)

Offline

#29 2014-08-14 18:26:21

Head_on_a_Stick
Member
From: London
Registered: 2014-02-20
Posts: 7,732
Website

Re: [SOLVED] How do I Auto-boot Gummiboot Instead of Windows?

According to the output of gdisk (post #14), sda2 is not an EFI system partition: "code" is given as "0700". This is identified in gdisk as "Microsoft basic data"...
EDIT: you could maybe try using gdisk to change the partition type of sda2 to "ef00". The EFI firmware on your motherboard uses this code to identify the EFI system partition.
Multiple EFI system partitions are not a problem per se (they can be selected via the firmware options): https://www.happyassassin.net/2014/01/2 … work-then/

Last edited by Head_on_a_Stick (2014-08-14 18:31:41)

Offline

#30 2014-08-14 20:32:38

philomathean
Member
Registered: 2013-09-17
Posts: 17

Re: [SOLVED] How do I Auto-boot Gummiboot Instead of Windows?

Ok, I think I've managed to make the majority of the changes I need to, but I'd like to get feedback before I reboot just in case I've forgotten something major.

First, I did:

umount /boot
mount /dev/sda2 /boot
mount /dev/sda1 /mnt

Then, I converted sda2 to an EFI partition via:

gdisk /dev/sda
Command (? for help): ?
Command (? for help): t
Partition number (1-7): 2
Current type is 'Microsoft basic data'
Hex code or GUID (L to show codes, Enter = 8300): EF00
Changed type of partition to 'EFI System'
Command (? for help): w

Then, I re-installed gummiboot to the new /boot location & copied files from the old boot to new locations:

gummiboot --path=/boot install
cp /mnt/initramfs-linux.img /boot/
cp /mnt/initramfs-linux-fallback.img /boot/
cp /mnt/vmlinuz-linux /boot/
cp -R /mnt ~/Downloads/sda1bootbackup/

New output for "efibootmgr -v"

BootCurrent: 0007
Timeout: 0 seconds
BootOrder: 0006,0004,3004,0001,0002,0007,2001,0003,0005,2002,2003
Boot0000* USB Hard Drive (UEFI) - PNY     USB 2.0 FD	ACPI(a0341d0,0)PCI(10,0)USB(3,0)HD(1,800,3cf0700,00032116)RC
Boot0001* EFI HDD Device (HGST HTS541075A9E680)	ACPI(a0341d0,0)PCI(11,0)ATAPI(0,0,0)HD(1,800,c8000,52d738a5-fab3-401f-868e-53a3db7e8e39)RC
Boot0002* ubuntu	HD(2,c8800,82000,1757c49b-b3b5-4201-b506-dcf15496be2a)File(\EFI\ubuntu\shimx64.efi)RC
Boot0003* Network Adapter (IPv4 UEFI)	ACPI(a0341d0,0)PCI(4,0)PCI(0,0)MAC(MAC(6c3be58d62da,0)RC
Boot0004* Windows Boot Manager	HD(2,c8800,82000,1757c49b-b3b5-4201-b506-dcf15496be2a)File(\EFI\Microsoft\Boot\bootmgfw.efi)WINDOWS.........x...B.C.D.O.B.J.E.C.T.=.{.9.d.e.a.8.6.2.c.-.5.c.d.d.-.4.e.7.0.-.a.c.c.1.-.f.3.2.b.3.4.4.d.4.7.9.5.}...a................
Boot0005* Network Adapter (IPv6 UEFI)	ACPI(a0341d0,0)PCI(4,0)PCI(0,0)MAC(MAC(6c3be58d62da,0)030d3c000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000RC
Boot0006* Linux Boot Manager	HD(2,c8800,82000,1757c49b-b3b5-4201-b506-dcf15496be2a)File(\EFI\gummiboot\gummibootx64.efi)
Boot0007* Linux Boot Manager	HD(1,800,c8000,52d738a5-fab3-401f-868e-53a3db7e8e39)File(\EFI\gummiboot\gummibootx64.efi)
Boot2001* USB Drive (UEFI)	RC
Boot3000* Internal Hard Disk or Solid State Disk	RC
Boot3002* Internal Hard Disk or Solid State Disk	RC
Boot3004* Internal Hard Disk or Solid State Disk	RC
Boot3007* Internal Hard Disk or Solid State Disk	RC

New partition table:

Number  Start (sector)    End (sector)  Size       Code  Name
   1            2048          821247   400.0 MiB   EF00  
   2          821248         1353727   260.0 MiB   EF00  EFI System
   3         1353728         1615871   128.0 MiB   0C01  
   4         1615872       316191329   150.0 GiB   0700  
   5       316191330       389576703   35.0 GiB    8300  
   6       389578260       402161171   6.0 GiB     8200  
   7       402161664      1465147391   506.9 GiB   8300

Does this seem like it should result in a bootable system or am I missing a step? smile

Edit: I haven't done anything with the fstab. I'm having difficulty finding any way to update it automatically. Do I need to change it manually?

Last edited by philomathean (2014-08-14 20:33:38)

Offline

#31 2014-08-14 20:41:24

Head_on_a_Stick
Member
From: London
Registered: 2014-02-20
Posts: 7,732
Website

Re: [SOLVED] How do I Auto-boot Gummiboot Instead of Windows?

Did you mount sda2 & check if there was anything inside before changing the partition type? I think you may lose data on that partition (sorry, I should have explicitly told you to backup any data there)...
You may want to "clear up" your NVRAM, use this to delete entries:

# efibootmgr -b xxxx -B

Where "xxxx" is the Boot number wink
Re: fstab --- use $EDITOR

Last edited by Head_on_a_Stick (2014-08-14 20:42:51)

Offline

#32 2014-08-14 20:50:03

loqs
Member
Registered: 2014-03-06
Posts: 17,427

Re: [SOLVED] How do I Auto-boot Gummiboot Instead of Windows?

fstab
Seems good hopefully the firmware likes that setup better as well

Offline

#33 2014-08-14 21:42:30

philomathean
Member
Registered: 2013-09-17
Posts: 17

Re: [SOLVED] How do I Auto-boot Gummiboot Instead of Windows?

There was data on /sda2 and I backed it up just in case, but it actually wasn't deleted during the partition type change (surprisingly).

Interestingly, though, it's still not behaving properly. sad

After first updating my fstab, the system booted gummiboot's interface first - it had an entry for Windows, but not for Arch linux.  I went into system interface and chose another option to load Arch which booted mosty fine (I failed to pay attention to case sensitivity of UUID, so I had to manually mount /boot).

However, once I was into Arch & corrected my fstab's /boot UUID and restarted, it loaded Windows again! mad

I copied my previous arch.conf file into my new /boot/loader/entries location in hopes that it should create an interface with both Arch & Windows. Rebooting to see what it looks like now.

Edit: Still booting to Windows & I don't seem to have an entry with Windows now that I've fixed my fstab (how would that even be related?). That should be a simple fix of adding an entry for Windows' partition.

/boot after all changes to this point:
screenshot-08142014-055120pm.php

Contents:
/boot/boot/boot.sdi
/boot/EFI//Boot/bootx64.efi
/boot/EFI/gummiboot/gummibootx64.efi
/boot/EFI/HP/(BIOS, BIOS Update, boot, EFI, & SystemDiags folders)
/boot/Microsoft/Boot/BCD
/boot/Microsoft/Boot/boot.stl
/boot/Microsoft/Boot/bootmgrfw.efi
/boot/Microsoft/Boot/bootmgr.efi
/boot/Microsoft/Boot/BOOTSTAT.DAT
/boot/Microsoft/Boot/memtest.efi

Edit2:
Should I have installed gummiboot into either /boot/EFI/Microsoft/boot or /boot/EFI/boot (both of which were on /sda2 to begin with) instead of /boot?

Last edited by philomathean (2014-08-14 22:00:47)

Offline

#34 2014-08-14 21:45:10

Head_on_a_Stick
Member
From: London
Registered: 2014-02-20
Posts: 7,732
Website

Re: [SOLVED] How do I Auto-boot Gummiboot Instead of Windows?

^ should work, as long as you change /boot/loader/loader.conf as well...

Last edited by Head_on_a_Stick (2014-08-14 21:46:08)

Offline

#35 2014-08-14 22:44:48

loqs
Member
Registered: 2014-03-06
Posts: 17,427

Re: [SOLVED] How do I Auto-boot Gummiboot Instead of Windows?

Did the boot order under efibootmgr change itself again so Windows Boot Manager is again set to boot first?
Does removing the duplicate / old EFI entries as Head_on_a_Stick suggested make any difference? (after deleting one entry I do not know if the remaining entries will be renumbered so best to check the numbering again after each operation)
Does changing it back still not stick on reboot?
If that fails Does just disabling /boot/EFI/Boot/bootx64.efi by renaming it or moving it incase the firmware is taking that in precedence to the the EFI Boot Order change the situation
If all the above is still failing I can not think of anything else to try but copying /boot/EFI/gummiboot/gummibootx64.efi to /boot/EFI//Boot/bootx64.efi
As above but copy /boot/EFI/gummiboot/gummibootx64.efi to /boot/Microsoft/Boot/bootmgrfw.efi after making a backup or the original
If it is still failing here might be worth trying with an alternative to gummiboot rEFInd (probably best to put the orginal  /boot/Microsoft/Boot/bootmgrfw.efi back at this point)
Edit:

philomathean wrote:

I went into system interface and chose another option to load Arch

I suspect the other option for arch still works because you copied the files to ~/Downloads/sda1bootbackup/ instead of moving them

Last edited by loqs (2014-08-14 23:17:42)

Offline

#36 2014-08-15 03:32:59

philomathean
Member
Registered: 2013-09-17
Posts: 17

Re: [SOLVED] How do I Auto-boot Gummiboot Instead of Windows?

Alright, I cleaned out /sda1 to get rid of the duplicate entry and deleted just one of my unused entries for now.

Tried updating boot order and disabling Windows partition, both on their own and in combination, but it still seems like the boot order is being bypassed.

I renamed the real /boot/EFI/Boot/bootx64.efi with no change to the boot pattern, followed by copying /boot/EFI/gummiboot/gummibootx64.efi to /boot/EFI//Boot/bootx64.efi and still with no changes.

It seems like the description posted in an earlier link (source), it seems like "OS boot manager" is somehow still overriding my boot info.

Quote:

There is some sort of a "recovery feature" or so that on every boot sets the very first UEFI load option to point to one of the two locations, in this order:

    \EFI\Microsoft\Boot\bootmgfw.efi
    \EFI\Boot\bootx64.efi

This option is displayed as "OS boot Manager" (for the first path) and something akin to "UEFI partition" for the second path, completely ignoring the actual name given to it (when you look at the EFI variables through efibootmgr, you can see that what is displayed as "OS boot Manager" actually is set to the name "Windows Boot Manager"; why anyone would do such renaming is beyond me). If you try to change the boot order so that this slot isn't the first, the UEFI will overwrite the BootOrder variable on next boot and reset it to point to "OS boot Manager" anyway.

Edit: It looks like I should be able to overcome this "security feature" by following the instructions features in the above link. I tried doing it on the Windows end earlier, with little success (Windows Command Prompt is truly terrible). I'll re-visit those instructions in my Arch terminal when I'm able to get back to my machine (probably late evening tomorrow, 8/15.

Last edited by philomathean (2014-08-15 03:37:53)

Offline

#37 2014-08-15 12:02:12

loqs
Member
Registered: 2014-03-06
Posts: 17,427

Re: [SOLVED] How do I Auto-boot Gummiboot Instead of Windows?

Might be worth trying renaming both /boot/EFI/Boot/bootx64.efi and /boot/Microsoft/Boot/bootmgrfw.efi to see if when both default locations missing if it will use the boot entry for gummiboot.
Either way I think you may need to create a manual gummiboot entry for Windows as the Windows Boot Manager is not longer at /boot/Microsoft/Boot/bootmgrfw.efi

Offline

#38 2014-08-16 06:27:52

philomathean
Member
Registered: 2013-09-17
Posts: 17

Re: [SOLVED] How do I Auto-boot Gummiboot Instead of Windows?

I renamed those files & I am now happily booting Arch automatically. It's actually bypassing the gummiboot menu altogether, but I'll handle that tomorrow. I'm assuming that since there is only one entry it's auto-launching and it'll present an option once I add a Windows entry into the mix.

Thanks to everyone for their input. I couldn't have solved it without you all. smile

Offline

#39 2014-08-16 11:50:36

midixinga
Member
Registered: 2014-01-18
Posts: 193

Re: [SOLVED] How do I Auto-boot Gummiboot Instead of Windows?

philomathean wrote:

I renamed those files & I am now happily booting Arch automatically. It's actually bypassing the gummiboot menu altogether, but I'll handle that tomorrow. I'm assuming that since there is only one entry it's auto-launching and it'll present an option once I add a Windows entry into the mix.

Thanks to everyone for their input. I couldn't have solved it without you all. smile

cool - short final description of the helpfull steps would be really nice

to get the gummiboot-menu just comment "timout" out in /boot/loader/loader.conf

Offline

Board footer

Powered by FluxBB