[x]
Posted via EE Mobile

Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again.

Question
[x]
Attachment Details

How to automate ssh login using putty?

Asked by nosremes in Automation, Bourne Shell (sh), Bourne-Again Shell (bash)

Tags: Putty Automation Script

Hi All,

I have something that I would like to automate but don't know how to start it.

I have a list of unix servers in a txt file. What I want is, I would like to create a script that will run putty to login to those servers inside the txt file and execute a sudo script like this ex. /var/testscripts/myscripts.pl then output it to a file if it is successful or not. The username and login can be declare on the script.

Or I would like to create a batch script that will call putty and automatically login to those servers inside the text file. Let say, the text file have 5 servers. The script will open up 5 putty session on those 5 different servers.

Appreciate any sample code related to my queries above. Thanks.
[+][-]03/11/09 02:13 PM, ID: 23862436Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]03/15/09 05:19 AM, ID: 23890785Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]03/26/09 12:05 AM, ID: 23987869Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/25/09 09:18 PM, ID: 25184408Administrative Comment

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 30-day free trial to view this Administrative Comment or ask the Experts your question.

 
[+][-]10/31/09 12:27 PM, ID: 25711159Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20091111-EE-VQP-92 - Hierarchy / EE_QW_3_20080625