parallel-scp(1)
π parallel-scp β the glow-up guide π
okay bestie, welcome to parallel-scp(1) from the General Commands Manual section. sit down, grab a boba, we're about to copy files to like a million hosts at once and it's gonna be β¨iconicβ¨.
β¨ NAME β¨
parallel-scp β parallel file upload program π¦
no fr that's the whole thing, it's a program that uploads files in parallel. slay.
πΈ SYNOPSIS πΈ
parallel-scp [-vAr] [-h hosts_file] [-H [user@]host[:port]] [-l user]
[-p par] [-o outdir] [-e errdir] [-t timeout] [-O options] [-x args] [-X
arg] local remote
π DESCRIPTION π
so parallel-scp is literally a program for copying files in parallel to a whole bunch of hosts, and it does it by using the scp program. it's giving main character energy for your file distribution era.
it also has some extra little features that are lowkey essential: passing a password to scp, saving output to files, and timing out. iykyk π
π OPTIONS π
-h host_file,--hosts host_fileβ read hosts from the givenhost_file. the lines in the host file look like[user@]host[:port], and yes you can include blank lines and comments (comments are lines that start with"#"). if you pass multiple host files (aka you use-hmore than once),parallel-scpacts like all those files got concatenated together. and if a host shows up multiple times? thenparallel-scpwill connect that many times. no cap. π₯-H[user@]host[:port]--host[user@]host[:port]-H"[user@]host[:port] [ [user@]host[:port ] ... ]"--host"[user@]host[:port] [ [user@]host[:port ] ... ]"β add the given host strings to the list of hosts. you can give this option multiple times, and you can absolutely use it alongside the-hoption. they're besties, not rivals π«Ά-l user,--user userβ use the given username as the default for any host entries that don't specifically specify a user. the backup username, the understudy, the girl who steps in when nobody else is named π-p parallelism,--par parallelismβ use the given number as the maximum number of concurrent connections. that's your "how many friends can come to the party at once" number.-t timeout,--timeout timeoutβ make connections time out after the given number of seconds. and if you set the value to0,parallel-scpwill not timeout any connections at all. zero means the vibes are eternal, no deadlines, no pressure β¨-o outdir,--outdir outdirβ save standard output to files in the given directory. filenames are of the form[user@]host[:port][.num], and the user and port only show up for hosts that explicitly specify them. thenumis a counter that gets incremented each time for hosts that are specified more than once.-e errdir,--errdir errdirβ save standard error to files in the given directory. filenames are the same form as with the-ooption. same energy, different stream π-x args,--extra-args argsβ passes extra SSH command-line arguments (peep thessh(1)man page for more info about SSH arguments). you can specify this option multiple times. the arguments get processed to split on whitespace, protect text within quotes, and escape with backslashes. if you wanna pass arguments without that processing, use the-Xoption instead.-X arg,--extra-arg argβ passes a single SSH command-line argument (again,ssh(1)man page for more about SSH arguments). unlike the-xoption, no processing happens on the argument, word splitting included. to pass multiple command-line arguments, use the option once for each argument. one arg, one use, periodt.-O options,--options optionsβ SSH options in the format used in the SSH configuration file (see thessh_config(5)man page for more info). this option may be specified multiple times. obsessed with the flexibility ngl.-A,--askpassβ prompt for a password and pass it to ssh. the password may be used either to unlock a key or for password authentication. the password is transferred in a fairly secure manner (like, it won't show up in argument lists, okay?). however β be aware that a root user on your system could potentially intercept the password. π so like, stay aware bestie.-v,--verboseβ include error messages from ssh with the-iand-eoptions. she's loud and she's proud.-r,--recursiveβ recursively copy directories. go down the whole tree, no skipping levels, we do not gatekeep π§
π TIPS π
the ssh_config file can include an arbitrary number of Host sections. each host entry specifies ssh options which apply only to that given host. and here's the wild part β Host definitions can even behave like aliases if the HostName option is included. this ssh feature, combined with parallel-ssh host files, provides a tremendous amount of flexibility. genuinely a power combo, i'm obsessed β
π EXIT STATUS π
the exit status codes from parallel-scp are as follows, bestie, memorize these:
0β Success β¨1β Miscellaneous error2β Syntax or usage error3β At least one process was killed by a signal or timed out.4β All processes completed, but at least onescpprocess reported an error (exit status other than0).
π AUTHORS π
written by Brent N. Chun <bnc@theether.org> and Andrew McNabb <amcnabb@mcnabbs.org>. absolute legends, we thank them for their service π«‘
https://github.com/lilydjwg/parallel-ssh
π¦ SEE ALSO π¦
ssh(1), ssh_config(5), parallel-ssh(1), parallel-rsync(1), parallel-slurp(1), parallel-nuke(1),
and that's the whole page, bestie!! π this one's from the General Commands Manual, dated January 24, 2012, and it's parallel-scp(1) β go forth and copy in parallel, you've got this ππΈβ¨
π¦ where this page comes from
- debian bookworm: pssh 2.3.4-2 Β· BSD-3-Clause
- debian trixie: pssh 2.3.5-2 Β· BSD-3-Clause
- ubuntu jammy: pssh 2.3.4-2 Β· BSD-3-Clause
- ubuntu noble: pssh 2.3.5-2 Β· BSD-3-Clause
- ubuntu questing: pssh 2.3.5-2
- ubuntu resolute: pssh 2.3.6-1 Β· BSD-3-Clause
- ubuntu stonking: pssh 2.3.6-1 Β· BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms