Skip to main content

Linux - How to use rClone

Here's how to get rclone doing what rsync was doing, but with real parallelism.

1. Install it

curl https://rclone.org/install.sh | sudo bash

or via package manager ( dnf install rclone, apt install rclone, brew install rclone, etc.)

2. Configure a remote

Rclone needs a "remote" config pointing at your server. Two good options for an SSH target:

Option A: SFTP backend (works over your existing SSH setup, no extra service needed)

rclone config

Walk through the prompts:

  • n for new remote
  • name it, e.g. sfl004
  • type: sftp
  • host: sfl-lin-004
  • user: root
  • port: 22 (default)
  • leave the rest default, use SSH agent or key auth if you have it set up

Or skip the wizard and write it directly to ~/.config/rclone/rclone.conf:

[sfl004]
type = sftp
host = sfl-lin-004
user = root

3. Run the sync

rclone sync /opt/kiwi/rev/ sfl004:/opt/kiwi/rev/ \
  --progress \
  --transfers=32 \
  --checkers=32

Key flags, and why:

  • sync — makes destination match source (like rsync -a, deletes extras on dest). Use copy instead if you don't want deletions.
  • --transfers=32 — number of files transferred in parallel. This is the big one for many-small-files workloads; rsync can't do this natively. Tune based on file count/CPU — 16–64 is a common range.
  • --checkers=32 — parallel workers for comparing file existence/size/hash before transfer.
  • --progress — live stats, like rsync's -P.

4. Useful additions

rclone sync /opt/kiwi/rev/ sfl004:/opt/kiwi/rev/ \
  --progress \
  --transfers=32 \
  --checkers=32 \
  --stats=5s \
  --stats-one-line \
  --exclude ".git/**" \
  --dry-run
  • --dry-run — test first, see what would change without touching anything
  • --stats=5s --stats-one-line — periodic compact progress instead of a wall of text
  • --exclude — same idea as rsync's exclude patterns
  • --checksum — only if you need content-based comparison instead of size+mtime (same cost tradeoff as rsync's -c)
#LAN
rclone sync sfl004:/mnt/volume1/data_syno /mnt/volume1/data/ \
--exclude="@*" /
--exclude="#recycle" /
--multi-thread-streams=16 /
--buffer-size=128M /
--transfers=16 /
--progress /
--checkers=32 /
--sftp-concurrency=128 /
--fast-list /
--log-level=INFO /
--stats=10s
#WAN
rclone sync sfl004:/mnt/volume1/data_syno /mnt/volume1/data/ \
--exclude "@*" /
--exclude "#recycle" /
--multi-thread-streams=4 /
--buffer-size=64M /
--transfers=8 /
--progress /
--checkers=16 /
--sftp-concurrency=64 /
--fast-list /
--bwlimit=20M /
--log-level=INFO /
--stats=30s

5. If SFTP itself is the bottleneck

SFTP-over-SSH still has per-file protocol overhead. For raw speed on a trusted LAN, rclone also supports:

  • type = local on both ends if you mount the remote filesystem (NFS/etc.) — no protocol overhead at all
  • Running an rclone serve daemon on the destination for a lighter native protocol

But for your use case (SSH between two Linux boxes), the SFTP backend with high --transfers is usually the easy win — try it and compare wall-clock time against your rsync run.