Upgrading the Hive Metastore to Use HDFS HA Using the Command Line

To configure the Hive metastore to use HDFS HA, change the records to
reflect the location specified in the dfs.nameservices property, using the
Hive metatool to obtain and change the locations.
  *Note*: Before attempting to upgrade the Hive metastore to use HDFS HA,
shut down the metastore and back it up to a persistent store.

If you are unsure which version of Avro SerDe is used, use both the
serdePropKey and tablePropKey arguments. For example:

$ metatool -listFSRoot
hdfs://oldnamenode.com/user/hive/warehouse
$ metatool -updateLocation hdfs://nameservice1 hdfs://oldnamenode.com
-tablePropKey avro.schema.url
-serdePropKey schema.url
$ metatool -listFSRoot
hdfs://nameservice1/user/hive/warehouse

where:

   - hdfs://oldnamenode.com/user/hive/warehouse identifies the NameNode
   location.
   - hdfs://nameservice1 specifies the new location and should match the
   value of the dfs.nameservices property.
   - tablePropKey is a table property key whose value field may reference
   the HDFS NameNode location and hence may require an update. To update the
   Avro SerDe schema URL, specify avro.schema.url for this argument.
   - serdePropKey is a SerDe property key whose value field may reference
   the HDFS NameNode location and hence may require an update. To update the
   Haivvero schema URL, specify schema.url for this argument.


On Tue, May 5, 2015 at 4:03 PM, r7raul1...@163.com <r7raul1...@163.com>
wrote:

>
> I want to turn my single namenode to namenode HA.  How to config hive ?
> ------------------------------
> r7raul1...@163.com
>

Reply via email to