I don't know what YOUR problem is, but I had a similar problem when using log4j in a web application.
Turned out that I had log4j JAR in one location, and some other application classes that use log4j in another location (location of a different classloader), and as a result I'd be able to compile, but I'd get these exceptions. > -----Original Message----- > From: Devender Marri [mailto:[EMAIL PROTECTED] > Sent: Tuesday, October 05, 2004 1:01 AM > To: [EMAIL PROTECTED] > Subject: java.lang.NoClassDefFoundError: org/apache/log4j/Category > > Hi All, > I am getting class not found exception when I am running my > application even when the class path is set properly. > > > Symptoms are as follows > 1) After starting the application it is able to log the messages > properly > 2) Class not found exception is thrown only when i excecute > Naming.rebind code > > Note: Please take note that it is definitely a class path problem, > as some of my codes are working properly. > > My environment is as follows > Java - JDK 1.3.1 > Log4j 1.2.8 > O.S Linux 8 > > Attached below is part of my log file which will give u a better > Idea. > > Thanks in advance for all the help. > > 1165 DEBUG [main] simios.framework.trn.SysHealthCfgFileData - > Total no of subsystems : 4 > 1166 DEBUG [main] simios.framework.trn.SysHealthCfgFileData - > Total no of subsystems : 4 > 1166 DEBUG [main] simios.framework.trn.SysHealthCfgFileData - > Total no of subsystems : 3 > 1167 DEBUG [main] simios.framework.trn.SysHealthCfgFileData - > Total no of subsystems : 3 > 1351 ERROR [main] amtios.ui.CRDN_MGM_ServerMainUI - > java.rmi.ServerError: Error occurred in server thread; nested > exception is: > java.lang.NoClassDefFoundError: org/apache/log4j/Category > java.lang.NoClassDefFoundError: org/apache/log4j/Category > at > sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemot > eCall.java:245) > at > sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:220) > at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:354) > at sun.rmi.registry.RegistryImpl_Stub.rebind(Unknown Source) > at java.rmi.Naming.rebind(Naming.java:160) > at > amtios.ui.CRDN_MGM_ServerMainUI.main(CRDN_MGM_ServerMainUI.java:142) > > > > > --- > Incoming mail is certified Virus Free. > Checked by AVG anti-virus system (http://www.grisoft.com). > Version: 6.0.772 / Virus Database: 519 - Release Date: 01.10.2004 > --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.772 / Virus Database: 519 - Release Date: 01.10.2004 --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
