Backups
Tools:
- Duplicity
- Borg
Borg
Encryption through:
- Passphrase only
- Passphrase + key local
Backup is stored in repositories in archives.
Init repository
With keyfile and blake2 algorithm(Key stored in ~/.config/blake/)
borg init -e keyfile-blake2 REPO
Create archive
borg create --stats --progress -C zlib,9 /path/to/repo::{hostname}-{user}-{now:%Y-%m-%dT%H:%M:%S} [PATH...]
Extract archive
- Go to the path to restore
borg extract --list /path/to/repo::my-files
Other example commands
borg create --stats --progress -C auto,zlib,6 [BACKUP-FOLDER]::usb-full-backup-{now:%Y-%m-%dT%H:%M:%S} [FOLDER-TO-BE-BACKED-UP]
borg init --encryption=none .
borg init --compression=none .
In combination with deja-vu
:
borg create --stats --progress -C auto,zlib,6 [BACKUP-FOLDER]::{hostname}-{user}-{now:%Y-%m-%dT%H:%M:%S} [FOLDER-TO-BE-BACKED-UP] && deja-dup --backup && notify-send -t 1000 "Backup ready"
without -C
compression option the lowest default is used.
Other Borg resources
- https://asciinema.org/a/133292
- https://github.com/borgbackup/borg
- https://wiki.ubuntuusers.de/BorgBackup/
- https://wiki.hetzner.de/index.php/BorgBackup
- https://stackoverflow.com/questions/1401482/yyyy-mm-dd-format-date-in-shell-script
Full system backup
Use Clonezilla
https://www.pcwelt.de/a/backup-und-klonen-mit-clonezilla,2103167 https://clonezilla.org/show-live-doc-content.php?topic=clonezilla-live/doc/01_Save_disk_image http://wiki.ubuntu-forum.de/index.php?title=Clonezilla https://www.giga.de/downloads/ubuntu-os/tipps/ubuntu-image-backup-erstellen-und-wiederherstellen-so-geht-s/