Page 1 of 1

Primocache doesn't work on the file just written.

Posted: Sun Dec 24, 2023 9:17 am
by arrenwu
OS: Windows 10 Pro 22H2
PrimoCache Version: 4.3.0

Setting
I set up a cache task for a Windows storage space (Mirror) with
  • 1GB L1 write-only cache and
  • 200GB L2 read-only cache.

Problem
If I have a file just newly-written to that storage space, I can see L1-cache is written.
However, when I read that file, PrimoCache GUI shows no read request to the storage space.
The issue here is: the file is not written into L2 cache after it's read.

I think the root-cause is that at the moment the file was written, it's already in the memory cache of windows.
Reading the file immediately after it's written touches only the memory cache and thus no request to the storage space is sent.
This theory can be consolidated by the fact that if I use RMMMap to clear standy memory, which includes the file cache, and then read the file, I can see the value of "Cached Read" in PrimoCache GUI increase and slight later the "L2Storage Write" also increases by the same amount of data.

I feel annoyed that the latest read on a file doesn't guarantee it's cached in L2Storage.
I also see in the doc of PrimoCache suggests keep Write-caching on the disk turned on. I wonder if we have some approach to deal with this issue?

Re: Primocache doesn't work on the file just written.

Posted: Thu Dec 28, 2023 7:08 pm
by Support
arrenwu wrote: Sun Dec 24, 2023 9:17 am I think the root-cause is that at the moment the file was written, it's already in the memory cache of windows.
Reading the file immediately after it's written touches only the memory cache and thus no request to the storage space is sent.
Yes, this is correct.

This is indeed a problem for which there is currently no good solution. However, since the L2 cache is persistent across reboots, if files are read later after Windows cache is replaced or after reboots, they can eventually be cached.

Re: Primocache doesn't work on the file just written.

Posted: Tue Jan 23, 2024 7:58 am
by ittsignal
Review the settings and configuration options in PrimoCache to ensure that you have set up the cache task correctly.

Re: Primocache doesn't work on the file just written.

Posted: Fri Mar 08, 2024 10:40 am
by Ushavilash
Hye, While enabling write caching on the disk and clearing standby memory could potentially help, the root cause could be more complex.

Re: Primocache doesn't work on the file just written.

Posted: Fri Mar 15, 2024 2:56 pm
by Endelin
Tweaking PrimoCache settings might help, and keeping Write-caching on the disk turned on could be worth a shot.