Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Exception while querying MBeans in WAS 6.1

43 views
Skip to first unread message

Levis

unread,
Mar 12, 2007, 6:32:06 AM3/12/07
to
Hi all,

I am using websphere 6.1 . When i tried to get the mbeans registered
in the server i am getting the following exception.


Code :
AdminClient adminClient =
AdminClientFactory.createAdminClient(connectProps);
Set set = adminClient.queryNames(null,null);

Exception :

WARNING: Could not find tmx4jTransform.jar in null/etc/
tmx4jTransform.jar - Inte
roperability to older versions of WebSphere is disabled
Mar 12, 2007 3:14:51 PM com.ibm.ws.ssl.config.SSLConfigManager
INFO: ssl.disable.url.hostname.verification.CWPKI0027I

The XML parser does not support disabling DOCTYPE declarations. This
server wil
l be vulnerable to some Denial-of-Service attacks.

com.ibm.websphere.management.exception.ConnectorException:
ADMC0009E: The system failed to make the SOAP RPC call: queryNames
at
com.ibm.ws.management.connector.soap.SOAPConnectorClient.invokeTemplate(SOAPConnectorClient.java:
747)

at
com.ibm.ws.management.connector.soap.SOAPConnectorClient.queryNames(SOAPConnectorClient.java:
499)

at
com.ibm.ws.management.connector.soap.SOAPConnectorClient.invoke(SOAPConnectorClient.java:
429)

at $Proxy0.queryNames(Unknown Source)

at
com.ibm.ws.management.AdminClientImpl.queryNames(AdminClientImpl.java:
89)


Any quick help will be appreciated.

regards,
George

Sven Vermeulen

unread,
Mar 12, 2007, 7:11:38 AM3/12/07
to
On Mar 12, 11:32 am, "Levis" <george_le...@hotmail.com> wrote:
> I am using websphere 6.1 . When i tried to get the mbeans registered
> in the server i am getting the following exception.
>
> Code :
> AdminClient adminClient =
> AdminClientFactory.createAdminClient(connectProps);
> Set set = adminClient.queryNames(null,null);
[...]

> com.ibm.websphere.management.exception.ConnectorException:
> ADMC0009E: The system failed to make the SOAP RPC call: queryNames
[...]

> Any quick help will be appreciated.

What are your connectProps and how does your classpath look like?

Doesn't it give more reason than just ADMC0009E (below the exception
it usually reads "Reason: " with the reason of the failure)?

Wkr,
Sven Vermeulen

Levis

unread,
Mar 12, 2007, 8:26:40 AM3/12/07
to


Dear Sven Vermeulen,

Thanks for quick help. I set the classpath to <SERVERROOT>\runtimes
\com.ibm.ws.admin.client_6.1.0.jar.

And here is my sample code snippet and full exception trace.

Sample Code :

Properties connectProps = new Properties();
connectProps.setProperty("host", connectorHost);
connectProps.setProperty("port",
String.valueOf(connectorPort));
connectProps.setProperty("type","SOAP");
connectProps.setProperty("securityEnabled", "false"); //
Since security is not enabled in server

AdminClient adminClient1 =
AdminClientFactory.createAdminClient(connectProps);
Set set = adminClient1.queryNames(null,null);

Exception Trace :

Mar 12, 2007 5:26:38 PM
com.ibm.websphere.management.AdminClientFactory
WARNING: ADMC0046W
Mar 12, 2007 5:26:38 PM
com.ibm.ws.management.connector.interop.JMXClassLoader


WARNING: Could not find tmx4jTransform.jar in null/etc/

tmx4jTransform.jar - Interoperability to older versions of WebSphere
is disabled
Mar 12, 2007 5:26:38 PM com.ibm.ws.ssl.config.SSLConfigManager


INFO: ssl.disable.url.hostname.verification.CWPKI0027I
The XML parser does not support disabling DOCTYPE declarations. This

server will be vulnerable to some Denial-of-Service attacks.

com.ibm.websphere.management.exception.ConnectorException: ADMC0009E:
The system failed to make the SOAP RPC call: queryNames

at
com.ibm.ws.management.connector.soap.SOAPConnectorClient.invokeTemplate(SOAPConnectorClient.java:
747)
at
com.ibm.ws.management.connector.soap.SOAPConnectorClient.queryNames(SOAPConnectorClient.java:
499)
at
com.ibm.ws.management.connector.soap.SOAPConnectorClient.invoke(SOAPConnectorClient.java:
429)
at $Proxy0.queryNames(Unknown Source)
at
com.ibm.ws.management.AdminClientImpl.queryNames(AdminClientImpl.java:
89)

at
com.Sample.Test.WebSphereClient.createAdminClient(WebSphereClient.java:
343)

Caused by: [SOAPException: faultCode=SOAP-ENV:Client;
msg=javax.management.ObjectName; local class incompatible: stream
classdesc serialVersionUID = 1081892073854801359, local class
serialVersionUID = -5467795090068647408
Server stack trace
JMXTransformException java.io.InvalidClassException:
javax.management.ObjectName; local class incompatible: stream
classdesc serialVersionUID = 1081892073854801359, local class
serialVersionUID = -5467795090068647408
at java.io.ObjectStreamClass.initNonProxy(Unknown Source)
at java.io.ObjectInputStream.readNonProxyDesc(Unknown Source)
at java.io.ObjectInputStream.readClassDesc(Unknown Source)
at java.io.ObjectInputStream.readOrdinaryObject(Unknown
Source)
at java.io.ObjectInputStream.readObject0(Unknown Source)
at java.io.ObjectInputStream.readObject(Unknown Source)
at java.util.HashSet.readObject(Unknown Source)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown
Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at java.io.ObjectStreamClass.invokeReadObject(Unknown Source)
at java.io.ObjectInputStream.readSerialData(Unknown Source)
at java.io.ObjectInputStream.readOrdinaryObject(Unknown
Source)
at java.io.ObjectInputStream.readObject0(Unknown Source)
at java.io.ObjectInputStream.readObject(Unknown Source)
at
com.ibm.ws.management.connector.soap.GenericSerializer.unmarshall(GenericSerializer.java:
220)
at
org.apache.soap.util.xml.XMLJavaMappingRegistry.unmarshall(Unknown
Source)
at
org.apache.soap.encoding.soapenc.ParameterSerializer.unmarshall(Unknown
Source)
at
org.apache.soap.util.xml.XMLJavaMappingRegistry.unmarshall(Unknown
Source)
at org.apache.soap.rpc.RPCMessage.unmarshall(Unknown Source)
at org.apache.soap.rpc.RPCMessage.extractFromEnvelope(Unknown
Source)
at org.apache.soap.rpc.Response.extractFromEnvelope(Unknown
Source)
at org.apache.soap.rpc.Call.invoke(Unknown Source)
at com.ibm.ws.management.connector.soap.SOAPConnectorClient
$8.run(SOAPConnectorClient.java:705)
at
com.ibm.ws.security.util.AccessController.doPrivileged(AccessController.java:
118)
at
com.ibm.ws.management.connector.soap.SOAPConnectorClient.invokeTemplate(SOAPConnectorClient.java:
698)


at
com.ibm.ws.management.connector.soap.SOAPConnectorClient.queryNames(SOAPConnectorClient.java:
499)
at
com.ibm.ws.management.connector.soap.SOAPConnectorClient.invoke(SOAPConnectorClient.java:
429)
at $Proxy0.queryNames(Unknown Source)
at
com.ibm.ws.management.AdminClientImpl.queryNames(AdminClientImpl.java:
89)

at
com.Sample.Test.WebSphereClient.createAdminClient(WebSphereClient.java:
343)

Client stack trace
; targetException=java.lang.IllegalArgumentException:
javax.management.ObjectNam
e; local class incompatible: stream classdesc serialVersionUID =
108189207385480
1359, local class serialVersionUID = -5467795090068647408
Server stack trace
JMXTransformException java.io.InvalidClassException:
javax.management.ObjectName; local class incompatible: stream
classdesc serialVersionUID = 1081892073854801359, local class
serialVersionUID = -5467795090068647408
at java.io.ObjectStreamClass.initNonProxy(Unknown Source)
at java.io.ObjectInputStream.readNonProxyDesc(Unknown Source)
at java.io.ObjectInputStream.readClassDesc(Unknown Source)
at java.io.ObjectInputStream.readOrdinaryObject(Unknown
Source)
at java.io.ObjectInputStream.readObject0(Unknown Source)
at java.io.ObjectInputStream.readObject(Unknown Source)
at java.util.HashSet.readObject(Unknown Source)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown
Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at java.io.ObjectStreamClass.invokeReadObject(Unknown Source)
at java.io.ObjectInputStream.readSerialData(Unknown Source)
at java.io.ObjectInputStream.readOrdinaryObject(Unknown
Source)
at java.io.ObjectInputStream.readObject0(Unknown Source)
at java.io.ObjectInputStream.readObject(Unknown Source)
at
com.ibm.ws.management.connector.soap.GenericSerializer.unmarshall(GenericSerializer.java:
220)
at
org.apache.soap.util.xml.XMLJavaMappingRegistry.unmarshall(Unknown
Source)
at
org.apache.soap.encoding.soapenc.ParameterSerializer.unmarshall(Unknown
Source)
at
org.apache.soap.util.xml.XMLJavaMappingRegistry.unmarshall(Unknown
Source)
at org.apache.soap.rpc.RPCMessage.unmarshall(Unknown Source)
at org.apache.soap.rpc.RPCMessage.extractFromEnvelope(Unknown
Source)
at org.apache.soap.rpc.Response.extractFromEnvelope(Unknown
Source)
at org.apache.soap.rpc.Call.invoke(Unknown Source)
at com.ibm.ws.management.connector.soap.SOAPConnectorClient
$8.run(SOAPConnectorClient.java:705)
at
com.ibm.ws.security.util.AccessController.doPrivileged(AccessController.java:
118)
at
com.ibm.ws.management.connector.soap.SOAPConnectorClient.invokeTemplate(SOAPConnectorClient.java:
698)


at
com.ibm.ws.management.connector.soap.SOAPConnectorClient.queryNames(SOAPConnectorClient.java:
499)
at
com.ibm.ws.management.connector.soap.SOAPConnectorClient.invoke(SOAPConnectorClient.java:
429)
at $Proxy0.queryNames(Unknown Source)
at
com.ibm.ws.management.AdminClientImpl.queryNames(AdminClientImpl.java:
89)

at
com.Sample.Test.WebSphereClient.createAdminClient(WebSphereClient.java:
343)

Client stack trace
]
at org.apache.soap.rpc.Call.invoke(Unknown Source)
at com.ibm.ws.management.connector.soap.SOAPConnectorClient
$8.run(SOAPConnectorClient.java:705)
at
com.ibm.ws.security.util.AccessController.doPrivileged(AccessController.java:
118)
at
com.ibm.ws.management.connector.soap.SOAPConnectorClient.invokeTemplate(SOAPConnectorClient.java:
698)
... 7 more
Exception in thread "main" java.net.ConnectException:


com.ibm.websphere.management.exception.ConnectorException: ADMC0009E:
The system failed to make the SOAP RPC call: queryNames

at com.Sample.Test.WebSphereClient.createAdminClient.
(WebSphereClient.java:343)
at com.Sample.Test.WebSphereClient.main(WebSphereClient.java:
713)


Regards,
George

Sven Vermeulen

unread,
Mar 12, 2007, 9:48:52 AM3/12/07
to
On Mar 12, 1:26 pm, "Levis" <george_le...@hotmail.com> wrote:
> Caused by: [SOAPException: faultCode=SOAP-ENV:Client;
> msg=javax.management.ObjectName; local class incompatible: stream
> classdesc serialVersionUID = 1081892073854801359, local class
> serialVersionUID = -5467795090068647408
> Server stack trace
> JMXTransformException java.io.InvalidClassException:
> javax.management.ObjectName; local class incompatible: stream
> classdesc serialVersionUID = 1081892073854801359, local class
> serialVersionUID = -5467795090068647408

It looks like the ObjectNames you receive from the Deployment Manager
are serialized using a different class than the ObjectName class you
have in your classpath. I don't have WS6.1 here and the IBM InfoCenter
is dogslow again to search for information, but my JMX clients use the
following java arguments to ensure that the classpath is correct:

-Dwas.install.root=${WAS_HOME} -Dwas.repository.root=${CONFIG_ROOT} -
Djava.ext.dirs=${WAS_EXT_DIRS}

The variables are declared in the setupCmdLine.sh script which you
need to source first.The "-Djava.ext.dirs" here is the important once
since the ObjectName definition resides in the management.jar file
which is in the ext-dir.

Wkr,
Sven Vermeulen

Levis

unread,
Mar 15, 2007, 3:04:27 AM3/15/07
to

Dear Sven Vermeulen,

After setting the classpath to management.jar file now I am able to
connect to the server. Initially, I have set the classpath to our
product jar files which includes our owm jmx spec and
com.ibm.ws.admin.client_6.1.0.jar file. I have not included
management.jar in the classpath. Hence, while running client program
ObjectName class is taken from our jmx jar. This is the reason for the
InvlaidClassException.

Thank you very much for helping me to solve the issue.

Regards,
George

Levis

unread,
Mar 17, 2007, 2:12:07 AM3/17/07
to

Hi all,

After enabling the administrative security in websphere 6.1, I am not
able to connect to the server using soap connector. I have set the
username and password in soap.client.props file located in
<product_home>\profiles\properties directory.

The connection properties are :

Properties connectProps = new Properties();

connectProps.setProperty(AdminClient.CONNECTOR_HOST, hostName);
connectProps.setProperty(AdminClient.USERNAME, userName);
connectProps.setProperty(AdminClient.PASSWORD, Password);
connectProps.setProperty(AdminClient.CONNECTOR_PORT, Port");
connectProps.setProperty(AdminClient.CONNECTOR_TYPE,
AdminClient.CONNECTOR_TYPE_SOAP);
connectProps.setProperty(AdminClient.CONNECTOR_SECURITY_ENABLED,
"true");
AdminClient adminClient1 =
AdminClientFactory.createAdminClient(connectProps);

Following is the exception I am getting.

INFO: ssl.disable.url.hostname.verification.CWPKI0027I
com.ibm.websphere.management.exception.ConnectorException: ADMC0053E:
The system cannot create a SOAP connector to connect to host tsenthil
at port 8880 with SOAP connector security enabled.
at
com.ibm.websphere.management.AdminClientFactory.createAdminClient(AdminClientFactory.java:
476)
at
com.myCompany.clients.WebsphereClient.main(WebsphereClient.java:21)
Caused by: java.lang.reflect.InvocationTargetException
at
sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:
67)
at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:
45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:
521)
at
com.ibm.websphere.management.AdminClientFactory.createAdminClient(AdminClientFactory.java:
331)
... 1 more
Caused by:
com.ibm.websphere.management.exception.ConnectorNotAvailableException:
[SOAPException: faultCode=SOAP-ENV:Client; msg=Error opening socket:
java.net.
SocketException; targetException=java.lang.IllegalArgumentException:
Error opening socket: java.net.SocketException]
at
com.ibm.ws.management.connector.soap.SOAPConnectorClient.reconnect(SOAPConnectorClient.java:
343)
at
com.ibm.ws.management.connector.soap.SOAPConnectorClient.<init>(SOAPConnectorClient.java:
176)
... 6 more
Caused by: [SOAPException: faultCode=SOAP-ENV:Client; msg=Error
opening socket:java.net.SocketException;
targetException=java.lang.IllegalArgumentException: Error opening
socket: java.net.SocketException]
at
org.apache.soap.transport.http.SOAPHTTPConnection.send(Unknown Source)


at org.apache.soap.rpc.Call.invoke(Unknown Source)
at com.ibm.ws.management.connector.soap.SOAPConnectorClient

$4.run(SOAPConnectorClient.java:316)
at
com.ibm.ws.security.util.AccessController.doPrivileged(AccessController.java:
118)
at
com.ibm.ws.management.connector.soap.SOAPConnectorClient.reconnect(SOAPConnectorClient.java:
301)
... 7 more

Any help will be appreciated.

Thanks
George

Sven Vermeulen

unread,
Mar 18, 2007, 9:53:14 AM3/18/07
to
On Mar 17, 7:12 am, "Levis" <george_le...@hotmail.com> wrote:
> Caused by: [SOAPException: faultCode=SOAP-ENV:Client; msg=Error
> opening socket:java.net.SocketException;
> targetException=java.lang.IllegalArgumentException: Error opening
> socket: java.net.SocketException]
[...]

> Any help will be appreciated.

How do you call your application (classpath and other options)?

It might be a long shot, but my first idea would be to switch back to
non-secure cell and try again - perhaps something happened to the
network or system when you switched from non-secure to secure.

Second idea would be to see if you need to define specific
certificates for the secure SOAP connection (iirc, when security is
enabled, SOAP connections to the dmgr are SSL-encrypted) but I would
suspect that another error would show up when the certificates aren't
correct.

Wkr,
Sven Vermeulen

Levis

unread,
Mar 19, 2007, 8:12:57 AM3/19/07
to

Dear Sven Vermeulen,

I tried with your first one, but with result not success. Because
when i return back to secure connection same exception occurs. With
your second one, I am not that much familiar with websphere securities
and also soap. Anyway now I started to analyse in this way. I beleive
that soon i will get something.

Before start my application i will run the setupCmdLine.bat file and
then i will set the classpath to following three jars. For testing
purpose, I have not included other jar files than this and no java
options.

%WAS_HOME%\runtimes\com.ibm.ws.admin.client_6.1.0.jar;%WAS_HOME%\lib
\webadmin\management.jar;%WAS_HOME%\plugins
\com.ibm.ws.security.crypto_6.1.0.jar;


Thanks in advance.


Regards,
George

0 new messages