e68fe9d2db
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@1561 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
92 lines
2.0 KiB
Plaintext
92 lines
2.0 KiB
Plaintext
=head1 Name
|
|
|
|
psh - parallel remote shell
|
|
|
|
=head1 B<Synopsis>
|
|
|
|
B<psh> [B<-i> I<interface>] [B<-l> I<user>] I<noderange> I<command>
|
|
|
|
B<psh> {B<-h>|B<--help>|B<-v>|B<--version>}
|
|
|
|
=head1 B<Description>
|
|
|
|
B<psh> is a utility used to run a command across a list of nodes in parallel.
|
|
|
|
B<ssh> must be set up to allow no prompting for B<psh> to work.
|
|
|
|
Note: this command does not run through xcatd like most xCAT commands do.
|
|
This means you must either run it on the management node, or have a network connection between
|
|
your machine and the nodes.
|
|
|
|
=head1 B<Options>
|
|
|
|
=over 7
|
|
|
|
=item B<-i> I<interface>
|
|
|
|
The NIC on the node that psh should communicate with. For example, if I<interface> is B<eth1>,
|
|
then psh will concatenate B<-eth1> to the end of every node name before ssh'ing to it. This
|
|
assumes those host names have been set up to resolve to the IP address of each of the eth1 NICs.
|
|
|
|
=item B<-l> I<user>
|
|
|
|
Log into the nodes as the specified username. The default is to use the same username as you
|
|
are running the psh command as.
|
|
|
|
=item B<noderange>
|
|
|
|
See L<noderange(3)|noderange.3>.
|
|
|
|
=item B<command>
|
|
|
|
Command to be run in parallel. If no command is give then B<psh>
|
|
enters interactive mode. In interactive mode a ">" prompt is
|
|
displayed. Any command entered is executed in parallel to the
|
|
nodes in the noderange. Use "exit" or "Ctrl-D" to end the interactive session.
|
|
|
|
=item B<-h>|B<--help>
|
|
|
|
Print help.
|
|
|
|
=back
|
|
|
|
|
|
=head1 B<Examples>
|
|
|
|
=over 3
|
|
|
|
=item *
|
|
|
|
Run uptime on 3 nodes:
|
|
|
|
B<psh> I<node4-node6> I<uptime>
|
|
|
|
node4: Sun Aug 5 17:42:06 MDT 2001
|
|
node5: Sun Aug 5 17:42:06 MDT 2001
|
|
node6: Sun Aug 5 17:42:06 MDT 2001
|
|
|
|
=item *
|
|
|
|
Run a command on some BladeCenter management modules:
|
|
|
|
B<psh> I<amm1-amm5> I<'info -T mm[1]'>
|
|
|
|
=item *
|
|
|
|
Remove the tmp files on the nodes in the 1st frame:
|
|
|
|
B<psh> I<rack01> I<'rm -f /tmp/*'>
|
|
|
|
Notice the use of '' to forward shell expansion. This is not necessary
|
|
in interactive mode.
|
|
|
|
=back
|
|
|
|
=head1 B<Author>
|
|
|
|
Egan Ford <egan@us.ibm.com>
|
|
|
|
=head1 B<See> B<Also>
|
|
|
|
L<noderange(3)|noderange.3>, L<pscp(1)|pscp.1>, L<pping(1)|pping.1>, L<prsync(1)|prsync.1>
|