I am connecting from Windows with Putty and XLaunch to a Debian machine version 7.6, I have tried it on other machines and it worked, the problem is the Debian machine itself, not the configuration. I have already tried this:

xhost localhost

The last command tells me that it is unable to open a display.

NOTE: I'm on a Windows system attempting to use XLaunch to remote display an X application from the Debian system, to Windows.

  • 1
    Open a shell on the Debian machine and issue the command echo $DISPLAY and report its output. – lord.garbage Oct 22 '14 at 12:04
  • This is the result :0.0DISPLAY=:0.0 – aDoN Oct 22 '14 at 12:05
  • 1
    First of all, where do you issue xhost localhost on the server or on you local machine. If the former try the latter. And if the latter: (Although you should not do this in terms of a long term soltion. And here only done for debugging purposes.) What happens, when you enter xhost + on your local machine thereby granting access to any user. – lord.garbage Oct 22 '14 at 12:11
  • 1
    What if you try set DISPLAY=put-in-you-ip-here and then export DISPLAY on the remote machine? That helped me with Putty. – lord.garbage Oct 22 '14 at 12:17
  • 2
    Do you want to display X11 applications on the Windows machine, or on the remote Debian machine? If you want to display things on Windows, do not set DISPLAY: if it isn't set, then forwarding is not in place and setting DISPLAY cannot help; the problem is probably in the PuTTY configuration. – Gilles 'SO- stop being evil' Oct 22 '14 at 16:45

Here is my configuration :


  • in first screen, there is a field called Display number, do not use 0, try 1756 (for instance), next
  • next (Start no client)
  • check 'no access control', next
  • done


  • in Connection -> SSH -> X11 :
    • enable X11 forwarding
    • X Display Location : put localhost:1756.0
  • connect, do not set DISPLAY in any .bashrc et all.

when connected launch any X client.

| improve this answer | |
  • Do you know what does the ".0" in localhost:1756.0" mean? – alpha_989 Nov 7 '17 at 15:43
  • Also how does the "no access control" help in setting up a reliable and repeatable connection with Xming? – alpha_989 Nov 7 '17 at 15:45
  • I always use 0, I guess .1, .2 are in case you have multiple screen. I use "no access control" because I was unable to set a proper access control. – Archemar Nov 7 '17 at 15:46
  • Thanks for the explanation.. when you mean multiple screens do you mean multiple screens on the server to which you are trying to login? – alpha_989 Nov 7 '17 at 17:22
  • For me, it turns out that using localhost:1757.0 (in putty) and 1756 (as Display Number in Xlaunch) works the same as using 0.0 (in putty) and 0 (as Display Number in Xlaunch). In either case when I login to the remote server "echo $DISPLAY" reads "localhost:10.0". – alpha_989 Nov 7 '17 at 17:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.