Restore error for multiple configurations #1160
Labels
No labels
blocked
breaking
bug
data loss
design finalized
good first issue
new feature area
question / support
security
waiting for response
No milestone
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
borgmatic-collective/borgmatic#1160
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What I'm trying to do and why
I have a Borgmatic setup with a single repository and two configurations files 'year.yaml' and 'week.yaml'. Only the 'year.yaml' contains a database configuration definition.
Database restore does work, but gives errors related to the configuration without database configuration ('week.yaml').
Steps to reproduce
Actual behavior
Expected behavior
Other notes / implementation ideas
No response
borgmatic version
2.0.7
borgmatic installation method
Container
Borg version
1.4.1
Python version
3.13.3
Database version (if applicable)
MariaDB 10.6.23
Operating system and version
Alpine 3.21.4
Thanks for filing this. The behavior you're seeing is somewhat by design... When you run an action, you're telling borgmatic: Execute this action (independently) for each borgmatic configuration file. So in the case of restore, it tries to restore the selected
--databaseonce for each config. That's why you're getting one success and one failure (resulting in an overall failure).So one thing you can do is specify
--config year.yamlalong with the rest of your command to select a particular config file. That way you're only running therestoreaction for that one config file.Awesome, that did the trick!
I must say I'm really impressed by the high quality of borg and borgmatic, glad I found it. Also documentation is very clear and helpful. Talking of documentation, you might want to add a note how to handle a multi config setup in https://torsion.org/borgmatic/docs/how-to/backup-your-databases/#database-restoration and the
--configoption.Glad to hear that did it! I'm currently revamping the documentation as part of #942, so I'll update the database restoration as you suggest as part of that work.