2

I am using the APC and see I still have 25MB of free memory.

However, in the Cache full count, I see I have 8 already.

So, why that happens? And if my understanding is: APC is not a LRU cache, so why I still have to free memory as I have reached the full count?

0

Regardless of exactly what the cache invalidation algorithm is, there will likely be some target amount of free space, or at least it's expected that space will be freed whenever the invalidation routine runs. So you should expect there to be some space clear almost all of the time.

To be honest I'm having some difficulty understanding exactly what you are seeing, and what you are asking. You might get more help if you re-phrase your question and add detail. If the specific amounts of memory you refer to are important for answering your question, then you should give a bit more context about how much shared memory space you allocated in total, and perhaps about how the free space varies over time.

25MB of free space seems pretty small to me.

I think the algorithm is that when the cache is full, APC does a full pass over the cache content, identifying all expired content. I'm not sure what it does if nothing is expired. Presumably the Cache_full_count is a count of how many such passes have occurred. Seems like a reasonable guess anyway. If you want better than guesswork, and it's not in the APC documentation, then you might be best to take a look at the source code. It's often the easiest way to answer such questions, and you'll learn a lot by taking that approach.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.