Initial B2 backup gone horribly wrong


I started backing up approx 700gb earlier this week but became suspicious when the bucket went above 700gb. It was then I discovered that I had somehow managed to run two copies of the backup script simultaneously…doh! I didn’t even think this was possible…shouldn’t it have been locked?

I killed one of the processes but unsure where this leaves me, should I leave the other process running to completion? My worry is how do I remove the unneeded data? Would the prune command do that or should I delete the bucket and start again?

Thanks for any advice.


Backup takes a shared lock, not an exclusive lock. This is intended and permits multiple parallel backup operations to the same repository. (This may be particularly desirable when more than one machine backs up to the same repository.)


Precisely; run prune when the backup completes and restic will discard the duplicate data.


Hmmm… how did I miss that. I wish I had realized :slight_smile: I gave up having a shared repository as I thought I was going to have locking issues with multiple machines accessing it.

Don’t guess there is an easy way to merge two repositories to gain the dedupe?

Thanks for a great tool!


If the master key is the same (you ran restic init once, copied that directory structure, and used both repos) then yes – you can merge the two directory structures and prune.

But I’m guessing you ran restic init twice on two different directories (the sane thing to do, after all) so no, there isn’t a way to merge them today.