

- #Install ubuntu on windows 10 install
- #Install ubuntu on windows 10 full
- #Install ubuntu on windows 10 windows 10
- #Install ubuntu on windows 10 code
(Optional) Type the following command to install Ubuntu if you already have WSL installed, and press Enter: wsl -install -d Ubuntu
#Install ubuntu on windows 10 windows 10
Type the following command to install the WSL and Ubuntu Linux on Windows 10 and press Enter: wsl -install Search for Command Prompt, right-click the top result, and select the Run as administrator option. To install Ubuntu on Windows 10, use these steps: Install Ubuntu on Windows 10 from Microsoft Store.This guide will teach you the steps to install Ubuntu on Windows 10. However, for this to happen, the company has partnered with the guys behind Ubuntu Linux (Canonical) to expand the command line toolset on Windows 10.Īlthough Linux integration into Windows 10 is not included by default, installing Linux distros is not difficult once you set up the Windows Subsystem for Linux 2 (WSL2) platform on your device.
#Install ubuntu on windows 10 code
Microsoft is moving to get more developers to code on any platform but using Windows 10 as their main tool. You can install the Ubuntu distribution alongside Windows 10 to run your favorite Linux tools without switching computers or creating a virtual machine.

Or run the wsl -install -d UBUNTU-VERSION to install a specific version of Ubuntu.To install Ubuntu on Windows 10, open Command Prompt (admin) and run the wsl -install command to install the latest version.The file likely doesn't exist at first installation, so let's get it set up, and for this you'll want to stay logged in as root and not your user account. Open up Ubuntu 21.10 and navigate to the file as below. There are a few different ways you can handle this, but the easiest, and largely safest, is to edit the wsl.conf file on the distro to tell WSL to log you in as your user account instead of root. Configuring the default user for a distro installed in this way is a little different to those that have an executable downloaded from the Store. While not a long process to switch to or enter your new installation as your user instead of root, automating the process is always better. To launch into Ubuntu 21.10 as your new user, from PowerShell enter: wsl -d -u So you'll want to create one and add it to the sudo group: adduser usermod -aG sudo As such you won't have a user set up, there will only be root. Basic setup of Ubuntu 21.10Īs you've basically sideloaded Ubuntu 21.10, it doesn't run through the initial setup process you get when you install Ubuntu from the Microsoft Store. If you use Windows Terminal, however, and you really should, WSL will automatically add it to the dropdown menu with all the other shells you can open. You'll need to launch it manually with: wsl -d As this hasn't been installed from the Microsoft Store, there is no app shortcut created in the Start Menu. It'll take a minute, but once it's finished you can move on to setting up.


Simply add a 1 or a 2 after the flag to specify which version you require. It will install to whichever version of WSL your system recognizes as default, but you can alter that at installation to save the need to convert it later on. It doesn't really matter where you unpack and install the image, but it doesn't hurt to create a dedicated directory, especially if you plan on installing multiple distros in this fashion.Īdditionally, you can specify a version of WSL at the end with the -versionįlag. So, on my system, it looks like this: wsl -import Ubuntu-2110 c:/WSL/Ubuntu-2110 c:/Downloads/ Inside PowerShell, you will need to enter the following command to import and install Ubuntu 21.10: wsl -import
#Install ubuntu on windows 10 full
We have a full guide on exporting and importing Linux distros in WSL that can help, but we'll still cover everything you need here. The process of installation begins with importing the downloaded image from Ubuntu into your WSL setup. Take a note of where you've downloaded the tar file from the steps above to as you'll need the file location as part of the install process. Source: Windows Central (Image credit: Source: Windows Central)įrom here on out you're going to be in your PowerShell terminal.
