配置Hbase查询 [英] Hive with Hbase Query
问题描述
我已经完成了与Hbase的整合
用于设置的版本
Hbase-0.98
Handoop-2.5
-h
blockquote>
当我使用子句开始查询时,查询如下所示
查询:select * from hbasehive_table by key;
我得到的错误不是,但Jar文件存在于相应的文件夹中
java.io.FileNotFoundException:文件不存在:
/home/hadoop/apache-hive-0.14.0-bin/lib /hbase-server-0.98.8-hadoop2.jar
at org.apache.hadoop.hdfs.DistributedFileSystem $ 17.doCall(DistributedFileSystem.java:1072)
at org.apache.hadoop.hdfs.DistributedFileSystem $ 17.doCall(DistributedFileSystem.java:1064)
在org.apache.hadoop.fs.FileSystemLinkResolver.resolve(FileSystemLinkResolver.java:8 1)
at org.apache.hadoop.hdfs.DistributedFileSystem.getFileStatus(DistributedFileSystem.java:1064)
解决方案试试这个,
sudo cp / usr / lib / hive / lib / hive-common- 0.7.0-cdh3u0.jar / usr / lib / hadoop / lib /
sudo cp /usr/lib/hive/lib/hbase-0.90.1-cdh3u0.jar / usr / lib / hadoop / lib /
2)使用以下COMMOND关闭HBASE和HADOOP
/usr/lib/hadoop/bin/stop-all.sh
/usr/lib/hbase/bin/stop-hbase.sh
<3>使用COMMOND重新启动HBASE和HADOOP/usr/lib/hadoop/bin/start-all.sh
/usr/lib/hadoop/bin/start-hbase.sh
I have done the integration with Hbase
Version used for setup
Hbase-0.98
Handoop-2.5
Hive-0.14
When I started the Query with Order by Clause The Query is mentioned below
Query : select * from hbasehive_table order by key;
I am getting below error , but Jar file is present in the respective folder
java.io.FileNotFoundException: File does not exist: /home/hadoop/apache-hive-0.14.0-bin/lib/hbase-server-0.98.8-hadoop2.jar at org.apache.hadoop.hdfs.DistributedFileSystem$17.doCall(DistributedFileSystem.java:1072) at org.apache.hadoop.hdfs.DistributedFileSystem$17.doCall(DistributedFileSystem.java:1064) at org.apache.hadoop.fs.FileSystemLinkResolver.resolve(FileSystemLinkResolver.java:81) at org.apache.hadoop.hdfs.DistributedFileSystem.getFileStatus(DistributedFileSystem.java:1064)
解决方案try this,
sudo cp /usr/lib/hive/lib/hive-common-0.7.0-cdh3u0.jar /usr/lib/hadoop/lib/ sudo cp /usr/lib/hive/lib/hbase-0.90.1-cdh3u0.jar /usr/lib/hadoop/lib/
2)CLOSE HBASE AND HADOOP USING FOLLOWING COMMOND
/usr/lib/hadoop/bin/stop-all.sh /usr/lib/hbase/bin/stop-hbase.sh
3) RESTART HBASE AND HADOOP USING COMMOND
/usr/lib/hadoop/bin/start-all.sh /usr/lib/hadoop/bin/start-hbase.sh
这篇关于配置Hbase查询的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!