rdiff-backup (GNU) Cheatsheet #
The rdiff-backup
command is used for incremental backups and restores in Unix-like operating systems.
Basic Commands #
Command/Option | Example | Description |
---|---|---|
rdiff-backup src dest | rdiff-backup /home/user /backup | Backup /home/user to /backup |
rdiff-backup --restore-as-of 2024-01-01 src dest | rdiff-backup --restore-as-of 2024-01-01 /backup /restore | Restore /backup to its state as of January 1, 2024 |
rdiff-backup -r now src dest | rdiff-backup -r now /backup /restore | Restore the most recent backup from /backup to /restore |
rdiff-backup --remove-older-than 30D src | rdiff-backup --remove-older-than 30D /backup | Remove backups older than 30 days from /backup |
Advanced Options #
Command/Option | Example | Description |
---|---|---|
rdiff-backup --exclude-file-globbing-file=file.txt src dest | rdiff-backup --exclude-file-globbing-file=exclude.txt /home/user /backup | Exclude files listed in exclude.txt from backup |
rdiff-backup --check-destination-dir src dest | rdiff-backup --check-destination-dir /home/user /backup | Check that the destination directory is valid |
rdiff-backup --print-statistics src dest | rdiff-backup --print-statistics /home/user /backup | Print statistics about the backup operation |
This cheatsheet covers essential GNU rdiff-backup
options for performing and managing incremental backups.