Optimizing Linux with cheap flash drives
Posted Feb 25, 2011 19:22 UTC (Fri) by giraffedata
In reply to: Optimizing Linux with cheap flash drives
Parent article: Optimizing Linux with cheap flash drives
How do you know you're caching these files? I don't know exactly what Linux's page replacement policy is this week, but I'd be surprised if it caches video and music files. It knows you're accessing these pages only once, so keeping them around in preference to something else would be a loss. It usually takes two accesses to a page to get it any significant priority for memory allocation. Linux also knows you're accessing the file sequentially, so it knows even sooner that it otherwise would that the pages won't be accessed a second time.
Of course, if there's absolutely nothing else worth using memory for, Linux will just go ahead and fill it with this data, just in case. But that's not a problem.
to post comments)