Upgrading HBase

Coprocessors and Custom JARs

When upgrading HBase between from one major version to another (such as upgrading from CDH 4 to CDH 5), you must recompile coprocessors and custom JARs after the upgrade.

Never rely on HBase directory layout on disk.

The HBase directory layout is an implementation detail and is subject to change. Do not rely on the directory layout for client or administration functionality. Instead, access HBase using the supported APIs.

Upgrading HBase from a Lower CDH 5 Release

To upgrade HBase from a lower CDH 5 release, proceed as follows.

The instructions that follow assume that you are upgrading HBase as part of an upgrade to the latest CDH 5 release, and have already performed the steps underUpgrading from an Earlier CDH 5 Release to the Latest Release.

Step 1: Perform a Graceful Cluster Shutdown

To shut HBase down gracefully:

  1. Stop the Thrift server and clients, then stop the cluster.
    1. Stop the Thrift server and clients:
      sudo service hbase-thrift stop
    2. Stop the cluster by shutting down the master and the region servers:
      • Use the following command on the master node:
        sudo service hbase-master stop
      • Use the following command on each node hosting a region server:
        sudo service hbase-regionserver stop
  2. Stop the ZooKeeper Server:
    $ sudo service zookeeper-server stop

Step 2: Install the new version of HBase

It is a good idea to back up the /hbase znode before proceeding. By default, this is in /var/lib/zookeeper.

To install the new version of HBase, follow directions in the next section, Installing HBase.