View Single Post

  #21  
Old 08-20-2008, 03:01 PM
Default Re: X applications fail to run on ssh -X

On 08/20/2008 07:20 PM, Frank Fegert wrote:
> On 2008-08-20, TsanChung wrote:
>> bash$ set|grep DISPLAY
>> bash$ xclock
>> Error: Can't open display:

>
> There's your problem. DISPLAY should be automatically set so some-
> thing like "localhost:$OFFSET.0" by SSHD. So either it doesn't get
> set in the first place (no xauth or no X11Forwarding) or it's reset
> by your environment. Check your .profile, .bashrc, etc. and make
> sure DISPLAY is not unset/overwritten.


It may also help to delete any existing $HOME/.Xauthority file you may
have. It will be recreated as soon as you log in using SSH if your setup
is proper.

Similar to the above tip for DISPLAY, you should check if the XAUTHORITY
or HOME environment variables are changed somewhere.

Also check your client SSH config (ssh_config). i.e. if
ForwardX11Trusted = no.

I have previously recommended that you should upgrade your SSH, for very
good reasons.

Here are the steps:
1. Download the SSHxxx.BFF file from the IBM website I previously posted
to a local directory i.e. /tmp/ssh
2. Run: cd /tmp/ssh; inutoc .
3. Run: smitty install_all -> use . for the directory -> press Esc and 4
to list the installable file-sets -> press Esc-7 to pick 'OpenSSH' and
press Enter until it installs.
4. Stop (kill) the current sshd. It might be a good idea to keep another
SSH session open just in case you run into any type of installation
problem, not that it's ever happened to me.
5. Run: startsrc -s sshd

If it still does not work, you need to post your ssh_config and
sshd_config files.

cheers
Niel



Reply With Quote