Consistency checks #1321

Open
opened 2026-06-11 21:48:35 +00:00 by solverz · 5 comments

What I'm trying to do and why

Regarding the consistency checks, are all of these backed by Borg's native check functionality, or have some of them been added by Borgmatic? Which map to which Borg check flag?

archives
repository
extract
data
spot

Steps to reproduce

No response

Actual behavior

No response

Expected behavior

No response

Other notes / implementation ideas

No response

borgmatic version

No response

borgmatic installation method

No response

Borg version

No response

Python version

No response

Database version (if applicable)

No response

Operating system and version

No response

### What I'm trying to do and why Regarding the consistency checks, are all of these backed by Borg's native check functionality, or have some of them been added by Borgmatic? Which map to which Borg check flag? archives repository extract data spot ### Steps to reproduce _No response_ ### Actual behavior _No response_ ### Expected behavior _No response_ ### Other notes / implementation ideas _No response_ ### borgmatic version _No response_ ### borgmatic installation method _No response_ ### Borg version _No response_ ### Python version _No response_ ### Database version (if applicable) _No response_ ### Operating system and version _No response_
Owner
  • archives: native Borg check --archives-only (unless repository is also a check)
  • repository: native Borg check --repository-only (unless archives is also a check)
  • extract: added by borgmatic
  • data: native Borg check --archives-only --verify-data (--archives-only is omitted if repository is also a check)
  • spot: added by borgmatic

Hope that helps!

* `archives`: native Borg `check --archives-only` (unless `repository` is also a check) * `repository`: native Borg `check --repository-only` (unless `archives` is also a check) * `extract`: added by borgmatic * `data`: native Borg `check --archives-only --verify-data` (`--archives-only` is omitted if `repository` is also a check) * `spot`: added by borgmatic Hope that helps!
Author

Thank you, what is the behaviour if archives and repository are both checks?

archives: native Borg check --archives-only (unless repository is also a check)

repository: native Borg check --repository-only (unless archives is also a check)

Why is archives-only omitted? Is it not repository-only that conflicts with verify-data?

data: native Borg check --archives-only --verify-data (--archives-only is omitted if repository is also a check)

Thank you, what is the behaviour if archives and repository are both checks? archives: native Borg check --archives-only (unless repository is also a check) repository: native Borg check --repository-only (unless archives is also a check) Why is archives-only omitted? Is it not repository-only that conflicts with verify-data? data: native Borg check --archives-only --verify-data (--archives-only is omitted if repository is also a check)
Owner

Thank you, what is the behaviour if archives and repository are both checks?

Then borgmatic runs borg check without any additional flags to modify the checks, because Borg's default is to run both repository and archives checks.

Why is archives-only omitted? Is it not repository-only that conflicts with verify-data?

Similar thing here: Borg defaults to both repository and archives checks unless told otherwise. So --archives-only is omitted in order to run both. (And then --verify-data is added to do the data check as well`.)

> Thank you, what is the behaviour if archives and repository are both checks? Then borgmatic runs `borg check` without any additional flags to modify the checks, because Borg's default is to run both `repository` and `archives` checks. > Why is archives-only omitted? Is it not repository-only that conflicts with verify-data? Similar thing here: Borg defaults to both `repository` and `archives` checks unless told otherwise. So `--archives-only` is omitted in order to run both. (And then `--verify-data` is added to do the `data` check as well`.)
Author

Got it, thank you.

Is there a recommended frequency for these consistency checks?

Got it, thank you. Is there a recommended frequency for these consistency checks?
Owner

Not really. It depends on your repository size and risk tolerance. For instance, with a small repository, you can probably get away with running consistency checks every time you create a backup, e.g. daily. For larger repositories, maybe every couple weeks to monthly is more reasonable.

As for varying that frequency by check type: The checks as listed above are roughly in order from fastest to slowest, so if you've got a really large repository, you can do the fast checks more frequently and the slower checks less frequently.

I'll also add that you don't need to run every check type. You should ideally pick and choose the ones you care about and omit the others.

Not really. It depends on your repository size and risk tolerance. For instance, with a small repository, you can probably get away with running consistency checks every time you create a backup, e.g. daily. For larger repositories, maybe every couple weeks to monthly is more reasonable. As for varying that frequency by check type: The checks as listed above are roughly in order from fastest to slowest, so if you've got a really large repository, you can do the fast checks more frequently and the slower checks less frequently. I'll also add that you don't need to run every check type. You should ideally pick and choose the ones you care about and omit the others.
Sign in to join this conversation.
No milestone
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
borgmatic-collective/borgmatic#1321
No description provided.