Introduction to rsync

The rsync package contains the rsync utility. This is useful for synchronizing large file archives over a network.

This package is known to build and work properly using an LFS-11.2 platform.

Package Information

  • Download (HTTP):

  • Download MD5 sum: 2fd61dfd76d39098c3be6eb5d54bb633

  • Download size: 1.1 MB

  • Estimated disk space required: 9.5 MB (with tests; add 24 MB for HTML API documentation)

  • Estimated build time: 0.7 SBU (with tests)

rsync Dependencies



Doxygen-1.9.4, lz4, and xxhash

User Notes:

Installation of rsync

For security reasons, running the rsync server as an unprivileged user and group is encouraged. If you intend to run rsync as a daemon, create the rsyncd user and group with the following commands issued by the root user:

groupadd -g 48 rsyncd &&
useradd -c "rsyncd Daemon" -m -d /home/rsync -g rsyncd \
    -s /bin/false -u 48 rsyncd

Install rsync by running the following commands:

./configure --prefix=/usr    \
            --disable-lz4    \
            --disable-xxhash \
            --without-included-zlib &&

If you have Doxygen-1.9.4 installed and wish to build HTML API documentation, issue:


To test the results, issue: make check.

Now, as the root user:

make install

If you built the documentation, install it using the following commands as the root user:

install -v -m755 -d          /usr/share/doc/rsync-3.2.5/api &&
install -v -m644 dox/html/*  /usr/share/doc/rsync-3.2.5/api

Command Explanations

--disable-lz4: This switch disables LZ4 compression support. Note that it uses the superior 'zstd' algorithm when this switch is in use, and zstd is provided in LFS.

--disable-xxhash: This switch disables advanced xxhash checksum support. Remove this switch if you have installed xxhash.

--without-included-zlib: This switch enables compilation with the system-installed zlib library.

Configuring rsync

Config Files


Configuration Information

For client access to remote files, you may need to install the OpenSSH-9.0p1 package to connect to the remote server.

This is a simple download-only configuration to set up running rsync as a server. See the rsyncd.conf(5) man-page for additional options (i.e., user authentication).

cat > /etc/rsyncd.conf << "EOF"
# This is a basic rsync configuration file
# It exports a single module without user authentication.

motd file = /home/rsync/welcome.msg
use chroot = yes

    path = /home/rsync
    comment = Default rsync module
    read only = yes
    list = yes
    uid = rsyncd
    gid = rsyncd


You can find additional configuration information and general documentation about rsync at

Boot Script

Note that you only need to start the rsync server if you want to provide an rsync archive on your local machine. You don't need this script to run the rsync client.

Install the /etc/rc.d/init.d/rsyncd init script included in the blfs-bootscripts-20220722 package.

make install-rsyncd


Installed Program: rsync and rsync-ssl
Installed Libraries: None
Installed Directories: Optionally, /usr/share/doc/rsync-3.2.5

Short Descriptions


is a replacement for rcp (and scp) that has many more features. It uses the rsync algorithm which provides a very fast method of syncing remote files. It does this by sending just the differences in the files across the link, without requiring that both sets of files are present at one end of the link beforehand


is a helper script used when connecting to an rsync daemon that has SSL support built in