views:

212

answers:

2

I'm trying to start perfmon and another program that have GUI's through a python script that uses a PKA ssh connection. Is it possible to do this? If so could anyone point me in the right direction?

+1  A: 

If you mean this perfmon (the one that runs under Linux &c == I believe there's a honomym program that's Windows-only and would behave very differently), ssh -X or ssh -Y let you open an ssh connection which tunnels an X11 (GUI) connection (if server and client are both configured to allow that, of course).

Here are copious details of how to do it "the old way" (with -p etc); here, the explanation of -X and the more secure -Y modern options. As long as the app is running on a Linux box, you can have the display ("X Server") just about anywhere, with a proper ssh tunnel securely connecting them.

If it's Windows you're talking about (i.e. running the perfmon app on a Windows box, wherever it is you want the GUI), I don't know how to tunnel a GUI over ssh (it may not be possible). One possibility is VNC (there are several implementations of the protocol, both commercial and free) but I'm not all that experienced with it.

Alex Martelli
It is possible to run an X server on Windows and use it to run GUI apps from a Linux server that you've SSH'd into. But the other way around? I'm guessing not possible :-/
David Zaslavsky
Right @David, that's what I meant -- let me edit and clarify!
Alex Martelli
A: 

I've found a program called psexec that will open a program remotely on another windows machine. http://technet.microsoft.com/en-us/sysinternals/bb897553.aspx There are options or flags that you can use with this command line program to open a program with a GUI and view it on a remote machine.

cmmacphe