Configure Squid to permanently cache specific directories

cachesquid

Can Squid be configured to permanently cache specific directories of a web site?
In the diagram below, the lan1 Squid should cache www.example.com/x and
www.example.com/y directories permanently. Contents of directories /x /y and /z
are write once.

              xww.example.com
                /w /x /y /z
                  Apache
         ------------------------
         Slow Internet Connection
         ------------------------
          lan1  |  lan2  |  lan3
                |        |
          cache |  cache |  cache
          /x /y |  /x /z |  /y /z
          Squid |  Squid |  Squid
         ------ | ------ | ------
         Browser| Browser|Browser
         Browser| Browser|Browser
         Browser| Browser|Browser
         Browser| Browser|Browser

Best Answer

A combination of cache and refresh_pattern will define how your SQUID cache performs. You can use cache to specify the directory and refresh_pattern to define how it expires.

You can use override-expire to enforce a minimum age, which violates the HTTP standard. I do not believe there is a setting for true permanence.

Cache Tuning Parameters

Related Topic