hbase shell: TypeError: can't dup NilClass

可紊 提交于 2019-12-23 23:08:42

问题


I'm getting this strange error when trying to launch hbase shell. I'm using CDH5.

# hbase shell
TypeError: can't dup NilClass
         dup at org/jruby/RubyKernel.java:1940
  initialize at file:/usr/lib/hbase/lib/jruby-complete-1.6.8.jar!/META-INF/jruby.home/lib/ruby/1.8/pathname.rb:212
      (root) at /usr/lib/hbase/bin/../bin/hirb.rb:41

Has it occurred to anyone? How can I resolve this?


回答1:


I faced a similar exception. The reason was because, my older version of hbase was actually pointed in the path. so when I type hbase shell, the older hbase was invoked. I corrected my environment variables properly and pointed it to new hbase, then it was working fine. So yours will be also similar issue.

export HBASE_HOME=<add the proper path to hbase-dir>
export PATH=$HBASE_HOME/bin:$PATH

This worked for me.



来源:https://stackoverflow.com/questions/23782879/hbase-shell-typeerror-cant-dup-nilclass

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!