Created attachment 11508 [details] Show progress information when SIGINFO is caught The attached patch causes the receiver to show the current file name and the progress line (same output as --progress) when SIGINFO (traditionally bound to ^T on ttys in BSD derivatives) is caught. Compare with, for instance, tcpdump, which prints statistics (the same information that it usually prints when you kill it) on SIGINFO.
Created attachment 11509 [details] Show progress information when SIGINFO is caught Updated patch eliminates compiler warning on platforms that lack SIGINFO.
What are the prospects for getting this committed? It works fine on FreeBSD & OSX applied to the latest Samba release and it's quiiiite handy.
This is a cool idea, but I hadn't taken the time (before today) to tweak it to make it work just right. As written it only output status on a pull, not a push (and thus not for a local copy which uses the push idiom internally). It also had a bug in the output of the file counts (the to-chk=N/TOTAL values) since we now need to set the file index values even when --progress isn't enabled (since a progress output can happen at any time now). I also made it not output the file name again if rsync is running with -v or -i and a status request comes in (it now outputs just the status line under the existing filename). I also wanted it to be able to work for Linux, so I decided to enable the instant progress output on SIGVTALRM as well as SIGINFO (since Linux doesn't support SIGINFO). Finally, I decided to change the type of status that gets output to the total-transfer info that is output when using --info=progress2. This gives you the total file size processed, percent of finished file sizes vs total file sizes (for known files), and the average speed of all received data since the start of the transfer (this is both because the show_progress() calls are not being made and because I think the total-transfer stats are more useful in this sporadic display).