Re: Multiple storeio types?

From: Joe Cooper <joe@dont-contact.us>
Date: Fri, 09 Nov 2001 05:52:51 -0600

Andres Kroonmaa wrote:

> On 9 Nov 2001, at 0:51, Joe Cooper <joe@swelltech.com> wrote:
>
>
>>Henrik Nordstrom wrote:
>>
>>
>>>Probably missing from the round-robin directory selection. Should be trivial
>>>to add.
>>>
>>Yep. It was. Patch will be forthcoming when I've tested it.
>>
>
> hmm, weird, I see its there:
> if (!storeDirValidSwapDirSize(i, objsize))
> continue;
> Isn't this the thing?

Hmmm... I'm not seeing it work in practice. Maybe it's broken? I'll
look at this to see if I can figure out what's happening. (I bumble
along pretty slowly when it comes to reading C. ;-)

>>If I find that least load is more efficient for my needs, I'm going to
>>give a diskd storedir type a try on my RAM disk. Maybe lighter weight
>>than 16 threads... Any thoughts on whether I'm misled in that assumption?
>
> One more thing you could implement is min-size=n config option for
> cache_dir. Then you can exclude aufs store from overlapping with ufs
> on your ramdisk by setting min-size(aufs)=max-size(ufs)
> This is more generally useful option anyway.

It may be a side effect of a bug in the least load selection code, but
this is actually the effect I'm seeing. No objects larger than my
configured max-size on the ramdisk ever hit the disk stores. Maybe
because it is always so much less loaded than they are? It's just what
I hoped I could convince it to do, so I didn't complain about it! ;-)

However, I'm seeing the reverse effect when one store is 'full' and the
other is not quite full. The unfull one gets /all/ objects until it
catches up to the full one. This strikes me as being quite broken.
Adding a new disk to a multi-disk Squid, without first flushing the old
disks could bring a heavily loaded cache to its knees in short order. I
saw it when I was trying to test different cache_dir sizes, and the
impact of favoring one of my disks over the other (because it benchmarks
a little faster and is bigger). I found that to get anything like
balanced behavior, the two disk cache_dirs have to be the same size.

Anyone know when this selection code came into being? I guess with the
storeio interface? I'll volunteer to do some poking at it when I get
back from the cacheoff (and maybe while I'm at the cacheoff waiting for
tests to run), as it needs some changes to handle edge cases gracefully.
  (Not that I'm an expert--but I see where it is falling down, now.)

-- 
Joe Cooper <joe@swelltech.com>
http://www.swelltech.com
Web Caching Appliances and Support
Received on Fri Nov 09 2001 - 04:49:31 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:14:37 MST