Search squid archive

Re: Squid in CARP setup

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Mark Elsen wrote:

Hi,

I need some help with a CARP setup. I want a large cooperative reverse
proxy for a static content website, minimizing redundant use of RAM. At
the moment I have two squid servers load-balanced by IVPS.
Because of the large amount of popular objects the in-memory-hit-ratio
is about 80%.
In theory, when using CARP the URI-space is partioned over my two squids
and thus I should be able to get a larger in-memory-hit-ratio. I expect
this will improve the performance, because of my slow backends.

I use
========
cache_peer 10.10.0.91 parent 3128 0 carp-load-factor=0.5 proxy-only
cache_peer 10.10.0.92 parent 3128 0 carp-load-factor=0.5 proxy-only
=========
in both squid.conf's. Further I use the following ACLs:
=============
acl internal src 10.10.0.0/24
cache_peer_access 10.10.0.91 allow internal
cache_peer_access 10.10.0.92 allow internal
=========

CARP is enabled, according to squid -v
==============
Squid Cache: Version 2.5.STABLE11
configure options:  --prefix=/usr --bindir=/usr/bin --exec-prefix=/usr
--sbindir=/usr/sbin --localstatedir=/var --mandir=/usr/share/man
--sysconfdir=/etc/squid --libexecdir=/usr/lib/squid
--enable-auth=basic,digest,ntlm --enable-removal-policies=lru,heap
--enable-digest-auth-helpers=password
--enable-basic-auth-helpers=PAM,getpwnam,YP,NCSA,SMB,MSNT,multi-domain-NTLM,winbind
--enable-external-acl-helpers=ip_user,unix_group,wbinfo_group,winbind_group
--enable-ntlm-auth-helpers=SMB,fakeauth,no_check,winbind
--enable-linux-netfilter --enable-ident-lookups --enable-useragent-log
--enable-cache-digests --enable-delay-pools --enable-referer-log
--enable-truncate --enable-arp-acl --with-pthreads --with-large-files
--enable-htcp --enable-carp --enable-poll
--disable-follow-x-forwarded-for --host=x86_64-pc-linux-gnu
--disable-snmp --enable-ssl --enable-storeio='ufs,diskd,coss,aufs,null'
--enable-async-io
==================

and squid -k parse indicates no errors.

Looking in the log-files, the requests are handled by one squid, instead
of two. Tcpdump indicates no
traffic between both squids.

Not much about CARP can be found on the internet. I used the O'Reilly on
Squid, but nothing more than stated above is mentioned in that book.

Can somebody clarify CARP for me (documentation, clues, antything :D)?
Thanks in advance.


- When CARP is enabled you should have a link pointing to stats
in 'cachemgr'

- Secondly note that the CARP principle can also be implemented
at the user agen site (proxy pac); for an example see :

                http://naragw.sharp.co.jp/sps/sample2.pac.txt

M.

I noticed that there was no 'carp' section in cachemgr. Quite strange, since the Squid is configured with --enable-carp according to squid -v. I checked the Ebuild (I use gentoo) and it mentions '--enable-carp'.
I will try to compile squid manually with --enable-carp.

Using 'carp' at the user agent side is not an option, since we use our squids as reverse proxies for our website (serving about 2 million registered users). At the moment we still use a kind of 'interval setup' with one set of Apache's and Squids for the first half of our images and another set of Apache and Squid for the last half of our images. But as number of requests and the number of images grow, we want to get rid of the interval-setup and use a cooperative squid setup.

Tristan

[Index of Archives]     [Linux Audio Users]     [Samba]     [Big List of Linux Books]     [Linux USB]     [Yosemite News]

  Powered by Linux