Couchbase
  • Why NoSQL?
  • Couchbase Server
  • Download
  • Resources
  • Careers
Home | Forums | Membase | Memcached Server 1.0.3

meaning of memcached cluster

6 replies [Last post]
  • Login or register to post comments
Wed, 08/04/2010 - 13:49
boxerab
Offline
Joined: 08/04/2010
Groups: None

Hello!

I just installed the Membase memcached server on two windows boxes.
I have a client using NHIbernate, and I would like to use memcached as my second
level cache.

In my NHibernate config file, I have entered the IPs for the two servers. Also, according
to the standard memcached docs, memcached servers are disconnected and know nothing about each other; it is up to the client to store and retrieve from the right server.

So, how does the Membase concept of cluster figure into all this? Does clustering or not clustering affect how the the cache is used? Do clustered servers talk to each other? Or is it purely for management purposes that servers are clustered.

Thanks!

Aaron

Top
Wed, 08/04/2010 - 14:05
Perry Krug
Offline
Joined: 06/02/2010
Groups: None

Hi Aaron, thanks for your inquiry. By default, the clustering within NorthScale's server doesn't have anything to do with your use of the cache. Each server will run and respond to requests independently (if accessed through port 11211).

Our clustering comes into play in a few areas:
-Management/statistics: You can create buckets, and view the statistics for the whole cluster as an aggregate
-"Smart clients": There are currently 2 clients (Enyim for C#/.Net and our wrapper to spymemcached for Java) that allows you to point your clients at the REST API of our cluster. They will automatically receive any cluster topology changes and update their configuration dynamically.
-When using the proxy port: Port 11212 is running a proxy which basically allows you to access any piece of data within the cluster from any node. This allows non-smart clients to not require all IP addresses to be in their configuration and thus prevent some of the problems associated with rehashing when adding/removing server.

Hope that helps Aaron, let me know if there's anything else I can answer for you.

Perry

Note that this discussion changes dramatically for our Membase product, but I've tailored my responses for Memcached.

__________________

Forum support is great for free but sometimes you need a guaranteed response time and dedicated resources for your questions or issues.
Consider purchasing enterprise-level support from Membase: http://www.membase.com/products-and-services/overview
Call or email "sales -at- membase -dot- com" today!

Top
Thu, 08/05/2010 - 07:29
boxerab
Offline
Joined: 08/04/2010
Groups: None

Thanks, Perry. Very interesting. My NHibernate client does not support consistent hashing at the moment, so the proxy solution looks interesting. But, I need to have high availability, so
if the proxy failed, then I would lose the entire cluster.

Top
Thu, 08/05/2010 - 09:14
Perry Krug
Offline
Joined: 06/02/2010
Groups: None

Aaron, each and every server runs an instance of the proxy. For HA, you would simply point your clients at multiple servers (though it need not be all) and that way if one died, you would have the others still available to handle requests. Does that make sense?

Perry

__________________

Forum support is great for free but sometimes you need a guaranteed response time and dedicated resources for your questions or issues.
Consider purchasing enterprise-level support from Membase: http://www.membase.com/products-and-services/overview
Call or email "sales -at- membase -dot- com" today!

Top
Thu, 08/05/2010 - 11:45
boxerab
Offline
Joined: 08/04/2010
Groups: None

Thanks, Perry.

In a previous post, you said, regarding the proxy port:

" This allows non-smart clients to not require all IP addresses to be in their configuration and thus prevent some of the problems associated with rehashing when adding/removing server."

My situation is: I have a non-smart client, and I need high availability. Suppose I have two memcached servers, IP1 and IP2, in a cluster. Are you saying that I could point my client to IP1:11212 and get access to both servers in the cluster? If so, then this would not provide HA, in case IP1 goes down.

I suppose, for HA, I could have two clusters, one clustered to IP1 and one clustered to IP2, and point my client to both IP1:11212 and IP2:11212, and then add and remove servers on the two clusters without updating my client configuration.

Currently, my memcached client doesn't support consistent hashing, but I am hoping to use the enyim client by the time we release, and this does support consistent hashing. But this proxy feature would still be useful.

Thanks again,
Aaron

Top
Thu, 08/05/2010 - 11:55
Perry Krug
Offline
Joined: 06/02/2010
Groups: None

Aaron, for your initial setup, you should be able to point your client at both IP1 and IP2 (while clustered together) on port 11212. As you add servers, the clients will have access to that data without worrying about hashing issues. In this case, the servers at IP1 and IP2 would handle all of the traffic for the whole cluster (potentially creating a bottleneck if the load is very high). As you grow, you could reconfigure your client to add more and more servers to distribute the load more evenly.

I would highly recommend implementing the Enyim client since it allows you to connect to the REST interface of our cluster and automatically update itself for any cluster topology changes. You would still want to point it at at least 2 IP's for HA, but instead of those two IP's being a potential bottleneck, the client will distribute load to all the servers in the cluster and talk to them directly without a proxy (which will provide better performance).

Does that all make sense?

Thanks Aaron.

Perry

__________________

Forum support is great for free but sometimes you need a guaranteed response time and dedicated resources for your questions or issues.
Consider purchasing enterprise-level support from Membase: http://www.membase.com/products-and-services/overview
Call or email "sales -at- membase -dot- com" today!

Top
Fri, 08/06/2010 - 11:10
boxerab
Offline
Joined: 08/04/2010
Groups: None

Yes, that does makes sense.
Thanks very much for the detailed explanation.

Top
  • Login or register to post comments
  • Login
  • Register

Company

  • About Us
  • Leadership
  • Customers
  • Partners
  • Contact Us

Product

  • Couchbase Server
  • Couchbase SDKs
  • Use Cases
  • Documentation
  • Forums

Open Source

  • Couchbase Project
  • Couchbase vs. CouchDB

Commercial

  • Subscriptions & Support
  • Training & Services

News

  • Blog
  • Newsletter
  • Press Releases
  • Buzz

Follow Us

    
  • Customer Login
  • Terms of Service
  • Privacy Policy
  • Trademark Policy
  • Site Map

© 2013 COUCHBASE All rights reserved.

Sign in to Couchbase Community

close
  • Create new account
  • Request new password
You are logging into the Forums, Wiki and Issue Tracker