[pbs-devel] [PATCH v2 proxmox-backup] partial fix #5560: client: periodically show backup progress

Gabriel Goller g.goller at proxmox.com
Thu Oct 10 12:50:21 CEST 2024


On 09.10.2024 11:20, Christian Ebner wrote:
>Spawn a new tokio task which about every minute displays the
>cumulative progress of the backup for pxar, ppxar or img archive
>streams. Catalog and metadata archive streams are excluded from the
>output for better readability, and because the catalog upload lives
>for the whole upload time, leading to possible temporal
>misalignments in the output. The actual payload data is written via
>the other streams anyway.
>
>Add accounting for uploaded chunks, to distinguish from chunks queued
>for upload, but not actually uploaded yet.
>
>Example output in the backup task log:
>```
>...
>INFO:  root.pxar: elapsed 60.00 s, new: 191.446 MiB, reused: 0 B, total: 191.446 MiB, uploaded: 13.021 MiB (compressed 5.327 MiB, average: 222.221 KiB/s)
>INFO:  root.pxar: elapsed 120.00 s, new: 191.446 MiB, reused: 0 B, total: 191.446 MiB, uploaded: 27.068 MiB (compressed 11.583 MiB, average: 230.977 KiB/s)
>INFO:  root.pxar: elapsed 180.00 s, new: 191.446 MiB, reused: 0 B, total: 191.446 MiB, uploaded: 36.138 MiB (compressed 14.987 MiB, average: 205.58 KiB/s)
>...
>```
>
>This partially fixes issue 5560:
>https://bugzilla.proxmox.com/show_bug.cgi?id=5560
>
>Signed-off-by: Christian Ebner <c.ebner at proxmox.com>
>---
>Changes since version 1, thanks Gabriel for comments and testing:
>- Abort progress output task when upload stream is finished
>- Limit output to pxar, ppxar or img archives for cleaner output
>- Adapted commit title and message
>
> pbs-client/src/backup_writer.rs | 98 +++++++++++++++++++++++++++++----
> 1 file changed, 86 insertions(+), 12 deletions(-)

LGTM! Tested this through a few times and the output is way cleaner now.
Consider: 

Tested-by: Gabriel Goller <g.goller at proxmox.com>





More information about the pbs-devel mailing list