java.lang.ClassNotFoundException: org.jnp.interfaces.NamingContextFactory

One my colleague was trying to monitor one of JBoss Server from Hyperic. While configuring the Hperic Agent he was getting the following exception:

The configuration has not been set for this resource due to : Invalid configuration: Error contacting resource: Can't connect to MBeanServer 

[java.naming.provider.url=jnp%3A//localhost%3A1099,
java.naming.security.principal=,java.naming.security.credentials=]: javax.naming.NoInitialContextException: Cannot instantiate class: org.jnp.interfaces.NamingContextFactory 
[Root exception is java.lang.ClassNotFoundException: 
org.jnp.interfaces.NamingContextFactory]

Searched the forums and found that it is the problem related to JNDI. So what we tried was that we put jbossall-client.jar in the one of lib directory of Hyperic Agent and the problem solved.

References:

About these ads

3 Comments

Filed under Errors/Exceptions, Java / Java EE

3 Responses to java.lang.ClassNotFoundException: org.jnp.interfaces.NamingContextFactory

  1. Yogesh

    Sir, i have “javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial” while running my client

  2. Yogesh

    Please tell me steps to write the EJB 3.1 application ( procedure to write beans and client ) , Thanx in Advance..

  3. I LOVE YOU Ranjan !!! Thanks a lot for this help…

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s