hadoop-hdfs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sampath Herga <sampat...@gmail.com>
Subject Issue with third party library
Date Wed, 05 Dec 2012 11:53:42 GMT

I was just trying to setup hadoop and run some sample programs. I ran into
some issues when trying to add a required library. I tried using the
DistributedCache methods to try adding to the classpath.

The basic code is:
  Path mysqlJar = new
  fs.copyFromLocalFile(mysqlJar, mysqlJar);
  DistributedCache.addArchiveToClassPath(mysqlJar, jobConf, fs);

I did a copyFromLocal since I wasnt sure where it would get picked from. I
tried both addArchiveToClassPath and addFileToClassPath. But with both, I
get a ClassNotFoundException.

Caused by: java.lang.RuntimeException: java.lang.ClassNotFoundException:
    ... 16 more

The job seems to have got the file added and also checked in the
tasktracker local dir and the file seems to be present.


Any clues would be helpful. I dont think I can use -libjars since I am
trying to execute the hadoop jobs from within another application and not
from the command line.


View raw message