On 07/19/2018 05:02 PM, Istvan Gabor wrote:
I have several linux OS-es on a hard disk. Each OS has its own boot loader installed on the OS's root partitition. The MBR has also a boot loader. This boot loader chainloads the other boot loaders on the root partitions. This makes easy to completely separate different boot menus for different OS-es.
I do this as well.
For the management of the above scenario at least one of the OS-es must have 2 different boot loader install configurations, one for the mbr boot loader (chainloader) and one for the OS's own boot loader on the root partition.
There's another way. What I do is reserve a small (~256M) ext2 partition just for the "master" GRUB loader. Using /dev/sda5 as an example: mount /dev/sda5 /mnt/grub grub2-install --boot-directory /mnt/grub /dev/sda This installs GRUB to /dev/sda5 and makes the MBR boot it. You'll have to provide your own grub.cfg to chainload to the installed operating systems, but that's largely an exercise in cut 'n' paste from your existing /boot/grub2/grub.cfg. You don't have to worry about /etc/grub.d because you're editing grub.cfg yourself rather than relying on the update-grub2 scripts to magically do it. I also make this "master" GRUB partition bootable: grub2-install --force --boot-directory /mnt/grub /dev/sda5 That way, if the MBR gets trashed, you can just start GRUB from a rescue disk and manually chainload to it from the GRUB command line to get access to all your installed operating systems: set root=(hd0,5) chainloader +1 This is what my "master" GRUB menu looks like: https://www.lyonlabs.org/shoggoth-boot.png I can provide the grub.cfg if you'd like to see it. -- Glenn Holmer (Linux registered user #16682) "After the vintage season came the aftermath -- and Cenbe." -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org