JBoss Not Listening on All Interfaces

I start my JBoss 3.2.3 server with run.sh --host= to have it listen only on localhost, and not directly accessible to the outside world. I found that the naming service was still looking up the hostname and serving that hostname and IP for RMI connections. This meant that clients (like shutdown.jar) would successfully lookup a service, but then try to connect to it on the outside interface which wasn't listening. I'd get a ConnectException when trying to use the shutdown.sh command even though I had specified --server=

To fix this, I added the -Djava.rmi.server.hostname= to my JAVA_OPTS in my run.conf.

The --host option sets jboss.bind.address. I wonder if it could be made to override java.rmi.server.hostname as well.

Filed Under: Java