Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,8 @@ BACKUP_SFTP_CONNECTIONS=2
# Optional upload cap in KiB/s for restic and the mirror, e.g. 5000 (about 40 Mbit/s).
# Empty = uncapped. Useful while the first upload of a large library runs.
BACKUP_LIMIT_UPLOAD_KBPS=
# Progress lines in the backup log, per second: 0.0166 is one a minute. 0 for none.
RESTIC_PROGRESS_FPS=0.0166
BACKUP_CRON_SCHEDULE=0 * * * *
BACKUP_KEEP_HOURLY=48
BACKUP_KEEP_DAILY=14
Expand Down
3 changes: 3 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,9 @@ services:
# Parallel SFTP connections, and an optional upload cap in KiB/s (empty = none).
- BACKUP_SFTP_CONNECTIONS=${BACKUP_SFTP_CONNECTIONS:-2}
- BACKUP_LIMIT_UPLOAD_KBPS=${BACKUP_LIMIT_UPLOAD_KBPS:-}
# restic shows no progress when its output is a log rather than a terminal, so a
# day-long first upload was silent from start to finish. One status line a minute.
- RESTIC_PROGRESS_FPS=${RESTIC_PROGRESS_FPS:-0.0166}
- BACKUP_CRON_SCHEDULE=${BACKUP_CRON_SCHEDULE:-0 * * * *}
- BACKUP_KEEP_HOURLY=${BACKUP_KEEP_HOURLY:-48}
- BACKUP_KEEP_DAILY=${BACKUP_KEEP_DAILY:-14}
Expand Down
7 changes: 7 additions & 0 deletions ops/backup/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -424,6 +424,13 @@ repository lock.
The first run sends the whole library, which over a home line can take most of a day
(restic prints an ETA). Later runs send only what changed, in minutes.

- **The log prints one progress line a minute** (`[1:23:45] 12.34% … files … ETA …`;
`RESTIC_PROGRESS_FPS` in `.env` changes the rate). Between them it is quiet, not
stuck. A `previous run still going, skipping` line from an hourly tick is proof the
run is alive: it is printed only while the run holds its lock. To see how much has
landed on the NAS, `docker compose exec backup rclone size nas:/GeckoNotes/gam/restic`
(your `BACKUP_SFTP_REMOTE_PATH`), a few minutes apart; or watch NET I/O climb in
`docker stats gam-backup-1`.
- **If it dies, run the same `exec` line again.** restic saves its index as it goes, so
what already reached the NAS is not sent twice; the rerun picks up roughly where the
last one stopped. The dead run's leftover repository lock is cleared automatically.
Expand Down
Loading