https://bugzilla.samba.org/show_bug.cgi?id=9560 Summary: drop-cache option Product: rsync Version: 3.0.9 Platform: All OS/Version: All Status: NEW Severity: normal Priority: P5 Component: core AssignedTo: wayned at samba.org ReportedBy: colundrum at gmail.com QAContact: rsync-qa at samba.org Hello, Please integrate --drop-cache option in your upstream. It should allow to avoid filling up the io cache with the copied data. The current behavior pushes the cached data of other process out of the memory and slows down the system as the ram gets filled up. For exemple, I use rsync without this patch, rsync use 7GB of ram and when it's finished, cache ram is always used. When I use rsync with this patch, rsync use 7GB of ram but when it's finished, cache ram is removed and avoid an unnecessary swap. Thanks. Website of the patch : http://insights.oetiker.ch/linux/fadvise/ Patch file : http://tobi.oetiker.ch/patches/rsync-3.0.9-2-fadvise.patch -- Configure bugmail: https://bugzilla.samba.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA contact for the bug.
https://bugzilla.samba.org/show_bug.cgi?id=9560 --- Comment #1 from michael+samba at stapelberg.de 2013-04-20 17:30:31 UTC --- I hate to say ?me too?, but I would really like to see this. Is there anything I can do to help make this happen? As you can see at http://tobi.oetiker.ch/patches/, the patch is maintained since 2007! -- Configure bugmail: https://bugzilla.samba.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA contact for the bug.
https://bugzilla.samba.org/show_bug.cgi?id=9560 --- Comment #2 from Frits <frits at frinux.com> 2013-07-17 10:29:33 UTC --- "me too" yes , this would be usefull. Filling up memory with cache is not always usefull. -- Configure bugmail: https://bugzilla.samba.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA contact for the bug.
https://bugzilla.samba.org/show_bug.cgi?id=9560 Wayne Davison <wayned at samba.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |WONTFIX --- Comment #3 from Wayne Davison <wayned at samba.org> 2013-12-25 23:13:57 UTC --- Since the patch is very linux-specific and overly klugy, it is better handled by a general-purpose (linux-specific) wrapper that can be used with any copy utility. I'd suggest checking into this utility: https://github.com/Feh/nocache I've compiled/installed it and done some basic testing, and it seems to do a good job of issuing the fadvise64() calls on the files rsync opens. Some examples: nocache rsync -aiv --rsync-patch='nocache rsync' some-host:/src/ /dest/ nocache rsync --daemon -- Configure bugmail: https://bugzilla.samba.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA contact for the bug.
https://bugzilla.samba.org/show_bug.cgi?id=9560 --- Comment #4 from Wayne Davison <wayned at samba.org> 2013-12-25 23:15:46 UTC ---> nocache rsync -aiv --rsync-patch='nocache rsync' some-host:/src/ /dest/That was supposed to be --rsync-path=... -- Configure bugmail: https://bugzilla.samba.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA contact for the bug.
https://bugzilla.samba.org/show_bug.cgi?id=9560 --- Comment #5 from Michele Dionisio <michele.dionisio at gmail.com> --- Created attachment 11169 --> https://bugzilla.samba.org/attachment.cgi?id=11169&action=edit fadvice without effect on remote -- You are receiving this mail because: You are the QA Contact for the bug.
https://bugzilla.samba.org/show_bug.cgi?id=9560 --- Comment #6 from Michele Dionisio <michele.dionisio at gmail.com> --- Hi, I'm testing the patch on 3.1.1 on an embedded device with swapless linux. The patch works perfect on my application but to avoid to apply the patch also on the remote side (where I have no control) I have saparated the new command line option --drop-cache in 2: --drop-cache that works local --remote-drop-cache that works on remote I think that the patch is more or less mandatory on embedded linux machine to avoid oomkill from not o well tuned kernel and to increase general performance. regards, and many thanks -- You are receiving this mail because: You are the QA Contact for the bug.
Apparently Analagous Threads
- DO NOT REPLY [Bug 7004] New: Use posix_fadvise to free cached file contents when done
- Announce: rsync fadvise (cache dropping) patch updated
- patch to stop rsync from polluting the filesystem cache
- Re: [PATCH nbdkit] plugins: file: More standard cache mode names
- fadvise DONTNEED implementation (or lack thereof)