0

I am reading an article titled How Computers Boot Up. In it, it suggests that a Master Boot Record (MBR) consists of "a tiny OS-specific bootstrapping program at the start of the MBR followed by a partition table for the disk".

It goes on to say that the OS-specific bootstrapping program could be "a Windows MBR loader, code from Linux loaders such as LILO or GRUB, or even a virus."

In a dual-boot system (e.g. Windows and Ubuntu), what factors determine which OS-specific bootstrapping program is used for the MBR?

N.B. This question is different from Determine what program is in my MBR code, which asks how to identify which program is in the MBR, whereas I'd like to know give two bootstrapping programs, what factors determine which one gets used.

dayuloli
  • 515
  • 4
  • 14
  • Your dual boot system still uses one boot loader. For example, `grub` can boot either Windows or Linux. – Peschke Aug 15 '19 at 20:53
  • I understand there's still just one boot program. But Windows uses Windows MBR, and Linux uses GRUB2. When I install Windows, it seems to overwrite whatever boot program I had installed previously, but it seems that not all OSes do this, so I am not sure if there's a convention as to which boot program is used. Is it the one from the last installed OS? – dayuloli Aug 15 '19 at 22:05
  • 1
    Correct, the boot loader used is the one last installed. Installers for systems such as Windows and Ubuntu typically install a boot loader without asking you. Therefore, if you were to install Windows last on a hard drive you had Linux on, the Windows boot loader will override whatever you had installed before. Some installers ask you if you want to install a boot loader or keep what you have, like Slackware. – Peschke Aug 15 '19 at 23:23
  • 1
    Perhaps you're thinking of UEFI, where you can have multiple UEFI executables on the EFI partition, including GRUB2 and the Windows bootloader? – jsbillings Aug 16 '19 at 00:43

0 Answers0