|OPENRSYNC(1)||General Commands Manual||OPENRSYNC(1)|
synchronise local and remote files
openrsync utility synchronises files
in the destination directory with one or more
source files. Either the source
or the destination directory may be remote, but not
both. The arguments are as follows:
--numeric-idsis also given or if the remote group name is unknown on the local machine, set the numeric group ID to match the source instead.
-ois also given.
--numeric-idsis also given or if the remote user name is unknown on the local machine, set the numeric user ID to match the source instead. Only works if run as root.
A remote source or
directory has the syntax
host:path for connecting via
or host::path for connecting to
a remote daemon. Subsequent to the first remote
source, the host may be dropped to become just
:path or ::path.
For connecting to a remote daemon with
host::path, the first path
component is interpreted as a "module":
This only applies to the first source invocation;
subsequent to that, the module should not be specified.
By default, new destination files and directories are given the current time and the source file permissions. Updated files retain their existing permissions. It is an error if updated files have their file types change (e.g., updating a directory with a file).
At this time, source may only consist of
regular files, directories (only with
symbolic links (only with
-l). The destination
directory must be a directory and is created if not
openrsync utility exits 0 on success,
1 if an error occurs, or 2 if the remote protocol version is older than the
local protocol version.
All examples use
-t so that destination
files inherit the source time. If not changed, subsequent invocations of
openrsync will then consider the file up to date and
not transfer block hashes.
To update the out-of-date remote files host:dest/bar and host:dest/baz with the local ../src/bar and ../src/baz:
% rsync -t ../src/bar ../src/baz host:dest
To update the out-of-date local files bar and baz with the remote files host:src/bar and host:src/baz:
% rsync -t host:src/bar :src/baz .
To update the out-of-date local files ../dest/bar and ../dest/baz with bar and baz:
% rsync -t bar baz ../dest
openrsync is compatible with rsync
protocol version 27 as supported by the samba.org implementation of
openrsync utility has been available
since OpenBSD 6.5.
openrsync utility was written by
|February 11, 2020||OpenBSD-6.8|