-
Notifications
You must be signed in to change notification settings - Fork 21
/
mpssh.1
89 lines (85 loc) · 3.32 KB
/
mpssh.1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
.Dd 08/03/2013
.Dt mpssh
.Sh NAME
.Nm mpssh
.Sh SYNOPSIS
.Nm
.Op Fl besvV
.Op Fl o Ar directory
.Op Fl u Ar username
.Op Fl f Ar hosts
.Op Fl p Ar procs
.Ar <command>
.Sh DESCRIPTION
-b, --blind enable blind mode (no remote output)
-d, --delay delay between each ssh fork (default 10 msec)
-e, --exit print the remote command return code
-f, --file=FILE name of the file with the list of hosts
-h, --help this screen
-l, --label=LABEL connect only to hosts under label LABEL
-o, --outdir=DIR save the remote output in this directory
-p, --procs=NPROC number of parallel ssh processes (default 100)
-s, --nokeychk disable ssh strict host key check
-t, --conntmout ssh connect timeout (default 30 sec)
-u, --user=USER ssh login as this username
-v, --verbose be more verbose (i.e. show usernames used)
-V, --version show program version
The
.Nm
utility executes multiple parallel ssh binary instances in order to connect to a list of hosts (specified in the hosts file) and execute the given <command> on each of them.
A list of flags and arguments with description:
.Bl -tag -width -indent
.It Fl b
This flag enables "blind" mode, in which no output from the remote hosts is output to the screen. This mode is normally used with the
.Fl o
flag, so the output is saved to disk.
.It Fl d
This flag sets some delay in msecs between each fork()/exec() of the ssh process.
.It Fl e
With this flag
.Nm
prints the return codes of the remotely executed commands.
.It Fl l LABEL
Only connect to the hosts under the given label.
.It Fl s
This flag disables the ssh(1)'s strict host key checking. For more info see the ssh(1) manual page.
.It Fl v
This flag makes the output more verbose.
.It Fl o Ar directory
This option creates files in the specified directory named after each host name listed in the "hosts" file and saves the output received from the remotely executed command there. If the directory does not exists and attempt is made to be created.
.It Fl u Ar username
This forces ssh to use the supplied username instead of the username of the current user.
.It Fl f Ar hosts
A file containing a list of hosts to whom we are going to connect. One host per line. Lines starting with # are skipped. If not specified $HOME/.mpssh/hosts will be used.
.It Fl p Ar procs
Spawn up-to "procs" number of ssh processes in parallel.
.El
.Pp
.\" .Sh ENVIRONMENT \" May not be needed
.\" .Bl -tag -width "ENV_VAR_1" -indent \" ENV_VAR_1 is width of the string ENV_VAR_1
.\" .It Ev ENV_VAR_1
.\" Description of ENV_VAR_1
.\" .It Ev ENV_VAR_2
.\" Description of ENV_VAR_2
.\" .El
.Sh FILES
.It Pa /usr/local/bin/mpssh
/usr/local/bin/mpssh The
.Nm
binary
.El
.\" .Sh DIAGNOSTICS \" May not be needed
.\" .Bl -diag
.\" .It Diagnostic Tag
.\" Diagnostic informtion here.
.\" .It Diagnostic Tag
.\" Diagnostic informtion here.
.\" .El
.Sh SEE ALSO
.\" List links in ascending order by section, alphabetically within a section.
.\" Please do not reference files that do not exist without filing a bug report
.Xr ssh 1 ,
.Xr ssh-keygen 1 ,
.Xr ssh-agent 1
.\" .Sh BUGS \" Document known, unremedied bugs
.\" .Sh HISTORY \" Document history if command behaves in a unique manner