backintime icon indicating copy to clipboard operation
backintime copied to clipboard

Show snapshot progress on cli

Open KUGA2 opened this issue 4 years ago • 3 comments

When i run the backintime cli, i do not see the progress. I can see it in the gui but not in cli.

There is no --verbose, and --debug only outputs the config. How can I show the progress, like rsync would show its progress?

I am using 1.1.12 on Ubuntu 18.04 (server/headless)

KUGA2 avatar Feb 06 '21 18:02 KUGA2

You can watch progress by tailing the log file as a separate process:

$ tail -f ~/.local/share/backintime/takesnapshot_.log

But a --verbose flag would indeed be useful and (I guess?) simple to implement

nodiscc avatar Mar 02 '22 23:03 nodiscc

If you have installed the BiT GUI too (backintime-qt) the the CLI does even show the system tray icon with the progress of the backup process since it is implemented as plugin:

backintime --profile-id 1 --debug backup-job 

If you see no sys tray icon this is subject to an open bug (#1306).

I am using 1.1.12 on Ubuntu 18.04 (server/headless)

In this case I assume you have not installed the BiT GUI and a sys tray icon cannot be shown.

Your are proposing a useful feature and I will implement it when I find the time (other bug fixes have higher prio ATM)

aryoda avatar Nov 20 '22 21:11 aryoda

Implementation hint:

I think this could easily be implemented at each call of filterRsyncProgress() (which updates a temporary progress file and includes "progress" percentage value in the regexp match group m.group(2)):

https://github.com/bit-team/backintime/blob/88d19d42e9128f60b8952a64ed1fff23bd28108f/common/snapshots.py#L750-L778

This function called exactly twice: In takeSnapshot and in restore so it is quite easy to write console output whenever the progress percentage changes...

aryoda avatar Nov 20 '22 22:11 aryoda