Hi, It works for me now. Just for the record, I had to copy junit*.jar to buil/lib because fat.jar expects it to be there. Then, I had to rebuild fatjar.jar.
On Wed, Apr 7, 2010 at 12:10 AM, Vishal K <vishalm...@gmail.com> wrote: > Hi, > > I am trying to run systest on a 3 node cluster ( > http://svn.apache.org/repos/asf/hadoop/zookeeper/trunk/src/java/systest/README.txt > ). > > When I reach the 4th step which is to actually run the test I get exception > shown below. > > Exception in thread "main" java.lang.NoClassDefFoundError: > junit/framework/TestC > ase > at java.lang.ClassLoader.defineClass1(Native Method) > at java.lang.ClassLoader.defineClassCond(ClassLoader.java:632) > at java.lang.ClassLoader.defineClass(ClassLoader.java:616) > at > java.security.SecureClassLoader.defineClass(SecureClassLoader.java:14 > 1) > at java.net.URLClassLoader.defineClass(URLClassLoader.java:283) > at java.net.URLClassLoader.access$000(URLClassLoader.java:58) > at java.net.URLClassLoader$1.run(URLClassLoader.java:197) > at java.security.AccessController.doPrivileged(Native Method) > at java.net.URLClassLoader.findClass(URLClassLoader.java:190) > at java.lang.ClassLoader.loadClass(ClassLoader.java:307) > at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) > at java.lang.ClassLoader.loadClass(ClassLoader.java:248) > at java.lang.Class.forName0(Native Method) > at java.lang.Class.forName(Class.java:169) > at org.apache.zookeeper.util.FatJarMain.main(FatJarMain.java:97) > Caused by: java.lang.ClassNotFoundException: junit.framework.TestCase > at java.net.URLClassLoader$1.run(URLClassLoader.java:202) > at java.security.AccessController.doPrivileged(Native Method) > at java.net.URLClassLoader.findClass(URLClassLoader.java:190) > at java.lang.ClassLoader.loadClass(ClassLoader.java:307) > at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) > at java.lang.ClassLoader.loadClass(ClassLoader.java:248) > ... 15 more > > Looks like it is not able to find classes in junit. However, my classpath > is set right: > > > :/opt/zookeeper-3.3.0/zookeeper.jar:/opt/zookeeper-3.3.0/lib/junit-4.4.jar:/opt/ > > zookeeper-3.3.0/lib/log4j-1.2.15.jar:/opt/zookeeper-3.3.0/build/test/lib/junit-4.8.1.jar > > Any suggestions how I can get around this problem? Thanks. >