Error while parsing a configuration file: Key 'compression' was not defined. Path: '/location' #133
Labels
No Label
bug
data loss
design finalized
good first issue
new feature area
question / support
security
waiting for response
No Milestone
No Assignees
3 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: borgmatic-collective/borgmatic#133
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
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?
I installed borgmatic on Arch Linux from AUR: https://aur.archlinux.org/packages/borgmatic/
If I uncomment
compression: lz4
in the configuration file I get an error when I run borgmatic.Step to reproduce:
Create a borg repository:
Generate a borgmatic config file:
$ generate-borgmatic-config -d /tmp/borgmatic/config.yaml
In
/tmp/borgmatic/config.yaml
edit onlysource_directories
andrepositories
:Make a backup with
$ borgmatic --config /tmp/borgmatic/config.yaml
and it works.Now edit
/tmp/borgmatic/config.yaml
and uncommentcompression: lz4
Make a backup with
$ borgmatic --config /tmp/borgmatic/config.yaml
and it doesn't works.This is the error:
compression
is a child ofstorage
(notlocation
as the checker claims).Did you by any chance forget to uncomment
storage
? This happened to me last week, too.I think @sdellenb is correct here. While the error message could be more helpful, it's basically the validator's way of saying "Uh, there's this key
compression
in thelocation
section, and I don't expect acompression
key there."Let us know if uncommenting the
storage:
section fixes this for you.Yes, you're right! Thank you very much @sdellenb and @witten!
I uncommented
storage:
and now it works.Sorry about that, but I'm new to yaml and I had not noticed the
storage:
line.No worries! Glad that did it.