oliver@... (Oliver M. Bolzer) writes:
> > Install libevent, install memcached, set a unique
> > memcached_keyprefix var for each of your Slash sites, set the
> > var memcached to 1, and restart slashd and apache. Watch
> > your DB utilization go down by a third :)
> > On Slashdot... we have a quarter-gig of memcached cache on each
^^^^^^^^^^^ oops, I meant eighth of a gig
> > of ~15 webheads.
> So is every webhead running it's own memcached only for it's own
> use or do they form together a single pool ?
This falls under advanced uses :)
On Slashdot, we have this process running on each of 15 webheads:
/usr/local/bin/memcached -p 11211 -d -m 128 -k -l 1.2.3.x
That sets aside 128 MB of RAM for memcached's use. "1.2.3.x" is the
IP interface for the machine (same thing you see in the output of
'ifconfig -a'). 11211 is the port it's listening on.
Then, our memcached_servers var is set to this value:
18.104.22.168:11211=3D1 22.214.171.124:11211=3D1 [...] 126.96.36.199:11211=3D1
I could break that up for you but you can probably figure it out
If you only have one machine and you start your memcached process on
it, the default value of memcached_servers will point to localhost,
which is what you want.
But in our case, every process that uses memcached (all the apache
children and slashd) looks to a pool of 15 servers, which all act
together as if they were one giant 1.9 GB RAM cache.