- How to create a Linux virtual machine on Windows 10 using Hyper-V
- Guide requirements
- How to enable Hyper-V on Windows 10
- Verifying Hyper-V support
- Enabling Hyper-V
- How to create a virtual machine using Hyper-V
- Creating a virtual switch
- Creating a virtual machine
- How to install Ubuntu Linux using Hyper-V on Windows 10
- More Windows 10 resources
- Halo: MCC’s live service elements make it better, not worse
- Microsoft’s Surface Duo is not ‘failing up’
- Here’s what you can do if Windows 10 update KB5001330 is causing issues
- These are the best PC sticks when you’re on the move
- Using a Virtual Machine to Run Linux on Windows
How to create a Linux virtual machine on Windows 10 using Hyper-V
Although it’s now possible to run a number of Linux distros natively on Windows 10, these environments can be somewhat limited in features and tools you can use. Also, you can only pick from three distros, including Ubuntu, SUSE Linux Enterprise, and OpenSUSE Leap, and you’re stuck with the command-line interface, which means that you can’t run any of the graphical experiences (e.g., GNOME, KDE, XFCE) or Linux-based graphical applications.
Of course, you can always install your favorite Linux distro on a second machine, but if you don’t have one, it’s still possible to run a full-blown version of Linux using a virtual machine (VM).
If you’re running Windows 10, you can enable Hyper-V on your device to create a VM to install your preferred distro whether you’re a developer or an enthusiast who just wants to know what’s the Linux fuzz all about.
In this Windows 10 guide, we’ll walk you through the steps to install most Linux distributions on virtual machines using Microsoft’s Hyper-V virtualization feature.
Guide requirements
To run a Linux virtual machine on Windows 10, you’ll need the following:
- A computer with support for Hyper-V.
- An ISO file to install your preferred Linux distribution.
In this guide, we’ll be using Ubuntu version 17.10, which you can download from the official Ubuntu website. However, it’s possible to install version 16.04, which might be a more stable version of the open source project, and you can also install other distros, including:
- CentOS and Red Hat Enterprise Linux.
- Debian.
- SUSE.
- Oracle Linux.
- FreeBSD.
How to enable Hyper-V on Windows 10
Hyper-V is a virtualization technology from Microsoft available on Windows 10 Pro, Enterprise, and Education, and it allows you to create one or multiple virtual machines to install and run different OSes on the same physical hardware.
Verifying Hyper-V support
Although Hyper-V is part of Windows 10, there is a minimum hardware requirement a computer must meet to enable the feature.
- 64-bit CPU with Second Level Address Translation (SLAT).
- Processor must support VM Monitor Mode Extension (VT-c on Intel chips).
- 4GB of memory at a minimum.
In addition, you have to make sure the Virtualization Technology and Hardware Enforced Data Execution Prevention options are enabled on your system BIOS.
You can quickly verify your computer has the required support for Hyper-V using Systeminfo:
- Open Start.
- Search for Command Prompt and click the top result.
Type the following command and press Enter:
Under Hyper-V Requirements, if the result reads Yes, then you can run Hyper-V.
If the command displays No under Hyper-V Requirements, then your hardware doesn’t support this feature, or you need to make sure to enable it manually.
Enabling Hyper-V
Use the following steps to enable Hyper-V on Windows 10:
- Open Control Panel.
- Click on Programs.
Click on Turn Windows features on or off.
Click OK to begin the process.
After the installation completes, click Restart now to apply the changes.
How to create a virtual machine using Hyper-V
Once you’ve completed adding the virtualization layer to Windows 10, you’ll need to create a virtual machine for the Linux distribution you want to use.
However, before you do that, you must create a virtual switch to allow the VM to connect to the internet.
Creating a virtual switch
Use the following steps to configure a virtual switch on Hyper-V:
- Open Start.
- Search for Hyper-V Manager and click the top result.
- Click on the Action menu.
Select New and click on Virtual Switch Manager.
Click the Create Virtual Switch button.
Click OK.
Creating a virtual machine
After creating the virtual switch, you can proceed to create a new virtual machine:
- Open Start.
- Search for Hyper-V Manager and click the top result.
- Click on the Action menu.
Select New and click on Virtual Machine.
Enter a descriptive name for your virtual machine (e.g., vm-ubuntu).
Click Next.
Select the amount of RAM to allocate for your virtual machine. In the case of Ubuntu, you need a minimum of 2GB of memory.
You can allocate as much memory as you want, but this setting will always depend on the physical memory available on your computer.
Click Next.
Click Next.
Click Next to continue.
Click Next.
How to install Ubuntu Linux using Hyper-V on Windows 10
The last step is to start the virtual machine and install the Linux distribution you want to use.
On Hyper-V Manager, under Virtual Machine, right-click the newly created device, and select Connect.
Click the Start (power) button.
Click the Install Ubuntu button.
Click Continue.
Click Continue.
Double-click the /dev/sda drive.
Double-click free space.
Click OK.
Double-click free space again.
Click OK.
Click the Install Now button.
Click Continue.
Click Continue.
Click Continue.
Restart the virtual machine to finish the setup.
Quick Tip: If during the final restart process, you get a message to remove the installation and press Enter, but hitting the key won’t restart the VM, just click the Turn off button and then turn it back on again.
After completing the steps, you can just turn on the VM and start using Ubuntu Linux alongside Windows 10.
While we’re focusing this guide setting up Ubuntu, you can also refer to these instructions to run other distributions of Linux.
More Windows 10 resources
For more helpful articles, coverage, and answers to common questions about Windows 10, visit the following resources:
Halo: MCC’s live service elements make it better, not worse
Halo: The Master Chief Collection is more popular than ever, but some fans don’t agree with the live service approach 343 Industries has taken with it. Here’s why those elements are, at the end of the day, great for the game and for Halo overall.
Microsoft’s Surface Duo is not ‘failing up’
Microsoft announced this week that it was expanding Surface Duo availability to nine new commercial markets. While Surface Duo is undoubtedly a work in progress, this is not a sign of a disaster. It’s also doesn’t mean that Surface Duo is selling a ton either. Instead, the reason for the expansion is a lot more straightforward.
Here’s what you can do if Windows 10 update KB5001330 is causing issues
In this guide, we’ll show you the steps to get rid of the update KB5001330 to fix profile, gaming, and BSoD problems with the Windows 10 October 2020 Update and May 2020 Update.
These are the best PC sticks when you’re on the move
Instant computer — just add a screen. That’s the general idea behind the ultra-portable PC, but it can be hard to know which one you want. Relax, we have you covered!
Using a Virtual Machine to Run Linux on Windows
If you would like to run Linux on Windows and have never used a virtual machine, this tutorial explains how you can do so in a few simple steps.
Linux and Windows are two of the most popular operating systems in the market. One can say that these two OSs have become essentials because of their continuous development and feature enhancements. Many people prefer one over the other. Yet, people who use Linux sometimes need the Windows operating system, and vice versa. For faster development and more security, people prefer to use Linux over Windows. So these people need Linux alongside Windows.
A common solution for this problem is to use a dual boot, which basically installs the entire operating system. However, due to boot loader changes (like UEFI mode), configuring dual boot becomes difficult.
This article is about running Linux on Windows, without using the dual boot technique. There are different ways to do so, one of the most popular being using a virtual machine.
Virtual machines
Virtualisation is fairly old technology now. It was started around 1980 by IBM. So, currently, this technology is pretty stable. We can create Linux virtual machines in Windows using software like Virtual Box, VMware Player, and VMware Workstation.
Figure 1: Virtual machine home
Figure 2: Creating a virtual machine
Figure 3: Assigning RAM
A virtual machine provides the same functionality as a physical computer, but it is an emulation of a physical computer. The virtual machine can be created or destroyed at any moment and it will not impact the actual operating system, which is the best part about using it.
To install Linux on Windows, we just require two things — the software to create a virtual machine which is Virtual Box (free software) and an ISO file of the operating system.
The installation process is pretty simple, like installing any software in Windows. The steps for installing Ubuntu (a favourite Linux flavour) inside Windows are given below.
The first step is to enable virtualisation technology in the BIOS. If you have already enabled it, you can skip this step.
You need to power on the system and go to the BIOS setup by pressing F2, Del or the Enter key, depending upon your computer model.
After that, under CPU Configuration -> System Configuration -> Advanced or Security Tab, we need to find Virtualization Technology or Intel Virtualization Technology. If the option is disabled, then it must be enabled. If it’s already enabled, skip this step.
If you get any of the following error messages at any point of time, it means that virtualisation technology is not enabled for you and you need to enable it:
- VT-x/AMD-V hardware acceleration is not available on your system
- This host supports Intel VT-x, but Intel VT-x is disabled
- The processor on this computer is not compatible with Hyper-V
If you have not installed Virtual Box, then you can go to the links https://www.virtualbox.org/wiki/Downloads and http://download.virtualbox.org/virtualbox/5.1.28/VirtualBox-5.1.28-117968-Win.exe, and download and install it. The steps are very straightforward; hence, I am not mentioning them here.
Figure 4: Select virtual hard disk
Figure 5: Select virtual hard disk type
Figure 6: Disk space
Open the Virtual Box application once it is installed. It will look like what’s shown in the snapshot in Figure 1.
Click on the New button and select the OS category before providing the appropriate name to the virtual machine.
Assign RAM as per your requirements. Ubuntu can run on 512MB, which is the minimum requirement to run Linux smoothly on Windows. Since I have 8GB RAM in my laptop, I have chosen 2048MB (2GB) RAM.
The next option is to select the virtual hard disk. Since we are creating a new virtual machine, we will use the ‘Create virtual hard disk now’ option.
Here we need to select the virtual hard disk type. Since we are using Virtual Box, we will use VDI which is a Virtual Box disk image.
There are two options here — we can either use a fixed size or a dynamic size. It is better to opt for the latter so that the size can be increased if required.
Allocate the disk space as per your requirement.
Once it is done, go to the virtual machine that you have created, right-click on it and go to the settings of that machine. Now we must attach the ISO file so that while we run the VM, it should know the location of the Ubuntu ISO file. As shown in the snapshot (Figure 7), click on the DISK button and browse the .ISO file of Ubuntu OS. The ISO file is now attached.
Figure 7: Selecting the ISO file
Figure 8: Installation started
Figure 9: Install Ubuntu like any normal OS
Next, go to the virtual machine, right-click on it and start it.
You will get the Ubuntu installation screen, which is similar to installing any operating system that you have chosen. The remaining steps are similar to the installation of any OS.
If you want to close the virtual machine window, you can do one of three things.
1. Save the machine: This is like hibernate. The system will resume from wherever you left off, the next time when you start — it will show you the same task at which you paused.
2. Send the ‘Shutdown’ signal: This is like pressing the power button. It will allow normal shutdown of the virtual machine.
3. Power off the machine: This is like pulling a power cable. It is for a hard shutdown which is required in scenarios where a VM gets hung or is not working properly.
At any time, if you want to destroy the virtual machine you created, right-click and select the Remove option. This will remove all the related files.
In this article, we have seen the basic operations of a virtual machine. We can explore other options in a subsequent one.