2011-07-26 37 views
6

我已經部署了一個具有本地和遠程接口的EJB,在部署後我可以查找本地的一個,但是我無法使用Java SE客戶。無法在Websphere上查找遠程EJB 8

的EJB代碼很簡單:

@Local(DemoFacade.class) 
@Remote(DemoFacadeRemote.class) 
@Stateless 
public class DemoFacadeBean implements DemoFacade 
<snip> 

查找代碼也很簡單:

Properties env1 = new Properties(); 
env1.put(Context.INITIAL_CONTEXT_FACTORY, "com.ibm.websphere.naming.WsnInitialContextFactory"); 
env1.put(Context.PROVIDER_URL, "corbaloc:iiop:localhost:2809"); 
Context initialContext; 

initialContext = new InitialContext(env1); 
Object ejbHome = initialContext.lookup("cell/nodes/OVLM46008QPZKQ1Node01/servers/server1/ejb/DemoFacadeRemote"); 

我也嘗試了JNDI查找的許多變化,但都失敗了同樣的錯誤。

Object ejbHome = initialContext.lookup("cell/nodes/OVLM46008QPZKQ1Node01/servers/server1/java:global/WebSphereDemo/WebSphereDemoEJB/DemoFacadeBean!com.test.DemoFacadeRemote"); 

我已經添加了下面的參數來幫助調試:

-Dcom.ibm.CORBA.Debug=true -Dcom.ibm.CORBA.CommTrace=true -Dcom.ibm.CORBA.Debug.Output=c:/temp/client.log -Dcom.ibm.ejs.ras.lite.traceSpecification=*=all -Djava.endorsed.dirs=C:/data/workspace/WebSphereDemoEJBTest/lib/websphereclient/eee 

類路徑設置到WebSphere/lib文件夾中的所有jar文件。

完整的控制檯輸出是(對輸出的長度感到抱歉,其中的一部分被省略)。真正的錯誤在最後。 感謝您的任何建議。

************ Start Display Current Environment ************ 
<snip> 

[26/07/2011 15:49:32:122 EST] 00000000 com.ibm.ws.naming.ipbase.NameSpace    > lookUpRootContext Entry 
           bindingName=IIOP_DEFAULT_ROOT 
           [email protected]386 
[26/07/2011 15:49:32:123 EST] 00000000 com.ibm.ws.naming.ipbase.NameSpace    < lookUpRootContext Exit 
           javax.naming.NameNotFoundException: Root context not found. 
[26/07/2011 15:49:32:123 EST] 00000000 com.ibm.ws.naming.jcache.Cache     3 lookup 
           NamingException: javax.naming.NameNotFoundException: Root context not found. 
[26/07/2011 15:49:32:123 EST] 00000000 com.ibm.ws.naming.jcache.Cache     < lookup Exit 
           Throwing CacheEntryNotFoundException: com.ibm.ws.naming.jcache.CacheEntryNotFoundException: Entry "IIOP_DEFAULT_ROOT" not found in cache. [Root exception is javax.naming.NameNotFoundException: Root context not found.] 
[26/07/2011 15:49:32:123 EST] 00000000 com.ibm.ws.naming.util.WsnInitCtxFactory   > getRootJndiContext Entry 
[26/07/2011 15:49:32:124 EST] 00000000 com.ibm.ws.naming.util.TransactionUtil   3 SOURCE CODE INFO: SERV1/ws/code/naming.client/src/com/ibm/ws/naming/util/TransactionUtil.java, WAS.naming.client, WAS80.SERV1, m1116.12, ver. 1.5 
[26/07/2011 15:49:32:124 EST] 00000000 com.ibm.ws.naming.util.TransactionUtil   > suspend Entry 
[26/07/2011 15:49:32:127 EST] 00000000 com.ibm.ws.uow.UOWManagerFactory     > getUOWManager Entry 
[26/07/2011 15:49:32:128 EST] 00000000 com.ibm.ws.uow.UOWManagerFactory     < getUOWManager Exit 
           [email protected] 
[26/07/2011 15:49:32:128 EST] 00000000 com.ibm.ws.naming.util.TransactionUtil   3 suspend 
           current transaction suspended 
[26/07/2011 15:49:32:128 EST] 00000000 com.ibm.ws.naming.util.TransactionUtil   < suspend Exit 
[26/07/2011 15:49:32:129 EST] 00000000 com.ibm.ws.naming.util.WsnInitCtxFactory   > getRootContextFromServer Entry 
           wsnObjectUrl=corbaloc:iiop:[email protected]:2809/WsnNameService 
           objectUrl=corbaloc:iiop:[email protected]:2809/NameService 
[26/07/2011 15:49:32:129 EST] 00000000 com.ibm.ws.naming.util.WsnInitCtxFactory   > getWsnNameService Entry 
           objectUrl=corbaloc:iiop:[email protected]:2809/WsnNameService 
[26/07/2011 15:49:32:130 EST] 00000000 com.ibm.ws.naming.util.WsnInitCtxFactory   3 getWsnNameService 
           Attempting to connect to name server using URL corbaloc:iiop:[email protected]:2809/WsnNameService 
[26/07/2011 15:49:32:130 EST] 00000000 com.ibm.ws.naming.util.WsnInitCtxFactory   > stringToObject Entry 
           string=corbaloc:iiop:[email protected]:2809/WsnNameService 
[26/07/2011 15:49:32:137 EST] 00000000 er.router.selection.WLMClientForCommonRouterImpl > initialize Entry 
[26/07/2011 15:49:32:138 EST] 00000000 com.ibm.ws.wlm.configuration.WLMIOR    3 version : 
           1.30 
[26/07/2011 15:49:32:138 EST] 00000000 com.ibm.ws.wlm.configuration.WLMIOR    > getWLMIOR Entry 
[26/07/2011 15:49:32:138 EST] 00000000 com.ibm.ws.wlm.configuration.WLMIOR    3 getWLMIOR - typeid= 
[26/07/2011 15:49:32:138 EST] 00000000 com.ibm.ws.wlm.configuration.WLMIOR    3 getWLMIOR - host= ovlm46008qpzkq1.oakton.com.au 
[26/07/2011 15:49:32:138 EST] 00000000 com.ibm.ws.wlm.configuration.WLMIOR    3 getWLMIOR - port= 2809 
[26/07/2011 15:49:32:139 EST] 00000000 com.ibm.ws.wlm.configuration.WLMIOR    3 getWLMIOR - objectKey= 0x57736e4e616d6553657276696365 
[26/07/2011 15:49:32:139 EST] 00000000 com.ibm.ws.wlm.configuration.WLMIOR    3 getWLMIOR - taggedcomponent= [Lcom.ibm.rmi.Profile$TaggedComponent;@fffde943 
[26/07/2011 15:49:32:143 EST] 00000000 ebsphere.cluster.topography.KeyRepositoryFactory 3 version : 
           1.2 
[26/07/2011 15:49:32:147 EST] 00000000 com.ibm.ws.cluster.topography.KeyRepositoryImpl 3 version : 
           1.15 
[26/07/2011 15:49:32:147 EST] 00000000 com.ibm.ws.wlm.configuration.WLMIOR    3 component_data 
[26/07/2011 15:49:32:147 EST] 00000000 er.router.selection.WLMClientForCommonRouterImpl < initialize - getWLMIOR returned a null Exit 
[26/07/2011 15:49:32:192 EST] 00000000 er.router.selection.WLMClientForCommonRouterImpl > initialize Entry 
[26/07/2011 15:49:32:192 EST] 00000000 com.ibm.ws.wlm.configuration.WLMIOR    > getWLMIOR Entry 
[26/07/2011 15:49:32:192 EST] 00000000 com.ibm.ws.wlm.configuration.WLMIOR    3 getWLMIOR - typeid= IDL:com.ibm/WsnBootstrap/WsnNameService:1.0 
[26/07/2011 15:49:32:192 EST] 00000000 com.ibm.ws.wlm.configuration.WLMIOR    3 getWLMIOR - host= OVLM46008QPZKQ1.oakton.com.au 
[26/07/2011 15:49:32:192 EST] 00000000 com.ibm.ws.wlm.configuration.WLMIOR    3 getWLMIOR - port= 0 
[26/07/2011 15:49:32:193 EST] 00000000 com.ibm.ws.wlm.configuration.WLMIOR    3 getWLMIOR - objectKey= 0x4a4d4249000000104773e3aa0000000000000000000000000000000000000024000000080000000000000000 
[26/07/2011 15:49:32:193 EST] 00000000 com.ibm.ws.wlm.configuration.WLMIOR    3 getWLMIOR - taggedcomponent= [Lcom.ibm.rmi.Profile$TaggedComponent;@fffc731f 
[26/07/2011 15:49:32:193 EST] 00000000 com.ibm.ws.wlm.configuration.WLMIOR    3 component_data 
[26/07/2011 15:49:32:193 EST] 00000000 er.router.selection.WLMClientForCommonRouterImpl < initialize - getWLMIOR returned a null Exit 
[26/07/2011 15:49:32:198 EST] 00000000 com.ibm.ws.naming.util.WsnInitCtxFactory   < stringToObject Exit 

[26/07/2011 15:49:32:200 EST] 00000000 com.ibm.ws.naming.util.WsnInitCtxFactory   < getWsnNameService Exit 

[26/07/2011 15:49:32:202 EST] 00000000 com.ibm.ws.naming.util.WsnInitCtxFactory   > mergeWsnNSProperties Entry 

[26/07/2011 15:49:32:217 EST] 00000000 com.ibm.ws.ffdc.FFDCFilter      3 FFDC exception: org.omg.CORBA.TRANSIENT: java.net.ConnectException: connect: Address is invalid on local machine, or port is not valid on remote machine:host=OVLM46008QPZKQ1.oakton.com.au,port=0 vmcid: IBM minor code: E02 completed: No com.ibm.ws.orbimpl.transport.WSTransport.getConnection 448 
[26/07/2011 15:49:32:237 EST] 00000000 com.ibm.ws.naming.util.RasUtil     3 SOURCE CODE INFO: SERV1/ws/code/naming/src/com/ibm/ws/naming/util/RasUtil.java, WAS.naming, WAS80.SERV1, m1116.12, ver. 1.2 
[26/07/2011 15:49:32:238 EST] 00000000 com.ibm.ws.ffdc.FFDCFilter      3 FFDC exception: org.omg.CORBA.TRANSIENT: initial and forwarded IOR inaccessible vmcid: IBM minor code: E07 completed: No com.ibm.ws.naming.util.WsnInitCtxFactory.mergeWsnNSProperties 1549 
[26/07/2011 15:49:32:238 EST] 00000000 com.ibm.ws.naming.util.WsnInitCtxFactory   mergeWsnNSProperties 
           FFDC: sourceId=com.ibm.ws.naming.util.WsnInitCtxFactory.mergeWsnNSProperties, probeId=1549 
           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:1274) 
    at com.ibm.CORBA.iiop.ClientDelegate.createRequest(ClientDelegate.java:1342) 
    at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1162) 
    at com.ibm.CORBA.iiop.ClientDelegate.createRequest(ClientDelegate.java:1308) 
    at com.ibm.rmi.corba.ClientDelegate.request(ClientDelegate.java:1884) 
    at com.ibm.CORBA.iiop.ClientDelegate.request(ClientDelegate.java:1264) 
    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:1547) 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.getRootContextFromServer(WsnInitCtxFactory.java:1040) 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.getRootJndiContext(WsnInitCtxFactory.java:960) 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.getInitialContextInternal(WsnInitCtxFactory.java:612) 
    at com.ibm.ws.naming.util.WsnInitCtx.getContext(WsnInitCtx.java:128) 
    at com.ibm.ws.naming.util.WsnInitCtx.getContextIfNull(WsnInitCtx.java:765) 
    at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:164) 
    at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:179) 
    at javax.naming.InitialContext.lookup(InitialContext.java:431) 
    at com.oakton.MainTest.main(MainTest.java:20) 
Caused by: java.net.ConnectException: connect: Address is invalid on local machine, or port is not valid on remote machine 
    at java.net.PlainSocketImpl.socketConnect(Native Method) 
    at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:383) 
    at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:245) 
    at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:232) 
    at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:377) 
    at java.net.Socket.connect(Socket.java:539) 
    at com.ibm.ws.orbimpl.transport.WSTCPTransportConnection.createSocket(WSTCPTransportConnection.java:295) 
    at com.ibm.CORBA.transport.TransportConnectionBase.connect(TransportConnectionBase.java:354) 
    at com.ibm.ws.orbimpl.transport.WSTransport.getConnection(WSTransport.java:436) 
    at com.ibm.CORBA.transport.TransportBase.getConnection(TransportBase.java:187) 
    at com.ibm.rmi.iiop.TransportManager.get(TransportManager.java:89) 
    at com.ibm.rmi.iiop.GIOPImpl.getConnection(GIOPImpl.java:130) 
    at com.ibm.rmi.iiop.GIOPImpl.locate(GIOPImpl.java:219) 
    at com.ibm.rmi.corba.ClientDelegate.locate(ClientDelegate.java:1981) 
    at com.ibm.rmi.corba.ClientDelegate._createRequest(ClientDelegate.java:2006) 
    at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1184) 
    at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1270) 
    ... 17 more 

[26/07/2011 15:49:32:239 EST] 00000000 com.ibm.ws.naming.util.WsnInitCtxFactory   < mergeWsnNSProperties Exit 
           javax.naming.NamingException: Error getting WsnNameService properties [Root exception is org.omg.CORBA.TRANSIENT: initial and forwarded IOR inaccessible vmcid: IBM minor code: E07 completed: No] 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.mergeWsnNSProperties(WsnInitCtxFactory.java:1550) 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.getRootContextFromServer(WsnInitCtxFactory.java:1040) 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.getRootJndiContext(WsnInitCtxFactory.java:960) 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.getInitialContextInternal(WsnInitCtxFactory.java:612) 
    at com.ibm.ws.naming.util.WsnInitCtx.getContext(WsnInitCtx.java:128) 
    at com.ibm.ws.naming.util.WsnInitCtx.getContextIfNull(WsnInitCtx.java:765) 
    at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:164) 
    at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:179) 
    at javax.naming.InitialContext.lookup(InitialContext.java:431) 
    at com.oakton.MainTest.main(MainTest.java:20) 
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:1274) 
    at com.ibm.CORBA.iiop.ClientDelegate.createRequest(ClientDelegate.java:1342) 
    at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1162) 
    at com.ibm.CORBA.iiop.ClientDelegate.createRequest(ClientDelegate.java:1308) 
    at com.ibm.rmi.corba.ClientDelegate.request(ClientDelegate.java:1884) 
    at com.ibm.CORBA.iiop.ClientDelegate.request(ClientDelegate.java:1264) 
    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:1547) 
    ... 9 more 
Caused by: java.net.ConnectException: connect: Address is invalid on local machine, or port is not valid on remote machine 
    at java.net.PlainSocketImpl.socketConnect(Native Method) 
    at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:383) 
    at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:245) 
    at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:232) 
    at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:377) 
    at java.net.Socket.connect(Socket.java:539) 
    at com.ibm.ws.orbimpl.transport.WSTCPTransportConnection.createSocket(WSTCPTransportConnection.java:295) 
    at com.ibm.CORBA.transport.TransportConnectionBase.connect(TransportConnectionBase.java:354) 
    at com.ibm.ws.orbimpl.transport.WSTransport.getConnection(WSTransport.java:436) 
    at com.ibm.CORBA.transport.TransportBase.getConnection(TransportBase.java:187) 
    at com.ibm.rmi.iiop.TransportManager.get(TransportManager.java:89) 
    at com.ibm.rmi.iiop.GIOPImpl.getConnection(GIOPImpl.java:130) 
    at com.ibm.rmi.iiop.GIOPImpl.locate(GIOPImpl.java:219) 
    at com.ibm.rmi.corba.ClientDelegate.locate(ClientDelegate.java:1981) 
    at com.ibm.rmi.corba.ClientDelegate._createRequest(ClientDelegate.java:2006) 
    at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1184) 
    at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1270) 
    ... 17 more 

[26/07/2011 15:49:32:240 EST] 00000000 com.ibm.ws.ffdc.FFDCFilter      3 FFDC exception: javax.naming.NamingException: Error getting WsnNameService properties [Root exception is org.omg.CORBA.TRANSIENT: initial and forwarded IOR inaccessible vmcid: IBM minor code: E07 completed: No] com.ibm.ws.naming.util.WsnInitCtxFactory.getRootJndiContext 963 
[26/07/2011 15:49:32:240 EST] 00000000 com.ibm.ws.naming.util.WsnInitCtxFactory   getRootJndiContext 
           FFDC: sourceId=com.ibm.ws.naming.util.WsnInitCtxFactory.getRootJndiContext, probeId=963 
           javax.naming.NamingException: Error getting WsnNameService properties [Root exception is org.omg.CORBA.TRANSIENT: initial and forwarded IOR inaccessible vmcid: IBM minor code: E07 completed: No] 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.mergeWsnNSProperties(WsnInitCtxFactory.java:1550) 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.getRootContextFromServer(WsnInitCtxFactory.java:1040) 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.getRootJndiContext(WsnInitCtxFactory.java:960) 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.getInitialContextInternal(WsnInitCtxFactory.java:612) 
    at com.ibm.ws.naming.util.WsnInitCtx.getContext(WsnInitCtx.java:128) 
    at com.ibm.ws.naming.util.WsnInitCtx.getContextIfNull(WsnInitCtx.java:765) 
    at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:164) 
    at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:179) 
    at javax.naming.InitialContext.lookup(InitialContext.java:431) 
    at com.oakton.MainTest.main(MainTest.java:20) 
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:1274) 
    at com.ibm.CORBA.iiop.ClientDelegate.createRequest(ClientDelegate.java:1342) 
    at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1162) 
    at com.ibm.CORBA.iiop.ClientDelegate.createRequest(ClientDelegate.java:1308) 
    at com.ibm.rmi.corba.ClientDelegate.request(ClientDelegate.java:1884) 
    at com.ibm.CORBA.iiop.ClientDelegate.request(ClientDelegate.java:1264) 
    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:1547) 
    ... 9 more 
Caused by: java.net.ConnectException: connect: Address is invalid on local machine, or port is not valid on remote machine 
    at java.net.PlainSocketImpl.socketConnect(Native Method) 
    at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:383) 
    at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:245) 
    at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:232) 
    at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:377) 
    at java.net.Socket.connect(Socket.java:539) 
    at com.ibm.ws.orbimpl.transport.WSTCPTransportConnection.createSocket(WSTCPTransportConnection.java:295) 
    at com.ibm.CORBA.transport.TransportConnectionBase.connect(TransportConnectionBase.java:354) 
    at com.ibm.ws.orbimpl.transport.WSTransport.getConnection(WSTransport.java:436) 
    at com.ibm.CORBA.transport.TransportBase.getConnection(TransportBase.java:187) 
    at com.ibm.rmi.iiop.TransportManager.get(TransportManager.java:89) 
    at com.ibm.rmi.iiop.GIOPImpl.getConnection(GIOPImpl.java:130) 
    at com.ibm.rmi.iiop.GIOPImpl.locate(GIOPImpl.java:219) 
    at com.ibm.rmi.corba.ClientDelegate.locate(ClientDelegate.java:1981) 
    at com.ibm.rmi.corba.ClientDelegate._createRequest(ClientDelegate.java:2006) 
    at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1184) 
    at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1270) 
    ... 17 more 

[26/07/2011 15:49:32:242 EST] 00000000 com.ibm.ws.naming.util.WsnInitCtxFactory   3 getRootJndiContext 
           Could not connect to name server using URL corbaloc:iiop:[email protected]:2809/NameService 
[26/07/2011 15:49:32:245 EST] 00000000 com.ibm.ws.ffdc.FFDCFilter      3 FFDC exception: javax.naming.NamingException: NMSV0602E: Naming Service unavailable. A communications error occurred. [Root exception is javax.naming.NamingException: Error getting WsnNameService properties [Root exception is org.omg.CORBA.TRANSIENT: initial and forwarded IOR inaccessible vmcid: IBM minor code: E07 completed: No]] com.ibm.ws.naming.util.WsnInitCtxFactory.getRootJndiContext 886 
[26/07/2011 15:49:32:247 EST] 00000000 com.ibm.ws.naming.util.WsnInitCtxFactory   getRootJndiContext 
           FFDC: sourceId=com.ibm.ws.naming.util.WsnInitCtxFactory.getRootJndiContext, probeId=886 
           javax.naming.NamingException: NMSV0602E: Naming Service unavailable. A communications error occurred. [Root exception is javax.naming.NamingException: Error getting WsnNameService properties [Root exception is org.omg.CORBA.TRANSIENT: initial and forwarded IOR inaccessible vmcid: IBM minor code: E07 completed: No]] 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.getRootJndiContext(WsnInitCtxFactory.java:979) 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.getInitialContextInternal(WsnInitCtxFactory.java:612) 
    at com.ibm.ws.naming.util.WsnInitCtx.getContext(WsnInitCtx.java:128) 
    at com.ibm.ws.naming.util.WsnInitCtx.getContextIfNull(WsnInitCtx.java:765) 
    at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:164) 
    at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:179) 
    at javax.naming.InitialContext.lookup(InitialContext.java:431) 
    at com.oakton.MainTest.main(MainTest.java:20) 
Caused by: javax.naming.NamingException: Error getting WsnNameService properties [Root exception is org.omg.CORBA.TRANSIENT: initial and forwarded IOR inaccessible vmcid: IBM minor code: E07 completed: No] 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.mergeWsnNSProperties(WsnInitCtxFactory.java:1550) 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.getRootContextFromServer(WsnInitCtxFactory.java:1040) 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.getRootJndiContext(WsnInitCtxFactory.java:960) 
    ... 7 more 
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:1274) 
    at com.ibm.CORBA.iiop.ClientDelegate.createRequest(ClientDelegate.java:1342) 
    at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1162) 
    at com.ibm.CORBA.iiop.ClientDelegate.createRequest(ClientDelegate.java:1308) 
    at com.ibm.rmi.corba.ClientDelegate.request(ClientDelegate.java:1884) 
    at com.ibm.CORBA.iiop.ClientDelegate.request(ClientDelegate.java:1264) 
    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:1547) 
    ... 9 more 
Caused by: java.net.ConnectException: connect: Address is invalid on local machine, or port is not valid on remote machine 
    at java.net.PlainSocketImpl.socketConnect(Native Method) 
    at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:383) 
    at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:245) 
    at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:232) 
    at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:377) 
    at java.net.Socket.connect(Socket.java:539) 
    at com.ibm.ws.orbimpl.transport.WSTCPTransportConnection.createSocket(WSTCPTransportConnection.java:295) 
    at com.ibm.CORBA.transport.TransportConnectionBase.connect(TransportConnectionBase.java:354) 
    at com.ibm.ws.orbimpl.transport.WSTransport.getConnection(WSTransport.java:436) 
    at com.ibm.CORBA.transport.TransportBase.getConnection(TransportBase.java:187) 
    at com.ibm.rmi.iiop.TransportManager.get(TransportManager.java:89) 
    at com.ibm.rmi.iiop.GIOPImpl.getConnection(GIOPImpl.java:130) 
    at com.ibm.rmi.iiop.GIOPImpl.locate(GIOPImpl.java:219) 
    at com.ibm.rmi.corba.ClientDelegate.locate(ClientDelegate.java:1981) 
    at com.ibm.rmi.corba.ClientDelegate._createRequest(ClientDelegate.java:2006) 
    at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1184) 
    at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1270) 
    ... 17 more 

[26/07/2011 15:49:32:247 EST] 00000000 com.ibm.ws.naming.util.TransactionUtil   > resume Entry 
           wr[email protected]fffae2a9[[email protected], _token=null] 
[26/07/2011 15:49:32:248 EST] 00000000 com.ibm.ws.naming.util.TransactionUtil   3 resume 
           no transaction to resume 
[26/07/2011 15:49:32:248 EST] 00000000 com.ibm.ws.naming.util.TransactionUtil   < resume Exit 
javax.naming.NamingException: Error getting WsnNameService properties [Root exception is org.omg.CORBA.TRANSIENT: initial and forwarded IOR inaccessible vmcid: IBM minor code: E07 completed: No] 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.mergeWsnNSProperties(WsnInitCtxFactory.java:1550) 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.getRootContextFromServer(WsnInitCtxFactory.java:1040) 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.getRootJndiContext(WsnInitCtxFactory.java:960) 
    at com.ibm.ws.naming.util.WsnInitCtxFactory.getInitialContextInternal(WsnInitCtxFactory.java:612) 
    at com.ibm.ws.naming.util.WsnInitCtx.getContext(WsnInitCtx.java:128) 
    at com.ibm.ws.naming.util.WsnInitCtx.getContextIfNull(WsnInitCtx.java:765) 
    at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:164) 
    at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:179) 
    at javax.naming.InitialContext.lookup(InitialContext.java:431) 
    at com.oakton.MainTest.main(MainTest.java:20) 
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:1274) 
    at com.ibm.CORBA.iiop.ClientDelegate.createRequest(ClientDelegate.java:1342) 
    at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1162) 
    at com.ibm.CORBA.iiop.ClientDelegate.createRequest(ClientDelegate.java:1308) 
    at com.ibm.rmi.corba.ClientDelegate.request(ClientDelegate.java:1884) 
    at com.ibm.CORBA.iiop.ClientDelegate.request(ClientDelegate.java:1264) 
    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:1547) 
    ... 9 more 
Caused by: java.net.ConnectException: connect: Address is invalid on local machine, or port is not valid on remote machine 
    at java.net.PlainSocketImpl.socketConnect(Native Method) 
    at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:383) 
    at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:245) 
    at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:232) 
    at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:377) 
    at java.net.Socket.connect(Socket.java:539) 
    at com.ibm.ws.orbimpl.transport.WSTCPTransportConnection.createSocket(WSTCPTransportConnection.java:295) 
    at com.ibm.CORBA.transport.TransportConnectionBase.connect(TransportConnectionBase.java:354) 
    at com.ibm.ws.orbimpl.transport.WSTransport.getConnection(WSTransport.java:436) 
    at com.ibm.CORBA.transport.TransportBase.getConnection(TransportBase.java:187) 
    at com.ibm.rmi.iiop.TransportManager.get(TransportManager.java:89) 
    at com.ibm.rmi.iiop.GIOPImpl.getConnection(GIOPImpl.java:130) 
    at com.ibm.rmi.iiop.GIOPImpl.locate(GIOPImpl.java:219) 
    at com.ibm.rmi.corba.ClientDelegate.locate(ClientDelegate.java:1981) 
    at com.ibm.rmi.corba.ClientDelegate._createRequest(ClientDelegate.java:2006) 
    at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1184) 
    at com.ibm.rmi.corba.ClientDelegate.createRequest(ClientDelegate.java:1270) 
    ... 17 more 
+0

服務器是否在localhost:2809上運行? SystemOut.log中的NMSV0018I消息中顯示了哪個端口?一個簡單的Socket.connect工作嗎?新的Socket()。connect(新的InetSocketAddress(「localhost」,2809)) –

回答

6

我碰到這樣的事情,並添加這兩個參數幫助:

-Dcom.ibm.SSL.ConfigURL =文件:$ profile_root /屬性/ ssl.client.props

- Dcom.ibm.CORBA.ConfigURL = file:$ profile_root/properties/sas.client.props

您可能還必須設置這些參數,或者將它們硬編碼到sas.client.props中,我注意到提示符保持時間如果我沒有包含這些登錄憑據,則等待登錄憑據。

-Dcom.ibm.CORBA.loginUserid = $ {那麼WasUserid}

-Dcom.ibm.CORBA.loginPassword = $ {WasPassword保留}

-Dcom.ibm.CORBA.loginSource =屬性

剛剛注意到我的監聽地址/ url格式也不一樣: -Djava.naming.provider.url = iiop:// localhost:$ {ORB_LISTENER_ADDRESS}。您可以在config/cells // nodes/serverindex.xml中找到orb偵聽器端口。

希望工程!

+2

我發現Websphere默認情況下是SSL保護的,所以最簡單的方法是使用SSL,如每條評論。 – oenningj

+0

謝謝了。將我的頭靠在牆上一週,找到這個愚蠢的Webpshere環境。同樣,這篇文章http://mresetar.blogspot.com/2012_06_01_archive.html – user1515304

+1

也有幫助,但默認情況下,WebSphere 8+的RMI/IIOP安全性設置爲SSL_required。在此之前(WAS7及以下版本),SSL_supported是開箱即用的。 – Renan