Leave a comment

Comments 7

swanhart October 27 2009, 07:53:01 UTC
Hooray for blog posts that actually make sense.

Great info.

Reply


boogabee October 27 2009, 13:16:01 UTC
good write up, thank you

Reply


katren November 26 2009, 22:16:57 UTC
> It is a fact that issuing a smaller multiget against a particular server will take *less* CPU time than a larger one. Adding servers does reduce CPU time on the server.

I suppose this is where you disagree with Jeff Rothschild.
I'd like to point out that even if CPU usage is less, each request still counts, so a brand new server immediately takes a fair amount of keys to serve and immediately an avalanche of requests starts coming in. Clients used to send requests to X servers to get Y keys, now they need to send X + 1.
So adding a new host did not reduce number of requests and thus CPU but rather multiplied it.
So if you sum up all CPU used across the cluster - it went UP

To make things worse - if one blindly continue down this path - one starts running out of connections of memcached servers.

I do agree with everything else you said.

Reply

dormando November 26 2009, 22:18:34 UTC
I thought I addressed that pretty clearly above. The point there was that it definitely does reduce CPU usage on a particular memcached instance.

If you read carefully, you'll notice that most of the post is just addressing the moronic twitter soundbites that were extracted from the talk.

Reply

katren November 26 2009, 22:26:04 UTC
> Hence, adding servers to a cluster *will* reduce the CPU usage on the cluster.

I'm not sure if I can agree here. You bought a new box, you put it there, you immediately see it running at, say, 40% CPU.
You don't see any significant CPU drop on all the old hosts.
Is it not a clear indication of more CPU consumed across the board?

Reply

dormando November 26 2009, 22:28:19 UTC
It's completely impossible to add a new host and not have the old host drop in CPU usage *at all*. Even if it's immeasurably small, making a multiget smaller on a host *will* reduce its CPU usage. The overhead for the request itself is high enough that spreading out the load becomes less effective, similar to adding slaves in a MySQL cluster as the write load increases.

The solution is the same, but it's a falsehood to believe that lookups within a multiget are completely "free" CPU-wise.

Reply


Leave a comment

Up