Exception in thread "main" java.lang.NoClassDefFoundError

0 votes

Please help me solve this error:

$ HADOOP_CLASSPATH="${HBASE_HOME}/bin/hbase classpath" hadoop jar /opt/cloudera/parcels/CDH/lib/hbase/hbase
-server-1.2.0-cdh5.11.1.jar importtsv -Dimporttsv.separator=, -Dimporttsv.bulk.output=output -Dimporttsv.columns=HBAE_ROW_KEY,info:id,info:f
name,info:lname,info:age,info:prof customers custs
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/hadoop/hbase/filter/Filter
at java.lang.Class.getDeclaredMethods0(Native Method)
at java.lang.Class.privateGetDeclaredMethods(Class.java:2701)
at java.lang.Class.privateGetMethodRecursive(Class.java:3048)
at java.lang.Class.getMethod0(Class.java:3018)
at java.lang.Class.getMethod(Class.java:1784)
at org.apache.hadoop.util.ProgramDriver$ProgramDescription.(ProgramDriver.java:59)
at org.apache.hadoop.util.ProgramDriver.addClass(ProgramDriver.java:103)
at org.apache.hadoop.hbase.mapreduce.Driver.main(Driver.java:42)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.apache.hadoop.util.RunJar.run(RunJar.java:221)
at org.apache.hadoop.util.RunJar.main(RunJar.java:136)
Caused by: java.lang.ClassNotFoundException: org.apache.hadoop.hbase.filter.Filter
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
... 14 more
Aug 9 in Big Data Hadoop by Reshma
32 views

1 answer to this question.

0 votes

As far I can make out from the command used by you as below:

HADOOP_CLASSPATH="${HBASE_HOME}/bin/hbase classpath" hadoop jar /opt/cloudera/parcels/CDH/lib/hbase/hbase
-server-1.2.0-cdh5.11.1.jar importtsv -Dimporttsv.separator=, -Dimporttsv.bulk.output=output -Dimporttsv.columns=HBAE_ROW_KEY,info:id,info:f
name,info:lname,info:age,info:prof customers custs

You are using double quotes (i.e., ") before $. It should not be double quotes, instead it should be backtick which is present just below the esc button in the keypad.

Also the table name that you are using, make sure it is unique. Since if this table already exists you will not be able to execute bulk load operation.

answered Aug 9 by Arpit

Related Questions In Big Data Hadoop

+1 vote
2 answers
0 votes
1 answer

Hadoop Java Error: java.lang.NoClassDefFoundError: WordCount (wrong name: org/myorg/WordCount)

Hey, try this code import java.io.IOException; import java.util.Iterator; import java.util.StringTokenizer; import ...READ MORE

answered Sep 19, 2018 in Big Data Hadoop by slayer
• 29,050 points
877 views
0 votes
1 answer

Hadoop Pig: java.lang.NoClassDefFoundError: org/apache/hadoop/hbase/filter/Filter

This seems like a problem with the ...READ MORE

answered Nov 16, 2018 in Big Data Hadoop by Omkar
• 67,460 points
217 views
0 votes
1 answer

Hadoop Mapreduce word count Program

Firstly you need to understand the concept ...READ MORE

answered Mar 16, 2018 in Data Analytics by nitinrawat895
• 10,670 points
2,698 views
0 votes
1 answer

hadoop.mapred vs hadoop.mapreduce?

org.apache.hadoop.mapred is the Old API  org.apache.hadoop.mapreduce is the ...READ MORE

answered Mar 16, 2018 in Data Analytics by nitinrawat895
• 10,670 points
284 views
0 votes
10 answers

hadoop fs -put command?

put syntax: put <localSrc> <dest> copy syntax: copyFr ...READ MORE

answered Dec 7, 2018 in Big Data Hadoop by Aditya
13,421 views
0 votes
1 answer

Hadoop dfs -ls command?

In your case there is no difference ...READ MORE

answered Mar 16, 2018 in Big Data Hadoop by kurt_cobain
• 9,240 points
983 views
0 votes
2 answers