Help coderanch get a
new server
by contributing to the fundraiser
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Devaka Cooray
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Tim Moores
  • Carey Brown
  • Mikalai Zaikin
Bartenders:
  • Lou Hamers
  • Piet Souris
  • Frits Walraven

JBoss 6 Shutdown - Failed to retrieve RMIServer stub: javax.naming.ServiceUnavailableExce

 
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Ranchers,

I have recently set up JBoss 6.0.0 up on a new Linux server.

I start JBoss with the -b xxx.xxx.xxx.xxx binding (where xxx.xxx.xxx.xxx is the IP of the machine).

To shutdown, i use the command: ./jboss-6.0.0.Final/bin/shutdown.sh --host=xxx.xxx.xxx.xxx --port=1090 -S

I have JBoss 6.0.0 running on another Linux server with identical startup/shutdown scripts and experience no issues. However, if I try and shutdown JBoss on the new Linux server I get the errors pasted below. Does anybody have any ideas what the problem may be here? I'm wondering if it may be something with the Linux setup on the new server rather than a JBoss issue, but can't seem to figure out what I've ensured the firewall is open for the required JBoss ports and experiemend changing the hosts file.

Exception in thread "main" java.io.IOException: Failed to retrieve RMIServer stub: javax.naming.ServiceUnavailableException [Root exception is java.rmi.ConnectException: Connection refused to host: xxx.xxx.xxx.xxx; nested exception is:
java.net.ConnectException: Connection refused]
at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:342)
at javax.management.remote.JMXConnectorFactory.connect(JMXConnectorFactory.java:267)
at org.jboss.Shutdown.main(Shutdown.java:235)
Caused by: javax.naming.ServiceUnavailableException [Root exception is java.rmi.ConnectException: Connection refused to host: xxx.xxx.xxx.xxx; nested exception is:
java.net.ConnectException: Connection refused]
at com.sun.jndi.rmi.registry.RegistryContext.lookup(RegistryContext.java:118)
at com.sun.jndi.toolkit.url.GenericURLContext.lookup(GenericURLContext.java:203)
at javax.naming.InitialContext.lookup(InitialContext.java:409)
at javax.management.remote.rmi.RMIConnector.findRMIServerJNDI(RMIConnector.java:1902)
at javax.management.remote.rmi.RMIConnector.findRMIServer(RMIConnector.java:1871)
at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:276)
... 2 more
Caused by: java.rmi.ConnectException: Connection refused to host: xxx.xxx.xxx.xxx; nested exception is:
java.net.ConnectException: Connection refused
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:340)
at sun.rmi.registry.RegistryImpl_Stub.lookup(Unknown Source)
at com.sun.jndi.rmi.registry.RegistryContext.lookup(RegistryContext.java:114)
... 7 more
Caused by: java.net.ConnectException: Connection refused
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:310)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:176)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:163)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:384)
at java.net.Socket.connect(Socket.java:546)
at java.net.Socket.connect(Socket.java:495)
at java.net.Socket.<init>(Socket.java:392)
at java.net.Socket.<init>(Socket.java:206)
at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(RMIDirectSocketFactory.java:40)
at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(RMIMasterSocketFactory.java:146)
at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:613)
... 12 more

Any ideas would be greatly appreciated.

Thanks!

 
Sheriff
Posts: 10445
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What does the following command output from that system?

 
M Hathaway
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Jaikiran,

Firstly thanks for the reply.

Telnet on this system whilst JBoss is running outputs:

Trying xxx.xxx.xxx.xxx...
Connected to xxx.xxx.xxx.xxx.
Escape character is '^]'.
¬ísrjava.rmi.MarshalledObject|½ícü>IhashlocBytest[BobjBytesq~xpFf
ur[B¬óTàxp-¬íthttp://xxx.xxx.xxx.xxx:8083/q~q~uq~Ƭísr org.jnp.server.NamingServer_Stubxrjava.rmi.server.RemoteStubéþÜÉáexrjava.rmi.server.RemoteObjectÓa´
a3xpw:
UnicastRefxxx.xxx.xxx1xx+wÂ,ó#¿xrU3s<xConnection closed by foreign host.

>
 
M Hathaway
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have a feeling this may be connected, but in the startup output I see this warning:

11:26:02,415 WARN [arjuna] ARJUNA-12210 Unable to use InetAddress.getLocalHost() to resolve address.

Could this be related to the shutdown problem?
 
Jaikiran Pai
Sheriff
Posts: 10445
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Sorry, in my previous post I asked you to try the wrong port. I meant:



Also, can you post the last few lines from your console logs when you start the server? That'll show us what bind address it uses to bind.

 
M Hathaway
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Jaikiran,

Some snippets from the startup log that may be useful:



telnet xxx.xxx.xxx.xxx 1090 returns:



I will add this is a clean JBoss startup with no alterations or deployed applications from downloading. Also, i notice the last few lines suggest "Failed to establish connection to server". I'm not sure what this means, i've not come across this message before either....

Thanks for your continued help, its greatly appreciated!
 
reply
    Bookmark Topic Watch Topic
  • New Topic