简体   繁体   中英

Info:Error: java.lang.ClassNotFoundException: org.apache.hadoop.hbase.util.Bytes

I was using my UDF in my pig script this morning without any problem. But now when I try I receive this error message:

Info:Error: java.lang.ClassNotFoundException: org.apache.hadoop.hbase.util.Bytes

I guess it means I miss a hbase jar in my classpath!! But I change nothing!

How can I fix that?

An example of how I can add the hbase jar will be great!!

I solve it by registering hbase in my pig script.

REGISTER path/to/hbase/jar

In my case

REGISTER /usr/lib/hbase/hbase.jar;

Add hbase jar into class path. If you are running it form command line then use java -cp to add jar in class path.

You have to add HBase jar file into your class path. You can also seee Hbase installation stuff at this site :

http://www.improgrammer.net/tag/hbase/

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM