Operations 5 min read

Mastering rsync: Compile and Sync Files on Embedded Boards Efficiently

This guide explains what rsync is, how to compile it for an ARM development board, configure it to avoid SIMD and other features, install the binary, and use rsync commands with options like -a, -v, -z, -u and --progress to efficiently synchronize files between the board and a PC.

Open Source Linux
Open Source Linux
Open Source Linux
Mastering rsync: Compile and Sync Files on Embedded Boards Efficiently

What is rsync?

rsync (remote sync)

is a file synchronization tool that can sync between local directories or between local and remote devices.

Unlike scp, rsync checks existing files on both sides and transfers only changed parts (by size or modification time).

Using rsync

Demonstration using a PC and a development board. Both sides must have rsync installed.

Note: Both the sender and receiver must have rsync installed.

The board lacks rsync, so we compile it from source.

Download rsync source from https://download.samba.org/pub/rsync/.

Extract, enter directory, create a temporary folder:

tar -xvf rsync-3.2.3.tar.gz
cd rsync-3.2.3/
mkdir tmp

Generate a cross‑compilation Makefile:

./configure --prefix=$PWD/tmp --host=arm-linux-gnueabihf CC=arm-linux-gnueabihf-gcc

If errors occur, disable SIMD as shown by ./configure --help and add --disable-simd (or other disables) to the configure command.

./configure --prefix=$PWD/tmp --disable-simd --host=arm-linux-gnueabihf CC=arm-linux-gnueabihf-gcc

Further errors may require disabling additional features:

./configure --prefix=$PWD/tmp --disable-simd --disable-openssl --disable-xxhash --disable-zstd --disable-lz4 --host=arm-linux-gnueabihf CC=arm-linux-gnueabihf-gcc

When configuration succeeds, a Makefile is generated.

Note: If more errors appear, adjust the configure options accordingly.

Compile and install:

make
make install

The compiled rsync binary appears in the tmp folder; copy it to the board’s /usr/bin:

scp rsync [email protected]:/usr/bin

Demonstration of rsync usage:

Create 100 files on the board, then sync to PC:

rsync -avzu --progress [email protected]:/root/test .
-a: archive mode, preserves metadata. -v: verbose output. -z: compress data during transfer. -u: skip files that are newer on the receiver. --progress: show progress.

After creating another 100 files on the board, running the same command continues syncing only the new files.

This concludes the brief guide to using rsync for efficient file synchronization on embedded devices.

Command Linersyncfile synchronizationcross-compilationEmbedded Linux
Open Source Linux
Written by

Open Source Linux

Focused on sharing Linux/Unix content, covering fundamentals, system development, network programming, automation/operations, cloud computing, and related professional knowledge.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.