Installing HDP Manually
Also available as:
PDF
loading table of contents...

Configuring HBase for Phoenix

To enable global indexing and local indexing in Phoenix, complete the following steps.

  1. Add the following properties to the hbase-site.xml file on all HBase nodes, the Master Server, and all Region servers.

    • Set hbase.defaults.for.version.skip to true:

      <property>
           <name>hbase.defaults.for.version.skip</name>
           <value>true</value>
      </property>
    • Set hbase.regionserver.wal.codec to enable custom write-ahead log ("WAL") edits to be written as follows:

      <property>
           <name>hbase.regionserver.wal.codec</name>
           <value>org.apache.hadoop.hbase.regionserver.wal.IndexedWALEditCodec</value>
      </property>
    • Set hbase.region.server.rpc.scheduler.factory.class to prevent deadlocks from occurring during maintenance on global indexes:

      <property>
           <name>hbase.region.server.rpc.scheduler.factory.class</name>
           <value>org.apache.phoenix.hbase.index.ipc.PhoenixIndexRpcSchedulerFactory</value>
           <description>Factory to create the Phoenix RPC Scheduler that knows to put index updates into index queues</description>
      </property>
  2. (Optional) To use local indexing, set the following two properties. These properties ensure co-location of data table and local index regions:

    [Warning]Warning

    The local indexing feature is a technical preview and considered under development. Do not use this feature in your production systems. If you have questions regarding this feature, contact Support by logging a case on our Hortonworks Support Portal at http://support.hortonworks.com.

    <property>
         <name>hbase.master.loadbalancer.class</name>
         <value>org.apache.phoenix.hbase.index.balancer.IndexLoadBalancer</value>
    </property>
     
    <property>
         <name>hbase.coprocessor.master.classes</name>
         <value>org.apache.phoenix.hbase.index.master.IndexMasterObserver</value>
    </property>
  3. Restart the HBase Master and Region Servers.