Skip to main content
  • Place orders quickly and easily
  • View orders and track your shipping status
  • Enjoy members-only rewards and discounts
  • Create and access a list of your products
  • Manage your Dell EMC sites, products, and product-level contacts using Company Administration.

ECS 3.6.2 Data Access Guide

PDF

Set up Hive

The additional steps provided in this procedure a required to configure Hive.

When using Hive, you should also ensure that the Hive metastore warehouse is being directed to the ViPRFS location. Assuming that mysql is being used to identify the Hive metastore location, start mysql, go to the Hive databases, and show the contents of the DBS table and set it as below.
  1. If Hive is using templeton, you should modify the following properties, and these properties are already defined.
    Table 1. Hive templeton configurationThe table lists te Hive templeton configuration
    Hadoop location Property Value (example)
    Advanced webhcat-site templeton.hive.archive viprfs://hdfsBucket2.s3.site1/hdp/apps/${hdp.version}/hive/hive.tar.gz
    templeton.pig.archive viprfs://hdfsBucket2.s3.site1/hdp/apps/${hdp.version}/pig/pig.tar.gz
    templeton.sqoop.archive viprfs://hdfsBucket2.s3.site1/hdp/apps/${hdp.version}/sqoop/sqoop.tar.gz
    templeton.streaming.jar viprfs://hdfsBucket2.s3.site1/hdp/apps/${hdp.version}/mapreduce/hadoop-streaming.jar
  2. Start mysql.
    [root@hdfs-pansy2 lib]# mysql -u hive -p
    Enter password: 
    Welcome to the MySQL monitor.  Commands end with ; or \g.
    
  3. Go to the Hive database.
    mysql> use hive;
    Reading table information for completion of table and column names
    You can turn off this feature to get a quicker startup with -A
    
  4. Show the contents of the database.
    select * from DBS;
    +------+-------------+-----------------------------------+--------+-------+------+
    |DB_ID | DESC        | DB_LOCATION_URI                   | NAME   | OWNER | OWNER|
    |      |             |                                   |        | _NAME | _TYPE|
    +------+-------------+-----------------------------------+--------+-------+------+
    |  1   | Default Hive| hdfs://hdfs-pansy1.ecs.lab.emc.   |default |public |ROLE  |
    |      | database    | com:8020/apps/hive/warehouse      |        |       |      |
    |      |             |                                   |        |       |      |
    |  6   | NULL        | viprfs://hdfsbucket.ns.Site1/     |retail  |hdfs   |USER  |
    |      |             | apps/hive/warehouse/retail_demo.db| _demo  |       |      |
    +------+-------------+-----------------------------------+--------+-------+------+
    2 rows in set (0.00 sec)
    
    
  5. Change the database.
    mysql> update DBS set DB_LOCATION_URI='viprfs://hdfsbucket3.ns.Site1/apps/hive/warehouse' where DB_ID=1;
    Query OK, 1 row affected (0.00 sec)
    Rows matched: 1  Changed: 1  Warnings: 0
    

Rate this content

Accurate
Useful
Easy to understand
Was this article helpful?
0/3000 characters
  Please provide ratings (1-5 stars).
  Please provide ratings (1-5 stars).
  Please provide ratings (1-5 stars).
  Please select whether the article was helpful or not.
  Comments cannot contain these special characters: <>()\