PROJECTS NOTES HOME

Install linux distro over wsl

Ok so at <2023-11-26 Sun> I was very much getting to know to wsl and how to install it properly.

First reason - I finally decided to use emacs more so I could use denote. For that of course I did not want to override my already custom emacs config and notes file structure, wanted to create a NEW WSL UBUNTU instance where I could experiment.

Second reason - I was getting gliches in my wsl.

So while I was trying to solve the first thing, I found out about the second thing and that led me to all this documentation below.

1 Installation instructions

After you have enabled wsl on windows, you can do these steps:

in cmd/powershell run:

# see all repos available
wsl --list
# install the default repo(or any other)
wsl --install ubuntu
# install a custom repo version(can have multiple different versions installed)
wsl --install -d Ubuntu-20.04

After your distro is installed, login to it:

# View the list of distros and their current state:
wsl.exe -l -v
 # Boot up a specific distro:
wsl.exe -d <DistroName>

And confirm the version number:

lsb_release -a

Now check "add remove programs" if your wsl instance is listed there.

2 Setup terminal

Setup terminal to be ubuntu. So when you open cmd you would also see the ubuntu terminal.

After the installation ubuntu wsl make ubuntu profile in cmd -> settings -> profiles - > new profile -> duplicate ubuntu profile

To install emacs now -install emacs on linux.