Getting NoClassDefFoundError when class does exist in classpath

I am not sure if this is the right area to post this question. The issue is related to JVM and/or Weblogic 9.2.

We have a client/server application using Java 1.5.1_10. Classes are in either the server or client jars. We have recently upgraded our development environment from Java 1.3/Weblogic 7x to Java 1.5.1_10/Weblogic 9.2. Every now and then while using the application we get the java.lang.NoClassDefFoundError on a class. The error is on a different class each time, and the class does exist in the server jar file which is in the class path. Other areas of the application works fine, that is, we are able to access other classes during normal use of the application. Just that particular area of the application keeps giving the "NoClassDefFoundError" until we restart the Weblogic server (without changing anything else).

Our JVM heap size is set to 1024m (Xms and Xmx). Server has 8 Gig available. The issue happens on AIX and Solaris, both running Weblogic 9.2 and same application code.

I will appreciate any suggestion or information that may help narrow down this issue.

Thanks.

Theta.

[1138 byte] By [Thetaa] at [2007-11-27 0:53:36]
# 1
This exception often means that the .class file was found but didn't contain the class expected, e.g. its package and its directory didn't agree.
ejpa at 2007-7-11 23:25:35 > top of Java-index,Core,Core APIs...
# 2
In our case the packages are fine, as the same code works without any issue under Java 1.3/Weblogic 7.Theta.
Thetaa at 2007-7-11 23:25:35 > top of Java-index,Core,Core APIs...
# 3

You probably need to recompile with the new jars in the path. Or the new jar containing the proper interfaces.

Likely what has happened is the library writers have recompiled the interface package. Eventhough no classes in it have changed. its probably their blunder.

Also someone mentioned that this can happen if your classes are on a windows network share drive.

_dnoyeBa at 2007-7-11 23:25:35 > top of Java-index,Core,Core APIs...
# 4

We had recompiled the new jars several times and have restarted the app server too. That fixes the problem for some duration of time but then at some point we get the "NoClassDefFoundError".

Our classes are not on windows network share drive, they are on Unix.

I did not understand what you meant by the following:

>Likely what has happened is the library writers have recompiled the >interface package. Eventhough no classes in it have changed. its >probably their blunder.

Thanks.

Theta.

Thetaa at 2007-7-11 23:25:35 > top of Java-index,Core,Core APIs...
# 5

Sometimes when you are using classes from an external source, they will provide you with one jar that is full of interfaces and a 2nd jar that has the actual implementation. If they recompiled both jars but you only changed one, it can cause odd issues eventhough it should not.

But since your problems are not consistent I would look toward a JVM or OS bug. Are the OS permissions on the jar file stable?

_dnoyeBa at 2007-7-11 23:25:35 > top of Java-index,Core,Core APIs...
# 6

If by stable you mean the rwx on jar files, Yes, the permissions on jar files are stable, we don't change them dynamically. I have opened up issues with both BEA and Sun at this point. I was just wondering if anyone has come across similar issue. The thing is we have upgraded from Java 1.3 to Java 1.5 and from Weblogic 7.02 to Weblogic 9.2.

Thetaa at 2007-7-11 23:25:35 > top of Java-index,Core,Core APIs...