Squid settings question
I just noticed (8 months into pfSense use) that low and high watermark on the Cache Management page says not quite what I expect them to say (or thought they said:) I have bolded the worrisome word.
Low-water-mark in %
Cache replacement begins when the swap usage is above the low-low-water mark and attempts to maintain utilisation near the low-water-mark.
High-water-mark in %
As swap utilisation gets close to the high-water-mark object eviction becomes more aggressive.
I thought I was adjusting the use/replacement scheme of cache space. Either the page text is wrong or this is a very different setting than I thought it was - I don't really want swap getting used at all.
How would cache replacement occur without swapping? Out with the old, in with the new based on watermark settings. I don't understand your concern with the word SWAP. You can swap to ramdrive, traditional drive, thumbdrive, but it's still a swap.
swap space has a very particular meaning in computing. It is the disk space larger than RAM onto which portions of RAM are placed when RAM capacity is exceeded. Given the relative speeds of disk and RAM, when a system starts using a significant amount of swap space, performance plummets. An ideally-tuned router will use all of it's RAM, but no swap. You will find SWAP usage reported on your dashboard (unless running embedded with no SWAP at all, in which case you're probably not going to be running squid, either.)
As such, if the squid cache management page is using the term swap correctly, it's tuning for disaster. I hope it's not using the term correctly, but if not, it's a very strange error to make, given that the rest of the page uses cache, appropriately, and swap does have this very specific meaning (that you, and perhaps whoever chose the word there are unaware of.) There are some behaviors I have seen recently that do make me wonder if swap IS what is actually meant, which is why I'm asking the question.
In addition, there is no "swapping" of files in cache management - old items are discarded, not swapped out.
Its much easier just to allocate a conservative maximum to both RAM cache and Disk Cache. If you do that, you don't need to worry yourself with the definition of "swap".
I see your point Ecnerwal. I would hope the author simply misused the word "swap" for "cache". Your right, there generally isn't any swapping going on in a cache. Operates more like a FIFO, in the case of Squid, a conditional or rules based FIFO. I don't swap anything to my SSD either, use RAM for all I can except the occasional logging on a 4 hr interval.