Hello List, i have got a large File-List which looks like this: ...snip... 165/165950*.jpg 166/166072*.jpg ...snap.... Now i would like to transfer only those file from that list. The rsync command: rsync -avz -F --files-from=/tmp/synclist-small.txt /mnt/ /data/ does not seem to work due to that wildcard. The command: rsync -avz -F --include-from=/tmp/synclist-small.txt /mnt/ /data/ syncs every files, not just the ones from my list. If i change my file list to: ...snip... + 165/165950* + 166/166072* - * ...snap... then everything gets excluded. Could someone give me a hint here?? Thanks, Mario
In <AANLkTim93g-cp9obGhZE3JX8JRNwELYJOe=WHTHR5hRb at mail.gmail.com>, on 10/22/10 at 11:30 AM, ml ml <mliebherr99 at googlemail.com> said: Hi listee,>If i change my file list to: >...snip... >+ 165/165950* >+ 166/166072* >- * >...snap...This is a common use case. Read the man page section titled INCLUDE/EXCLUDE PATTERN RULES and find the part that reads + /some/ + /some/path/ + /some/path/this-file-is-found + /file-also-included - * It should help you understand how to set up the filter rules you need. The docs discuss a couple of other ways to solve this problem. Regards, Steven -- ---------------------------------------------------------------------- "Steven Levine" <steve53 at earthlink.net> eCS/Warp/DIY etc. www.scoug.com www.ecomstation.com ----------------------------------------------------------------------
Hello, it seems it does not transfer my files recursively: My Files and Folders: mario at mario-laptop:~/foo2$ find . . ./include.txt ./file-also-included ./path ./path/this-file-is-found ./some My rsync command: rsync -avnz --recursive --include-from="include.txt" * bar cat include.txt + /some/ + /some/path/ + /some/path/this-file-is-found + /file-also-included - * rsync -avnz --recursive --include-from="include.txt" * bar sending incremental file list created directory bar file-also-included some/ sent 89 bytes received 19 bytes 216.00 bytes/sec total size is 0 speedup is 0.00 (DRY RUN) Why does it not transfer the files recursively? Cheers, Mario On Fri, Oct 22, 2010 at 8:11 PM, Steven Levine <steve53 at earthlink.net> wrote:> In <AANLkTim93g-cp9obGhZE3JX8JRNwELYJOe=WHTHR5hRb at mail.gmail.com>, on > 10/22/10 > ? at 11:30 AM, ml ml <mliebherr99 at googlemail.com> said: > > Hi listee, > > >>If i change my file list to: >>...snip... >>+ 165/165950* >>+ 166/166072* >>- * >>...snap... > > This is a common use case. ?Read the man page section titled > INCLUDE/EXCLUDE PATTERN RULES and find the part that reads > > ? ? ? ? ? ? ?+ /some/ > ? ? ? ? ? ? ?+ /some/path/ > ? ? ? ? ? ? ?+ /some/path/this-file-is-found > ? ? ? ? ? ? ?+ /file-also-included > ? ? ? ? ? ? ?- * > > It should help you understand how to set up the filter rules you need. > > The docs discuss a couple of other ways to solve this problem. > > Regards, > > Steven > > -- > ---------------------------------------------------------------------- > "Steven Levine" <steve53 at earthlink.net> ?eCS/Warp/DIY etc. > www.scoug.com www.ecomstation.com > ---------------------------------------------------------------------- > > -- > Please use reply-all for most replies to avoid omitting the mailing list. > To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync > Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html >
On Mon, Oct 25, 2010 at 1:18 AM, ml ml <mliebherr99 at googlemail.com> wrote:> Why does it not transfer the files recursively? >Because your exclude (- *) is not anchored, so it matches the deeper files. You can either anchor it (- /*) or specify your prior includes with "**" or "***" components. e.g. "+ /path/***" would include both path (+ /path/) and its contents (+ /path/**). ..wayne.. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.samba.org/pipermail/rsync/attachments/20101028/5636420d/attachment.html>
Possibly Parallel Threads
- Kernel Error with Debian Squeeze, DRBD, 3.2.0-0.bpo.4-amd64 and Xen4.0
- Cannot get the syntax of --include-from right
- rsync keeps writing files over
- cannot rsync when source directory lacks write permission
- DO NOT REPLY [Bug 5401] New: getpassf() should honor strict modes