Thread (16 messages) 16 messages, 6 authors, 2016-02-16

Re: [PATCH] kernel: fs: drop_caches: add dds drop_caches_count

From: Theodore Ts'o <tytso@mit.edu>
Date: 2016-02-16 00:45:31
Also in: linux-fsdevel, lkml

On Mon, Feb 15, 2016 at 03:52:31PM -0800, Daniel Walker wrote:
quoted
quoted
We need it to determine accurately what the free memory in the
system is. If you know where we can get this information already
please tell, we aren't aware of it. For instance /proc/meminfo isn't
accurate enough.
Approximate point-in-time indication is an accurate characterization
of what we are doing. This is good enough for us. NO matter what we
do, we are never going to be able to address the "time of check to
time of usea?? window.  But, this approximation works reasonably well
for our use case.
Why do you need such accuracy, and what do you consider "good enough".
Having something which iterates over all of the inodes in the system
is something that really shouldn't be in a general production kernel
At the very least it should only be accessible by root (so now only a
careless system administrator can DOS attack the system) but the
Dave's original question still stands.  Why do you need a certain
level of accuracy regarding how much memory is available after
dropping all of the caches?  What problem are you trying to
solve/avoid?

It may be that you are going about things completely the wrong way,
which is why understanding the higher order problem you are trying to
solve might be helpful in finding something which is safer,
architecturally cleaner, and something that could go into the upstream
kernel.

Cheers,

						- Ted

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help