In Windows
- Download the Image
Download an Ubuntu cloud image, such asnoble-server-cloudimg-amd64-root.tar.xz
, from Ubuntu Cloud Images. - Create a New WSL2 Image
Use WSL Manager to create a new WSL2 image from the downloaded.tar.xz
file. - Start the New WSL2 Image
Launch the newly created WSL2 instance.
Now Inside WSL
- Update Package Lists
apt update
- Install XFCE and XRDP
apt install xfce4 xrdp
- Set XFCE as the Default Session
echo xfce4-session > ~/.xsession
- Restart XRDP Service
service xrdp restart
- Install Additional Tools
apt install net-tools -y apt install dbus-x11 apt install libguestfs-tools
- Set a Root Password (Required for XRDP login)
passwd
- Get the IP Address
ifconfig | grep inet
Look for an entry likeinet 172.27.172.177
and copy the IP address. - Connect via Windows Remote Desktop
Use Windows Remote Desktop (RDP) to connect to the copied IP address and log in with your WSL2 credentials.
Now you have a fully functional Ubuntu environment with XFCE running on WSL2! 🚀
