views:

93

answers:

2

Is memcached capable of making full use of multi-core? Or is there any way tuning this?

+1  A: 

memcached has "-t" option:

       -t <threads>
          Number of threads to use to process incoming requests. This option is only meaningful
          if memcached was compiled with thread support enabled. It is typically not useful  to
          set  this higher than the number of CPU cores on the memcached server. The default is
          4.

so, I believe it can use all your CPU cores, of course if it was compiled with corresponding option.

zed_0xff
Thank you very much~
Mickey Shine
please mark the answer as 'accepted' if it was helpful for you
zed_0xff
A: 

memcached is multi-threaded by default and has no problem saturating many cores. It's a bit harder to saturate all cores on more massively parallel boxes (e.g. a 256-core CMT box) just because it gets harder to get the data in and out of the network.

If you find areas where some sort of contention is preventing you from saturating cores, file a bug or start a discussion.

Dustin

related questions