1
votes

I'm trying to expose Apache Camels MBeans through JMX so that I can manage the deployed Camel instance in a WebSphere Application Server (7.0).

Actually, I don't know if this is even related to Camel, but more an issue on how to expose MBeans from WebSphere.

Connecting to JConsole goes fine as well as listing the Camel MBeans. However, when trying to invoke any operation, I get access denied.

The user UNAUTHENTICATED (unique ID: unauthenticated) was not granted any of the following required roles: operator, administrator.

It also seems some of these MBeans might not get created (from WAS log).

[2012-12-29 16:17:15:328 CET] 00000010 PlatformMBean W   Failed to activate MBean org.yourname:cell=segotw10099999Node01Cell,name="marshal13",context=segotw10099999/camelContext,type=processors,node=segotw10099999,process=server1

I'm connecting with something like this:

start %WAS_JDK_HOME%/bin/jconsole -J-Djava.class.path=%WAS_JDK_HOME%\lib\tools.jar;%WAS_JDK_HOME%\lib\jconsole.jar;%WAS_HOME%\runtimes\com.ibm.ws.admin.client_7.0.0.jar service:jmx:iiop://localhost:2809/jndi/JMXConnector

I also tried fill in a user that has administrative privileges (as well as a user that is in the "administrator" group) in WAS into the user/password fileds in JConsole.

This is a default configured "RAD" setup of WebSphere, so nothing fancy pancy. However, I want to be able to use this on a production server later on with multiple applications and LDAP users.

Any pointers are very welcome!

2

2 Answers

1
votes

What Camel version do you use? And how did you configure JMX in Camel?

When using some servers like WebSphere you most likely need to configure it a bit special. We have some details at the Camel docs at: http://camel.apache.org/camel-jmx.html#CamelJMX-WebSphere

1
votes

The reason for the problem is likely that JConsole is not correctly configured to connect to a secured WebSphere instance. While connecting to a WebSphere instance that has security disabled is relatively simple, things become much more tricky when security is enabled. If you want to save yourself the headaches of figuring out how to do that, you can follow the instructions given here:

http://code.google.com/p/xm4was/wiki/VisualVMHowTo

They are for VisualVM, but I guess that doesn't matter.