I am running windows 11 and have updated my ubuntu instalation to wsl2. whenever I try to run something like xclock the it looks like it is running in the command line but no gui opens up. I've tried this with a number of applications and none seem to work.
I've used everything in these guides:
31 Answer
I have a hunch on why it's not working, but we'll need some additional troubleshooting to see for sure.
I don't normally recommend "reinstall", but I'm going to offer a slight variation on that here to see if it helps.
Try the following:
- Exit WSL/Ubuntu
- From PowerShell or CMD, issue
wsl --shutdown - From the Microsoft Store, install "Ubuntu 20.04". This will install a second WSL instance (named "Ubuntu20.04") without modifying your existing installation. instance.
- Start Ubuntu 20.04
sudo apt update && sudo apt upgrade- Just install a simple app like
xtermand see if it launches
If it does, we can try to figure out why your default Ubuntu installation isn't worked and how to prevent it from happening again.
3