Score:1

are bootloaders the same when installing them into different locations?

tj flag

I created 2 Linux partitions on my secondary drive along with my Windows main drive.

One of the partition, when created, i selected to install the boot loader on the Windows drive, and another partition the boot loader was installed on that partition.

I read about what boot loader is in general, but i am not sure whether they are the same, i.e. could i use either one boot loader to load either one of my linux systems on those partitions?

Thank you in advance.

oldfred avatar
cn flag
You do not install bootloaders to a partition like sda1, you install to a drive like sda. With BIOS it goes into first sector/MBR before first partition. With UEFI it knows to install into the ESP - efi system partition. If UEFI and installed to ESP on each drive, you will have two UEFI boot entries as "ubuntu". And UEFI entry used GUID/partUUID of the ESP. Post this if UEFI. `sudo efibootmgr -v` and `lsblk -e 7 -o name,fstype,size,fsused,label,UUID,mountpoint,partuuid`
GGinside avatar
tj flag
right now when i use this external drive on a windows pc without the bootloader installed, i need to go to advanced startup and only one ubuntu shows up. I need to check with my other windows machine which has a bootloader in the primary drive.
oldfred avatar
cn flag
If an exteranl drive that you want to use with more than one system, better to have an ESP with boot files on external drive.You need both /EFI/Boot and /EFI/ubuntu folders on external & it will boot from UEFI entry of external drive (not Ubuntu). Internal drive boot entry may be "ubuntu" but often removing drive changes UEFI entry, so it may not work, but then a drive entry like booting live installer should still work. Newer versions do not use Ubiquity installer, 22.04 does. https://bugs.launchpad.net/ubuntu/+source/ubiquity/+bug/1396379
Score:0
cn flag

"Could I use either one boot loader to load either one of my Linux systems on those partitions?"

Yes, but that's needlessly complicated for most users.

Most typical-usage folks use a single bootloader for the whole system.

Most installers are smart enough to locate and edit that bootloader during the install. Manually editing EFI or GRUB settings was common years ago, but rare today for most Ubuntu users.

rando avatar
kz flag
Manually editing EFI / GRUB settings is not rare at all! Ask any Linux From Scratch user.
GGinside avatar
tj flag
could you elaborate "needlessly complicated"? are they the same or not? it feels like installing it on the drive where windows system is, i could get change boot options from bios and choose ubuntu. But installing the bootloader onto an external disk i have to do advanced startup option after boot into windows first, or maybe im wrong, but i dont see a viable boot option in bios.
user535733 avatar
cn flag
If File A and File B are on different storage devices, then they are clearly not the same, even if the contents of both were identical at one time. If having two bootloaders (and occasionally synchronizing them) does not seem complicated to you, then feel free to go right ahead and install both. The OS that gets loaded won't mind at all.
GGinside avatar
tj flag
so basically bootloader need to cache some information locally? this is not easy to tell from the answer. since i consider bootloader a program to load the os, i thought all it has to know is where the os is. i would only suspect two ways of knowing that: 1. code that info when installing the os. 2. bootloader could scan the system for multiple installed os, and let user select. I was thinking about 2 as how bootloader works, since it would be much easier for people to use it.
user535733 avatar
cn flag
Grub is only about 130kb. It cannot scan. It does not cache. It is not intended to be user-friendly. It has one job, and that job is really important.
GGinside avatar
tj flag
okay, i am hoping to know more. if you could point me to anywhere i could read more? you said to no both, but you didn't answer how it works. or will i get a typical response like "this is another question, open another thread answer?"
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.