hive1.2.1安装详解(亲测有效)

1、下载apache-hive-1.2.1-bin.tar.gz并解压
$tar -xf apache-hive-1.2.1-bin.tar.gz
$cd apache-hive-1.2.1-bin
$cd conf

2、复制hive-env.sh.tmplate为hive-env.sh,复制hive-default.xml.tmplate为hive-site.xml

1)$vim hive-env.sh,增加如下内容
HADOOP_HOME=/usr/local/hadoop-2.6.0
export HIVE_CONF_DIR=/usr/local/hadoop-2.6.0/apache-hive-1.2.1-bin/conf
export HIVE_HOME=/usr/local/hadoop-2.6.0/apache-hive-1.2.1-bin

2)$vim hive-site.xml,修改如下内容:
< property >
< name>hive.exec.scratchdir< /name>
< !–< value>/tmp/hive< /value>–>
< value>hdfs://Master:9000/hive/scratchdir< /value>
< description>HDFS root scratch dir for Hive jobs which gets created with write all (733) permission. For each connecting user, an HDFS scratch dir: ${hive.exec.scratchdir}/<username> is created, with ${hive.scratch.dir.permission}.< /description>
< /property>
< property>
< name>hive.exec.local.scratchdir< /name>
< !–< value>${/usr/local/hadoop-2.6.0/apache-hive-1.2.1-bin/iotmp}/${system:user.name}< /value>–>
< value>/usr/local/hadoop-2.6.0/apache-hive-1.2.1-bin/iotmp< /value>
< description>Local scratch space for Hive jobs< /description>
< /property>
< property>
< name>hive.downloaded.resources.dir< /name>

< value>/usr/local/hadoop-2.6.0/apache-hive-1.2.1-bin/iotmp< /value>
< description>Temporary local directory for added resources in the remote file system.< /description>
< /property>
< property>
< name>hive.metastore.warehouse.dir< /name>
< !–< value>/user/hive/warehouse< /value>–>
< value>hdfs://Master:9000/hive/warehousedir
< description>location of default database for the warehouse

< property>
< name>hive.metastore.uris
< value/>
< !–< value>thrift://Master:9084–>
< description>Thrift URI for the remote metastore. Used by metastore client to connect to remote metastore.

< property>
< name>javax.jdo.option.ConnectionPassword
< !–< value>mine–>
< value>h

  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值