×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

NoClassDefFoundError on the managed server which comes up second ..

NoClassDefFoundError on the managed server which comes up second ..

NoClassDefFoundError on the managed server which comes up second ..

(OP)
Hi

I have a cluster on weblogic 8.1 sp6 with two managed servers and when I deploy my application onto that I get NoClassDefFoundError while looking up (jndi lookup) the session bean on the managed server which comes up second.

I have checked the JNDI trees on both servers and they look good and I have checked that the application(and EJB) are deployed on both the managed servers through the admin server console.

The client that I am trying to look up from is deployed on another ear (diff. application).

Also there are some other beans deployed on the same ear which I am able to look up.

If I deploy this application on a cluster where both the managed servers are on the same machine and then start both managed servers through admin console, they come up simultaneously and I don't get any issue on both the servers, but even on this machine if i start one managed server first and then the second one, I am getting this problem on the server which comes up second.

Why is this problem always occurring on the managed server which comes up second, it works well on the first one?

Also this application works well on a single server deployment.

Here is the stack trace:

java.lang.NoClassDefFoundError: com/cc/aa/ejb/obj/HHLocalHome at java.lang.Class.getDeclaredMethods0(Native Method) at java.lang.Class.privateGetDeclaredMethods(Class.java:1655) at java.lang.Class.getMethod0(Class.java:1901) at java.lang.Class.getMethod(Class.java:984) at com.cc.aa.service.data.dd.am.ejb.AcMa_sbdv2o_HomeImpl.(AcMa_sbdv2o_HomeImpl.java:231) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:219) at weblogic.j2ee.ApplicationManager.loadClass(ApplicationManager.java:277) at weblogic.j2ee.ApplicationManager.loadClassWithNoDependencyClassLoader(ApplicationManager.java:233) at weblogic.rmi.cluster.ReplicaAwareRemoteObject.getPrimaryRepresentative(ReplicaAwareRemoteObject.java:92) at weblogic.rmi.cluster.ClusterableRemoteObject.getReferent(ClusterableRemoteObject.java:109) at weblogic.jndi.internal.WLNamingManager.getObjectInstance(WLNamingManager.java:90) at weblogic.jndi.internal.ServerNamingNode.resolveObject(ServerNamingNode.java:292) at weblogic.jndi.internal.BasicNamingNode.resolveObject(BasicNamingNode.java:798) at weblogic.jndi.internal.BasicNamingNode.lookup(BasicNamingNode.java:191) at weblogic.jndi.internal.BasicNamingNode.lookup(BasicNamingNode.java:196) at weblogic.jndi.internal.BasicNamingNode.lookup(BasicNamingNode.java:196) at weblogic.jndi.internal.WLEventContextImpl.lookup(WLEventContextImpl.java:258) at weblogic.jndi.internal.WLContextImpl.lookup(WLContextImpl.java:363) at javax.naming.InitialContext.lookup(InitialContext.java:347) at com.cc.aa.tool.loc.BeanLocator.getObjFromJndi(BeanLocator.java:321) at ........

This stack trace come on the first hit when the second server comes up. Here HHLocalHome is the local home class for an entity bean which is referred in the "AcMaBean" which is the session bean whose lookup fails. Ejb jars for the entity bea and the session bean are packaged in same ear.


Here is the stack trace for NoClassDefFoundError which occurs at lookup for the "AcMaBean" session bean on all the subsequent hits to the second server:


java.lang.NoClassDefFoundError at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:219) at weblogic.j2ee.ApplicationManager.loadClass(ApplicationManager.java:277) at weblogic.j2ee.ApplicationManager.loadClassWithNoDependencyClassLoader(ApplicationManager.java:233) at weblogic.rmi.cluster.ReplicaAwareRemoteObject.getPrimaryRepresentative(ReplicaAwareRemoteObject.java:92) at weblogic.rmi.cluster.ClusterableRemoteObject.getReferent(ClusterableRemoteObject.java:109) at weblogic.jndi.internal.WLNamingManager.getObjectInstance(WLNamingManager.java:90) at weblogic.jndi.internal.ServerNamingNode.resolveObject(ServerNamingNode.java:292) at weblogic.jndi.internal.BasicNamingNode.resolveObject(BasicNamingNode.java:798) at weblogic.jndi.internal.BasicNamingNode.lookup(BasicNamingNode.java:191) at weblogic.jndi.internal.BasicNamingNode.lookup(BasicNamingNode.java:196) at weblogic.jndi.internal.BasicNamingNode.lookup(BasicNamingNode.java:196) at weblogic.jndi.internal.WLEventContextImpl.lookup(WLEventContextImpl.java:258) at weblogic.jndi.internal.WLContextImpl.lookup(WLContextImpl.java:363) at javax.naming.InitialContext.lookup(InitialContext.java:347) at com.cc.aa.tool.loc.BeanLocator.getObjFromJndi(BeanLocator.java:321) at ......


Please suggest what can be done to resolve this issue, any help will really be appreciated.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login


Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close