mkstage4
mkstage4 copied to clipboard
Progress bar
This tool is a lifesaver but with larger system installations it can take quite a while to finish and a progress bar would be very useful. For instance, when using the dd
tool this can be accomplished with fsync:
dd if=/dev/nvme0n1p3 bs=4M status=progress conv=fsync | bzip2 > /mnt/nvme1n1/backup.bz2
Are there actually any existing methods to view the progress of mkstage4?
I agree that this could be useful, though I'm not entirely sure how to do this in a way that supports the various compression algorithms. If you have a suggestion I'd be happy to review it.
Good point @TheChymera
I've switched to NixOS since Gentoo was consuming too much of my free time. Nix ecosystem also offers incredibly fast rollbacks and OS configuration switching
@TheChymera it would probably suffice to add to
TAR_OPTIONS=(
-cpP
--ignore-failed-read
"--xattrs-include=*.*"
--numeric-owner
--checkpoint=.500
"--use-compress-prog=${COMP_OPTIONS[*]}"
)
@antonellocaroli that just prints a period every 0.5 seconds, not really a progress bar since it's not relative to anything. Not sure if tar
can even correctly guess how far into the operation it is.
I guess the --checkpoint-action
parameter might be usable to contrive something, but this and other approaches I could track down, seem to gobble stdout, which is quite vital to notify you of any files that might have changed while reading...