How to install Ubuntu 22.04 alongside Windows 10

If you want to run Ubuntu 22.04 Jammy Jellyfish on your system but you already have Windows 10 installed and do not want to give it up completely, you have a couple of options.

One option is to run Ubuntu 22.04 inside of a virtual machine on Windows 10, and the other option is to create a dual boot system. Both options have their pros and cons. A big advantage of a dual boot system is that both operating systems will have direct access to your computer’s hardware – no virtualized hardware and unnecessary overhead.

A dual boot system gives you the best of both worlds. It works by prompting you at startup to select which operating system you would like to load into. So, you will have to reboot your computer each time you want to load into a different operating system. Make sure you consider this before deciding to proceed with the dual boot option. Ready to get Ubuntu 22.04 installed alongside Windows 10? Read on below as we take you through all the steps.

In this tutorial you will learn:

  • How to install Ubuntu 22.04 alongside Windows 10
  • How to load into Ubuntu 22.04 or Windows 10 at system boot
Selecting Ubuntu or Windows at system boot
Selecting Ubuntu or Windows at system boot
Software Requirements and Linux Command Line Conventions
Category Requirements, Conventions or Software Version Used
System Ubuntu 22.04 Jammy Jellyfish and Windows 10
Software N/A
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

Installing Ubuntu



Twitter icon Follow LinuxConfig.org on Twitter for the latest tips and tricks about Linux!


In this guide, we’re assuming that you already have a fully functional Windows 10 system. Before we begin, you will need to download Ubuntu 22.04 installation media. Next, turn off your computer and boot to the installation media – whether it be a flash drive, CD, or whatever. Note that you may have to press a certain key (sometimes F11 or F12, but it varies by manufacturer) in order to load into the boot menu and select your installation media.

  1. After booting into the Ubuntu installation, you will be presented with the traditional prompts. On the first one, select “Install Ubuntu.”
    Install Ubuntu
    Install Ubuntu
  2. Select your keyboard layout and click continue.
    Selecting keyboard layout
    Selecting keyboard layout
  3. The “Updates and other software” options are up to you. Usually, though, you will want a normal installation along with the updates and third-party software. Those options save you time and hassle later on.
    Updates and other software
    Updates and other software
  4. This is the part that makes installation alongside Windows 10 different from a normal installation. The Ubuntu installer automatically detects that we have a pre-existing Windows 10 installation on our system, so there’s really nothing fancy we need to do here, except make sure the “Install Ubuntu alongside Windows 10” option is selected before clicking on continue.
    Is the “Install Ubuntu alongside Windows 10” option missing?

    Please note that in the following circumstances the Ubuntu 22.04 installation option “Install Ubuntu alongside Windows 10” may be missing, if your Windows 10 installation: is not correctly shutdown or is hibernating, has corrupted partition which needs repair, partition has not enough free disk space left for resizing, uses Dynamic Disk or the file system contains uncontrollable file fragmentation

    Install Ubuntu alongside Windows 10
    Install Ubuntu alongside Windows 10
  5. Next, you get to decide which hard drive you would like to install Ubuntu to. If you choose to install it to the same drive as Windows 10, Ubuntu will allow you to shrink that pre-existing Windows partition and make room for the new operating system. Alternatively, if you have multiple hard drives, you can choose to keep the two installations completely separate and select a different drive for Ubuntu at the top of the window.




    You should try to allocate a minimum of 10 GB to your Ubuntu install. You can drag the divider left and right to choose how you want to divide your hard drive space between the two operating systems. Notice the Windows installation is formatted with NTFS and the Ubuntu installation with ext4. Click “install now” when you feel good about your space allocation.

    Selecting partition sizes
    Selecting partition sizes
  6. Ubuntu warns us that it is going to make some irreversible changes to our hard drive in the form of resizing the pre-existing partition for Windows 10.
    Confirm writing changes to disk
    Confirm writing changes to disk
  7. Another warning about the changes about to be made. Click continue once more.
    Confirm the changes once more
    Confirm the changes once more
  8. The next couple prompts will ask some general questions about your timezone and a username and password. Fill all this out and be prepared to wait a little while as the installer resizes the hard drive partitions and installs Ubuntu.
    Ubuntu begins to install alongside Windows 10
    Ubuntu begins to install alongside Windows 10
  9. When it is finished installing, you will be asked to reboot the system. Then, you will load into Ubuntu 22.04 automatically.
  10. There is one more thing we need to do in order to have the ability to select which operating system we want to use at system startup. Once Ubuntu is booted, open a command line terminal and execute the following commands to add Windows 10 to your GRUB boot menu:
    $ sudo echo "GRUB_DISABLE_OS_PROBER=false" >> /etc/default/grub
    $ sudo update-grub
    

    Grub 2.06 won’t automatically probe for other OS installations and add them to the boot menu, but adding the aforementioned line to the /etc/default/grub file will fix the issue.



Booting into Ubuntu 22.04 or Windows 10

From now on, when you start your system, the GRUB loader will ask you which operating system you want to load into. Use your arrow keys to scroll up and down, and press enter to choose an option. After making your selection, the chosen operating system should load as normal.

GRUB boot loader
GRUB boot loader

If you do not select anything within a few seconds, Ubuntu will load by default.

Loading into Ubuntu 22.04
Loading into Ubuntu 22.04

Closing Thoughts

In this guide, we took you through the step by step instructions that you can follow to get Ubuntu 22.04 installed alongside Windows 10. Creating a dual boot system is a viable solution for users that wish to leverage the best of both worlds by having Ubuntu and Windows installed simultaneously. While not as flexible as virtualization, it offers some advantage by allowing both operating systems to have direct access to your system’s hardware.