[Tutor] ssh connection

शंतनू shantanoo at gmail.com
Tue Dec 18 10:26:28 CET 2012


On 18/12/12 7:51 PM, Alan Gauld wrote:
> On 18/12/12 08:03, Ufuk Eskici wrote:
>> I have Putty and I it runs from CMD successfully.
>>
>> *C:\Users\eufuesk>*"c:\Program Files\Putty\putty.exe" -ssh
>> [username]@10.0.0.1 <http://10.0.0.1>
>>   -pw [password]
>>
>> But I dont know how to send this command from Pyhton. :(
>
> Have you read the subprocess module documentation?
> It provides many examples of running commands.
>
> The raw Popen class can be a bit intimidating but there are wrapper
> functions that make it easier for simple applications.
>

You may also like to have a look at 'commands' module, especially when
no user input is required.

-- 
शंतनू


More information about the Tutor mailing list