[pbs-devel] applied: [PATCH v3 proxmox-backup] partial fix #5560: client: periodically show backup progress
Christian Ebner
c.ebner at proxmox.com
Fri Oct 18 10:33:20 CEST 2024
On 10/18/24 09:53, Thomas Lamprecht wrote:
> Am 18/10/2024 um 09:37 schrieb Christian Ebner:
>> One thing still came to mind yesterday though:
>> Progress logging is now enabled unconditionally, and as is it is not
>> possible to disable it or configure the interval.
>>
>> So I plan to send a patch to make the progress log output opt-in, and
>
> Personally I'd prefer opt-out, I'm not a fan of tools that stay silent
> by default (looking at you `dd`).
>
> Tools can always turn this off easily, and we already have some output
> so it's not like we'd previously have none and now suddenly print stuff,
> which might indeed surprise some existing users that relied on no output
> (IMO a bit weird thing to do, but well not completely out of the picture)
Ack'ed, so let's keep the current default progress log output interval
of 60 seconds and make it opt-out by allowing to set the interval to 0.
Disabling should however be possible, as the backup upload writer stream
might be used in other places as well, having unintentional side effects
(e.g. the sync job in push direction will use the same code path).
>
>> make the interval configurable within a meaningful value range (maybe
>> within 0s to 3600s?).
>>
>> Something like:
>> ```
>> proxmox-backup-client backup root.pxar:/ --progress-log-interval=10
>> ```
>>
>> And disable progress log output for a value of 0 or the optional
>> parameter is not given.
>>
>> That would also allow to more flexibly control the behavior when being
>> invoked by vzdump.
>>
>> What are your opinions on that?
>
> Minus the s/opt-in/opt-out/ preference that's fine by me. We could then
> also switch to a higher reporting rate in PVE, albeit FWIW, for VM backups
> there we use 10s and then slow down after some time, trying to take a
> balance for early fast feedback and short backups and long backups.
> And just throwing out ideas, one could also do a size-related interval,
> like print a report every (at least) X MB or GB uploaded.
Hmm, that would be nice to have, maybe allow to pass either a `TimeSpan`
or a `HumanByte` for the log interval parameter? Not sure if parsing
would work without possible value clashes though (e.g. 4M could be 4
months or 4 MiB...).
But maybe that is overkill and not so user friendly, the better option
being to set either time or size based intervals by (yet another) flag.
> Oh, and do you plan to take a TimeSpan as interval parameter? Might
> provide nice UX here.
That is a great idea!
More information about the pbs-devel
mailing list