error: cannot open display
Hi, i have the same problem, i can't open gedit.
I connect to CentOS server with Putty with enabled X11 forwarding. I tried to use Cygwin X or Xming, didn't help. In Putty i do: - export DISPLAY='IP of local station:0.0' - xhost+ But after that - error: cannot open display. I installed all X packages (xorg-x11-xauth, xorg-x11-fonts-*, xorg-x11-utilsxorg, etc). X11Forwarding options is 'Yes' in /etc/ssh/sshd_config on CentOS server. In /etc/hosts: 127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4 IP-address-of-server hostname What is wrong? Help pls. I looked in the Internet all advices to solve the issue, but nothing helped. |
Have you installed an X server on your Windows machine? Which one?
Disclamer: I've never understood how to connect a remote client to X on a server. (or why one would want to) Consider: Rather than using gedit, install WinSCP and SciTE on the Windows PC. WinSCP can open remote files into SciTE, which is an excellent text editor for scripting/programming. |
For remote management SSH and a text editor as VIM is all you ever need. Works reliably over thousands of miles, even if there is slow internet connection somewhere in the way.
|
gedit it is just example. i can't launch gui apps. Oracle DB doesn't launch too.
|
This is how it works. Your local box must accept incoming X connections, local X server must be listening on port 6000. The xhost command has to be run in local box, not remote. How it all works in Windows - I have no clue. I do not run Windows, never will.
|
On the local box I use multiple users and one X session. And this is my method of sorts.
$ startx -- :0 -dpi 100 -to 10 -nolisten tcp -retro -depth 24 -layout MultiHead $ xhost local: $ su - otheruser $ export DISPLAY=":0" $ xcalc I would imagine that the X on the server has something like "-nolisten tcp" which disables remote X services. Various Xephyr and Xdmx ways to get things going. Assuming linux to linux. Otherwise vnc, x2go, and other methods might prove simpler. If I'm fiddling with Xdmx or other things I drop the "-nolisten tcp" option so that ssh -X and stuff works. Not that I've done any remote X stuff in recent history. |
ssh -X works even if X server is not listening.
|
All times are GMT -5. The time now is 02:12 PM. |