I have a follow up question to 377448, but not enough rep to comment there.
Before I get dinged for asking the same dumb question, let me say I've been reading a lot of similar posts and answers regarding caching, and I understand what's going on there, but I haven't found an answer that fits my context. Which is this;
VirtualBox, contrary to what its documentation currently says, doesn't allocate the full base memory from the host when the guest VM launches, but allocates it as the guest demands. Rather than tuning and bench marking and re-tuning the base memory to fit the ever changing VM, I allocated it more than enough - 4 Gig.
What I've noticed is that shortly after boot, the VM consumes about 2 Gig, but that over time, even if the apps running in the VM are largely idle, the linux memory caching slowly balloons until the 4 Gig limit is reached.
Since the RAM on the laptop is precious and my processing (performance) demands are low, I added a cron @reboot command like so;
@reboot root while true; do sleep 1; /sbin/sysctl -w vm.drop_caches=3; done
which eliminates the continual growth in a way that doesn't noticeably degrade performance. 1 second intervals might be too aggressive, but I'll experiment with that later.
I'm pretty happy with the result, but this solution seems like a brutish hack.
Is there an existing method for configuriong the memory caching as 'lazy'/'aggressive' or 'high performance'/'low performance' or by providing some cache size limit, or cache purge interval?