How do admins handle a situation with many boxes like 50 for example. If I wish to tell 50 boxes to run a handful of commands - how is that done? (I mean without actually logging into 1,2,3,4...X and executing the commands) Thanks, Jerry
Jerry Geis wrote:> How do admins handle a situation with many boxes like 50 for example. > If I wish to tell 50 boxes to run a handful of commands - how is that done? > (I mean without actually logging into 1,2,3,4...X and executing the > commands) > > Thanks, > > Jerry > _______________________________________________ > CentOS mailing list > CentOS at centos.org > http://lists.centos.org/mailman/listinfo/centos >Depending on situation, either by using a config management system like puppet or cfengine, or by using a tool like dssh or clusterssh. -Alan
On Aug 4, 2009, at 3:32 PM, Jerry Geis wrote:> How do admins handle a situation with many boxes like 50 for example. > If I wish to tell 50 boxes to run a handful of commands - how is > that done?one such tool, and links to many others, are here: http://web.taranis.org/shmux/ -steve -- If this were played upon a stage now, I could condemn it as an improbable fiction. - Fabian, Twelfth Night, III,v http://five.sentenc.es -------------- next part -------------- A non-text attachment was scrubbed... Name: PGP.sig Type: application/pgp-signature Size: 194 bytes Desc: This is a digitally signed message part URL: <http://lists.centos.org/pipermail/centos/attachments/20090804/b5a38816/attachment-0003.sig>
Jerry Geis wrote:> How do admins handle a situation with many boxes like 50 for example. > If I wish to tell 50 boxes to run a handful of commands - how is that done? > (I mean without actually logging into 1,2,3,4...X and executing the > commands)Depends what the commands have to do. For most of my management I use cfengine which runs hourly and can run things on classes of boxes. If I want to run something *right now* I use a simple script and ssh keys, and ssh-agent to automatically login to however many boxes I want and run the command. e.g. assuming the boxes have various names, create a text file that has all of their names and a simple 1-liner to iterate through the file and login to the systems, if they are all named similarly you can use something like seq to help e.g. for i in `seq -w 1 50`; do ssh username at myserver${i} "my command";done There are also tools like clusterssh which can run the commands in parallel. Never used them myself. nate
Jerry Geis schrieb:> How do admins handle a situation with many boxes like 50 for example. > If I wish to tell 50 boxes to run a handful of commands - how is that done? > (I mean without actually logging into 1,2,3,4...X and executing the > commands)Just found phpAdamoto[1] on freshmeat and will test it the next days. Right now, it is a mixture of clusterssh and self-written scripts. [1] http://www.phpadamoto.org/Server/doc.php Regards, Peter -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 257 bytes Desc: OpenPGP digital signature URL: <http://lists.centos.org/pipermail/centos/attachments/20090804/499a2bfc/attachment-0003.sig>
--- On Tue, 8/4/09, Jerry Geis <geisj at pagestation.com> wrote:> How do admins handle a situation with > many boxes like 50 for example. > If I wish to tell 50 boxes to run a handful of commands - > how is that done? > (I mean without actually logging into 1,2,3,4...X? and > executing the > commands) >You could use a cluster shell like C3 or pdsh for this. Both are open source projects. With C3, for instance, you can define your nodes as part of a cluster and then simply run shell commands against the entire cluster or, if wanted, against a sub set of nodes.
On Tue, Aug 4, 2009 at 3:32 PM, Jerry Geis<geisj at pagestation.com> wrote:> How do admins handle a situation with many boxes like 50 for example. > If I wish to tell 50 boxes to run a handful of commands - how is that done? > (I mean without actually logging into 1,2,3,4...X ?and executing the > commands)We use a combination of puppet and dsh: http://reductivelabs.com/products/puppet/ http://www.garbled.net/clusterit.html Puppet ensures configs are in sync, and dsh allows us to run 1 off commands across all our hosts in parallel. - Ryan -- http://prefetch.net