Use ssh on multiple servers at one time
Posted by rodo on Thu 4 Oct 2007 at 11:07
Lots of us have many server to manage and we perform the same tasks on each of the machine every day, if you want to save time the package cssh will make you happy!
Simply install the clusterssh package:
host:/# apt-get install clusterssh
Now if you want to perform the same command on the three servers one, two, & three simply run:
host:/# cssh one two three
This will open three console, one for each server, over an ssh connection, and one little console to type your command.
Enjoy !
[ Parent | Reply to this comment ]
[ Parent | Reply to this comment ]
man cssh of course, for details.
[ Parent | Reply to this comment ]
[ Parent | Reply to this comment ]
...will allow you to use abbreviations defined in ~/.ssh/config
BS
[ Parent | Reply to this comment ]
http://www.stearns.org
[ Parent | Reply to this comment ]
[ Parent | Reply to this comment ]
[ Parent | Reply to this comment ]
[ Parent | Reply to this comment ]
Very powerful and useful tool although a bit of a pain to identify which output comes from which host.
[ Parent | Reply to this comment ]
[ Parent | Reply to this comment ]
There will be the machine name as prefix of all output lines.
[ Parent | Reply to this comment ]
Cheers for the tip ;)
[ Parent | Reply to this comment ]
[ Parent | Reply to this comment ]
would you have any advice on how to get pssh running on debian sarge.
I'm quite interested by what pscp has to offer.
I seem to be having some trouble getting this to run with either python2.3 or python 2.4.
Cheers
[ Parent | Reply to this comment ]
[ Parent | Reply to this comment ]
[ Parent | Reply to this comment ]
http://taktuk.gforge.inria.fr/
taktuk package is in Debian and is very fast (to be quick: ssh are not made only by the server but by the other nodes also. So you have a tree based ssh connections).
So if you have a large amount of computers to contact, enjoy...
[ Parent | Reply to this comment ]
http://nile.ifae.es/FAQ.html
Cheers!
-Sx-
--
http://youve-reached-the.endoftheinternet.org/
[ Parent | Reply to this comment ]
http://dish.mirendom.net
[ Parent | Reply to this comment ]
write your /etc/clusters & ~/.csshrc files which is described as below :
cluster1 username@hostname1 username@hostname2 ....
and save it. After that add that hosts' ip4 address and hostnames to /etc/hosts. Open cssh via terminal ( for debugging) and click Hosts from menu and Add Hosts.
Write cluster1 to text box and OK.
I used cssh for our test client machines.
Thanks
** Serkan OKTER **
[ Parent | Reply to this comment ]