Configuring a computer as dual boot system is a popular solution for users that wish to use Linux and Microsoft Windows on the same device. However, getting the two operating systems to share the same computer can be a bit tricky. In particular, Windows has its own boot loader and Linux uses GRUB. It’s easiest to have a dual boot system when GRUB is used as the boot loader, as it can be easily configured to boot into Windows as well as Linux.
In this guide, we’ll go through the step by step instructions to add Windows 10 to the GRUB menu. This way, you can select between Windows and your installed Linux distro when the computer first boots up. This guide assumes that you’ve already installed Linux and Windows on the same computer, and simply need to add Windows as an option to your GRUB menu.
In this tutorial you will learn:
- How to add Windows to GRUB boot menu
Category | Requirements, Conventions or Software Version Used |
---|---|
System | Any Linux distro dual boot with Windows 10 |
Software | os-prober, GRUB |
Other | Privileged access to your Linux system as root or via the sudo command. |
Conventions |
# – requires given linux commands to be executed with root privileges either directly as a root user or by use of sudo command$ – requires given linux commands to be executed as a regular non-privileged user |
Add Windows to GRUB boot menu
Once you are booted into your Linux partition, follow the steps below to get your Windows 10 install added to the GRUB menu list.
- Open a terminal and run the
os-prober
command with root privileges. This will search for other operating system installations besides the current distro you’re booted into.$ sudo os-prober
It should find your Linux distro, the Windows installation, and possibly a memory test installation or recovery partition.
- To add these findings to the GRUB menu, execute the
update-grub
command with root permissions.$ sudo update-grub
The output should show that Windows 10 has been found and added to the GRUB boot menu.
You can see this change for yourself by examining the GRUB menu configuration file at /boot/grub/grub.cfg
as seen below. Deleting this entry will indeed erase Windows 10 from the GRUB menu, but it’s easy enough to put it back by following the steps above.
In the future, when powering on your system, you should see Windows 10 listed as an option in the boot menu.
Use your arrow keys to select Windows 10, and you will boot into it instead of your installed Linux distro.