Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've install Squid Proxy via sudo apt-get install squidon Ubuntu for a forward proxy

I've not modified any of the default settings in squid.conf apart from http_access deny all to http_access allow all

Now I've used this command # tail -f /var/log/squid3/access.log to monitor the squid access logs in real time and I see that despite numerous different types of websites, static and dynamic, lots of images and static files, the results are still always the same.

Lots of TCP_Miss and barely two or three TCP_Hits I've also checked the size of Squid's spool and it's only 4.0K

So I know now that Squid is not caching anything. Is there anyone able to help me out there with this? I've read almost every single article from google when searching for "Squid TCP_Miss" and "Squid not caching" but none of those worked for me.


share|improve this question
Check the caching headers of the pages squid is retrieving. They may not allow caching. – Ladadadada Jul 13 '13 at 16:06
I really don't think it's the headers... I've tried like over 20 different websites and none of them have a single actual TCP_Hit – jc.yin Jul 13 '13 at 16:07
Check it anyway. – Michael Hampton Jul 13 '13 at 18:13
Sorry for my newbiness but could you tell me how do I check the headers? And what I'm I looking for exactly. Thanks – jc.yin Jul 13 '13 at 18:49

Squid (and the rest of the Proxy servers out there), caches only static content. Not dynamic web pages. So, you will see a lot of TCP_MISS for php/asp etc pages. In addition, in case the webmaster set the no_cache directive, not even the JPG files will be cached.

share|improve this answer
But the thing is, I noticed that a lot of images, which are supposed to be static, aren't getting cached anyway, because there's a few ? in the URL. Also shouldn't contents like js and css files also be cached? They aren't getting either – jc.yin Jul 13 '13 at 19:09
Also I have followed the guide here and implemented the new code but still barely anything is getting cached at all. I mean if out a "normal" web 2.0 website, with 30 images, only two images get cached each time, how come Squid is still so popular? – jc.yin Jul 13 '13 at 19:10
Please tell us which part of the tutorial you did follow?.Also note, that the cache size is important. I strongly suggest to use one of the tools you can find at I used them in the loooong past (when squid was a necessity) and managed to pinpoint any issue I had. – Peter Jul 14 '13 at 5:56

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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