>I'm tring to set up Squid 1.1.8.
>I have two disks for cache, and I want to use these.
>How should I change squid.conf?
>
>***Two disks...***
>/work/cache -> (I want to set up it "cache_swap 800")
>/work2/cache -> (I want to set up it "cache_swap 1600")
[...] This is a very common question that has been asked here, and
really this isn't something that squid should be doing (OK, so it -could-
but..)
The much better alternative is for you to use a raid0 device to concatenate
those two devices into one -logical- volume. Eg:
proxy:~$ df
Filesystem 1024-blocks Used Available Capacity Mounted on
/dev/hda1 396500 279508 96506 74% /
/dev/hdc2 532755 211503 293734 42% /logs
/dev/md0 9920004 508415 8896797 5% /cache
proxy:~$
In this, /dev/md0 is made up of 6 devices, over 3 controllers, interleaved
together. There's only one filesystem, so you can set squid to the exact
size. Please note, however, that this is -not- an optimal setup. My
cache_dir's are
cache_dir /cache/part1
cache_dir /cache/part2
cache_dir /cache/part3
[...]
cache_dir /cache/part10
just to make sure squid has locations to play with (It's OK, memory isn't
a concern here, either 8-)
An optimal setup would have 6 devices over 3 controllers ( 2 on each
controller), with 6 cache_dir entries, each a different volume group.
Each volume group would have 1/6th of every device, and should be striped
at a slice size of (n)k. (n being an unknown amount, as I haven't worked out
the average size of each file in squid -- yet 8-)
Admittedly, thats probably more work that you want to put in, but, if you're
running linux, a simple mdadd in a simple concatenation of the two partitions
will solve your immediate problem.
Does anyone want me to do a part in the FAQ on this sorta stuff? Considering
that most squid's are running either on Solaris (Online DiskSuite), HP
(HP's volume groups rock. But, thats IMHO 8-), or Linux (md pseudo driver)
it's not all that hard to do.
--Rob
Received on Tue Mar 25 1997 - 02:11:32 MST
This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:34:46 MST