Remote X session via SSH

c0rrupt

Weaksauce
Joined
Jun 25, 2004
Messages
102
Can someone tell me how to get this running, since I can't find any resoulution for this error. I log onto my Linux machine as root via SSH w/ PuTTY in Windows and type startx. I keep getting an error about a mouse not being found. I don't have a mouse connected to this machine since it is intended to be headless and all work done on it will be done over SSH (it is a router). What is going on here?
 
So you're trying to get the X session from your Linux box to show up on your Windows box? You won't be able to do that with just PuTTY...Maybe I don't understand what you're trying to accomplish. PuTTY is just a terminal emulator, not an X server.
 
What you want to do is
1) Get an X server for windows. (Cygwin is the most common solution)
2) Set it up, start it
3) Set up X-forwarding in putty (there's a checkbox somewhere)
4) When you're connected, start some program. (kicker is a good choice if you're a KDE guy).

When you run startx, it tries to start an X-server on the remote computer. Since you don't want to display anything there, that's meaningless.
 
If it's a router, why do you need X? As far as software goes, you just need an x server for windows. There are plenty out there, some free and some not.
 
Here is a probably more useful solution:

1) Download cygwin. Keep all the defaults, except choose "full" or "install" for the x windows stuff
2) Make sure that in your ssh DAEMON (ssh listening program on the server) that x forwarding is enabled. Depending on your OS this may not be the case.
3) if it wasn't enabled, make sure you kill -HUP the sshd process to re-read the config file
4) Open a cygwin window and type "startx". This should start the x server
5) ssh into your machine that has the x applications, after making sure x forwarding is turned on in putty
6) try "xeyes &" and see if this opens up xeyes on your windows machine. If everything is setup correctly, it should.

- Rob
 
Back
Top