DO NOT REPLY [Bug 4082] RFE: prioritize work by size (or other criteria)

samba-bugs at samba.org samba-bugs at samba.org
Mon Sep 11 22:20:43 GMT 2006


https://bugzilla.samba.org/show_bug.cgi?id=4082





------- Comment #1 from hashproduct+rsync at gmail.com  2006-09-11 17:20 MST -------
I agree that it would be useful if rsync could process files in an order
specified by the user.  However, I think individual prioritization algorithms
are not rsync's job.  Thus, I support the idea of wrapper scripts.

In the meantime, you might be able to use a hack along the following lines to
control the transfer order.  Create ten symlinks named "0" through "9" in the
root directories of the source and the destination; they should all link to
".".  Run two passes of rsync.  The first deals with everything except
transfers of regular files; to do this, specify contradictory --max-size and
--min-size.  Then run a script that finds all regular files and assigns each a
priority expressed as an integer with the same number of digits.  Insert
slashes in the output so you get paths like "0/4/2/foo/bar" for a file at
"foo/bar" of priority 042.  Feed these paths to the second pass of rsync using
--files-from, and be sure to use --no-implied-dirs.  When rsync sorts the file
list, it effectively sorts according to your priorities.


-- 
Configure bugmail: https://bugzilla.samba.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug, or are watching the QA contact.


More information about the rsync mailing list