1 Reply Latest reply on Mar 25, 2015 9:49 AM by thinksteep thinksteep

    JMX connection to JBoss7.1 from Wildfly

    thinksteep thinksteep Novice

      I followed sample described here to establish a JMX connection with Wildfly (from Wildfly), which worked fine.

      JMX subsystem configuration - WildFly 8 - Project Documentation Editor

       

      Then I tried to establish a JMX connection from Wildfly by using following code:

       

              HashMap<String, String[]> env = getCredentialsMap();

              String host = "remoteserverip";

              int port = 4447;

              String urlString

                      = System.getProperty("jmx.service.url", "service:jmx:remoting-jmx://" + host + ":" + port);

              JMXServiceURL serviceURL = new JMXServiceURL(urlString);

              JMXConnector jmxConnector = JMXConnectorFactory.connect(serviceURL, env);

              MBeanServerConnection connection = jmxConnector.getMBeanServerConnection();

       

      But I got following exception:

       

      Mar 24, 2015 5:09:43 PM org.jboss.remoting3.remote.RemoteConnection handleException

      ERROR: JBREM000200: Remote connection failed: javax.security.sasl.SaslException: Authentication failed: the server presented no authentication mechanisms

      Exception in thread "main" javax.security.sasl.SaslException: Authentication failed: the server presented no authentication mechanisms

        at org.jboss.remoting3.remote.ClientConnectionOpenListener$Capabilities.handleEvent(ClientConnectionOpenListener.java:388)

        at org.jboss.remoting3.remote.ClientConnectionOpenListener$Capabilities.handleEvent(ClientConnectionOpenListener.java:242)

        at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:92)

        at org.xnio.channels.TranslatingSuspendableChannel.handleReadable(TranslatingSuspendableChannel.java:199)

        at org.xnio.channels.TranslatingSuspendableChannel$1.handleEvent(TranslatingSuspendableChannel.java:113)

        at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:92)

        at org.xnio.ChannelListeners$DelegatingChannelListener.handleEvent(ChannelListeners.java:1092)

        at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:92)

        at org.xnio.conduits.ReadReadyHandler$ChannelListenerHandler.readReady(ReadReadyHandler.java:66)

        at org.xnio.nio.NioSocketConduit.handleReady(NioSocketConduit.java:88)

        at org.xnio.nio.WorkerThread.run(WorkerThread.java:539)

        at ...asynchronous invocation...(Unknown Source)

        at org.jboss.remoting3.EndpointImpl.doConnect(EndpointImpl.java:272)

        at org.jboss.remoting3.EndpointImpl.doConnect(EndpointImpl.java:253)

        at org.jboss.remoting3.EndpointImpl.connect(EndpointImpl.java:351)

        at org.jboss.remoting3.EndpointImpl.connect(EndpointImpl.java:335)

        at org.jboss.remotingjmx.RemotingConnector.internalRemotingConnect(RemotingConnector.java:232)

        at org.jboss.remotingjmx.RemotingConnector.internalConnect(RemotingConnector.java:151)

        at org.jboss.remotingjmx.RemotingConnector.connect(RemotingConnector.java:102)

        at javax.management.remote.JMXConnectorFactory.connect(JMXConnectorFactory.java:268)

       

      Is there any way I can establish JMX connection to Jboss AS 7.1.Final from Wildfly? Any help appreciated.