When you use Couchbase Server in the cloud, server nodes can use internal or public IP addresses. Because IP addresses in the cloud may change quite frequently, you should configure Couchbase to use a hostname instead of an IP address.
By default Couchbase Servers use specific IP addresses as a unique identifier. If the IP changes, an individual node will not be able to identify its own address and other servers in the same cluster will not be able to access it. To configure Couchbase Server instances in the cloud to use hostnames, you should follow steps later in this section. Note that RightScale server templates provided by Couchbase can automatically configure a node with a provided hostname.
Make sure that your hostname always resolves to the IP address of the node. This can be accomplished by using a dynamic DNS service such as DNSMadeEasy which will allow you to automatically update the hostname when an underlying IP address changes.
The steps that follow will completely destroy any data and configuration from the node, so you should start with a fresh Couchbase install. If you already have a running cluster, you can rebalance a node out of the cluster, make the change and then rebalance it back into the cluster. For more information, see Section 2.5, “Upgrading to Couchbase Server 2.0.x”.
Nodes with both IPs and hostnames can exist in the same
cluster. When you set the IP address using this method, you
should not specify the address
127.0.0.1 as this will be invalid when used
as the identifier for multiple nodes within the cluster.
Instead, use the correct IP address for your host.
Linux and Windows 2.0.1 and earlier
For Couchbase Server 2.0.1 and earlier you must follow a manual process where you edit config files for each node which we describe below for Couchbase in the cloud. For instructions, see Section 2.4.1, “Hostnames for Couchbase Server 2.0.1 and Earlier”.