Rsync shouldn't display a meaningless speedup on a dry run

Matt McCutchen matt at
Wed Nov 7 04:18:08 GMT 2007

On Tue, 2007-11-06 at 22:22 -0500, foner-rsync at wrote:
> I worry about those trying to write things that parse rsync's output;
> if -n changes the output format, such things will have to be tested on
> live data.

No, just run rsync's output through a sed script that adds the desired
speedup to the last line.

> Is it possible (e.g., without ridiculous amounts of code-massaging) to
> have -n output the speedup (or some more-reasonable estimate) anyway?
> Sure, all kinds of differences haven't been computed, but...

Rsync could estimate an upper bound on how much a real run might send by
adding the size of the data that wasn't transferred (regular file data
and abbreviated xattrs) to the amount the dry run sent, but I'm not sure
the resulting value would be useful enough to make this worthwhile.

> Or maybe
> just have it report a speedup of 1.00 instead?  Still misleading, but
> it preserves the output format and is trivial to write (but still,
> alas, confusing for the user, so this doesn't fill me with glee).

That lie would be no improvement over the current one.


More information about the rsync mailing list