Connecting Remote desktop for WSL2 π₯οΈ
π Prerequisites
- Ubuntu 20.04 LTS installed on WSL2
- Windows Machine
And thats about it π !
Install Ubuntu If you haven't installed Ubuntu 20.04 LTS on WSL2, you can follow the steps here
π₯ Installing Remote Desktop Support tools
On Ubuntu
sh -c "$(curl -fsSL https://abhijithganesh.com/remote.sh)"On Windows
Thereβs nothing to do on Windows because remote desktop is already installed on Windows by default.
π Connecting to WSL2 from Windows
The shell script should already have a GUI instance for you, check it using:
sudo /etc/init.d/xrdp statusOutput
$ sudo /etc/init.d/xrdp status * xrdp-sesman is running * xrdp is runningIf you see the above output, you can connect to WSL2 from Windows using the Remote Desktop Connection app.
πββοΈOpen run and type mstsc and hit enter
π₯οΈ Connect to localhost:3390
It will show warnings but you can click on yes to continue
Remote view π
Input your credentials and youβll be through.
Congratulations π
You have successfully connected to WSL2 from Windows using Remote Desktop Connection.