2017-02-23 168 views
0

我们正在将应用程序从JBoss AS 4.2迁移到JBoss eap 6.4。在部署应用程序时得到以下例外。JBoss eap 6.4的JNDI端口配置

javax.naming.CommunicationException: Could not obtain connection to any of these urls: localhost:10099 and discovery failed with error: javax.naming.CommunicationException: Receive timed out [Root exception is java.net.SocketTimeoutException: Receive timed out] [Root exception is javax.naming.CommunicationException: Failed to connect to server localhost:10099 [Root exception is javax.naming.ServiceUnavailableException: Failed to connect to server localhost:10099 [Root exception is java.net.ConnectException: Connection refused: connect]]] 
    at org.jnp.interfaces.NamingContext.checkRef(NamingContext.java:1562) 
    at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:634) 
    at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:627) 
    at javax.naming.InitialContext.lookup(InitialContext.java:411) 

到localhost:10099的连接失败。当我检入AS 4.2的jboss-service.xml文件时,存在此端口的配置。

<mbean code="org.jboss.naming.NamingService" 
     name="jboss:service=Naming" 
     xmbean-dd="resource:xmdesc/NamingService-xmbean.xml"> 
     <!-- The call by value mode. true if all lookups are unmarshalled using 
     the caller's TCL, false if in VM lookups return the value by reference. 
     --> 
     <attribute name="CallByValue">false</attribute> 
     <!-- The listening port for the bootstrap JNP service. Set this to -1 
     to run the NamingService without the JNP invoker listening port. 
     --> 
     <attribute name="Port">10099</attribute> 

谁能告诉我哪里可以做EAP 6类似的配置在尝试加入standalone.xml插座结合,组,但没有奏效。

回答

0
  • 检查boot.log以查看jboss.bind.address的值是什么。
  • 应该有相似的一行: DEBUG [ServerInfo] jboss.bind.address:127.0.0.1
  • Telnet到JNDI端口,以确认在服务器上有一个服务监听:1.telnet主机名/ IP JNDI_PORT 2.默认情况下JNDI将位于端口1099上
  • 检查主机上的防火墙规则并确保端口10099已打开,以便旋转工作。