`
ouyida3
  • 浏览: 47949 次
  • 性别: Icon_minigender_1
  • 来自: 广州
社区版块
存档分类
最新评论

ubuntu安装hive

 
阅读更多
从机器上拷贝hive包(因为我在windows上已经下载,并且安装不成功),解压;
然后export HADOOP_HOME和HIVE_HOME
安装成功。

bin/hive即可。

想不到在windows上搞不天不行,在ubuntu是这么easy。

===========

hadoop@ubuntu:~/hive-0.7.1$ bin/hive
Cannot find hadoop installation: $HADOOP_HOME must be set or hadoop must be in the path
配上hadoophome即可


hive> create table tt(id int,name string) row format delimited fields terminated by "," collection items terminated by "\n" stored as textfile;
FAILED: Error in metadata: MetaException(message:Got exception: java.io.FileNotFoundException File file:/user/hive/warehouse/tt does not exist.)
FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask
参考:
http://yymmiinngg.iteye.com/?show_full=true
$HADOOP_HOME/bin/hadoop fs -mkdir /user/hive/warehouse
注意是user不是usr哦

分享到:
评论
1 楼 Jerrick 2012-02-17  
我也是在windows上利用cygwin搭建的hadoop环境,在安装好hive后,配置环境变量后

Administrator@03ad6b3ba2f34fe /cygdrive/d/hive-0.7.1
$ ./bin/hive --auxpath
Hive history file=/tmp/Administrator/hive_job_log_Administrator_201202171651_1556716221.txt
hive> show tables;

Administrator@03ad6b3ba2f34fe /cygdrive/d/hive-0.7.1
$ ./bin/hive --service cli
Hive history file=/tmp/Administrator/hive_job_log_Administrator_201202171706_1590927976.txt
hive> show tables;

都不报错,但是一直没有反应。查看了下日志,只有这么一行“SessionStart SESSION_ID="Administrator_201202171651" TIME="1329468709843” 我初学,不知道什么原因,希望您能帮忙看看,谢谢

相关推荐

Global site tag (gtag.js) - Google Analytics