Learn how to a build a cloud-first strategyRegister Now

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 598
  • Last Modified:

Optimizing/troubleshooting squid performance

My problem started because of slower internet connections at our office. I am guessing this is caused
by the slower performance of my squid proxy. But honestly, I am not sure if it is indeed the source of my headache.

Now I am not a Unix guru: u c I am just a part-time sys ad here (since no one else can take the job) my main task being a programmer. When something works already I just stop there and tweak no more. Now I have gotten my squid running on a FreeBSD machine to work already, peering with two parent proxies from two different ISPs. The setup already works fine, workstations can access the net. At a particular point in time, in-fact, download times are satisfactory. Well, until machines connected to the LAN increased little by little, that is. Now things are slow!!!!

I don't know where to start "debugging" whether the trouble is in squid, and how I can optimize it if it is.
I don't even know how to check how much memory squid is eating up (maybe I just need an additional RAM).
Or how to know whether my two NICs (1 eth internal, 1 eth for external traffic) are the bottlenecks.

I've read some online articles about setting up cache_mem to be larger, lessening cache_dir coz disk access maybe the bottleneck (my disks are SCSI, but you see I'm willing to try anything), running squid using nice (I haven't tried that one yet). But my net access is still slow. Either squid is the problem or it is my ISP.

Can anyone help me troubleshoot squid, or maybe get "statistical data" that will help me determine squid is already using up all available hardware resources (ram,cpu,eth...) but still can't cope up? Maybe I just need to run this on a faster machine.

2 Solutions
Could be squid, could be machine resources, or it could be that you are just loading up your Internet link. We might get a clue from the load average, processor utilization, and memory/swap usage from the top command when things are slow. The other useful data point would be some stats on your Internet Link.
How many users you serve ???
rqsAuthor Commented:
Hi guys. I
This site helped: http://www.uck.uni.torun.pl/~maciek/w3cache/perf.html, followed some of the recommended config.
Also the top command. As it turned out, squid wasn't using up all the mem and cpu, only a moderate portion of it.
What I did was tried to experiment with various combinations of parent peers. The best mix that I got
was not to use at all the proxy at the other ISP which was performing very very slow.
The traffic improved so far. Thanks for the help.

We have around 50 users by the way.

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now