unable open xterm
Eirik Byrkjeflot Anonsen
eirik at opera.com
Tue May 10 10:13:42 PDT 2011
Usuário do Sistema <maiconlp at ig.com.br> writes:
> yes! I'm trying open a window xterm from ssh connection.
> how I'm doing:
> from my windows machine ( with Win 7 ) I conneted to my X Server
> machine by Puty.
> there I run the xterm command.
> the X server Machine hasn't a monitor!
> the daemon xfs it's up
> but the problem still occur:
> -bash-3.2# echo $DISPLAY
> -bash-3.2# xterm
> Warning: This program is an suid-root program or is being run by the root user.
> The full text of the error or warning message cannot be safely formatted
> in this environment. You may get a more descriptive message by running the
> program as a non-root user or by removing the suid bit on the executable.
> xterm Xt error: Can't open display: %s
If you want to see the xterm window on your windows machine, you'll
1. Run an X server on your windows machine.
2. Configure PuTTY to use X11 forwarding.
3. Ensure ssh on the linux machine allows X forwarding.
1. There seems to be several X servers that can run on windows,
e.g. XMing (http://www.straightrunning.com/XmingNotes/) or XWin32
(http://www.starnet.com/products/xwin32/). I haven't tried any of them,
as I don't run windows myself. On the other hand, if this used to work
for you (and you haven't reinstalled windows or otherwise uninstalled
the X server on your windows machine), you should already have it.
2. The first hit on google says that PuTTY has a setting
Connections->SSH->Tunnels->X11 forwarding. You'll need to make sure
this one is turned on.
3. On the linux machine, you may need to do something to
/etc/sshd/sshd_config. You probably need to make sure a line like this
is in sshd_config:
If you've got all that right, you should not need to set DISPLAY on the
linux machine. It should be set automatically by ssh. If your
sshd_config does not specify otherwise, you will most likely have a
DISPLAY value of ":10.0" (NOT ":0.0"). See "man sshd_config" (on the
linux machine) for details (X11DisplayOffset, in particular).
More information about the xorg