wsld icon indicating copy to clipboard operation
wsld copied to clipboard

Connection refused while initiating application

Open ihtiuh opened this issue 3 years ago • 1 comments

Hi @nbdd0121, I am having issues with running Terminator GUI via WSL2 Ubuntu.

Here is my setup:

  1. Start VcXSrv on windows host with vcxsrv.exe :0 -ac -terminate -lesspointer -multiwindow -clipboard -wgl -dpi auto
  2. Start the wsldhost --daemon with in Windows CMD as admin, and verified that it is running on the port 6000
  3. Inside WSL via windows CMD export DISPLAY=:0 and start wsld process in background.
  4. But I can't get any response for xset q, it just waits.
  5. And also when initiating the application I get the following error:
C:\>wsl.exe bash -c "DISPLAY=:0 terminator"
Unable to init server: Could not connect: Connection refused
Unable to init server: Could not connect: Connection refused
You need to run terminator in an X environment. Make sure $DISPLAY is properly set

I can see the correct PID in /tmp/.X0-lock for the wsld process I started. And the /tmp/.X11-unix/X0 also have correct permissions(777):

Thanks!

ihtiuh avatar Sep 17 '22 10:09 ihtiuh

I have no immediate clue of what's wrong there. Maybe try deleting files in /tmp and try again as WSL doesn't clean up the temporary files automatically.

nbdd0121 avatar Sep 26 '22 17:09 nbdd0121