ADMN0022E: Access denied due to insufficient or empty credentials.

While trying to monitor Websphere programmatically via its AdminClient framework, I faced many problems that can be easily solved by reading the documentation carefully. But this one, seems to be quite misleading.

ADMN0022E: Access denied for the getStatsObject operation on Perf MBean due to insufficient or empty credentials.

If you get this error while trying to read PMI data using admin client on websphere, and you are sure about username and password, be sure that the user you are tring to connect has Monitor privileges in the administrative role. You can check it from WAS administrative console > Users and Groups > Administrative User Role  and then see if the “Monitor” role is assigned.

Something else that might help, params to connect my WAS 7 instance are (administrative security enabled):

String hostname = "localhost";
String soapport = "8882";
String username = "salem";
String password = "salem";
String truststore = "D:/WAS7/profiles/etc/DummyClientTrustFile.jks";
String keystore = "D:/WAS7/profiles/et/DummyClientKeyFile.jks";
String truststorepass = "WebAS";//default for WAS 7, but for WAS 6.1 it's the node name
String keystorepass = "WebAS";
String truststoretype = "jks";
String keystoretype = "jks";

You may start working on Java admin client from here; If you couldn’t figure out using IBM documentation, you may use this…

Measuring distance to stars

Just kidding you… will tell you how to do it sooner 🙂

Advertisements

About Salem Ben Afia

Big Data & Java developer

Posted on June 26, 2012, in J2EE, Websphere and tagged , , , , , , . Bookmark the permalink. Leave a comment.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: