Configuring Fault Tolerance
Also available as:
PDF
loading table of contents...

Use Cases and Failover Scenarios

Deploying the Metastore service in High Availability (HA) mode can help in handling service failures. You should deploy the Metastore service on multiple systems concurrently.

Use Cases

The Metastore HA solution is designed to handle Metastore service failures. Whenever a deployed Metastore service goes down, Metastore service can remain unavailable for a considerable time until service is brought back up. To avoid such outages, deploy the Metastore service in HA mode.

Deployment Scenarios

Hortonworks recommends deploying the Metastore service on multiple systems concurrently. Each Hive Metastore client will read the configuration property hive.metastore.uris to get a list of Metastore servers with which it can try to communicate.

<property>
 <name> hive.metastore.uris </name>
 <value> thrift://$Hive_Metastore_Server_Host_Machine_FQDN </value>
 <description> A comma separated list of Metastore uris on which Metastore service is running </description>
</property>

Note that the relational database that backs the Hive Metastore itself should also be made highly available using the best practices defined for the database system in use.

In the case of a secure cluster, add the following configuration property to the hive-site.xml file for each Metastore server:

<property>
 <name> hive.cluster.delegation.token.store.class</name>
 <value>org.apache.hadoop.hive.thrift.ZooKeeperTokenStore</value>
</property>

Failover Scenario

The Hive metastore client randomly chooses a metastore URI when multiple metastores are configured, which helps in load-balancing.