0

I'm sure this question is asked a lot on here but I can't seem to find an answer/solution that has worked for me.

I have Windows 10 on a Samsung 850 SSD and Linux mint 19.3 on a Samsung 750 SSD. I've set my SATA config in my BIOS to AHCI as some solutions have said.

When I set my BIOS to "UEFI only" or "UEFI and legacy" it will boot to Windows, irrespective of boot priority. If I set the BIOS to "Legacy only" then it will boot to Linux irrespective of boot priority and doesn't even recognize the windows drive anywhere in grub.

Before this new motherboard (Asus TUF GAMING X570-PLUS) I used to use EasyBCD to manage the dual booting which worked for me. I'm not fussed if I use this or grub for my purpose. All I want is Windows to be the default option when it boots up and obviously linux as an option.

I've been trying for the past day finding every possible situation that sounds similar to mine.

2 Answers 2

3

Solution

I would abandon legacy boot for Ubuntu. EFI is designed to have multiple boot loaders side by side. The easiest thing you can do is to install grub into the EFI partition on your Windows drive and then boot "UEFI Only".

To do this:

  1. Boot into Linux
  2. Locate your EFI partition. You can use sudo blkid to find the right one. Mine is /dev/sdb2.
  3. Mount your EFI directory to /boot/efi, make the directory if necessary

    sudo mkdir /boot/efi
    # replace /dev/sdb2 with your EFI partition
    sudo mount /dev/sdb2 /boot/efi   
    
  4. Install grub-efi. I'm assuming this is a standard 64 Bit Intel CPU

    sudo apt-get install grub-efi-amd64
    
  5. Install grub to your EFI partition.

    sudo grub-install /dev/sdb2
    
  6. Optional: you might need to tell your BIOS exactly where to look for the EFI file. You may need to go into your BIOS settings to add it manually. From memory, mint uses the same setup as ubuntu, so Grub should have written it to EFI/ubuntu/grubx64.efi. But you might want to check this with:

    sudo ls -lh /boot/efi/EFI/ubuntu/
    
  7. Once you have everything setup neatly with UEFI, you should find that update-grub can detect the windows bootloader. This should give you a menu option to boot Windows. So boot back into Linux and call:

    sudo update-grub 
    

Discussion

BIOS Behaviour is very tricky because there are very many different BIOS with wildly different implementations of boot logic.

You say that your legacy disk doesn't show up when in UEFI + Legacy but it does in Legacy only. I believe that for your BIOS UEFI + Legacy may be interpreted as "UEFI or Legacy" not "UEFI and Legacy".

It's not uncommon to get problems with a multi-disk setup like this. Contrary to ron's answer, I've experienced more boot problems with multiple disks than single disks. Multiple disks was a big advantage in the days of "legacy only". But since UEFI it can cause a problems. For example some BIOS just don't recognise it when you have multiple EFI partitions spread across multiple disks... They find the first EFI partition and stop looking.

UEFI was designed so that you can have multiple boot loaders side by side. Since you already have EFI working for Windows, it makes sense to install Grub right along side.

5
  • I'm having trouble identifying my EFI partition. It kinda looks like there is 3 to me? dpaste.org/BuWj
    – shmink
    Commented May 27, 2020 at 14:47
  • 1
    That's odd. You are looking for a FAT32 partition. When you mount it, you expect it to contain only one directory named EFI. Commented May 27, 2020 at 14:50
  • So it's that the one partition with the EFI label is vfat rather than FAT32?
    – shmink
    Commented May 27, 2020 at 15:01
  • That sounds like the one. Commented May 27, 2020 at 15:15
  • Got an issue on step 5 dpaste.org/mdHa
    – shmink
    Commented May 27, 2020 at 16:43
-1

when you have just one disk, trying to have both win10 and linux on that one disk, then that gets problematic with the windows boot manager not playing nice with GRUB... or possibly any other boot manager.

You seem to indicate you have two disks, with windows all by itself on one disk and linux all by itself on a separate disk. I think this is the best way, as it keeps the boot manager programs, and disk boot partitions, completely separate. As such, you then leave it up to your motherboard to choose which disk to boot, after which point everything is normal... one operating system and/or boot manager as no idea about the other and no chance of conflicts.

In the second (preferred) case then it comes down to motherboard setting/capability

  • if any disk is formatted with a MBR and dos partition scheme, then you need to enable that legacy bios mode so it can recognize such a disk; you cannot use UEFI only.
  • Usually the Legacy mode also includes UEFI so that is generally the safest setting if ignorance is bliss, but recognize a UEFI ONLY setting requires a disk formatted as GPT having an EFI boot partition.

Win10 is definitely UEFI, and linux can be both so you have to recognize if your linux install onto its specific disk if that linux disk was formatted with a dos partition scheme and MBR, or was done as GPT and has an EFI partition.

Only if both disks have EFI partitions can you set your motherboard to UEFI ONLY.

At that point, look in your mobo settings for a boot manager or whatever it may be called. I have an ASROCK mobo, and with their thing enabled it defaults to booting my win10 disk but if I choose within N seconds can choose my other [linux] disk. Here is an example pic: https://i.sstatic.net/kUZuu.jpg

In UEFI w/Legacy mode it should simply be a matter of instruction the mobo which disk(s) to boot in which order. It does not need to be any more complicated than that. Then when whatever disk is booting, it's boot partition and boot manager takes over like it always would/should have in a single disk computer.

2
  • 1
    I've run a large range of Linux / Windows dual boot environments from a single disk for over ten years. I've never witnessed anything to suggest that it's particularly problematic. Commented May 26, 2020 at 22:01
  • 1
    From the OPs description of what works for them and what doesn't, it looks perhaps like the mixed mode (UEFI And legacy) doesn't behave the way you expect. Such behaviour is not well standardised and varies wildly between different BIOSes. Without knowing the specifics of the OPs BIOS I don't think you have the evidence to clim that it will just work, when the evidence in the question is that it doesn't. Commented May 26, 2020 at 22:07

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .