問(wèn)題描述
訪(fǎng)問(wèn)weblogic.management.mbeanservers.domainruntime失?。?weblogic.management.NoAccessRuntimeException: [Management:141102]Subject: principals=[] does not have access to perform Admin actions.
問(wèn)題出現(xiàn)的環(huán)境背景及自己嘗試過(guò)哪些方法
參考How it’s done: Password change functionality in OBIEE
相關(guān)代碼
// 請(qǐng)把代碼文本粘貼到下方(請(qǐng)勿用圖片代替代碼)初始化連接方法如下:
public static void InlCctn(String Adr, String AdrUsr, String AdrPswd) throws IOException, MalformedURLException {
JMXServiceURL SvcUrl =
new JMXServiceURL("service:jmx:iiop://" + Adr + "/jndi/weblogic.management.mbeanservers.domainruntime");
Hashtable h = new Hashtable();
h.put(Context.INITIAL_CONTEXT_FACTORY, "weblogic.jndi.WLInitialContextFactory");
h.put(Context.SECURITY_PRINCIPAL, AdrUsr);
h.put(Context.SECURITY_CREDENTIALS, AdrPswd);
// String[] credentials = new String[] { AdrUsr, AdrPswd };
// h.put("jmx.remote.credentials", credentials);
cctor = JMXConnectorFactory.connect(SvcUrl, h);
mbsc = cctor.getMBeanServerConnection();
}
用了兩種方式連接都是同樣的報(bào)錯(cuò)。
期待
到底是Weblogic配置問(wèn)題,還是我方法的問(wèn)題?
1 回答

慕哥6287543
TA貢獻(xiàn)1831條經(jīng)驗(yàn) 獲得超10個(gè)贊
方法構(gòu)造問(wèn)題,請(qǐng)參考Accessing WebLogic Server MBeans with JMX
添加回答
舉報(bào)
0/150
提交
取消