Earlier I was having LinuxMint along with Windows 8.1 and openSUSE 13.2. Now I’ve replaced it with Ubuntu. Rest others are intact and can boot into them.
Problem with openSUSE
I want to use openSUSE as default bootloader. In yast > bootloader, while installing bootloader, it quits at 66% and still Ubuntu is default bootloader.
Is there any command line equivalnet. Currently I’ve enabled secureboot.
While booting openSUSE at the plymouth boot screen a message is displayed - loading .swap 2s/1m30s (I don’t remember the full text). And it waits till 1m30s. Before installing Ubuntu this problem was not there. This is too slow. I can’t wait that much
Before installing ubuntu I could select openSUSE in the BIOS settings. Now Ubuntu has replaced openSUSE in the BIOS boot order and option for openSUSE is not their. That is why I’m trying to reinstall the bootloader. And yast bootloader doesn’t seem to work properly.
So in one of the Linux look at /boot/efi see if there are directories for all 3 OS
Each OS should have a directory with several files in it
Note that things can get complicated if you did mix in a MBR boot with the EFI boots
It always best to use the same boot mode for all OS.
Also in Yast boot you should see that the installed grub is grub2-efi if not then you may have used a MBR install instead of an EFI install and strengthening that out full is complicated
ls /boot/efi/EFI/
Boot Microsoft OEM opensuse ubuntu
All the os were installed in efi mode. You confused me by talking about MBR. See I’ve spent less time on linux as you might have. So, if you or anyone else helps me out, I won’t judge, I would readily believe.
Ok in Yast - Bootloader: Bootloader - Grub2-EFI, Secure Boot Enable, Protective MBR Flag - Unchanged
I clicked ok. After 66% the window suddenly closed
Now I want to install openSUSE bootloader by command
Ok fine no MBR but there are plenty that come here that have messed things up mixing boot modes or maybe just deciding to do a full MBR install and not telling us.
You probably only need to use “efibootmgr” for this. Everything else is likely in place. You will need the “-c” option to “efibootmgr”. The man pages are fairly good, and google will turn up some examples of using it this way.
As I recall, you need to specify the partition (for your “/boot/efi”) and the disk drive. And you need to give the path to the command (probably ‘\EFI\opensuse\shim.efi’) and the boot name (usually “opensuse-secureboot”.
This adds the NVRAM entry that the firmware uses during booting.
I would think you would need the option -o for efibootmgr.
Here’s the portion of the man page.
-o | --bootorder XXXX,YYYY,ZZZZ
Explicitly set BootOrder (hex)
Here is thre result from efibootmgr for my system. I can set up my system to select any of the drives as the default boot drive by using the -o option.
Note that they do not necessarily show the drive or partition number directly although mine are mapped as number → sdX. In other words, Bootorder 0000 corresponds to sda1, 00001 is sdb and so on. If there are more than one bootable systems on a single drive, the partitions will be shown in the string. You’ll need to know where on each drive you installed a system unless, like mine, the system is labeled as such.
bart@UNIVAC:~> su -
Password:
UNIVAC:~ # efibootmgr
BootCurrent: 0001
Timeout: 0 seconds
BootOrder: 0001,0002,0005,0000,0006,0003,0004
Boot0000* Windows Boot Manager
Boot0001* opensuse
Boot0002* Fedora
Boot0003* CD/DVD Drive
Boot0004* Hard Drive
Boot0005* UEFI OS
Boot0006* UEFI OS
UNIVAC:~ #
Yes, he might be able to use that. But you can only put the opensuse entry first if it already exists. I got the impression that it doesn’t even exist. The files for it seem to be there in the EFI partition, but the NVRAM entry looks as if it is missing.
It’s shim-install not install-shim actually. And it gave error then.
Out of curiosity this time I wanted to used the same command. Given man shim-install didn’t give any result. I gave a try.
I did
su -
shim-install
And success. openSUSE bootloader is now the default bootloader.
And now a question. Why did the same command fail in previously mentioned thread? What does shim-install actually do?
There seemed to be limitations on your BIOS, for the previous thread.
Note that you can get a small amount of help with:
shim-install --help
As for what it does: It copies “shim.efi”, “MokManager.efi”, “grub.efi” to “/boot/efi/EFI/opensuse”. It also generates a suitable “grub.cfg” (and possibly “boot.csv”) in that same directory. Then it use “efibootmgr” to create an NVRAM entry for your firmware to use. I think it also makes changes to “/etc/default/grub”. At some point, it calls “grub2-mkconfig” to generate “/boot/grub2/grub.cfg” which is your main boot menu.
I had one more major breakthrough.
Currently I’m quadrabooting with Windows, openSUSE, Ubuntu and Fedora.
I’ve also enabled secure-boot. And only windows and openSUSE can boot with openSUSE bootloader (with secure boot on)
(That, is what I like about openSUSE bootloader. If the secure boot is on, no other bootloader (I’ve tested Ubuntu and Fedora) can load windows by default.)