Upgrade an Offline Cluster
The simplest way to upgrade a multi-node cluster is with the cluster offline, during a maintenance window in which it serves no requests.
Understanding Offline Cluster Upgrade
In an offline upgrade, all application access to the cluster stops, and each node is upgraded in turn. Each node keeps its identity, its configuration, and its data, so no rebalance is needed. When every node has been upgraded, the cluster is brought back online.
Offline upgrade is available from every Enterprise Analytics release, including 2.0.x.
The procedure has three stages.
Stage One: Prepare the Cluster
-
Stop all applications that send requests to the cluster.
-
Disable auto-failover, so that no node is failed over while it stops communicating with the rest of the cluster during its upgrade. You only need to do this once, on any node:
/opt/enterprise-analytics/bin/couchbase-cli setting-autofailover \ -c ${CLUSTER_NODE}:8091 -u ${USERNAME} -p ${PASSWORD} \ --enable-auto-failover 0For more information, see setting-autofailover.
-
Record each node’s UUID and data path, which you use to verify the node after its upgrade. The per-node procedure in the next stage describes how.
Stage Two: Upgrade Each Individual Node
Upgrade each node in turn, by following the per-node procedure for how the node is installed:
-
For a node installed from an
.rpmor.debpackage, follow Offline Upgrade from Enterprise Analytics to Operational Insights. -
For a node that runs in a Docker container, follow Offline Upgrade of a Docker Cluster from Enterprise Analytics to Operational Insights.
Each procedure moves the node from Enterprise Analytics to Operational Insights while keeping the node’s state. Follow every step: a node that starts without its state initializes itself as a new, empty node.
Verify each node, as the procedure describes, before you move on to the next.
Stage Three: Bring the Cluster Back Online
-
Confirm that every node is active, on the Servers screen of the Operational Insights Web Console, or with the following command:
/opt/couchbase/bin/couchbase-cli server-list \ -c ${CLUSTER_NODE}:8091 -u ${USERNAME} -p ${PASSWORD} -
Enable auto-failover again, with the settings the cluster used before the upgrade:
/opt/couchbase/bin/couchbase-cli setting-autofailover \ -c ${CLUSTER_NODE}:8091 -u ${USERNAME} -p ${PASSWORD} \ --enable-auto-failover 1 --auto-failover-timeout ${TIMEOUT} -
Restart the applications that send requests to the cluster.
The upgrade is complete.