1 Commits
Author SHA1 Message Date
lotherkandClaude Opus 5.5 68f11cc393 mcde: backup by BorgBackup to a disk of its own, with a watcher for space
McdeSys gets the backup (lib/McdeSys/backup.c): a partition becomes the
backup disk with an encrypted repository (borg init -e repokey-blake2);
every hour root's crontab runs dtbackup run: borg create of / (and /home)
on its own file systems, lz4, then prune -- 24 hourly, 30 daily, 52
weekly, every monthly unless set otherwise (keep_* in
/etc/mcde-backup.conf, -1 keeps every one) -- and compact.  The watcher:
before and after each run, while the backup disk has less than min_free
percent free (10 unless set), the oldest backup is deleted and the space
given back; the newest is never deleted.  Listing (borg list --json) and
restoring a path into a folder (borg extract).  The passphrase lives in
/etc/mcde-backup.pass, root's alone, handed over by BORG_PASSCOMMAND.
docs/reference/borg.txt from borg 1.4.5's own documentation.

dtbackup run | status | list: the same from a shell and for cron, no X.

Measured: builds on the Linux host and compiles in the build VM; as a
user dtbackup status says no disk is set up and dtbackup run refuses.
Not measured: a real backup -- borg is not on the host and goes into the
set with the next userland.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-11 13:49:38 +00:00