1CSSH(1)               User Contributed Perl Documentation              CSSH(1)
2
3
4

NAME

6       cssh (crsh) - Cluster administration tool
7

SYNOPSIS

9       cssh [options] [[user@]<server>⎪<tag>] [...]
10       crsh [options] [[user@]<server>⎪<tag>] [...]
11       cssh [options] [[user@]<server>[:port]⎪<tag>] [...]
12       crsh [options] [[user@]<server>[:port]⎪<tag>] [...]
13

DESCRIPTION

15       The command opens an administration console and an xterm to all speci‐
16       fied hosts.  Any text typed into the administration console is repli‐
17       cated to all windows.  All windows may also be typed into directly.
18
19       This tool is intended for (but not limited to) cluster administration
20       where the same configuration or commands must be run on each node
21       within the cluster.  Performing these commands all at once via this
22       tool ensures all nodes are kept in sync.
23
24       Connections are opened via ssh so a correctly installed and configured
25       ssh installation is required.  If, however, the program is called by
26       "crsh" then the rsh protocol is used (and the communications channel is
27       insecure).
28
29       Extra caution should be taken when editing system files such as
30       /etc/inet/hosts as lines may not necessarily be in the same order.
31       Assuming line 5 is the same across all servers and modifying that is
32       dangerous.  Better to search for the specific line to be changed and
33       double-check before changes are committed.
34
35       Further Notes
36
37       ·   The dotted line on any sub-menu is a tear-off, i.e. click on it and
38           the sub-menu is turned into its own window.
39
40       ·   Unchecking a hostname on the Hosts sub-menu will unplug the host
41           from the cluster control window, so any text typed into the console
42           is not sent to that host.  Re-selecting it will plug it back in.
43
44       ·   If the code is called as crsh instead of cssh (i.e. a symlink
45           called crsh points to the cssh file or the file is renamed) rsh is
46           used as the communications protocol instead of ssh.
47
48       ·   Starting the utility will be much faster with a configuration file
49           (as this prevents searching for required files).  Generate one con‐
50           taining all default entries with:
51
52           "cssh -u > $HOME/.csshrc"
53
54       ·   When using cssh on a large number of systems to connect back to a
55           single system (e.g. you issue a command to the cluster to scp a
56           file from a given location) and when these connections require
57           authentication (i.e. you are going to authenticate with a pass‐
58           word), the sshd daemon at that location may refuse connects after
59           the number specified by MaxStartups in sshd_config is exceeded.
60           (If this value is not set, it defaults to 10.)  This is expected
61           behavior; sshd uses this mechanism to prevent DoS attacks from
62           unauthenticated sources.  Please tune sshd_config and reload the
63           SSH daemon, or consider using the ~/.ssh/authorized_keys mechanism
64           for authentication if you encounter this problem.
65
66       ·   If client windows fail to open, try running "cssh -d <single host
67           name>".  This will output a command to run which will test the
68           method used by cssh to open client windows.  If you copy-and-paste
69           this command into a window and it fails, this is the issue.  It is
70           most likely due to the "-xrm" option which enables "AllowSendE‐
71           vents" in the terminal.  Some terminal do not require this option,
72           other terminals have another method for enabling it.  See your ter‐
73           minal documention for further information.
74

OPTIONS

76       Some of these options may also be defined within the configuration
77       file.  Default options are shown as appropriate.
78
79       -h⎪-?
80           Show basic help text, and exit
81
82       -H  Show full help test (the man page), and exit
83
84       -v  Show version information and exit
85
86       -d  Enable basic debugging mode (can be combined with -D)
87
88       -D  Enable extended debugging mode (can be combined with -d)
89
90       -q⎪-Q
91           Enable⎪Disable automatically quiting after the last client window
92           has closed (overriding the config file)
93
94       -u  Output configuration in the format used by the $HOME/.csshrc file
95
96       -g⎪-G
97           Enable⎪Disable window tiling (overriding the config file)
98
99       -c <file>
100           Use supplied file as additional cluster file (see also "FILES")
101
102       -l $LOGNAME
103           Specify the default username to use for connections (if different
104           from the currently logged in user).  NOTE: will be overridden by
105           <user>@<host>
106
107       -T "CSSH"
108           Specify the initial part of the title used in the console and
109           client windows
110
111       -o "-x -o ConnectTimeout=10" - for ssh connections
112       -o ""                        - for rsh connections
113           Specify arguments to be passed to ssh or rsh when making the con‐
114           nection.
115
116           NOTE: any "generic" change to the method (i.e. specifying the ssh
117           port to use) should be done in the medium's own config file (see
118           ssh_config and $HOME/.ssh/config).
119
120       -t ""
121           Specify arguments to be passed to terminals being used
122
123       -i  Ignore errors from unresolvable host names (i.e. because the name
124           is an alias within an ssh config file or similar) (see also
125           "ignore_host_errors" in "FILES")
126
127       -e [user@]<hostname>[:port]
128           Display and evaluate the terminal and connection arguments so dis‐
129           play any potential errors.  The <hostname> is required to aid the
130           evaluation.
131

ARGUMENTS

133       The following arguments are support:
134
135       [user@]<hostname>[:port] ...
136           Open an xterm to the given hostname and connect to the administra‐
137           tion console.  An optional port number can be used if sshd is not
138           listening on standard port (e.g not listening on port 22) and
139           ssh_config cannot be used.
140
141       <tag> ...
142           Open a series of xterms defined by <tag> within either /etc/clus‐
143           ters or $HOME/.csshrc (see "FILES").
144

KEY SHORTCUTS

146       The following key shortcuts are available within the console window,
147       and all of them may be changed via the configuration files.
148
149       Control-q
150           Quit the program and close all connections and windows
151
152       Control-+
153           Open the Add Host dialogue box
154
155       Alt-n
156           Paste in the correct client name to all clients, i.e.
157
158           "scp /etc/hosts server:files/<Alt-n>.hosts"
159
160           would replace the <Alt-n> with the client's name in all the client
161           windows
162
163       Alt-r
164           Retile all the client windows
165

FILES

167       /etc/clusters
168           This file contains a list of tags to server names mappings.  When
169           any name is used on the command line it is checked to see if it is
170           a tag in /etc/clusters (or the .csshrc file, or any additional
171           cluster file specified by -c).  If it is a tag, then the tag is
172           replaced with the list of servers from the file.  The file is for‐
173           mated as follows:
174
175           <tag> [user@]<server> [user@]<server> [...]
176
177           i.e.
178
179            # List of servers in live
180            live admin1@server1 admin2@server2 server3 server4
181
182           All standard comments and blank lines are ignored.  Tags may be
183           nested, but be aware of recursive tags.
184
185           Clusters may also be specified within the user's .csshrc file, as
186           documented below.
187
188       /etc/csshrc & $HOME/.csshrc
189           This file contains configuration overrides - the defaults are as
190           marked.  Default options are overwritten first by the global file,
191           and then by the user file.
192
193           always_tile = yes
194               Setting to anything other than "yes" does not perform window
195               tiling (see also -G).
196
197           auto_quit = yes
198               Automatically quit after the last client window closes.  Set to
199               anything other than "yes" to disable.  Can be overridden by
200               "-Q" on the command line.
201
202           comms = ssh
203               Sets the default communication method (initially taken from the
204               name of program, but can be overridden here).
205
206           clusters = <blank>
207               Define a number of cluster tags in addition to (or to replace)
208               tags defined in the /etc/clusters file.  The format is:
209
210                clusters = <tag1> <tag2> <tag3>
211                <tag1> = host1 host2 host3
212                <tag2> = user@host4 user@host5 host6
213                <tag3> = <tag1> <tag2>
214
215               As with the /etc/clusters file, be sure not to create recur‐
216               sivly nested tags.
217
218           console_position = <null>
219               Set the initial position of the console - if empty then let the
220               window manager decide.  Format is '+<x>+<y>', i.e. '+0+0' is
221               top left hand corner of the screen, '+0-70' is bottom left hand
222               side of screen (more or less).
223
224           ssh_args = "-x -o ConnectTimeout=10"
225           rsh_args = <blank>
226               Sets any arguments to be used with the communication method
227               (defaults to ssh arguments).
228
229               NOTE: The given defaults are based on OpenSSH, not commercial
230               ssh software.
231
232               NOTE: Any "generic" change to the method (i.e. specifying the
233               ssh port to use) should be done in the medium's own config file
234               (see ssh_config and $HOME/.ssh/config).
235
236           ignore_host_errors = "no"
237               If set to "yes", ignore errors from host names that cannot be
238               resolved and attempt to connect anyway (i.e. because they are
239               aliased in an ssh config file) - see also "-i"
240
241           key_addhost = Control-plus
242               Default key sequence to open AddHost menu.  See below notes on
243               shortcuts.
244
245           key_clientname = Alt-n
246               Default key sequence to send cssh client names to client.  See
247               below notes on shortcuts.
248
249           key_quit = Control-q
250               Default key sequence to quit the program (will terminate all
251               open windows).  See below notes on shortcuts.
252
253           key_retilehosts = Alt-r
254               Default key sequence to retile host windows.  See below notes
255               on shortcuts.
256
257           key_paste = Control-v
258               Default key sequence to paste text into the console window.
259               See below notes on shortcuts.
260
261           mouse_paste = Button-2 (middle mouse button)
262               Default key sequence to paste text into the console window
263               using the mouse.  See below notes on shortcuts.
264
265           screen_reserve_top = 25
266           screen_reserve_bottom = 30
267           screen_reserve_left = 0
268           screen_reserve_right = 0
269               Number of pixels from the screen side to reserve when calculat‐
270               ing screen geometry for tiling.  Setting this to something like
271               50 will help keep cssh from positioning windows over your win‐
272               dow manager's menu bar if it draws one at that side of the
273               screen.
274
275           ssh = /path/to/ssh
276           rsh = /path/to/rsh
277               Depending on the value of comms, set the path of the communica‐
278               tion binary.
279
280           terminal = /path/to/terminal
281               Path to the x-windows terminal used for the client.
282
283           terminal_args = <blank>
284               Arguments to use when opening terminal windows.  Otherwise
285               takes defaults from $HOME/.Xdefaults or $<$HOME/.Xresources>
286               file.
287
288           terminal_font = 6x13
289               Font to use in the terminal windows.  Use standard X font nota‐
290               tion.
291
292           terminal_reserve_top = 0
293           terminal_reserve_bottom = 0
294           terminal_reserve_left = 0
295           terminal_reserve_right = 0
296               Number of pixels from the terminal side to reserve when calcu‐
297               lating screen geometry for tiling.  Setting these will help
298               keep cssh from positioning windows over your scroll and title
299               bars
300
301           terminal_size = 80x24
302               Initial size of terminals to use (note: the number of lines
303               (24) will be decreased when resizing terminals for tiling, not
304               the number of characters (80))
305
306           terminal_title_opt = -T
307               Option used with "terminal" to set the title of the window
308
309           terminal_allow_send_events = -xrm 'XTerm.VT100.allowSendE‐
310           vents:true'
311               Option required by the terminal to allow XSendEvents to be
312               received
313
314           title = cssh
315               Title of windows to use for both the console and terminals.
316
317           use_hotkeys = yes
318               Setting to anything other than "yes" will disable all hotkeys.
319
320           user = $LOGNAME
321               Sets the default user for running commands on clients.
322
323           window_tiling = yes
324               Perform window tiling (set to "no" to disable)
325
326           window_tiling_direction = right
327               Direction to tile windows, where "right" means starting top
328               left and moving right and then down, and anything else means
329               starting bottom right and moving left and then up
330
331           NOTE: The key shortcut modifiers must be in the form "Control",
332           "Alt", or "Shift", i.e. with the first letter capitalised and the
333           rest lower case.  Keys may also be disabled individually by setting
334           to the work "null".
335

AUTHOR

337       Duncan Ferguson
338

CREDITS

340       clusterssh is distributed under the GNU public license.  See the file
341       LICENSE for details.
342
343       A web site for comments, requests, bug reports and bug fixes/patches is
344       available at <http://clusterssh.sourceforge.net/>
345

KNOWN BUGS

347       Swapping virtual desktops can can a redraw of all the terminal windows.
348       This is due to a lack of distinction within Tk between switching desk‐
349       tops and minimising/maximising windows.  Until Tk can tell the differ‐
350       ence between the two events, there is no fix (apart from rewriting
351       everything directly in X)
352

REPORTING BUGS

354       · If you have issues running cssh, first try:
355
356         "cssh -e [user@]<hostname>[:port]"
357
358         This performs two tests to confirm cssh is able to work properly with
359         the settings provided within the .csshrc file (or internal defaults).
360
361                 1. test the terminal window works with the options provided
362
363                 2. test ssh works to a host with the configured arguments
364
365         Configuration options to watch for in ssh are
366
367                 - Doesnt understand "-o ConnectTimeout=10" - remove the option
368                   in the F<.csshrc> file
369
370                 - OpenSSH-3.8 using untrusted ssh tunnels - use "-Y" instead of "-X"
371                   or use "ForwardX11Trusted yes' in ssh_config (if you change the
372                   default ssh options from -x to -X)
373
374       · If you require support, please run the following commands and post it
375         on the web site in the support/problems forum:
376
377         "perl -V"
378
379         "perl -MTk -e 'print $Tk::VERSION,$/'"
380
381         "perl -MX11::Protocol -e 'print $X11::Protocol::VERSION,$/'"
382
383         "cat /etc/csshrc $HOME/.csshrc"
384
385       · Use the debug switches (-d, -D, or -dD) will turn on debugging out‐
386         put.  However, please only use this option with one host at a time,
387         i.e. "cssh -d <host>" due to the amount of output produced (in both
388         main and child windows).
389

SEE ALSO

391       <http://clusterssh.sourceforge.net/>, ssh, Tk::overview, X11::Protocol,
392       perl
393
394
395
396perl v5.8.8                       2006-07-24                           CSSH(1)
Impressum