Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I have a micro Amazon instance the I want to use for testing and everything is going fine until the title. If I set up all the info in PuTTy, open it up and run 'xclock', all runs perfectly and it opens on Xming on my local desktop. If, however, I run

ssh xxxxxxx.amazonaws.com xclock

I get

Error: Can't open display:

If I run either of

ssh xxxxxxx.amazonaws.com -X DISPLAY=localhost:0:0 xclock
ssh xxxxxxx.amazonaws.com -Y DISPLAY=localhost:0:0 xclock

I get the same again, but just after about a 30 second delay.

In .ssh/config in Windows, I do have

ForwardX11 yes

set, and I really can't think of anything more to get this working. The fact that PuTTy is working perfectly, not no matter what I do on the command line, I get absolutely no joy is driving me crazy.

Can I even see the commands PuTTy is running somewhere, to see if it's doing some extra magic?

The ssh I'm running in Windows is MinGW32's.

share|improve this question

1 Answer 1

Have you tried

ssh -X username@hostname xclock

Normally, the DISPLAY on the remote machine is not 0:0, but will be set by ssh automatically.

Also, Putty has a command line mode too, all you have to do is to add it's directory to your path and you can do

plink -X username@hostname xclock
share|improve this answer
    
Also, use the -C flag to compress data on the connection. That might pick up the speed of the startup, and that might be part of PuTTy's "extra magic" (if any). –  pjmorse Sep 18 '12 at 23:48

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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