Ruediger Meier wrote on 12/04/2015 10:40 PM:
On Friday 04 December 2015, U.Mutlu wrote:
I think it's a double-edged sword: if user has less memory then
the integrated caching will IMO degrade the performance.
It will use as much memory as available (not more). Ideally Linux would
use always 100% memory. You've spent money for memory ... why you
wouldn't want to use it?
After ...
$ echo 3 > /proc/sys/vm/drop_caches
... my memory looks like this:
$ free -h
total used free shared buffers cached
Mem: 7.7G 1.8G 6.0G 230M 4.4M 487M
-/+ buffers/cache: 1.3G 6.5G
Swap: 1.7G 68M 1.6G
Then after ...
$ dd if=/dev/sda of=/dev/null count=8K bs=1M
... cache/buffer is filled
$ free -h
total used free shared buffers cached
Mem: 7.7G 7.6G 168M <=(1) 230M 5.6G 665M
-/+ buffers/cache: 1.3G 6.5G <=(2)
Swap: 1.7G 68M 1.6G
... and this should not change until reboot.
(1) shows that almost 100% memory is "in use"
(2) shows that it's just buffer or cache
Try the test with fsck at boot with drop_caches=0, and you will get an
illogical result as shown in my initial posting.
I'm not a friend of such default integrated system caching, it reminds
me of Windows idiocy. This is nothing but a diskcache in ram, but then
the admin should have the the freedom to set the size of the cache via
a config file in etc, for example /etc/default/cache or in /etc/default/tmpfs.
sorun yapma ;)
:-)
Rudi
--
To unsubscribe from this list: send the line "unsubscribe util-linux" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html