User-Defined Functions (UDFs) with HiveServer2 Using Cloudera Manager
来源:互联网 发布:华中科技大学网络 编辑:程序博客网 时间:2024/05/18 07:00
Creating Permanent Functions
- Copy the JAR file to HDFS and make sure the hive user can access this JAR file.
- Copy the JAR file to the host on which HiveServer2 is running. Save the JARs to any directory you choose, give the hive user read, write, and execute access to this directory, and make a note of the path (for example,/opt/local/hive/lib/).
- In the Cloudera Manager Admin Console, go to the Hive service.
- Click the Configuration tab.
- Expand the categories.
- Configure the Hive Auxiliary JARs Directory property with the HiveServer2 host path from Step 1, /opt/local/hive/lib/.
- Click Save Changes. The JARs are added to HIVE_AUX_JARS_PATH environment variable.
- Redeploy the Hive client configuration.
- In the Cloudera Manager Admin Console, go to the Hive service.
- From the Actions menu at the top right of the service page, select Deploy Client Configuration.
- Click Deploy Client Configuration.
- Restart the Hive service. If the Hive Auxiliary JARs Directory property is configured but the directory does not exist, HiveServer2 will not start.
- If Sentry is enabled - Grant privileges on the JAR files to the roles that require access. Login to Beeline as user hive and use the Hive SQL GRANT statement to do so. For example:
GRANT ALL ON URI 'file:///opt/local/hive/lib/my.jar' TO ROLE EXAMPLE_ROLE
You must also grant privilege to the JAR on HDFS:GRANT ALL ON URI 'hdfs:///path/to/jar' TO ROLE EXAMPLE_ROLE
- Run the CREATE FUNCTION command and point to the JAR file location in HDFS. For example:
CREATE FUNCTION addfunc AS 'com.example.hiveserver2.udf.add' USING JAR 'hdfs:///path/to/jar'
0 0
- User-Defined Functions (UDFs) with HiveServer2 Using Cloudera Manager
- Hive Operators and User-Defined Functions (UDFs)
- UDFs — User-Defined Functions
- Hive Operators and User-Defined Functions (UDFs) hive 日期函数
- User Defined Functions
- Transact SQL User Defined Functions
- Table-Valued User-Defined Functions
- Invoking CLR User-Defined Aggregate Functions
- Using User Defined Types in COM & ATL
- Using User Defined Types in COM & ATL
- cloudera manager
- cloudera manager
- cloudera manager
- eXtremeDB stored procedure & Dynaimically-loaded user defined functions
- AWK学习笔记-2.3User-Defined Functions自定义函数
- The way of enabling HDFS HA by using Cloudera-manager
- ALV with user defined menu on toolbar
- c++ container with user defined compare function
- Spiral Matrix II
- python 单元测试
- Selenium webdriver 学习总结-元素定位
- C++中class和struct的区别
- Windows下配置nginx+php(wnmp)
- User-Defined Functions (UDFs) with HiveServer2 Using Cloudera Manager
- 《windows核心编程系列》三谈谈内核对象及句柄的本质
- 大数据在火电厂中的技术
- 拿到6个offer的面试经验-2015年硬件类笔面试经历之面试篇(转)
- ubuntu下jdk安装问题
- unity中如何获取所有子物体的组件
- dispatch_after dispatch_group_async dispatch_once
- 专题分享
- SylixOS线程间通信-SylixOS信号量