Bug 13071 - [PATCH] Allow --partial-dir with --inplace
[PATCH] Allow --partial-dir with --inplace
Status: NEW
Product: rsync
Classification: Unclassified
Component: core
All All
: P5 normal
: ---
Assigned To: Wayne Davison
Rsync QA Contact
Depends on:
  Show dependency treegraph
Reported: 2017-10-04 18:17 UTC by Ben RUBSON
Modified: 2018-02-13 20:15 UTC (History)
0 users

See Also:

Allow partial-dir with inplace (5.46 KB, patch)
2017-10-04 18:17 UTC, Ben RUBSON
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ben RUBSON 2017-10-04 18:17:36 UTC
Created attachment 13649 [details]
Allow partial-dir with inplace


Here is a patch to allow partial-dir with inplace.

Why ?

Quoting modified man-page :
If --inplace is used with --partial-dir, or with any option implying it (--delay-update), the inplace behavior will take place in the partial directory, each file being moved to its final destination once completed.

It really helps when one want to keep partial files but don't want rsync server to duplicate them remotely when transfer is restarted. Partial files will then be used "inplace", in the partial directory.
Really useful in conjunction with for example --link-dest.
More generally this helps saving space / dealing with short free-space targets.

Could we then think about reviewing and merging this please ?

Thank you very much !


(this patch has been written so that current client versions can easily benefit from this using --temp-dir to indicate their partial directory, server code being really easy to modify to take tmpdir as partial_dir)
Comment 1 Ben RUBSON 2018-02-13 20:15:31 UTC
Tested and still correctly works with rsync 3.1.3.
Thx !