Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate restic repository from one URL to another #2572

Closed
shibumi opened this issue Feb 8, 2020 · 5 comments
Closed

Migrate restic repository from one URL to another #2572

shibumi opened this issue Feb 8, 2020 · 5 comments

Comments

@shibumi
Copy link

shibumi commented Feb 8, 2020

Hi,
It would be cool if it would be possible to migrate a repository from one backup repository to another.

Let's imagine the following config:

export RESTIC_REPOSITORY=s3:s3.wasabisys.com/<my repository>

I would like to migrate the whole repository to:

export RESTIC_REPOSITORY=s3:s3.newdomain.tld/<my repository>

Is this do-able right now? If not, what is the easiest way to do this?

Problem: I don't have enough space to checkout the whole repository (and I don't even know if this is possible).

@bjoe2k4
Copy link

bjoe2k4 commented Feb 8, 2020

Easily doable, but not with restic. Use rclone instead.

https://rclone.org/

@rawtaz
Copy link
Contributor

rawtaz commented Feb 8, 2020

@shibumi You say you don't have enough space to "check out" the whole repository.

If by that you mean to "restore" the entire repository from the old S3, and then back the restored files up to the new S3, then yeah, no point in trying that.

If you mean that the new S3 doesn't have enough space to accomodate the entire old S3 repository, there's no simple way to deal with that (besides of course just making a new repository and start backing up to it, losing your history from the old one).

However, @middelink wrote some code to copy specific snapshots from one repo to another. Please see her comment and this other comment to see if it might be useful to you.

@seqizz
Copy link

seqizz commented Feb 9, 2020

If you're dealing with s3 endpoints, check out mc from Minio. It has a mirror command you might find useful. Otherwise, you can loop copying snapshots with the branch @rawtaz commented above.

@shibumi
Copy link
Author

shibumi commented Feb 9, 2020

I am overwhelmed by this much feedback. Thanks guys. I will have a look on rclone and mc.
@rawtaz yes, I meant local storage. The s3 storage is no problem. I thought about switching from wasabi.com to backblaze (I hate the wasabi.com UI.. it's awful. Although they have better pricing than blackbaze mhh)

@rawtaz
Copy link
Contributor

rawtaz commented Feb 12, 2020

I'm closing this as it's a usage question rather than a bug or feature request as it stands now. Please continue the discussion in the forum if need be :)

@rawtaz rawtaz closed this as completed Feb 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants