Re: fadvise DONTNEED implementation (or lack thereof)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Nov 3, 2010 at 10:58 PM, Ben Gamari <bgamari.foss@xxxxxxxxx> wrote:
It looks like a fewÂfolks have discussed addressing the issue in the past, but nothingÂhas happened as of 2.6.36.

Yeah, the linux code for this has long been buggy and near useless. ÂWhat is really needed is a way for some file access to be marked as generating low-priority cache data into the filesystem cache. ÂSuch a flag should only apply to newly cached data, so that copying a file that was cached by some other program would not lower its cache priority (nor kick it out of the cache). ÂIf some other process comes along and reads from the low-priority cache with a normal-priority read, it should get upgraded to normal priority. ÂSomething like that seems pretty simple and useful.

As for rsync, all current implementations of cache dropping are way too klugey to go into rsync. ÂI'd personally suggest that someone create a linux-specific pre-load library that overrides read() and write() calls and use that when running rsync (or whatever else) to implement the extreme weirdness that is currently needed for cache twiddling.

..wayne..

[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]