pscp — copy a file to multiple nodes in parallel.
pscp [ -p? ] [ -h
] [ -i
filename ] [ -o
filename ] [ -I
command ] [ -O
command ] [ -m
num ] [ -s
server ] [ -l
port ] [ --maxsize
size ] [ --tokens
num ] [ --lowtokens
num ] [ -v
pscp [ -V ]
The pscp command is designed to copy files to many nodes in real parallelism. The implemented strategy ensures scalability up to hundreds of nodes for arbitrary file sizes.
Beside copying a single file to all destination hosts, the pscp command may generate and unpack on-the-fly archives to copy a set of files at once. Data compression could also be enabled by defining proper compress/uncompress commands.
List of hosts to copy the file(s) to.
List of node ids to copy the file(s) to.
Filename to be sent to remote nodes.
Filename stored on the remote nodes.
In case of the option
-i is given, this
option must be given, too, even if input and output file
are the same.
Command to pack a file or list of files to be transmitted.
The file or list of files to be transmitted must be part
command, see examples below.
The command must send its output to stdout.
Command to unpack a file or list of files received.
Create and unpack a tar-file on-the-fly including sub-directories.
This is a short hand for
cvPf - .
files" -O "/bin/tar xPf -"
Manually start up
Only for debugging purposes.
Server to connect to for clients started using
Port number to connect to for clients started using
Show progress information.
Size of chunks to send or receive at once.
Number of tokens to use for flow control stop.
Number of low tokens to use for flow control start.
Be more verbose.
Level could be
in the range from 0 to 3.
Print pscp version and exit.
Print usage and exit.
nodelist may be comma separated lists
of host names or host id, respectively.
nodelist is given, the file will
be copied to all but the local host.
All files will be copied relatively to the current working
are mutually exclusive.
Pscp copies an input file or an input data stream to an output file or an output data stream on many nodes in parallel. Writing data to disk and forwarding data to the next node takes place in parallel.
Pscp uses the ParaStation MPI
psport library for data transfers,
that automatically will use the most effective communication
If required, the communication layer may be controlled using
environment variables, refer to
ps_environment(7) for details.
The client process on each node is spawned using the ParaStation MPI
As pscp uses administrative ParaStation MPI tasks to
spawn the client processes, the user must be a member of the
adminuser list or the user's group must
be a member of the
admingroup list. Refer
to ParaStation MPI User's Guide and
psiadmin(8) for details.
Copy the file
/boot/vmlinuz to all other
pscp -i /boot/vmlinuz -o /boot/vmlinuz
To copy all files and directories within
/boot to hosts
node9 and show the progress, enter
pscp -C /boot -h node5,node6,node7,node8,node9 -p
To send the file
testfile2 to nodes
node19 and compress/decompress it
pscp -h `seq -s , -f "node%02g" 10 19` -I \ "bzip2 -c testfile2" -O "bunzip2 > testfile2"
The same will be accomplished using
pscp -n `seq -s , -f "node%02g" 10 19` -I \ "/bin/tar cvPfj - testfile2" -O "/bin/tar xPfj -"
-O may be
combined to do things like
pscp -h node03,node17 -i myfiles.tar.gz -O "/bin/tar xPfz -"
This command will transfer the already existing compressed tar
myfiles.tar.gz to nodes
will decompress and unpack the archive on each node.
The size of the file or archive transfered to the remote nodes is only limited by the available disk space on the particular nodes and the underlying filesystem.