立即注册 登录
About云-梭伦科技 返回首页

desehawk的个人空间 https://www.aboutyun.com/?29 [收藏] [复制] [分享] [RSS]

日志

oozie运行hive以及hive的udf

已有 1443 次阅读2014-12-21 12:09

一, 
执行hiveAction除了需要配置oozie.hive.defaults外,还需要配置几个hive的参数。 
这点我不是很理解,以为只要在hive-site.xml里面配置了,就完事了,结果不行,还需要单独配置,而且oozie.hive.defaults不配置还不行。 
配置如下: 


<property>
    <name>oozie.hive.defaults</name>
    <value>my-hive-default.xml</value>
</property>

<property>
  <name>hive.metastore.local</name>
  <value>false</value>
  <description>controls whether to connect to remove metastore server or open a new metastore server in Hive Client JVM</description>
</property>

<property>
  <name>hive.metastore.uris</name>
  <value>thrift://xx.xx.xx.xx:9083</value>
  <description>host and port for the thrift metastore server</description>
</property>

<property>
  <name>hive.metastore.warehouse.dir</name>
  <value>/hive/warehouse0</value>
  <description>location of default database for the warehouse</description>
</property>

二, 
执行hive的udf时,不需要在hive脚本里面写add /xxx/xxx/xxx/HIVE_UDF.jar. 
只要保证这个HIVE_UDF.jar在sharelib里面,或者file指定应该也行(这个没试,猜的)。 
那个create temporary function xxxxx as 'yyy';还是要在脚本里面写的。 



路过

雷人

握手

鲜花

鸡蛋

评论 (0 个评论)

facelist doodle 涂鸦板

您需要登录后才可以评论 登录 | 立即注册

关闭

推荐上一条 /2 下一条