#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    May 2004
    Posts
    21
    Rep Power
    0

    connect by ssh to another computer


    Hello,

    I need some help on this little problem of mine... On the network i'm working on I have to connect by ssh to other nodes.
    I want to call a C program with python with the os.system(command) function, but the computer I use to launch all my python scripts doesn't have the good processor architecture to launch this particular C program (and I cannot compile it for this processor since the source codes are corupted).
    I would like to log on to another computer on the network and use the C program, and then logout again once the calculating is done...

    Do you see a way to do that?

    Little precision: I don't need a password for the ssh command on this network.
    Little precision number 2: python is not installed in the same directory in the other computers of the nework...
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2003
    Posts
    133
    Rep Power
    12
    You might want more help than this but take a look at Paramiko. Paramiko is a set of Python modules for enabling ssh connectivity. Look for instance at the included demo.py script. It's the same thing as setting up a remote shell with the ssh client.

IMN logo majestic logo threadwatch logo seochat tools logo