Tiny Core Base > TCB Talk
Convenience of Using cache-clear
(1/1)
SamK:
Clearing the cache is becoming a frequent event for me. To make it more convenient I am considering adding a menu entry to FLWM.
Are there any practical (as opposed to theoretical) disadvantages to running cache-clear often?
Are there any plans to add this menu option to future versions of TC?
curaga:
No disadvantages, except that it slows down your access to files that were in cache before the clear.
SamK:
--- Quote from: curaga on February 09, 2010, 02:23:36 AM ---...it slows down your access to files that were in cache before the clear.
--- End quote ---
The access time difference is unnoticeable and quite acceptable to me; which leads to a further ideas.
* Is it possible automatically run cache-clear to a repeating schedule? For example every 15 minutes or 20 or 45 or whatever the user might consider appropriate.
* Might it be possible to set a threshold value e.g. a percentage of available RAM? If the theshold is exceeded cache-clear is automatically started
curaga:
Sure, cron is available in the base for automating tasks.
Your second point however is getting a bit redundant - caches, and freeing them when necessary, is done by the kernel already. Quite well usually, but things are tunable in /proc/sys.
Having a process looking at the used caches would just consume cpu without any benefit IMHO.
SamK:
--- Quote from: curaga on February 09, 2010, 07:34:21 AM ---Your second point however is getting a bit redundant - caches, and freeing them when necessary, is done by the kernel already. Quite well usually, but things are tunable in /proc/sys.
--- End quote ---
On my test rig the cache slowly fills up over a period of hours often to the point of rendering the system unresponsive (monitored via top). Unless the cache is cleared manually, the memory usage continues to rise. A small decrease can,of course, be obtained by closing an app.
I have begun to rely on frequently running cache-clear manually to maintain a workable environment - hence my question about the use and automation of it. Relying on the kernel to maintain it is problematical for me.
Navigation
[0] Message Index
Go to full version