prsync(1)
π prsync β the parallel file sync bestie π
okay so this is prsync(1), from the General Commands Manual, and honestly? she's iconic. she's the group chat member who can clone herself and sync files to like forty hosts at once and not even break a sweat.
β¨ NAME β¨
prsync β parallel file sync program π¦
πΈ SYNOPSIS πΈ
prsync [-vAraz] [-h hosts_file] [-H [user@]host[:port]] [-l user] [-p
par] [-o outdir] [-e errdir] [-t timeout] [-O options] [-x args] [-X
arg] [-S args] local ... remote
π DESCRIPTION π
so prsync is literally a program for copying files in parallel to a whole bunch of hosts, and it does it using the popular rsync program. no cap. she's got features like passing a password to ssh, saving output to files, and timing out. main character energy fr fr.
π OPTIONS π
-hhost_file,--hostshost_file β read hosts from the given host_file. lines in the host file look like[user@]host[:port]and can include blank lines and comments (lines beginning with#). if you give multiple host files (aka you use the-hoption more than once), thenprsyncbehaves as though these files were concatenated together. and if a host is specified multiple times?prsyncwill connect the given number of times. she said what she said π-H [user@]host[:port],--host [user@]host[:port]β add the given host strings to the list of hosts. this option may be given multiple times, and may be used in conjunction with the-hoption.-H "[user@]host[:port] [ [user@]host[:port ] ... ]",--host "[user@]host[:port] [ [user@]host[:port ] ... ]"β same deal, you can also pass a whole little bundle of host strings in one quoted argument. π«Ά-luser,--useruser β use the given username as the default for any host entries that don't specifically specify a user.-pparallelism,--parparallelism β use the given number as the maximum number of concurrent connections. she multitasks, obviously.-ttimeout,--timeouttimeout β make connections time out after the given number of seconds. with a value of0,prsyncwill not timeout any connections. (zero means "we wait forever, bestie, we're committed")-ooutdir,--outdiroutdir β save standard output to files in the given directory. filenames are of the form[user@]host[:port][.num]where the user and port are only included for hosts that explicitly specify them. the number is a counter that is incremented each time for hosts that are specified more than once. π-eerrdir,--errdirerrdir β save standard error to files in the given directory. filenames are of the same form as with the-ooption.-xargs,--extra-argsargs β passes extrarsynccommand-line arguments (see thersync(1)man page for more information aboutrsyncarguments). this option may be specified multiple times. the arguments are processed to split on whitespace, protect text within quotes, and escape with backslashes. to pass arguments without such processing, use the-Xoption instead.-Xarg,--extra-argarg β passes a singlersynccommand-line argument (see thersync(1)man page for more information aboutrsyncarguments). unlike the-xoption, no processing is performed on the argument, including word splitting. to pass multiple command-line arguments, use the option once for each argument.-Ooptions,--optionsoptions βSSHoptions in the format used in theSSHconfiguration file (see thessh_config(5)man page for more information). this option may be specified multiple times.-A,--askpassβ prompt for a password and pass it tossh. the password may be used for either to unlock a key or for password authentication. the password is transferred in a fairly secure manner (e.g., it will not show up in argument lists).
okay but real talk: be aware that a root user on your system could potentially intercept the password. she's careful, but root is root. π
-v,--verboseβ include error messages fromrsyncwith the-iand-eoptions.-r,--recursiveβ recursively copy directories. down the rabbit hole we go π-a,--archiveβ usersyncarchive mode (rsync's-aoption).-z,--compressβ usersynccompression.-Sargs,--ssh-argsargs β passes extraSSHcommand-line arguments (see thessh(1)man page for more information aboutSSHarguments). the given value is appended to thesshcommand (rsync's-eoption) without any processing.
π TIPS π
the ssh_config file can include an arbitrary number of Host sections. each host entry specifies ssh options which apply only to the given host. Host definitions can even behave like aliases if the HostName option is included. this ssh feature, in combination with pssh host files, provides a tremendous amount of flexibility. it's giving β¨infrastructureβ¨ ngl.
β EXIT STATUS β
the exit status codes from prsync are as follows:
0β Success1β 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 onersyncprocess reported an error (exit status other than0).
π AUTHORS π
written by Brent N. Chun <bnc@theether.org> and Andrew McNabb <amcnabb@mcnabbs.org>.
https://github.com/lilydjwg/pssh
π SEE ALSO π
rsync(1), ssh(1), ssh_config(5), pssh(1), prsync(1), pslurp(1), pnuke(1),
okay that's the whole page bestie, mwah π this icon dropped on January 24, 2012 (yes she's a vintage queen, we stan) and she's been out here living her best life in the General Commands Manual ever since. periodt. π β¨
π¦ where this page comes from
- epel 10: pssh 2.3.5-8.el10_0 Β· LicenseRef-Callaway-BSD
- epel 9: pssh 2.3.4-1.el9 Β· BSD
- fedora 43: pssh 2.3.5-13.fc43 Β· LicenseRef-Callaway-BSD
- fedora 43: pssh 2.3.6-1.fc43 Β· LicenseRef-Callaway-BSD
- fedora 44: pssh 2.3.6-2.fc44 Β· LicenseRef-Callaway-BSD
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms