Created 01-10-2017 06:10 AM
Hi All,
I'm running a mapReduce java program using the command shown below, the mapreduce program scans Hbase table and puts the data into hdfs.
mr.jar -> has the .class files
HADOOP_CLASSPATH=$(ls -1 /usr/hdp/current/hbase-client/lib/* | tr '\n', ':') yarn jar mr.jar hbase.labfiles.Exercise5.ProductAnalyzer -libjars $(ls -1 /usr/hdp/current/hbase-client/lib/* | tr '\n', ',')
This gives the following error ->
Exception in thread "main" java.io.FileNotFoundException: File /usr/hdp/current/hbase-client/lib/ojdbc6.jar does not exist. at org.apache.hadoop.util.GenericOptionsParser.validateFiles(GenericOptionsParser.java:405) at org.apache.hadoop.util.GenericOptionsParser.processGeneralOptions(GenericOptionsParser.java:299) at org.apache.hadoop.util.GenericOptionsParser.parseGeneralOptions(GenericOptionsParser.java:487) at org.apache.hadoop.util.GenericOptionsParser.<init>(GenericOptionsParser.java:170) at org.apache.hadoop.util.GenericOptionsParser.<init>(GenericOptionsParser.java:153) at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:70) at hbase.labfiles.Exercise5.ProductAnalyzer.main(ProductAnalyzer.java:69) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.hadoop.util.RunJar.run(RunJar.java:221) at org.apache.hadoop.util.RunJar.main(RunJar.java:136)
However, the file actually exists
[root@sandbox Exercise5]# ls -lrt /usr/hdp/current/hbase-client/lib/ojdbc6.jar lrwxrwxrwx 1 root root 26 2016-03-14 14:11 /usr/hdp/current/hbase-client/lib/ojdbc6.jar -> /usr/share/java/ojdbc6.jar
Any ideas what the issue is & how to fix this ?
Created 01-10-2017 06:12 AM
Can you check if /usr/share/java/ojdbc6.jar file exist. "/usr/hdp/current/hbase-client/lib/ojdbc6.jar" is symlink to /usr/share/java/ojdbc6.jar.
Created 01-10-2017 06:12 AM
Can you check if /usr/share/java/ojdbc6.jar file exist. "/usr/hdp/current/hbase-client/lib/ojdbc6.jar" is symlink to /usr/share/java/ojdbc6.jar.
Created 01-10-2017 06:16 AM
actually the file - /usr/share/java/ojdbc6.jar does not exist, though the symlink exists.
This is the default installation, so wondering how come the symlink exists but the file does not !
so, what needs to be done to fix this ? drop the symlink ?
Created 01-10-2017 06:23 AM
@Karan AlangDownload ojdbc6.jar and copy to the location /usr/share/java/ You can download ojdbc6.jar from http://www.oracle.com/technetwork/apps-tech/jdbc-111060-084321.html
Created 01-10-2017 06:30 AM