running SSH from a windows .bat file?

headstrong

Expert Member
Joined
May 10, 2006
Messages
1,099
Reaction score
0
Hi Guys

I want to initiate an SSH session to a remote machine and run a single command..

However, I want the whole process to be initiated from a single .bat file in windows.

How would I do this?

Thanks
 
thanks that looks exactly what I need...

what would be the easiest way to prevent the remote box from asking for a password...using saved session or a private key?
 
Well I will be using this only on an internal lan so I am not worried about security...Can I use the same saved putty session for multiple batch files with different commands?
 
I created a saved session by following this:
1. Click on the little computers in the title bar to bring up the menu.
2. Click "Change Settings". This will bring up the PuTTY Reconfiguration screen.
3. In the blank box under the words "Saved Settings", put a name for your session.
4. Click "Save".

However, it still asks for a username and password, how do I get those details stored in the saved session too?

thanks
 
Use putty, it will save the certification and the sessions for you!
 
Top
Sign up to the MyBroadband newsletter
X