Understanding EFI, GRUB and all that jazz

Chat about just about anything else
Post Reply
User avatar
GS3
Level 7
Level 7
Posts: 1742
Joined: Fri Jan 06, 2017 7:51 am

Understanding EFI, GRUB and all that jazz

Post by GS3 »

In the good old days before EFI the BIOS would have a look around and tell you what devices you could boot from and would have a default boot order you could set. You could connect or disconnect devices and it would not affect the rest. One bootable device knew nothing about any other bootable devices. Simple, easy and it worked.

Enter the EFI which was done to solve some problem of which I am not aware (except maybe helping MS prevent other OS from booting).

Now we have EFI and, I for one, all the problems which come with it. Which are many and frequent. I see EFI entries for things which I have no idea what they are or may be or may have been.

Every time I add some device it seems the EFI list gets more mangled.

GRUB was updated and that mangled things even further.

So I am trying to understand how this thing works and see if I can make any sense of it.

It seems to me the EFI boot list or table is kept on NVRAM on the mobo and this list can be modified by the BIOS itself or by any of the OS installed which is a problem when they all decide to mess with entries for other OS. Which I think is what is happening to me.

Somehow entries keep being added which I think just are duplicates of existing entries. Once one entry was deleted but I think it was overwritten by another entry.

So, if I focus only on three of the entries It seems to me the first one "Ubuntu" points to a GRUB on the HDD where LM18 resides but that GRUB menu also gives me the option of starting LM19 which resides on a different SSD

If in EFI I choose the second choice, "Ubuntu" it sends me to GRUB on the SSD and it only gives me the choice of booting LM19 from that very SSD.

If in the EFI menu I choose the third choice, "Mint" (this entry was created manually to replace one which was deleted) it send me to the same GRUB menu as the first choice, with the same options.

I am not going to list all the entries because there are too many.

Is my understanding so far correct?

It seems to me it would be better to have each drive be self-contained and not have GRUB pointing at an OS on another drive.

Not only that, entries are added to the EFI list which I think are duplicates of existing entries. Why?
Does the BIOS not recognise the drives already have entries?

It seems to me since GRUB was updated all these problems have cropped up.

And I have the HDD containing Windows 7 physically disconnected and I am afraid to connect it. If the EFI/BIOS has problems with two versions of LM I hate to think how trying to have Windows and Mint get along would work out. Probably each one deleting the other's entries.

Come to think about it, does "Secureboot" lock the EFI in place as it is? Because I guess I could try to get the EFI in a reasonably usable state and then lock it so no one could mess with it.

I have half dozen EFI entries named "Ubuntu" and I don't need any more.

Should I be afraid to physically connect the Windows HDD? Will it kill the EFI entries for LM so I can no longer boot?
Attachments
efigrub01.png
efigrub01.png (1.62 KiB) Viewed 429 times
Please do not use animated GIFs in avatars because many of us find them distracting and obnoxious. Thank you.
User avatar
Portreve
Level 10
Level 10
Posts: 3317
Joined: Mon Apr 18, 2011 12:03 am
Location: Florida

Re: Understanding EFI, GRUB and all that jazz

Post by Portreve »

Image
Please remember to mark your fixed problem [SOLVED].

Running Linux Mint Cinnamon 20.0.

The noblest of all dogs is the hot-dog; it feeds the hand that bites it.
— Dr. Lawrence J. Peter
lexon
Level 6
Level 6
Posts: 1127
Joined: Sat Jan 31, 2009 10:53 pm
Location: MA USA

Re: Understanding EFI, GRUB and all that jazz

Post by lexon »

I got around that by buying a Dell laptop with W10 about three years ago when my Two Acer's all failed with Linux. Could not figure out dual boot anymore even following instructions here. Details not the same.
I bought another with Lenovo from Amazon with Linux Mint on it. USB mouse not recognized. Must need a driver but no CD machine in it.
Problem solved anyway.

L
Lindows, Linspire, Freespire, Ubuntu, Mint 15 Cinnamon, Mint 16 XFCE, Mint 17 Cinnamon 64 bit. MInt 18 64 bit Cinnamon.
lexon
Level 6
Level 6
Posts: 1127
Joined: Sat Jan 31, 2009 10:53 pm
Location: MA USA

Re: Understanding EFI, GRUB and all that jazz

Post by lexon »

I will not mess up a good W10 PC.

L
Lindows, Linspire, Freespire, Ubuntu, Mint 15 Cinnamon, Mint 16 XFCE, Mint 17 Cinnamon 64 bit. MInt 18 64 bit Cinnamon.
User avatar
GS3
Level 7
Level 7
Posts: 1742
Joined: Fri Jan 06, 2017 7:51 am

Re: Understanding EFI, GRUB and all that jazz

Post by GS3 »

I am bumping this because it is something I want to understand and I think it is important to understand. I am hoping for some in-depth knowledge.
Please do not use animated GIFs in avatars because many of us find them distracting and obnoxious. Thank you.
Hoser Rob
Level 16
Level 16
Posts: 6609
Joined: Sat Dec 15, 2012 8:57 am

Re: Understanding EFI, GRUB and all that jazz

Post by Hoser Rob »

Ubuntu wikis are very good info sources, the Arch ones may be even better but then you have to know the difference between the way ubuntu and arch do things.
Bobb24
Level 3
Level 3
Posts: 106
Joined: Sun Mar 10, 2019 12:12 pm

Re: Understanding EFI, GRUB and all that jazz

Post by Bobb24 »

I was running 18.3 Mate and then removed and replaced hard drive and installed 19.3 Mate. It installed itself with UEFI partition unlike 18.3 which was legacy.
Later reinstalled 18.3 hard drive along side 19.3 disk and had to go into BIOS and select the 18.3 drive to boot. All good , booted to 18.3. Mounted 19.3 disk to browse folders.
Now when I turn on computer it starts 18.3 disk and grub has updated itself and shows option to boot 19.3 as well. And it works if I choose it.
So not sure if this helps you figure out your particular question but this installation sequence got my system to dual boot between 2 hard drives, one with UEFI boot and the other with legacy boot without having to go into BIOS to select between legacy and UEFI and I didn't think this was possible but Linux set this up by itself.
Also a tutorial ? for UEFI for HP
viewtopic.php?f=42&t=243338
User avatar
olo
Level 2
Level 2
Posts: 76
Joined: Mon Oct 05, 2020 3:01 pm

Re: Understanding EFI, GRUB and all that jazz

Post by olo »

I just can talk about the M$ PC world.
One day M$ decided the users had it much to easy to screw around with their computers and decided the fun ride up to win 7 was over.
A "more secure" way was looked at to make things as complicated as possible so you need a certified M$ trained pro to get things right. EFI and UEFI showed up
Enter Win 8 - people were outraged and it flopped big as it is norm in the windows world, 1 good os is followed by a bad os since 95.
People stuck with their win 7, even win 8.1 did not safe the crappy 8 os.
So M$ told intel, with your next chip generation you will block 7 and below. People will not be able to install 7 on their system they will be forced to 10.
Since Apple stayed with 10 (X) since many years M$ copied that, so there was no win 9.

The bios was blocked and with a lot of modern computers F2 or ESC or F1 does not bring you into the bios any more.
You need to do the detour over recovery and on the last screen you are finally able go get into the bios (UEFI).
There if the hardware vendor allows, you can disable secure boot, fast boot, enable legacy support, legacy usb support and can choose the boot order and if legacy (win 7 and b4 and fat 32) will be able to boot. If you are lucky you can safe all this or have at least in the last screen a possible boot order override.
Since a bios can be locked down as far as the hardware vendor chooses you have to see what your bios allows.

I tried to boot from 2 different I3 win 7 laptops but both, no matter what setting, refused to boot from the linux life usb.
An older one had no problem at all.

This does not answer your question in anyway, but gives you and idea who and what motives are behind all that mess, why you see 3 little partitions before the big ones in win.
... hope it was at least a bit entertaining.



(The same guy wants now to chip and vaccinate the whole world.)
Testing with Mint20C right now (and giving up on it): LENOVO YOGA 710-14IKB
Bobb24
Level 3
Level 3
Posts: 106
Joined: Sun Mar 10, 2019 12:12 pm

Re: Understanding EFI, GRUB and all that jazz

Post by Bobb24 »

olo wrote:
Sun Oct 18, 2020 6:08 pm
I just can talk about the M$ PC world.

Since a bios can be locked down as far as the hardware vendor chooses you have to see what your bios allows.

I tried to boot from 2 different I3 win 7 laptops but both, no matter what setting, refused to boot from the linux life usb.
An older one had no problem at all.

(The same guy wants now to chip and vaccinate the whole world.)
That's interesting. You may be right but if you run into that problem again you should look at posts under "installation and boot" and ask for advice if you can't find any info there. I say this because from what I have read on this site is that most computers can be manipulated to start/install off a live disk. Maybe not all but older I3 Win 7 should be a go. Lots of Win 10 converts too.
Post Reply

Return to “Open chat”