Do I need to setup the IPs of all servers in the Console?
I'm running on Amazon EC2 and have an image that I use for both the dev and prod servers. I'd like to install Membase server (using memcached) but I'm wondering how I should set it up. I have 1 dev server and 2 prod serves and obviously they have different IPs. But since I'm using 1 image for all of them, I can't setup the IPs for both prod servers in the console because then things won't work right on dev!
I'm using the Enyim .NET Memcached library and part of the configuration is to enter the IPs of all your memcached servers. I have different configs for dev and prod so part of me thinks that if I just enter 127.0.0.1 into the console but put the actual ips of the dev & prod servers into my configs that things will work fine. But part of me is scared! Any suggestions?
Ok, that makes sense. What would be easier than using a load balancer for us at this time would be to just use separate config files for each server (prod vs dev). Is there a way to do this? Being a linux port I would expect to see some .conf files but instead I have these .dat files in the config folder. Is there a reference for what each of these .dat files does? For the differences I'm looking for (just IP addresses), is there a single .dat file that I could swap out between the different machines or would I need to swap out the whole directory? I'd really rather use some good-ol'-fasion .conf text files for configuration though so that I could easily manipulate them with a script or something.
Or maybe I could just write a batch file that runs the necessary commands to configure the machines. So I could have a prod-setup.bat and dev-setup.bat. I suppose I'll look into that first. I'd appreciate any advice/direction!
Looking at the membase cluster-init flag. Can I run cluster-init on both prod servers using 127.0.0.1 and then add both external server's external ips as servers in the cluster? I guess I'm not clear on the cluster concept -- I was under the impression (at least for memcached) that the servers don't know or need to know they are part of a cluster but here I am setting up a cluster in membase server.
You're correct that memcached doesn't have a concept of a cluster...but Membase does.
Yes, you can run cluster-init on the local servers using 127.0.0.1 and then add the other servers in.
In response to your other questions, you don't want to be manipulating the .dat files. We are working on a better configuration management system, but there is really very little configuration that needs to happen on a Membase cluster.
Perhaps I'm not entirely understanding the problems you're facing. You can very easily setup multiple clusters of Membase, and you don't want to be transferring the config between nodes since they each have their own IP and knowledge of the cluster.
If it's still unclear, please step back a minute and explain the problem you're trying to solve and I will try to help.
Perry
Will running cluster-init using 127.0.0.1 and adding the other servers mess up the hashing since now the server list will be in a different order on each server?
The problem is basically just that we want to have the same image run on our development and production servers and so we need a way to automate the server configuration on server startup or deployment. Using the console is not a great option because it's a manual step and is prone to error.
That totally makes sense. No, adding the servers in various orders will not mess up any hashing.
Don't be scared! Test it out! :-)
If you use the Membase portion of the Enyim library, you only need to enter one URL to your Membase servers (you can enter more than one for fault-tolerance, but don't need them all). You'll want to use the Membase section even if you're using it just as memcached...all that matters is which bucket you point it to.
The client will connect to the URL and get the list of all servers in the configuration. It will even update itself dynamically if you add or remove nodes. This is the recommended way of connecting to Membase (even in memcached mode).
Edit: re-read the topic and understand your question a bit better now.
Many customers actually use an elastic load-balancer that their Membase servers register with. That way, you can point your Enyim client at a single vip on the load-balancer and not need to worry about the IP addresses of the Membase servers.
Let me know if that makes 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 Couchbase: http://www.couchbase.com/products-and-services/overview
Call or email "sales -at- couchbase-dot- com" today!