Allow remote sources in config #99
Labels
No Label
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#99
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?
Is there a reason why borgmatic allows remote borg repositorys as a destination but no remote folders as a source? I would like to use borgmatic on my backup server to "pull" files from one or several other servers, and borg itself should support this situation.
Am I doing anything wrong with having either
user@example.com:/path/to/folder
orssh://user@example.com:/path/to/folder
? I always get[Errno 2] No such file or directory
Thanks for the question.. A remote "pull"-based source isn't something I've tried before. I'll give it a shot and see if I can reproduce locally.
Based on the Borg documentation, it doesn't look like using remote sources is supported directly/automatically. Instead, the docs suggest to use an sshfs mount to mount the remote host as if it were a local path. At that point, you can invoke
borg create
as per usual on a local path:So if you wanted to do this with borgmatic, my recommendation would be to make use of the hooks feature. Basically, you would create the sshfs mount in a
before_backup
hook, and then unmount in theafter_backup
hook.Something like (totally untested):
Let me know if that works for your use case.
Thanks for your answer! Then I didn't get that correct from the borg documentation, but I already thought of using sshfs as an alternative, your proposal sounds like a good possibility!
Cool. Feel free to follow up here and let me know how it works out.
Just for documentation, what I've been doing now, if storage space is not an issue, is copying the remote location to a local folder using rsync, which is very fast detecting and copying only the changes, and backing-up that local folder. Even file dates, etc. can be preserved using the
rsync -a
option.Okay, that sounds like it'll work. Note that you could also do that with borgmatic hooks if you so desired.