2014-01-25 124 views
1

我有glassfish服務器,我試圖從netbeans運行服務器。我收到以下錯誤:rmiexception同時啓動glassfish服務器

WARNING: Cannot start JMX connector JmxConnector config: { name = system, Protocol = rmi_jrmp, Address = 0.0.0.0, Port = 8686, AcceptAll = false, AuthRealmName = admin-realm, SecurityEnabled = false} due to exception java.io.IOException: Cannot bind to URL [rmi://MAZUMDAM4.americas.hpqcorp.net:8686/jmxrmi]: javax.naming.ServiceUnavailableException [Root exception is java.rmi.ConnectException: Connection refused to host: MAZUMDAM4.americas.hpqcorp.net; nested exception is: 
    java.net.ConnectException: Connection timed out: connect] 
SEVERE: java.io.IOException: Cannot bind to URL [rmi://MAZUMDAM4.americas.hpqcorp.net:8686/jmxrmi]: javax.naming.ServiceUnavailableException [Root exception is java.rmi.ConnectException: Connection refused to host: MAZUMDAM4.americas.hpqcorp.net; nested exception is: 
    java.net.ConnectException: Connection timed out: connect] 
    at javax.management.remote.rmi.RMIConnectorServer.newIOException(RMIConnectorServer.java:826) 
    at javax.management.remote.rmi.RMIConnectorServer.start(RMIConnectorServer.java:431) 
    at org.glassfish.admin.mbeanserver.RMIConnectorStarter.start(RMIConnectorStarter.java:300) 
    at org.glassfish.admin.mbeanserver.JMXStartupService$JMXConnectorsStarterThread.startConnector(JMXStartupService.java:297) 
    at org.glassfish.admin.mbeanserver.JMXStartupService$JMXConnectorsStarterThread.run(JMXStartupService.java:333) 
Caused by: javax.naming.ServiceUnavailableException [Root exception is java.rmi.ConnectException: Connection refused to host: MAZUMDAM4.americas.hpqcorp.net; nested exception is: 
    java.net.ConnectException: Connection timed out: connect] 
    at com.sun.jndi.rmi.registry.RegistryContext.rebind(RegistryContext.java:159) 
    at com.sun.jndi.toolkit.url.GenericURLContext.rebind(GenericURLContext.java:249) 
    at javax.naming.InitialContext.rebind(InitialContext.java:427) 
    at javax.naming.InitialContext.rebind(InitialContext.java:427) 
    at javax.management.remote.rmi.RMIConnectorServer.bind(RMIConnectorServer.java:641) 
    at javax.management.remote.rmi.RMIConnectorServer.start(RMIConnectorServer.java:426) 
    ... 3 more 
Caused by: java.rmi.ConnectException: Connection refused to host: MAZUMDAM4.americas.hpqcorp.net; nested exception is: 
    java.net.ConnectException: Connection timed out: connect 
    at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:619) 
    at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:216) 
    at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:202) 
    at sun.rmi.server.UnicastRef.newCall(UnicastRef.java:341) 
    at sun.rmi.registry.RegistryImpl_Stub.rebind(Unknown Source) 
    at com.sun.jndi.rmi.registry.RegistryContext.rebind(RegistryContext.java:157) 
    ... 8 more 
Caused by: java.net.ConnectException: Connection timed out: connect 
    at java.net.DualStackPlainSocketImpl.connect0(Native Method) 
    at java.net.DualStackPlainSocketImpl.socketConnect(DualStackPlainSocketImpl.java:79) 
    at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339) 
    at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200) 
    at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182) 
    at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172) 
    at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) 
    at java.net.Socket.connect(Socket.java:579) 
    at java.net.Socket.connect(Socket.java:528) 
    at java.net.Socket.<init>(Socket.java:425) 
    at java.net.Socket.<init>(Socket.java:208) 
    at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(RMIDirectSocketFactory.java:40) 
    at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(RMIMasterSocketFactory.java:147) 
    at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:613) 
    ... 13 more 

現在搜索谷歌後,我遇到了各種建議。

a。檢查防火牆。防火牆不是問題。因爲這兩天前工作正常,突然停了下來。

b。從管理控制檯設置JMX端口。我做到了,它不起作用。

c。檢查端口以查看它是否已被使用。我檢查了它。此外,我重新啓動了glassfish服務器。即使重新啓動電腦。沒有改變。

現在我需要一些聰明人的幫助來解決這個問題。

由於

+0

呃這個問題似乎已經通過將IP設置爲127.0.0.1從0.0.0.0解決。這引發了下一個問題。它以前是如何工作的? – user1539343

回答

1

根本問題是

Caused by: java.rmi.ConnectException: Connection refused to host: MAZUMDAM4.americas.hpqcorp.net; nested exception is: 
    java.net.ConnectException: Connection timed out: connect 
重新綁定期間

()。查看堆棧跟蹤。試圖將遠程對象綁定到其註冊表時,RMI根本沒有收到該主機的任何響應。這是網絡拓撲問題或可能是DNS問題。它應該試圖僅綁定到'localhost'的註冊表。

5

啓動域,進入管理控制檯。

在管理控制檯中,導航 配置>服務器配置> AdminService

有一個在主窗口中的選項卡是名爲「編輯JMX連接器」

的IP地址可能是設置爲「 0.0.0.0" (所有IP的)

變化,爲‘127.0.0.1’

,你可能還需要在您的主機添加一個條目在errror文件 的域名「mymachine.SOMmainmain.net」或其他..所以它解析爲127.0.0.1。

相關問題