On 3/8/21 5:52 am, Frank Steinmetzger wrote: > Am Mon, Aug 02, 2021 at 01:38:31PM +0800 schrieb William Kenworthy: > >>> Yup. Today I did my (not so) weekly backup and rsynced the repo to the new >>> drive. After that I wanted to compare performance of my old 3 TB drive and >>> the new SMR one by deleting a snapshot from the repo on each drive. But Borg >>> objected on the second deletion, because “the cache was newer”. But that’s >>> okay. I actually like this, as this will prevent me from chaning two repos >>> in parallel which would make them incompatible. >>> >> Keep in mind that both repos have the same ID - you should also rsync >> the cache and security directories as well as they are now out of sync >> (hence the warning). > That thought crossed my mind recently but I was unsure how to store the > cache. But since the repo is a monolith, it should suffice to rsync > the whole cache directory to the backup drive (or do it as a tar). > > The only problem is the temporal sequence: > 1. Host A runs borg and gets a current cache. > 2. Host B runs borg on the same repo and gets a current cache. > 2a. Host A now has an outdated cache. > > Usually, Host B uses Host A via ssh as remote location of the repository. > So I could simply run a borg command on Host A to update the cache somehow. > >> Be very careful on how you do this - you are one step away from losing the >> while repo if the cache gets out of sync. The docs warn against rsyncing >> two repos and then using them at the same time for a good reason. > I won’t use them at the same time. It will always be one direction: > Hosts --[borg]--> Main backup drive --[rsync]--> secondary backup drive > You could delete and rebuild the cache each time (or I think there is a way to do without it). There are quite a few threads on the borg lists about this in the past (usually people trying to recover trashed repos) - you might ask there if there is a way to deal with changing the ID now?
In any case, I think doing it the way you are has a fairly high chance you will irretrievably trash both repos. BillK