[pbs-devel] [RFC proxmox-backup] fix #5710: api: backup: stat known chunks during backup

Christian Ebner c.ebner at proxmox.com
Tue Sep 17 13:40:57 CEST 2024


On 9/17/24 09:19, Christian Ebner wrote:
> On 9/13/24 17:23, Dietmar Maurer wrote:
>>
>>
>> Is it possible to only stat actually reused chunks at the end?
> 
> Yes, as is all the chunks, even not reused but indexed by the previous 
> backup snapshot are stat'ed.
> 
> I can add an additional flag to the hashmap's value storing known chunks
> to differentiate and only stat these.
> 
> Will send a new version of the patch.

Unfortunately, the accounting of known chunks for fixed indices when 
using the incremental mode turns out to be harder than expected.

For this case, the index is initially copied over from the previous 
snapshot and chunk digests inserted into the known chunks hashmap.
On client side, only changed chunks are uploaded via the backup api, and 
inserted in the fixed index on the corresponding index position. The 
information which previously indexed chunk it replaced is however lacking.

Because of this, I currently tend to rather not modify the current 
behavior and stat all of the known chunks.

Any thoughts on this? Is there a better approach I currently am failing 
to see?





More information about the pbs-devel mailing list