设为首页 加入收藏

TOP

Hbase Shell启动失败
2019-04-14 13:48:03 】 浏览:111
Tags:Hbase Shell 启动 失败

最近一个新部署一个gateway,用户在执行hbase shell的方式连接hbase,报错

[testuser@ip-192-168-133-238lib]$hbaseshell
SLF4J:ClasspathcontainsmultipleSLF4Jbindings.
SLF4J:Foundbindingin[jar:file:/usr/local/hadoop/hbase-1.1.3/lib/kylin-jdbc-1.5.2.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J:Foundbindingin[jar:file:/usr/local/hadoop/hbase-1.1.3/lib/kylin-job-1.5.2.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J:Foundbindingin[jar:file:/usr/local/hadoop/hbase-1.1.3/lib/slf4j-log4j12-1.7.5.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J:Foundbindingin[jar:file:/usr/local/hadoop/hadoop-2.7.1/share/hadoop/common/lib/slf4j-log4j12-1.7.10.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J:Seehttp://www.slf4j.org/codes.html#multiple_bindingsforanexplanation.
SLF4J:Actualbindingisoftype[org.slf4j.impl.Log4jLoggerFactory]
NativeException:java.io.IOException:java.lang.reflect.InvocationTargetException
initializeat/usr/local/hadoop/hbase-release/lib/ruby/hbase/hbase.rb:42
(root)at/usr/local/hadoop/hbase-release/bin/hirb.rb:118


经过百度,解决问题。是由于testuesr对hbase.tmp.dir设置的路径,没有读写权限。添加权限即可。(实际上是我根本就没有创建这个路径。由于是gateway,只是利用一下hbase的软件和配置文件作为客户端。也不启动它。自然也就没有想到这些路径还会影响到hbase shell的使用。)

Unabletostarthbaseshellduetojava.io.IOException:java.lang.reflect.InvocationTargetException

SYMPTOM:
Whenattemptingtoexecute"hbaseshell"asanon-root/non-hbaseuser,hbaseshellfailswiththefollowingexception:
[jyoung@jyoung-hdp234-1~]$hbaseshell
SLF4J:ClasspathcontainsmultipleSLF4Jbindings.
SLF4J:Foundbindingin[jar:file:/usr/hdp/2.3.4.0-3485/hadoop/lib/slf4j-log4j12-1.7.10.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J:Foundbindingin[jar:file:/usr/hdp/2.3.4.0-3485/zookeeper/lib/slf4j-log4j12-1.6.1.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J:Seehttp://www.slf4j.org/codes.html#multiple_bindingsforanexplanation.
SLF4J:Actualbindingisoftype[org.slf4j.impl.Log4jLoggerFactory]
NativeException:java.io.IOException:java.lang.reflect.InvocationTargetException
initializeat/usr/hdp/2.3.4.0-3485/hbase/lib/ruby/hbase/hbase.rb:42
(root)at/usr/hdp/2.3.4.0-3485/hbase/bin/hirb.rb:131
ROOTCAUSE:
Theuserofhbaseshellneedsreadandwritepermissionsonthehbasetmpdirectoryconfiguredbythehbase.tmp.dirpropertyinhbase-site.xml.
Toverifyyourhbasetmpdirectoryconfigurationsettings:
[root@jyoung-hdp234-1~]#grep-C2"hbase.tmp.dir"/etc/hbase/conf/hbase-site.xml
<property>
<name>hbase.local.dir</name>
<value>${hbase.tmp.dir}/local</value>
</property>

--

<property>
<name>hbase.tmp.dir</name>
<value>/tmp/hbase-${user.name}</value>
</property>
RESOLUTION:
Ensuretheusersofhbaseshellhavereadandwritepermissionsforhbase.tmp.dir


参考链接:

https://community.hortonworks.com/content/supportkb/150642/unable-to-start-hbase-shell-due-to-javaioioexcepti.html


】【打印繁体】【投稿】【收藏】 【推荐】【举报】【评论】 【关闭】 【返回顶部
上一篇java连接有kerberos认证的hbase 下一篇HBase核心概念(LSM树、底层持久..

最新文章

热门文章

Hot 文章

Python

C 语言

C++基础

大数据基础

linux编程基础

C/C++面试题目