In this Step-by-Step article, I'll show you how to safely remove Windows from a Windows-Linux dual boot system. I'll cover the steps involved in deleting the Windows partition, updating the boot loader, and troubleshooting any problems that might occur.
By the end of this article, you'll know how to uninstall Windows from your dual boot system without causing any damage to your data or your computer.
Table of Contents
Dual booting Windows and Linux is a great way to get the best of both worlds. You can use Windows for your everyday tasks, like browsing the web, working on documents, and playing games. And you can use Linux for more specialized tasks, like programming, software development, and security research.
But what if you decide that you no longer need Windows? Maybe you're tired of the dual boot hassle, or maybe you've decided to switch to Linux full-time. Whatever the reason, it's important to know how to safely remove Windows from your dual boot system.
Why Remove Windows from Dual Boot?
Firstly and foremost, I appreciate your decision to remove Windows and keep Linux as the only operating system. Compared to Windows operating system Linux gives you full control and offers a lot of customizations.
Unlike Windows, there are a wide variety of distributions and desktop flavors in the Linux ecosystem. You have full control of system updates. You can choose which packages to be updated and you can do that at your preferred time.
Linux is more secure compared to Windows. Additionally can install a firewall or any other security-related solutions (Eg. UFW) to protect your linux operating system from malicious attacks.
Installing Windows on older hardware is practically not a preferred solution. However, there are lightweight Linux distributions that can be installed on older hardware and it will just work fine without any slowness or issues.
Linux stands as the preferred choice for mission-critical production workloads. Regardless of your job role, you'll encounter Linux servers, either physical or in the cloud. Gaining knowledge about Linux proves beneficial for both personal and professional purposes.
Backup your Important Data!
Before we dive into the step-by-step process of removing the Windows operating system from your dual-boot setup, you must back up your data. Though the Windows uninstallation process is simple, anything can happen and you might end up losing your important data.
So. it is very important to copy your personal files from both Windows & Linux operating systems to any cloud storage or external hard drive.
You can also use the "Timeshift" backup application to save a copy of your Linux system. This way, if anything unexpected happens, you can easily restore your Linux operating system.
Timeshift is an excellent system-level backup utility for Linux. We have a detailed article about Timeshift Backup application installation and usage in Linux and highly recommend you to use Timeshift to take a snapshot of your Linux system before moving to the next step.
My Demo Setup
I will use Windows 11 and Zorion OS dual boot setup for demonstration. The procedure will be the same for any system that uses EFI and GPT scheme.
I will be using the Gparted disk utility to remove Windows partitions. If your Linux operating system has no Gparted utility, you can install it by running any one of the following relevant command.
Debian/Ubuntu and its derivatives:
$ sudo apt update $ sudo apt install -y gparted
Arch Linux and its variants:
$ sudo pacman -S gparted
RHEL and its derivative operating systems:
$ sudo dnf install gparted -y
Steps to Safely Remove Windows from a Dual Boot System
Step 1: Boot into Linux
Turn on your computer, and you will see the GRUB boot loader screen. Here, you can choose between the Windows and Linux operating systems. By default, the Linux operating system will be selected, so go ahead and boot into it.
Step 2: Remove Windows Partitions
Open the Gparted utility. The utility will show you the disk layout, file system type, mount points, and used/unused size, etc.
Here our focus is to delete the Windows partitions. Look out for partitions with FAT32 and NTFS as the file system type.
The following image shows my file system layout. I have four Windows partitions as listed below.
/dev/sda1- Boot Partition
/dev/sda2- Microsoft Reserved Partition
/dev/sda3- C Drive
/dev/sda4- Hidden Partition
Here I will remove all the partitions except the boot partition.
To delete a Windows partition, right-click on the partition and click "Delete".
Repeat the same step for deleting all the Windows partitions except the boot partition. I repeat do not delete Boot partition.
The GParted utility will keep a record of the delete operation but won't apply it to the disk just yet. You should notice a pending operation message at the bottom of the GParted utility.
To proceed with partition deletion and write the changes to the disk, click the "tick" icon from the menu bar.
You will be prompted with a confirmation message to apply the changes. Click "Apply".
Once the change is applied, a completion window will appear. Additionally, you can verify for any pending operations at the bottom of the GParted window.
Now you will have some unallocated space that can be used to expand existing linux partitions or create new linux partitions.
Step 3: Resize or Create New Linux Partitions
To create a new partition from the unallocated space, right-click on "unallocated partition" and click "New".
A window will pop up, asking you to input partition details such as size and file system type. You can enter the size in MiB or use the slider to adjust it. Once you've entered all the required information, click on "Add."
If you wish to resize an existing partition, right-click on the existing partition and click "Resize/Move" option.
After clicking on the partition you wish to resize, a window will appear, asking you to enter the desired size in MiB. Once you've entered the size, click on "Resize/Move" to proceed with the operation.
To make the changes take effect, simply click on the "Tick" icon located in the menu bar. This action will write the pending changes to the disk and apply your modifications successfully.
Step 4: Delete Microsoft Boot Loader Entry
Reboot the machine. You will still see the Windows boot loader entry in the GRUB menu. If you try to enter into Windows, you will encounter with the following error message.
The reason for this is that we haven't removed the Microsoft boot loader entry, which resides in the
/dev/sda1 partition. To resolve this, manual cleaning is required.
Make sure you logged in to your Linux OS. Open the Terminal and execute the os-prober command to scan for available operating systems. As shown in the image below, the Windows boot loader is detected during this process.
All the boot files are saved under
/boot/efi/UEFI. You can verify it using
Navigate to the
/boot/efi/EFI/ directory using the command:
$ cd /boot/efi/EFI/
Then, delete the "Microsoft" directory along with all Windows-related files by executing the following command:
$ rm -rf Microsoft/
It's essential to double-check the path before deleting it to avoid any accidental deletions.
Step 5 - Update GRUB Bootloader
Execute the following command to reload the GRUB configurations, which internally utilizes the
os-prober command to detect operating systems:
$ sudo update-grub
Alternatively, if you are the
root user, you can use:
By running this command, the GRUB bootloader will be updated with the latest configurations.
From the image below, you can see that no entries for the Windows operating system are found, indicating that it has been successfully removed from the boot menu.
After completing the process, simply reboot your machine. Upon restart, you will no longer see the Windows boot loader entry in the GRUB boot menu. The Windows operating system has been successfully removed from the boot menu.
Frequently Asked Questions (FAQ)
A: Yes, you can safely remove Windows without losing your Linux data by following the proper procedures as described in this guide and ensuring you have backups in place. Be cautious during the partition resizing and deletion steps to avoid any accidental data loss.
A: Yes, you will need tools like GParted for partition management and Timeshift for creating backups. These tools will help you resize partitions, delete Windows-related files, and safeguard your Linux system during the process.
A: If you make backups using Timeshift before proceeding with the removal, you can easily revert to the previous state if you decide to re-establish the dual boot setup later on. The backups will allow you to restore your system to its earlier configuration.
A: Yes, removing Windows will impact the GRUB boot menu. After deleting Windows-related files and updating GRUB configurations, the Windows boot loader entry will no longer appear in the GRUB menu, leaving Linux as the sole operating system option.
A: There is a risk involved in any system operation that modifies partitions and boot configurations. It is important to follow the steps carefully and double-check before executing any commands to avoid unintended consequences. Creating backups using Timeshift provides an added layer of safety.
A: No. After removing Windows from the dual boot setup, the Windows partitions will be deleted, and you won't be able to access those files directly from Linux. If you need to access specific Windows files, it's best to back them up before starting the removal process.
A: Yes, removing Windows from the dual boot setup can potentially improve system performance, as it allows Linux to utilize the entire resources of the system without sharing them with another operating system. This could lead to faster boot times and smoother overall performance.
A: Yes, you can reinstall Windows on the same machine after removing it from the dual boot setup. You would need to allocate space for a new Windows partition, perform the installation, and update the GRUB configurations to add Windows back to the boot menu alongside Linux. Please check our "Dual Boot" category for setting up Dual boot with various Linux distributions.
A: Removing Windows from a dual boot setup requires some technical knowledge and understanding of partition management. If you are new to Linux, it is recommended to proceed with caution and seek guidance from experienced users or tutorials to ensure a smooth process and avoid potential issues.
This article has guided you through a detailed, step-by-step process to safely remove Windows from your dual-boot configuration, leaving Linux as the sole operating system on your machine.
Congratulations on successfully uninstalling Windows from your dual boot system! You can now enjoy the full benefits of Linux without any of the hassle of dual booting.
Once you remove Windows, you'll free up a significant amount of disk space. This space can be used to store your Linux files, or you can use it to install other operating systems.
We would love to hear about your experience and any challenges you encountered during the removal process. Please feel free to share your feedback and insights in the comment box below.