0

I have a Lenovo Yoga 720 laptop with Windows 10 installed. I was attempting to install Ubuntu 18.04 as a dual boot option.

I was able to install Ubuntu successfully, but encountered some difficulties in that during the boot up process, I was not seeing an option to choose between the two OSs. I had to press F12 manually and select from one of the choices to boot into either Windows 10 or Ubuntu 18.04.

I think this was because I had installed Ubuntu in legacy mode, but later found out that I should have installed it in UEFI mode instead.

To start over, I removed the Ubuntu partitions using the Disk Management application in Windows.

Now when the boot mode is set to "Legacy Support" (boot mode: legacy support), I either get an error and go into GRUB rescue mode (I tried Boot-Repair by loading Ubuntu using a live USB as well as the program Dual-boot Repair Tool to no effect) or have to press F12, after which I go to this screen. From there, I have to choose the second option to load Windows 10.

On the other hand, if I set the boot mode to "UEFI" (boot mode: UEFI), I can load Windows without any issues. In this case, on pressing F12 and loading the boot manager, I see this. As you can see, there is only one option (Windows Boot Manager).

Can someone explain is happening here? Why do I not see the second option when the boot mode is set to "UEFI?"

I also wish to know how I can remove the additional option ("SATA HDD : SAMSUMG MZ......") from the Boot Manager when the boot option is set to "Legacy Support," so that Windows loads automatically in this case too without having to press F12 and choosing the 2nd option from the Boot Option Menu?

  • I never tried it, but I think maybe Rescatux can do this because it has options for Windows in a dual boot too. Restore Windows bootloader – karel Dec 11 '18 at 16:12
1

Legacy boot mode and UEFI boot mode work totally different. You need to understand the basics.

Legacy boot mode

A legacy boot loader is stored in the MBR (first sector of the disk), only one boot-loader can exist at this location. If you have legacy mode enabled in you UEFI settings and a boot-loader exists in the MBR of a drive, an entry like "SATA HDD : SAMSUMG MZ......" will be added to the EFI boot menu.

You had Ubuntu installed in legacy mode, so you have Grub in the MBR of your drive. Deleting the Ubuntu partition(s) does not remove anything from the MBR, so you still have Grub as a left-over in your MBR. This instance of Grub will refuse to work because it can't find it's configuration files which where located in your Ubuntu partition.

UEFI boot mode

In UEFI boot mode, boot-loaders are stored in the EFI System Partition (ESP), several bootloaders can coexist here, each boot-loader resides in it's own folder in this partition. The EFI boot menu will be populated with entries for each bot-loader, usually the folder-names in the ESP are used then.

If you have both boot modes enabled, your EFI boot menu will be populated with the entries for both boot modes, that should be trivial.

Solutions

  • The safest way is to disable legacy boot mode. You don't need to have legacy boot mode enabled if your OS is installed in UEFI boot mode. This will boot faster ( the compatibility support module (CSM) doesn't need to be loaded) and reduces the clutter in your EFI boot menu. You can re-enable legacy boot mode whenever you need it though. It will also prevent you from installing Ubuntu in the wrong boot mode.

  • If you insist on leaving legacy boot mode enabled, adjust the boot order in your UEFI settings to boot Windows first.

  • Overwrite the first 446 Byte of your MBR with zeros. This is a quite dangerous action, a simple typo might leave you with a disaster and I strongly recommend not to do so. You could achieve that with booting your Ubuntu installer (try without installing), find out the correct drive name with sudo fdisk -l and overwrite Grub with sudo dd if=/dev/zero of=/dev/sdx bs=446 count=1 (you have to replace sdx with the correct drive name of course). If you do so, do it on your own risk, you've been warned.

| improve this answer | |
  • Thank you for the detailed response. If I were to set the boot mode to UEFI and then install Ubuntu while following the instructions here (askubuntu.com/questions/927924/…) or here (help.ubuntu.com/community/UEFI), I will see two boot managers upon rebooting post-installation and will have the option of choosing the OS I wish to boot into? – Anonymouse Dec 13 '18 at 21:18
  • If you want to dual-boot with Windows, installing Ubuntu in the same boot-mode as Windows is installed is the correct way to go. Grub can handle Os's installed in the same boot-mode and offers you the choice which OS to boot. There might be other caveats, depending on your hardware. Try to install and, if you run into problems, please ask a new question. – mook765 Dec 14 '18 at 6:45

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.