iam-sysop / cachemon Goto Github PK
View Code? Open in Web Editor NEWWindows 10 Standby Cache Monitor and Flusher
License: GNU General Public License v3.0
Windows 10 Standby Cache Monitor and Flusher
License: GNU General Public License v3.0
Hey, great work.
Haven't tried this tool yet but I have been using RamMap64.exe to GREAT results. (in my experience RamMap seems to clean a bit more than using the stand-alone EmptyStandbyList.exe app for some reason, which the additional benefit of being a mouse button press, instead of having to type command lines)
I started experimenting with it but I noticed after a few minutes my RAM was back into near 70% usage, which triggers pagefile usage.
Then, I stumbled on this tool called NTCacheSet (this version still works on Windows 10 1904 onwards...)
https://www.uwe-sieber.de/ntcacheset_e.html#SetSystemFileCacheSize
After using NTCacheSet and paying attention to the area marked with color Pink in RamMap (the Metafile cache) I fully realized what was going on:
Not only Windows 10 caches frequently used apps in memory (Memory Caching). Windows 10 also caches Filesystem files (go to a folder you know is populated with thousands of files and right-click into Properties, then watch that filesystem cache grow)
That is a completely separate Cache that Windows does NOT free up when system reaches full RAM usage (it prefers to use pagefile first, as you mention it)
The solution I found to this is using both RamMap64 (manually once a day) and NtCacheSet (it runs automatically in the background every X seconds)
Filesystem Cache was the culprit for the rest of free memory being exhausted.
After 8 hours of usage, I had browser with dozens of open tabs and haven't noticed my RAM going above 55% at all times, 55 at most.
You might want to add NtCacheSet functionality to your app for even more consistent results.
These are the settings I use for NtCacheSet:
(create shortcut and insert these parameters at the end)
NtCacheSet.exe /int=15000 /min=8M /max=32M /show=1
(activates each 15 seconds, this is useful for moments where the disk is busy, it works better than when I had lower interval)
I wish there was a way to at least set a hard ceiling limit for Mem Cache on Windows, that alone would avoid all these problems, would avoid all this manual labor. Automatic memory management never worked. For now, this seems to stop the recurring cycle of death that caused pagefile spikes (unnecessary writes on disk, reduces lifespan, etc)
Inside the registry location HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SysMain
there is a key called SvcMemHardLimitInMB
I've tried values of 256 and 64 for that key,
but haven't observed Mem Caching using a limited amount at all. I wish this worked.
I wonder if manually deleting sysmain.DLL file is an option to avoid mem caching entirely?
Any DPI-Aware environments do not properly render the form - text and data are garbled.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.