Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I want to start a x-window application on a server named "server1". First I start X server, then on xterm I do:

$ssh -Y server1

shell says:

The authenticity of host 'server1 (10.11.93.232)' can't be established.
RSA key fingerprint is b6:6d:fe:dd:aa:f6:64:1c:1d:6d:66:61:fb:5b:eb:e1.

Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'server1,10.11.93.232' (RSA) to the list of known hosts.
user1@server1's password: 
[user1@server1 /users/user1]

then I run a sh script to start to x-window:

[user1@server1 /opt/app/soft/test]$bin/start.sh -t
Error opening display "servert9:0.0"

How can I start this application on server1? I think it directs the x-window application to servert9. I think I have to forward X, could you please help?

Best Regards

share|improve this question

Your X11-forwarding is fine. The problem is that your bin/start.sh script has a line somewhere that explicitly connects to servert9:0.0, ignoring any currently set $DISPLAY value.

Edit the script to honor whatever $DISPLAY is currently set; usually you'll need to remove all DISPLAY=... and export DISPLAY=... lines. If any programs are given the -display ... option, remove it as well.

share|improve this answer
    
I don't have any lines with DISPLAY in start.sh, when I do "echo $display" on xterm it says localhost:13.0 – alwbtc Oct 11 '11 at 18:02
    
@alwbtc: It's echo $DISPLAY in uppercase, and of course it will show the correct value on xterm -- it's only being overriden by this particular program you try to start. – grawity Oct 11 '11 at 18:54
    
But start.sh does not have a DISPLAY line, – alwbtc Oct 11 '11 at 19:03
    
@alwbtc, then grep the entire program directory for DISPLAY, -display, or servert9, until you find anything possibly related. – grawity Oct 12 '11 at 16:02
up vote 0 down vote accepted

I found the solution:

$export DISPLAY='my_pc_ip_address:0.0'

$cd bin

$./start.sh -t
share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .