Java org.omg.CORBA.TRANSIENT:初始和转发的 IOR 无法访问 vmcid:IBM 次要代码:来自独立应用程序的 E07
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/23062079/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
org.omg.CORBA.TRANSIENT: initial and forwarded IOR inaccessible vmcid: IBM minor code: E07 from stand-alone app
提问by Danubian Sailor
I'm connecting to the WebSphere instance from the stand-alone Java app which is quite trivial:
我从独立的 Java 应用程序连接到 WebSphere 实例,这很简单:
InitialContext initCtx = new InitialContext();
That code was working perfectly in WebSphere 7, but after updating to WebSphere 8.5 I got the following exception:
该代码在 WebSphere 7 中运行良好,但在更新到 WebSphere 8.5 后出现以下异常:
Caused by: org.omg.CORBA.TRANSIENT: initial and forwarded IOR inaccessible vmcid: IBM minor code: E07 completed: No
at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1276)
at com.ibm.CORBA.iiop.ClientDelegate.createRequest(ClientDelegate.java:1457)
at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1164)
at com.ibm.CORBA.iiop.ClientDelegate.createRequest(ClientDelegate.java:1423)
at com.ibm.rmi.corba.ClientDelegate.request(ClientDelegate.java:1886)
at com.ibm.CORBA.iiop.ClientDelegate.request(ClientDelegate.java:1379)
at org.omg.CORBA.portable.ObjectImpl._request(ObjectImpl.java:458)
at com.ibm.WsnBootstrap._WsnNameServiceStub.getProperties(_WsnNameServiceStub.java:38)
at com.ibm.ws.naming.util.WsnInitCtxFactory.mergeWsnNSProperties(WsnInitCtxFactory.java:1441)
... 43 more
After research, I've fout out that IBM support page, which said to go to CSIv2 inbound and outbound settings (by me, Admin Console->Security->GlobalSecurity->RMI/IIOP security) and set the transport to SSL-Supported.
经过研究,我发现了IBM 支持页面,该页面说要转到 CSIv2 入站和出站设置(由我管理控制台->安全性->GlobalSecurity->RMI/IIOP 安全性)并将传输设置为 SSL-Supported .
However, it didn't change anything. I've tried to change the 'Cleint certificate authentication' to Never, and Transport to TCP/IP for both CSIv2 inbound and outbound, but still without success. The error persisted until I've turned off 'Enable administrative security', which is not an option, because I need to enable 'Application Security' (the application logic depends of that).
然而,它并没有改变任何东西。我尝试将 CSIv2 入站和出站的“Cleint 证书身份验证”更改为从不,并将传输到 TCP/IP,但仍然没有成功。错误一直存在,直到我关闭“启用管理安全性”,这不是一个选项,因为我需要启用“应用程序安全性”(应用程序逻辑取决于此)。
How can I make my code working again? Everything was OK on WebSphere 7.
我怎样才能让我的代码再次工作?在 WebSphere 7 上一切正常。
回答by Danubian Sailor
The error description
错误描述
org.omg.CORBA.TRANSIENT: initial and forwarded IOR inaccessible vmcid: IBM minor code: E07
org.omg.CORBA.TRANSIENT:初始和转发的 IOR 无法访问 vmcid:IBM 次要代码:E07
is very vague and happens under many, not directly connected circumstances.
非常模糊,发生在许多没有直接关联的情况下。
In my case it had nothing to do with RMI/IIOP security settings, but it was a classpath problem. I was still using old version of com.ibm.ws.webservices.thinclient
.
就我而言,它与 RMI/IIOP 安全设置无关,但它是一个类路径问题。我还在使用旧版本的com.ibm.ws.webservices.thinclient
.
Switching to thinclient 8.5.0, as well as setting the launch JRE to standard (Oracle) JVM has fixed the problem.
切换到 Thinclient 8.5.0 并将启动 JRE 设置为标准 (Oracle) JVM 已解决了该问题。
回答by Diarmuid
My research on this issue may prove useful to others;
我对这个问题的研究可能对其他人有用;
WebSphere 8 changed the default setting of RMI/IIOP SSL security from 'supported' to 'required'. If you want a secure connection you'll need to get the certs from the server and set Java system properties to files that specify the location of the certs;
WebSphere 8 将 RMI/IIOP SSL 安全性的默认设置从“支持”更改为“必需”。如果您想要安全连接,您需要从服务器获取证书并将 Java 系统属性设置为指定证书位置的文件;
com.ibm.CORBA.ConfigURL=file:/opt/IBM/JazzSM/profile/properties/sas.client.props com.ibm.SSL.ConfigURL=file:/opt/IBM/JazzSM/profile/properties/ssl.client.props
com.ibm.CORBA.ConfigURL=file:/opt/IBM/JazzSM/profile/properties/sas.client.props com.ibm.SSL.ConfigURL=file:/opt/IBM/JazzSM/profile/properties/ssl.client.props
If this doesn't work, you'll need to start debugging by setting the following System properties;
如果这不起作用,您需要通过设置以下系统属性来开始调试;
com.ibm.CORBA.Debug=true com.ibm.CORBA.CommTrace=true com.ibm.CORBA.Debug.Output=/tmp/corba.log
com.ibm.CORBA.Debug=true com.ibm.CORBA.CommTrace=true com.ibm.CORBA.Debug.Output=/tmp/corba.log
By studying this log and orb trace logs in the working directory, I found that the client failed to establish an ephemeral TCP connection to the server at "port=0". No mention of SSL in the logs! I wrote a small app to test my code running as a java console app and found that the SSL connection was successful and it worked fine. By diff'ing the logs, I found that only in the good case, the JVM was finding a local file 'orb.properties'. I then found that in my problem case, my test app was using a different JVM and my real app was using a JVM that had no 'orb.properties'. I could resolve the problem in a number of ways .. e.g. by including an orb.properties in my application and injecting the contents as System properties.
通过研究工作目录中的这个日志和 orb 跟踪日志,我发现客户端无法在“端口 = 0”处建立到服务器的临时 TCP 连接。日志中没有提到 SSL!我写了一个小应用程序来测试我作为 Java 控制台应用程序运行的代码,发现 SSL 连接成功并且工作正常。通过比较日志,我发现只有在好的情况下,JVM 才能找到本地文件“orb.properties”。然后我发现在我的问题案例中,我的测试应用程序使用的是不同的 JVM,而我的真实应用程序使用的是没有“orb.properties”的 JVM。我可以通过多种方式解决问题.. 例如,通过在我的应用程序中包含一个 orb.properties 并将内容作为系统属性注入。
回答by radekbaranowski
In my case switching CSIV inbound to SSL-Supported from SSL-required andrestarting the server helped.
在我的情况下,将 CSIV 入站切换到 SSL 支持从需要 SSL并重新启动服务器有帮助。