[Borgbackup] Is it possible to encrypt and existing unencrypted borg repository?

Advrk Aplmrkt avkaplmkt at gmail.com
Fri Apr 3 15:15:01 EDT 2020


Thank you!

Can you clarify the step " use mc to copy from unencrypted mount to new repo"?

I can't find the `mc` command in my terminal (would `cp` work?). Also,
did you mean I mount the old backup somewhere, and ask borg to back up
the mounted files into the new, encrypted repo?

If so, this will probably work to achieve most of my goals, but doing
it this way means the *history* of all of my backups will not be
migrated unless I manually mount each backup in the old repository and
back it up into the new one? Sounds tedious considering I have a lot
of backups in the old repo!

On 02/04/2020, Bzzzz <lazyvirus at gmx.com> wrote:
> On Thu, 2 Apr 2020 20:03:18 +0100
> Advrk Aplmrkt <avkaplmkt at gmail.com> wrote:
>
>> Hello,
>
> Hi
>
>> I have an old borg repository (last used with version 1.1.10) that
>> doesn't have encryption. I would like to keep the archives in this
>> repository, but I'd prefer to "upgrade" the repository so that is uses
>> encryption. Can this be done? If so, how? If not, is there anyway to
>> migrate the data in this repository to a new one that has encryption?
>>
>> From what I can tell, encryption is applied at the very beginning when
>> using the `borg init` command. But is there a way around this? Sorry
>> if I missed something obvious in the documentation, if so please
>> correct me. Thank you very much.
>
> I'd say the fastest would be:
>
> * create a new & encrypted repo
>
> * borg mount old_backup::backup#1 /somewhere
>
> * use mc to copy from unencrypted mount to new repo
>
> * borg mount new_backup::backup#1 /other_place
>
> * randomly test if everything's right
> 	cmp /somewhere/path/file1 /other_place/path/file1
>
> * iterate N times where N=Nb_backups
>
> All operations one the server machine, of course.
>
> Jean-Yves


More information about the Borgbackup mailing list