What's new? | Help | Directory | Sign in
Google
myrpm
Rpm building tools, server park and cluster rpm managed utilities
  
  
  
  
    
Search
for
Updated Jul 13, 2007 by jmrenouard
Labels: Featured, Phase-Support
ClusterMangementHowTo  
How to mange large range of machine easily

Introduction

The csu utilities are a set of scripts essentially based on SSH helping you to execute script, command, copy from a single machine to a set of server without pain.

SSH key installation

ssh rsa key generation

  1. Create your set of public/private keys
  2. ssh-keygen -t rsa
  3. press Enter until you get the prompt.
  4. check the SSH keys - $HOME/.ssh/id_rsa and $HOME/.ssh/id_rsa.pub

create a file containing the IP or DNS name of your server

All cluster script used a list of ip/dns name to perform there commands.

192.169.1.1

192.169.1.2

192.169.1.3

....

Deploy your public key on server

We have provide 2 scripts in csu : putKey and deployKeys

putKey

This script deploy your key and try to connect you directly after.

putKey root@cluster1.123solution.fr

deployKeys

This script performs a public ssh key deployment but based on a ip list file as above.

So this is the borrowning part of the job ( if you don't try to used pssh).

deployKeys root ipClusterListFile.txt

Performing automatic remote operations on a group of server

copy file or dirctory on several server in one command line and no shell interaction

the mass-rsync is a equivalent to rsync but for group of server.

Imagine you want to deploy crontab for all your servers

mass-rsync root local_crontab /etc/crontab ipClusterListFile.txt

execute remotly a script in one command line and no shell interaction

the mass-ssh-remote-exec help you to execute a local script on several servers.

mass-ssh-remote-exec root local_script ipClusterListFile.txt

execute remotly a command on all server in one command line and no shell interaction

the mass-ssh-remote-cmd help you to execute a one line command on several servers.

mass-ssh-remote-cmd root "yum -y upgrade" ipClusterListFile.txt


Sign in to add a comment