X11 Forwarding works on Windows with Xming and Putty, but not with ssh command line

Posted by seaders on Server Fault See other posts from Server Fault or by seaders
Published on 2012-09-16T11:56:09Z Indexed on 2012/09/16 15:40 UTC
Read the original article Hit count: 360

Filed under:
|
|

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.

© Server Fault or respective owner

Related posts about ssh

Related posts about putty