Authentication failed: the server presented no authentication mechanisms in JBoss EAP 6

Solution Unverified - Updated -

Issue

  • We have two standalone JBOSS EAP server. server 1 hosts the JMS topic and server 2 is trying to connect to it remotely.
    Server 2 will try to do a remote JNDI loop up to connect to JMS server one server 1. This will fail with the error.
    I am attaching both server config file and error below:
ERROR (127.0.0.1:8080-2) Exception while getting the JMS Connection: javax.naming.AuthenticationException: Failed to connect to any server. Servers tried: [remote://remote-host:4447 (Authentication failed: the server presented no authentication mechanisms)] [Root exception is javax.security.sasl.SaslException: Authentication failed: the server presented no authentication mechanisms]
                at org.jboss.naming.remote.client.HaRemoteNamingStore.failOverSequence(HaRemoteNamingStore.java:237) [jboss-remote-naming-1.0.8.Final-redhat-1.jar:1.0.8.Final-redhat-1]
                at org.jboss.naming.remote.client.HaRemoteNamingStore.namingStore(HaRemoteNamingStore.java:149) [jboss-remote-naming-1.0.8.Final-redhat-1.jar:1.0.8.Final-redhat-1]
                at org.jboss.naming.remote.client.HaRemoteNamingStore.namingOperation(HaRemoteNamingStore.java:130) [jboss-remote-naming-1.0.8.Final-redhat-1.jar:1.0.8.Final-redhat-1]
                at org.jboss.naming.remote.client.HaRemoteNamingStore.lookup(HaRemoteNamingStore.java:271) [jboss-remote-naming-1.0.8.Final-redhat-1.jar:1.0.8.Final-redhat-1]
                at org.jboss.naming.remote.client.RemoteContext.lookup(RemoteContext.java:79) [jboss-remote-naming-1.0.8.Final-redhat-1.jar:1.0.8.Final-redhat-1]
                at org.jboss.naming.remote.client.RemoteContext.lookup(RemoteContext.java:83) [jboss-remote-naming-1.0.8.Final-redhat-1.jar:1.0.8.Final-redhat-1]
                at javax.naming.InitialContext.lookup(InitialContext.java:417) [rt.jar:1.8.0_65]
                at javax.naming.InitialContext.lookup(InitialContext.java:417) [rt.jar:1.8.0_65]
                at com.redhat.examples.util.ServiceLocator.lookup(ServiceLocator.java:123) [util.jar:1]
  • Our client application is failing with this exception trying to do a remote jndi lookup with remote-naming:
javax.naming.AuthenticationException: Failed to connect to any server. Servers tried: [remote://localhost:4447 (Authentication failed: the server presented no authentication mechanisms)] [Root exception is javax.security.sasl.SaslException: Authentication failed: the server presented no authentication mechanisms]
    at org.jboss.naming.remote.client.HaRemoteNamingStore.failOverSequence(HaRemoteNamingStore.java:237)
    at org.jboss.naming.remote.client.HaRemoteNamingStore.namingStore(HaRemoteNamingStore.java:149)
    at org.jboss.naming.remote.client.HaRemoteNamingStore.namingOperation(HaRemoteNamingStore.java:130)
    at org.jboss.naming.remote.client.HaRemoteNamingStore.lookup(HaRemoteNamingStore.java:271)
    at org.jboss.naming.remote.client.RemoteContext.lookupInternal(RemoteContext.java:104)
    at org.jboss.naming.remote.client.RemoteContext.lookup(RemoteContext.java:93)
    at org.jboss.naming.remote.client.RemoteContext.lookup(RemoteContext.java:146)
    at javax.naming.InitialContext.lookup(InitialContext.java:411)
    at Test.main(Test.java:32)
Caused by: javax.security.sasl.SaslException: Authentication failed: the server presented no authentication mechanisms
    at org.jboss.remoting3.remote.ClientConnectionOpenListener$Capabilities.handleEvent(ClientConnectionOpenListener.java:389)
    at org.jboss.remoting3.remote.ClientConnectionOpenListener$Capabilities.handleEvent(ClientConnectionOpenListener.java:243)
    at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:72)
    at org.xnio.channels.TranslatingSuspendableChannel.handleReadable(TranslatingSuspendableChannel.java:189)
    at org.xnio.channels.TranslatingSuspendableChannel$1.handleEvent(TranslatingSuspendableChannel.java:103)
    at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:72)
    at org.xnio.nio.NioHandle.run(NioHandle.java:90)
    at org.xnio.nio.WorkerThread.run(WorkerThread.java:198)
    at ...asynchronous invocation...(Unknown Source)
    at org.jboss.remoting3.EndpointImpl.doConnect(EndpointImpl.java:286)
    at org.jboss.remoting3.EndpointImpl.doConnect(EndpointImpl.java:267)
    at org.jboss.remoting3.EndpointImpl.connect(EndpointImpl.java:365)
    at org.jboss.remoting3.EndpointImpl.connect(EndpointImpl.java:349)
    at org.jboss.naming.remote.client.EndpointCache$EndpointWrapper.connect(EndpointCache.java:105)
    at org.jboss.naming.remote.client.HaRemoteNamingStore.failOverSequence(HaRemoteNamingStore.java:197)
    ... 8 more

Environment

  • Red Hat JBoss Enterprise Application Platform (EAP)
    • 6

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.