How large should my Squid 3 cache be?
-
I'm quite new to pfsense, and have set up squid3 to save a bit of internet quota wasted on windows updates, double downloads of files, etc and make things like windows updates a bit quicker.
This pfsense box is just set up at home for my family. It has various mobile devices connected to it via my e4200 but the primary users are 3 PCs doing things like online gaming, youtube and downloading games/movies, etc.
It's has 1GB of RAM and a 250GB HDD. It currently just runs squid3 and HAVP antivirus. I may do m
I heard that larger sized caches can slow down everything, so I was wondering what would be an optimal starting point for situation like with a system like this? So that I can at least have a good starting point for tweaking.
I just assumed bigger is better and set 150GB. I have noticed I'm dropped from an average of 700kbps on downloads to more like 100kbps today and yesterday, I'm not sure if it is related or not, but worth mentioning. The box has been up for a week, and the HDD is only 2% used though.
Also is it worth upgrading the RAM for my useage?
-
Squid loves RAM. RAM caching is fast, and if you don't have a server motherboard it's cheap to upgrade. Get as much RAM as you can in there. For reference, I have 8 GB on my pfSense VM. I have 3.5 GB reserved for squid, and a 5 GB HD cache. My HD max object size is 256 KB, and RAM max object size is 512 KB.
As for your download speeds, test without squid first and make sure it's actually the problem, then tune from there.
-
256KB? Doesnt that mean if an exe bigger than that is dl'd it wont get cached? Or is that not how it works?
-
That's correct. I personally don't like a lot of caching to go on in disk because our internet is plenty fast and we have no bandwidth caps. If you were wanting to save bandwidth or had lots of updates from the same place that didn't change often, you'd want to increase those values. For my scenario, I want minimal caching - images and static content in general is usually fine.
-
I see, thank you. :)