1

After reading a lot online, I start to get more and more confused about how boot manager work. I have realized that boot manager, such as rEFInd, is not an update or anything related to firmware (correct me if wrong). I now have the following understanding:

For BIOS machine, one would expect the BIOS firmware to recognize all the disks present in the computer (it does not recognize partitions on any disk). Let's say the machine has a internal hard drive and a external CD connected to it. Then BIOS let you choose one of them and read the boot loader on the MBR of the hard drive or CD. Now, suppose that you have both Windows and Linux installed on the hard drive. Here comes the part I am not completely sure, if you have installed GRUB, both a boot manager and boot loader, does it mean that after you choose to boot from the hard drive, the GRUB boot loader is read and executed, which invokes the GRUB boot manager? then GRUB boot manager recognize the different systems you have on your machine, and invoke then invoke the boot loader for windows or boot loader for Linux, which is still a part of GRUB?

For UEFI machine, it seems like the firmware is already a boot manager as it recognizes the partition table and all the disks connected to the computer. So all you need is to write the boot loader to the EFI system partition and firmware will let your choose which boot loader you want to use at boot time. Is that right? However, I notice that there is still boot manager such as rEFInd available for UEFI machine, what are they for then if the firmware is already acting like a boot manager. Moreover, is rEFInd considered firmware stuff or just some application installed on a particular disk's EFI system partition?

1

Any code that runs before the main operating system is started, and that's involved in starting other programs, is a bootloader. Most computers, even most embedded devices have a chain of bootloaders: code in ROM or flash memory that loads another piece of code from flash memory or a disk drive, that loads another piece of code and so on. The BIOS is a bootloader (and it may have), reFInd is a bootloader, Grub is a bootloader, etc.

Some bootloaders do nothing but load another piece of code and branch to it, but most perform additional tasks such as reading configuration data, detecting connected peripherals, testing hardware, initializing devices, enumerating storage and network devices to determine what to load next, displaying messages on the screen, listening to user input to allow the user to influence the boot process, etc.

A boot manager is a particular type of bootloader that includes a way for the user to select between several operating systems. The Grub bootloader doesn't really “invoke” the Grub boot manager, the boot manager functionality is one aspect of Grub.

Some PC legacy BIOS have crude boot manager facilities in that they allow the user to select between a few devices; it's limited because legacy BIOS can only load the first 512 bytes of a disk and execute code there. UEFI has a more powerful boot manager that allows the user to select between files on a FAT partition.

Whether bootloaders count as firmware depends on exactly how you define firmware. By the definition “provided with the computer hardware, as opposed to installed on a storage device”, BIOS and UEFI are firmware but reFInd and Grub aren't. By the definition “independent from the operating system”, reFInd and Grub are firmware.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.