Home » Internet » 6 Ways to Fix Windows 10 Not Booting up on Linux

6 Ways to Fix Windows 10 Not Booting up on Linux

by Pratik
0 comment

Using Windows 10 and Linux on the same machine is painful. At times, the UEFI secure boot breaks GRUB and the other times GRUB cannot just boot Windows 10. Recently, I upgraded Ubuntu to 19.10 Beta from Ubuntu 19.04. Now, Ubuntu 19.10 comes with the new version of GRUB 2.04 which reportedly has lots of bugs.  In my case, GRUB somehow messed up Windows MBR location and now I cannot boot to Windows 10. To fix things, I ran a couple of steps and here is a detailed guide on how to fix Windows 10 not booting up on Linux.

Fix Windows 10 Not Booting up on Linux

If you are on Ubuntu 19.10 Beta, the GRUB 2.04 has a lot of bugs. It would be better to downgrade to Ubuntu 19.04 or move totally onto Windows. Skip to this step to check methods to change the default bootloader to Windows NT.

1. Rebuild GRUB

At times, GRUB has problems locating the Windows MBR file on your disks. The first step would be to check if Windows 10 can be detected by Linux. To do that, run the following command.

sudo os-prober

The above command will look for other operating systems installed on your disks. If Windows is detected, you would get an output like below.

os prober command detecting windows operating system

If the above command is able to find the Windows 10 operating system, then we can rebuild the GRUB configuration file. To do that, use the following command.

sudo update-grub

command to rebuild grub configuration file

The above command initiates scanning of all the partitions on your local disk and looks for various Operating systems installed. If it detects Windows 10, you should get a similar output as below. The command will automatically create a Windows entry in the configuration file as well.
windows EFI boot manager detected in update grub command

2. Boot Repair

If the command line is not your cup of tea, you can alternatively try the graphical Boot Repair tool. At times, the GRUB file is broken. The Boot Repair tool automatically searches for other operating systems on your disk. It also repairs and rebuilds the GRUB configuration file. It is similar to manually running os-prober and rebuilding the GRUB configuration file.

To begin with, use the following commands to add the required repository and install Boot Repair.

sudo apt-add-repository ppa:yannubuntu/boot-repair && sudo apt-get update 
sudo apt-get install -y boot-repair

Next, launch the boot repair tool. It will take a minute or two to scan all your disks and partitions. Once done, click on “Recommended Repair”. This option will delete the previous GRUB file and rebuild it from scratch.

select recommended boot repair in boot repair graphical tool

The next screen will present to you a set of commands which you have to copy and paste in the terminal. Just follow the on-screen instructions provided by the Boot Repair tool and it will repair the GRUB file for you.

commands to run as prompted by the boot repair tool

Boot Repair will give you an unexpected error if you are using a beta version of Linux distro.

If this method doesn’t work for you, chances are the Windows Boot manager file cannot be detected by GRUB. Hence, we would need to create an entry for it in the GRUB configuration file.

3. Use GRUB customizer tool

Straight up, I wouldn’t recommend manually updating anything in the GRUB configuration file. We will use an open-source tool called Grub Customizer. Run the following commands to download and install the tool.

sudo add-apt-repository ppa:danielrichter2007/grub-customizer && sudo apt-get update
sudo apt install grub-customizer

command to install grub customizer

Next, we need the location for the boot loader of Windows 10. To find that, run the following command in the terminal.

lsblk

Check out for the partition which has mount point as “/boot/efi”. This is the partition where the Windows boot manager is installed. We need the device name of the particular partition. In my case, it is sda1 hence the boot file location is “/dev/sda1”.

lsblk-command-displaying-windows-efi-file-location

Alternatively, you can also install gnome-disk-utility which is a graphical tool to display the disks and partitions. On the menu, you can look for the EFI System partition. The partition description should look something as follows.

gnome disks utility displaying disks and partitions

Next, head over to the GRUB customizer tool and click on the page icon at the top to make an entry.

On the entry editor pop-up, select the type as “Chainloader” and partition as “/dev/sda1”. You can also provide a suitable name to the entry. Post this, hit Enter.

adding windows 10 entry on sda1 in grub customizerYou would now be able to see the entry you have created on the Grub customizer menu. However, you need to click on Save to sync the changes with the original GRUB configuration file.

save windows entry from grub customizer to the configuration file

Finally, do a restart and now you should be able to boot to Windows 10. In case you can’t, most probably the Windows MBR is broker or boot files have gone corrupt.

4. Startup repair

If GRUB cannot load Windows MBR, chances are the file may be corrupt. We can repair it using a Windows ISO file and a flash drive. You can use any USB bootable software for Linux. I would recommend WoeUSB as it is simple and gets the job done quickly. Once you have the USB drive ready, boot from it. Click Next on the first screen and then click on “Repair your computer” on the next screen.

repair you computer option on the windows 10 installation screen

On the next page, click on Troubleshoot options and finally click on “Startup Repair”. It would take a while to fix the boot files and MBR.

startup repair on advanced options page

Most of the time, startup repair will fix the Windows Boot file. Once successful, reboot your machine and GRUB should be able to boot up Windows. If still there is a problem, we would need to switch the bootloader back to Windows NT.

5. Change default bootloader

If you are sure that the Windows startup file is not corrupt and you haven’t mistakenly wiped off C Drive, we can change the bootloader back to Windows NT. To do that, boot from the Windows USB, click on Next on the first screen. Next, click on Repair your computer and then on Troubleshoot.

troubleshoot option on windows installation screen

On the Advanced options page, click on “Command Prompt”.

command prompt option in advanced options page of windows boot page

On the command line, run the following command.

bcdedit /set {bootmgr} path \WINDOWS\system32\winload.efi

bcdedit command to change bootloader to windows nt

The above-mentioned command will change the bootloader from GRUB to Windows NT. Now, when you reboot your system, it should boot straight to Windows. In case you are coming from Ubuntu 19.10, you would need to roll back to Ubuntu stable 19.04 as GRUB 2.04 has lots of bugs.

6. Fresh Install Windows 10

In case none of the above methods work for you, chances are you might have accidentally wiped off Windows. The last resort is to do a fresh install of Windows 10. The good thing is you would only need to format the C drive and data in other drives won’t be lost. But still, you would end up losing files on the Desktop, Downloads, and Documents folder.

Closing Words

These are some of the methods to solve Windows 10 not booting on Linux. For more issues or queries regarding Linux or GRUB, let me know in the comments below.

Also Read: How to Get Windows And Mac Like Multi-Touch Gestures on Ubuntu

You may also like

Leave a Comment