No description
Find a file
2026-08-12 12:17:46 +02:00
desktop Rename app link BackupJetzt to BackupNOW 2026-08-12 12:17:46 +02:00
docs Rename app link BackupJetzt to BackupNOW 2026-08-12 12:17:46 +02:00
scripts Rename app link BackupJetzt to BackupNOW 2026-08-12 12:17:46 +02:00
systemd Translate documentation and code to English, remove server-specific references 2026-08-12 12:16:30 +02:00
.gitignore Translate documentation and code to English, remove server-specific references 2026-08-12 12:16:30 +02:00
install.sh Rename app link BackupJetzt to BackupNOW 2026-08-12 12:17:46 +02:00
README.md Rename app link BackupJetzt to BackupNOW 2026-08-12 12:17:46 +02:00
uninstall.sh Rename app link BackupJetzt to BackupNOW 2026-08-12 12:17:46 +02:00

Synology Backup

Automated backup of a Linux home directory to a Synology NAS.

The scripts are deliberately kept simple so that even inexperienced admins can manage backup and restore without prior knowledge.

What this project does

  • Daily at 11:00 the entire home directory (excluding caches, games and videos) is mirrored to the NAS via rsync over ssh.
  • If the PC was powered off at that time, the backup runs automatically after booting (Persistent=true).
  • An app link "BackupNOW" in the app menu starts a backup on demand.
  • Parallel runs are prevented by a lock mechanism.
  • An interactive restore script fetches files/folders back from the NAS - always with a preview and confirmation, and it never deletes anything on the PC.

Quick start (on a new machine)

# 1. Get the repo
git clone <repo-url> synology-backup
cd synology-backup

# 2. Adjust the configuration (NAS address + target path)
nano scripts/config.env

# 3. Install (timer + app link + scripts)
./install.sh

# 4. Test
bash ~/.local/bin/backup-nas.sh

After that everything runs automatically. Details: docs/01-QUICKSTART.md

Restore

bash ~/.local/bin/restore-nas.sh

The script asks what to restore, shows a preview and asks for confirmation before overwriting. Detailed guide: docs/02-RESTORE.md

Structure

synology-backup/
├── install.sh                 ← installation / update (safe to re-run)
├── uninstall.sh               ← full uninstall (NAS stays untouched)
├── scripts/
│   ├── config.env             ← ONLY configuration, adjust here
│   ├── backup-nas.sh          ← backup (called by timer / app link)
│   ├── restore-nas.sh         ← restore (interactive)
│   └── backup-nas.exclude     ← what is NOT backed up
├── systemd/
│   ├── backup-nas.service     ← timer task
│   └── backup-nas.timer       ← daily 11:00, with catch-up
└── desktop/
    └── backup-now.desktop   ← app link "BackupNOW"

Important notes

  • The backup uses --delete: what is deleted locally will also be deleted on the NAS after the next backup. The NAS is therefore a 1:1 mirror, not a version archive.
  • Videos, cloud-synced folders, games and caches are NOT backed up - see scripts/backup-nas.exclude.
  • SSH access to the NAS is required (see docs/01-QUICKSTART.md).

More docs