Re: [squid-users] Cache large file in chunks?

From: Henry Yuan <forwardmy_at_gmail.com>
Date: Fri, 29 Apr 2011 13:55:36 -0500

Hi Amos,

Thanks for the reply. I have a new question in the content.

On Fri, Apr 29, 2011 at 1:01 PM, Amos Jeffries <squid3_at_treenet.co.nz> wrote:
> On 30/04/11 05:08, Henry Yuan wrote:
>>
>> Hi,
>>
>> I'm wondering whether the current squid implementation cache large
>> files in chunks?
>
> No. It caches them as whole files.
>
>>
>> Let's say the Squid is downloading a large file A for client 1, when
>> it just finished transferring say 10% of the file, another client,
>> Client 2 asked for the same file A. Will Squid start serve Client 2
>> immediately with the 10% of file A it has or Squid has to wait until
>> all the parts of file A is downloaded in order to get a cache hit.
>
> Depends on your version of Squid.
>  Squid-2.6 or 2.7 will start sending client 2 the same file client 1
> fetched.
>  Squid 3.x will fetch a new copy in parallel. As soon as one of the two has
> finished it will start serving client 3,4,5 etc as HITs.
>

1. Are you saying Squid 3.x will fetch AT MOST 2 copies of the same
file, or it will fetch as many as the pending requests before the
whole file is downloaded (so if 100 clients ask for the same large
file, 100 fetches will be conducted if the whole file is not
downloaded yet)?

2. What's the motivation of fetching the same content twice in
parallel for Squid 3.x? It seems to me that serving the file right
after parts of it being cached is more efficient.

>>
>> I saw there were some discussions on this page but not sure what is
>> its status quo.(
>> http://wiki.squid-cache.org/Features/PartialResponsesCaching)
>
> As documented: Status is "Not started"
>
> Amos
> --
> Please be using
>  Current Stable Squid 2.7.STABLE9 or 3.1.12
>  Beta testers wanted for 3.2.0.7 and 3.1.12.1
>
Received on Fri Apr 29 2011 - 18:55:44 MDT

This archive was generated by hypermail 2.2.0 : Sat Apr 30 2011 - 12:00:04 MDT