How do you guys run scripts against ALL your servers ?


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting How do you guys run scripts against ALL your servers ?
# 1  
Old 12-14-2009
How do you guys run scripts against ALL your servers ?

I have 2000 odd servers (may of which are virtualisations) and if we want to run a script against all of them or distribute files/install software to all of them, we currently perform a simple for loop against a managed list of our servers called SLIST

Code:
for host in `cat SLIST` ; do
   ssh $host 'run command'
   scp some-files $host/opt/
done

obviously there are some additional checks in there as well, but this is basically what it does

The problem is, doing the simplist thing takes the best part of half a day.... (to run through the servers in SLIST)

Id love to hear the methods that you guys use to distribute stuff out to large environments or run scripts on multiple machines...

ive seen some utilities like shmux etc, are these any good in an enterprise environment? is there a better way I should be looking to perform this task

Any thoughts would be great
# 2  
Old 12-14-2009
Assuming you have a passwd less ssh connection between all 2000 servers i can sugest one method to reduce time..
split your SLIST file into 10 or 20 small files and invoke your script parrellely providing it diff SLIST files... its like multistreaming your process..
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Run a shell script on all 15 servers at the same time?

We have 15 servers. Hostnames for these 15 servers are stored in a text files and loop through each server to connect to the remote server and run a command, but this loop process runs the command one after another. However, the requirement is to run the same command on all 15 servers at the same... (10 Replies)
Discussion started by: laknar
10 Replies

2. Shell Programming and Scripting

Run a script on multiple servers

I need to run a script on a bunch of remote servers. how can this be done without ssh into each individual server and run it its under /sbin/script.sh on each server (1 Reply)
Discussion started by: tdubb123
1 Replies

3. UNIX for Dummies Questions & Answers

Scripts can be run manually but couldn't run with cronjobs

I am from MQ/MB technology. My requirement is to display the queue manger and broker status on daily basis. If I manually run the script, it works fine and displays output. But when I have scheduled the same using cronjobs it shows only the queue manger status and not the broker status. Can... (3 Replies)
Discussion started by: Anusha M
3 Replies

4. Shell Programming and Scripting

Handling scripts in two different servers

Hi , My Script work as below 1- On server 1 execute script1.sh , through this script one parameter file is generated as file.txt this is to transfer on server 2 2- After reaching on server2 other shell script script2.sh execute using parameter file file.txt This generate file... (1 Reply)
Discussion started by: kaushik02018
1 Replies

5. Shell Programming and Scripting

Run a script in parts on 2 servers

Hi all, I have a task for which I need to run some commands on one server1 and then jump from the server1 (using ssh and asking user to enter login credentials manually for server2 server) to server2 and run some commands there and exit. I know the script I need here but problem is when I... (5 Replies)
Discussion started by: pat_pramod
5 Replies

6. Shell Programming and Scripting

Executing scripts on remote servers

Hello all, I'm typing away a script that will send a script to a remote host and execute it. This is what i have at the moment and i was wondering if i can improve that or thats basicly what everybody does. Using bash on RHEL 5.5 To over simplify it... #!/bin/bash # start_ () { ... (3 Replies)
Discussion started by: maverick72
3 Replies

7. UNIX for Advanced & Expert Users

Command to run across servers

Hi, I have to run several unix commands like lsof or sed and need to execute across different servers as part of my monitoring tasks. There are around 40 Unix Servers. It is really cumbersome to run those command on several servers. can some help me in this regard. Is it possible to run... (6 Replies)
Discussion started by: john_prince
6 Replies

8. Shell Programming and Scripting

How to run same script on multiples servers

Hi All, I have some script that run some commands and send results to my email. I want to run same script on mulitiple servers. How can I do that. I know there is an option "ssh". But I'm not quite sure how to use it in the script. And also. scripts has some parameters like following, if :... (10 Replies)
Discussion started by: s_linux
10 Replies

9. Shell Programming and Scripting

Shell Scripts for automating server inventory for unix servers

Dear Team, I am very new to shell scripting & and presently monitoring unix boxes I am looking for a shell script which will give me the below output script should contain - hostname,OS Version,CPU details, Physical Memory, Partitions Details, Network Details and Software Installed,... (5 Replies)
Discussion started by: whizkidash
5 Replies

10. Shell Programming and Scripting

ksh to run servers

I want to write a Kshell program which will start the servers(Oracle,DataIntegrator). Can anybody help me with this? I would appreciate your help. Thanks in advance (0 Replies)
Discussion started by: pari111222
0 Replies
Login or Register to Ask a Question