7. Upgrade HBase

  1. Upgrade HBase.

    Run the following commands on both the HBase Master and the RegionServers hosts.

    • For RHEL/CentOS/Oracle Linux:

      yum upgrade hbase  

      For SLES:

       zypper install hbase
    • For Ubuntu:

       apt-get install hbase
  2. Replace your configuration after upgrading. Replace the HBase template configuration in /etc/hbase/conf.

  3. Check for HFiles in V1 format. HBase 0.96.0 discontinues support for HFileV1. Before the actual upgrade, run the following command to check if there are HFiles in V1 format:

    hbase upgrade -check

    HFileV1 was a common format prior to HBase 0.94. You may see output similar to:

    Tables Processed:
    Count of HFileV1: 2
    Count of corrupted files: 1
    Corrupted Files:
    Count of Regions with HFileV1: 2
    Regions to Major Compact:

    When you run the upgrade check, if “Count of HFileV1” returns any files, start the hbase shell to use major compaction for regions that have HFileV1 format. For example in the sample output above, you must compact the fa02dac1f38d03577bd0f7e666f12812 and ecdd3eaee2d2fcf8184ac025555bb2af regions.

  4. As the HBase user, run an upgrade:

    sudo su -l $HBASE_USER -c "hbase upgrade -execute"

    You should see a completed Znode upgrade with no errors.

  5. Start services. Run as root:

    Suppose $HBASE_USER = hbase
    sudo su -l hbase -c "/usr/lib/hbase/bin/hbase-daemon.sh --config /etc/hbase/conf start master"
    sudo su -l hbase -c "/usr/lib/hbase/bin/hbase-daemon.sh --config /etc/hbase/conf start regionserver"
  6. Check processes.

    ps -ef | grep -i hmaster
    ps -ef | grep -i hregion 

loading table of contents...