This week's book giveaway is in the Cloud forum.
We're giving away four copies of Terraform in Action and have Scott Winkler on-line!
See this thread for details.
Win a copy of Terraform in Action this week in the Cloud forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Tim Cooke
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • Rob Spoor
  • Bear Bibeault
Saloon Keepers:
  • Jesse Silverman
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • Al Hobbs
  • salvin francis

JBoss error: Could not obtain connection...

 
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am using JBoss-4.0.4RC1, when I do the jndi lookup for remote interface, I get the error:

--------------------------------------------------------------------------
01:14:53,156 ERROR [STDERR] javax.naming.CommunicationException: Could not obtain connection to any of these urls: localhost:1099 and discovery failed with error: javax.naming.CommunicationException: Failed to connect to server 192.168.0.111:1100 [Root exception is java.lang.ClassCastException: $Proxy353] [Root exception is javax.naming.CommunicationException: Failed to connect to server localhost
:1099 [Root exception is java.lang.ClassCastException: org.jnp.server.NamingServer_Stub]]
01:14:53,156 ERROR [STDERR] at org.jnp.interfaces.NamingContext.checkRef(NamingContext.java:1414
)
01:14:53,156 ERROR [STDERR] at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:594)
01:14:53,156 ERROR [STDERR] at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:587)
01:14:53,156 ERROR [STDERR] at javax.naming.InitialContext.lookup(InitialContext.java:351)
---------------------------------------------------------------------------

Context.INITIAL_CONTEXT_FACTORY=org.jnp.interfaces.NamingContextFactory
Context.PROVIDER_URL=jnp://localhost:1099
Context.URL_PKG_PREFIXES=org.jboss.naming rg.jnp.interfaces

are there any errors with my configuration?
 
Ranch Hand
Posts: 243
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Looks like you are using different version client.jar in the Client end. take the jboss-client jar from the JBOSS_HOME/client/ and put it in your client's class path.
 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I've just overcome a similar problem. All I did was replace jboss-client.jar with jbossall-client.jar in my classpath.

See if it works for you.
 
Ranch Hand
Posts: 72
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I facing same problem ,it been solved by replace jbossall-client.jar from jboss server.

Thanks very much.
reply
    Bookmark Topic Watch Topic
  • New Topic