-3

I just started experimenting with Linux, and wsl2 seems like a great option to do so, and still keep Windows 10.

I know for sure I can install programs (since I decided to test it with the Minecraft Linux launcher, and got no errors) But how can I display the window inside Windows?

So far I have received this error:

Gtk-WARNING **: 15:16:44.531: cannot open display:

I suppose that means that Windows currently "owns" the displays, and Linux would have to make some remote connection, in order to make it work.

I've found some instructions online (even on superuser), but I'm currently too big of a Linux noob to make it function.

Dave M
  • 13,250

1 Answers1

1

WSL2 comes with no gui installed, so it doesn't know how to create an output or display anything but the shell. What you need to do is install a desktop environment for Ubuntu and then connect to it via VcXsrv. Follow this tutorial.

https://medium.com/@japheth.yates/the-complete-wsl2-gui-setup-2582828f4577

Wouldn't advise trying to play games on wsl2 (you wont have a gpu)

MrCake
  • 21