-
1. Re: Unable to connect via JMX to AS7: Operation failed with status WAITING
dlofthouse Mar 20, 2013 11:43 AM (in response to pruivo)Have you tried if you can connect remotely using the CLI? Also is there any stack trace with the error?
-
2. Re: Unable to connect via JMX to AS7: Operation failed with status WAITING
pruivo Mar 21, 2013 9:46 AM (in response to dlofthouse)Hi Darran,
Sorry the delay replying but we have to synchronize the access to the cluster.
So, from a remote machine I got:
{code}$ ./jboss-cli.sh --connect --controller=172.31.0.2:9999
org.jboss.as.cli.CliInitializationException: Failed to connect to the controller
at org.jboss.as.cli.impl.CliLauncher.initCommandContext(CliLauncher.java:229)
at org.jboss.as.cli.impl.CliLauncher.main(CliLauncher.java:207)
at org.jboss.as.cli.CommandLineMain.main(CommandLineMain.java:34)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.modules.Module.run(Module.java:260)
at org.jboss.modules.Main.main(Main.java:291)
Caused by: org.jboss.as.cli.CommandLineException: The controller is not available at 172.31.0.2:9999
at org.jboss.as.cli.impl.CommandContextImpl.connectController(CommandContextImpl.java:639)
at org.jboss.as.cli.impl.CommandContextImpl.connectController(CommandContextImpl.java:613)
at org.jboss.as.cli.impl.CliLauncher.initCommandContext(CliLauncher.java:227)
... 8 more{code}
and from my application I get:
{code}1363872475600 [ERROR] Connection failed with service:jmx:remoting-jmx://172.31.0.2:9999
stack trace:
java.lang.RuntimeException: Operation failed with status WAITING
at org.jboss.remotingjmx.RemotingConnector.internalConnect(RemotingConnector.java:168)
at org.jboss.remotingjmx.RemotingConnector.connect(RemotingConnector.java:94)
at javax.management.remote.JMXConnectorFactory.connect(JMXConnectorFactory.java:248)
at eu.cloudtm.reporter.manager.jmx.JmxConnection.connect(Unknown Source)
at eu.cloudtm.reporter.manager.jmx.JmxResource.<init>(Unknown Source)
at eu.cloudtm.reporter.manager.jmx.JmxResourceManager.addResource(Unknown Source)
at eu.cloudtm.reporter.CsvReporter.main(Unknown Source){code}
and with telnet:
{code}$ telnet 172.31.0.2 9999
Trying 172.31.0.2...
Connected to 172.31.0.2.
Escape character is '^]'.
madmass-node
Connection closed by foreign host.{code}
If I try the CLI from the same machine as JBossAS7, it connects:
{code} $ ./jboss-cli.sh --connect --controller=172.31.0.2:9999
[standalone@172.31.0.2:9999 /]
[standalone@172.31.0.2:9999 /] ls
core-service deployment extension interface
path socket-binding-group subsystem system-property
launch-type=STANDALONE management-major-version=1 management-micro-version=0 management-minor-version=3
name=geograph-dev namespaces=[] process-type=Server product-name=undefined
product-version=undefined profile-name=undefined release-codename=Arges release-version=7.1.x.incremental.129
running-mode=NORMAL schema-locations=[] server-state=running
[standalone@172.31.0.2:9999 /] {code}
-
3. Re: Unable to connect via JMX to AS7: Operation failed with status WAITING
pruivo Sep 2, 2013 9:37 AM (in response to pruivo)Hi Darran,
Below is the version that I'm using. Also, I've give it a try today with trace logs that can be found here: https://gist.github.com/pruivo/6412911
07:36:27,607 INFO [org.torquebox.core.as] Welcome to TorqueBox AS - http://torquebox.org/
07:36:27,607 INFO [org.torquebox.core.as] version........... 2.3.2
07:36:27,607 INFO [org.torquebox.core.as] build............. 80
07:36:27,607 INFO [org.torquebox.core.as] revision.......... be5e4d6cc59fc43f2b0189f0c83466dd8268da5d
07:36:27,608 INFO [org.torquebox.core.as] built with:
07:36:27,608 INFO [org.torquebox.core.as] HornetQ......... 2.2.21.SNAPSHOT (HQ_2_2_21_final, 122)
07:36:27,609 INFO [org.torquebox.core.as] JBossAS......... 7.1.x.incremental.129
07:36:27,609 INFO [org.torquebox.core.as] Infinispan...... 5.1.8.Final
07:36:27,610 INFO [org.torquebox.core.as] Quartz.......... 2.1.5
07:36:27,610 INFO [org.torquebox.core.as] JRuby........... 1.7.4
-
4. Re: Unable to connect via JMX to AS7: Operation failed with status WAITING
dlofthouse Sep 2, 2013 9:49 AM (in response to pruivo)Going to download that torquebox version and double check the default config first.
-
5. Re: Unable to connect via JMX to AS7: Operation failed with status WAITING
dlofthouse Sep 2, 2013 11:39 AM (in response to dlofthouse)Reviewing the configuration of the default torquebox distribution one thing that is apparent is that the security realm assignment appears to have been removed from the management interface definitions, as a first step if your server is accessible remotely I would suggest restoring these to prevent unauthorized access to your servers e.g.
<management-interfaces>
<native-interface security-realm="ManagementRealm">
<socket-binding native="management-native"/>
</native-interface>
<http-interface security-realm="ManagementRealm">
<socket-binding http="management-http"/>
</http-interface>
</management-interfaces>
I do not believe this is related to your problem but it is essential to ensure this is configured when publicly accessible.
Next I think it will be easier to focus just on the CLI connection to the server and we can come back to the JMX connection later, underneath both of these use the same approach to connecting to the server.
What would be really useful would be if you could capture a wireshark trace of the network calls on both the client side and server side as the CLI attempts to establish a remote connection to the server, you can then either attach those here or e-mail them to me and I can take a closer look comparing them to successful exchanges.