Rsync & Rsnapshot Incremental Backup with Hardlink Deduplication

Data loss from accidental deletion or failure is a risk that can halt business operations. We configure incremental backup using rsync and rsnapshot, ensuring reliable snapshot storage with hardlink-based deduplication. Our team delivers turnkey implementation—from infrastructure audit to deployment and ongoing support—so you can restore files anytime without extra costs.

Our competencies:

Frequently Asked Questions

Latest works

  • Development of a web application for FEEDME
    Development of a web application for FEEDME
    1365
  • Development of an online store for the company FURNORO
    Development of an online store for the company FURNORO
    1330
  • B2B Advance company logo design
    B2B Advance company logo design
    776
  • Development of a web application for Enviok
    Development of a web application for Enviok
    1077
  • AIDER company logo development
    AIDER company logo development
    1022
  • CRM development for Chasseurs
    CRM development for Chasseurs
    1113

Backups Are Not Copying — They Are Recovery Guarantee

Imagine a colleague accidentally deletes an nginx config, and the last full backup was a week ago. With rsnapshot, recovery takes one cp command — the file is available directly in the snapshot without decompression. We configure such systems for projects ranging from 10 to 500 servers, and rsnapshot remains the standard for bare-metal and file machines on Linux thanks to deduplication via hardlinks: disk space savings can reach 90% compared to full copies. For an average volume of 1 TB, this saves about $500 per year. On projects with 500 GB of data, savings amount to $250/year on cloud storage. Our basic rsnapshot setup starts from $500 per server, and you can expect ROI within months.

Our experience — 5 years configuring rsync+rsnapshot. We have completed over 50 backup setup projects. With over 5 years of experience and 50+ completed projects, we guarantee that your data will be accessible on any snapshot without special software, and we test every backup against your checklist. Average recovery time: 1 minute. Get a consultation on configuring rsnapshot with a recovery guarantee.

Problems rsnapshot Solves

  • Recover a randomly deleted file with a single cp command.
  • Store 30+ snapshots with minimal space usage (hardlinks).
  • Transparent monitoring: ls shows all snapshots as regular folders.
  • Version independence: rsync is available on any system.

How to Configure rsnapshot for Maximum Performance

To benefit from hardlinks, choose the right filesystem for snapshot_root. We use ext4 with the noatime option — this eliminates unnecessary writes on reads and boosts rotation speed by 20%. Ensure the partition is mounted with this option:

# /etc/fstab /dev/sdb1 /mnt/backups ext4 defaults,noatime 0 2 

Configuring /etc/rsnapshot.conf requires attention to separators — only tabs. Example base file:

config_version  1.2
snapshot_root   /mnt/backups/rsnapshot/
cmd_rsync       /usr/bin/rsync
retain          hourly  6
retain          daily   7
retain          weekly  4
retain          monthly 6
verbose         2
logfile         /var/log/rsnapshot.log
rsync_short_args -aHz
rsync_long_args  --delete --numeric-ids --relative --delete-excluded
ssh_args         -i /root/.ssh/backup_ed25519 -o StrictHostKeyChecking=no
exclude          .cache/
exclude          node_modules/
exclude          *.tmp
backup           root@web-server-01:/etc/  web-server-01/
backup           root@web-server-01:/var/www/  web-server-01/
backup           root@db-server-01:/etc/  db-server-01/
backup           root@db-server-01:/var/lib/postgresql/  db-server-01/

Step-by-Step rsnapshot Setup

  1. Install the package: apt install rsnapshot or yum install rsnapshot.
  2. Edit /etc/rsnapshot.conf for your scenario (sources, schedule).
  3. Test the configuration: rsnapshot -t daily.
  4. Run the first backup: rsnapshot hourly. Check the log for errors.

Then set up cron for automatic scheduled execution.

Why rsnapshot Is 10x More Efficient Than Plain rsync

Plain rsync with rotation copies all files every time — time- and space-consuming. rsnapshot with hardlinks updates only changed blocks and links the rest. Compare:

Method Full rotation time Space for 30 snapshots Recovery without decompression
rsync + archives 1 hour (overwrite) 30× data volume No (need tar)
rsnapshot 5 minutes (incremental) 1.1× volume (hardlinks) Yes, direct cp

rsnapshot is also 3x faster than traditional archive-based backups for restoration. Our rsync backup solution with rsnapshot configuration enables efficient incremental backup on Linux.

Cron Schedule

Snapshot frequency is chosen based on your RPO. For a typical project:

0 */4 * * * root /usr/bin/rsnapshot hourly
30 3 * * * root /usr/bin/rsnapshot daily
0 3 * * 1 root /usr/bin/rsnapshot weekly
30 2 1 * * root /usr/bin/rsnapshot monthly

When rsnapshot runs daily, it renames old snapshots, creates a hardlink copy of the last hourly.0, and runs rsync for update. The result in /mnt/backups/rsnapshot/ appears as folders with dates.

Hardlinks Explained and Why They Save 90% Space

When a file hasn't changed, rsnapshot doesn't copy it but creates a hard link to the previous snapshot. You see full copies, but space is occupied only once. In tests on static configs, savings reach 90%. This is tens of times more efficient than compression archiving. Learn more about hardlinks.

Simple Backup Freshness Monitoring

A single command checks if the latest snapshot is stale:

LAST=$(stat -c %Y /mnt/backups/rsnapshot/daily.0/)
NOW=$(date +%s)
AGE=$(( (NOW - LAST) / 3600 ))
[ "$AGE" -gt 25 ] && echo "rsnapshot daily stale: ${AGE}h"

We integrate this check into Prometheus and set up an alert if a backup fails. A full recovery runbook is part of our documentation.

Limitations of rsnapshot

Hard links work only within a single filesystem. If snapshot_root is an NFS mount, some hardlink operations are incorrect. For cloud storage, we add rclone with encryption. For databases, direct rsync of postgresql/data without pre-freeze is risky — we always run pg_dump or pg_basebackup to a separate directory first, and rsnapshot picks it up.

Turnkey rsnapshot Setup Includes

Backup verification checklist
  • [ ] rsnapshot log checked for errors
  • [ ] Latest snapshot not older than 4 hours
  • [ ] Incremental snapshot size < 500 MB (normal for configs)
  • [ ] File from snapshot recovered with cp
  • [ ] Prometheus alert triggers if backup missing > 6 hours
Component Description
Backup source audit Identify critical directories and databases
Rotation scheme design hourly/daily/weekly/monthly per your RTO/RPO
rsnapshot configuration Files, excludes, SSH keys
Monitoring setup Prometheus + alert if backup fails
Documentation Runbook with recovery commands
Team training Show how to find a file from any snapshot

Duration and Cost

Basic setup of one server takes 1–2 days. Starting from $500 per server, you get a fully tested system. Cost is calculated individually based on the number of sources and infrastructure complexity. Trusted by 20+ companies, we deliver reliable backups. Contact us — we will assess your project and offer the best solution. Get a consultation on configuring rsnapshot with a recovery guarantee. Order setup now.