Multiple JBoss AS (6.1.0.Final) servers shutdown together when on port 8080 and 8180

475 views Asked by At

I have 2 JBoss servers: one is running on default ports (8080). The other one is using ports-01 (8180). Both of them are started using a Windows service (service.bat). They are from the same version: 6.1.0.Final.

When I shutdown the one which is running on port 8180 (using Windows services), the one running on port 8080 also stops.

Both of the AS servers are running fine next to each other, but somehow, there's a link between the 2 servers.

Any idea why/how?

1

There are 1 answers

0
kaskelotti On

I got my similar issue solved by setting the jboss native management port to jboss-cli.bat calls. By default jboss-cli uses port 9999.

The stop and restart commands in service.bat have the following line

call jboss-cli.bat --connect --command=:shutdown >> shutdown.log 2>&1

This will cause the jBoss instance using the default ports to shutdown even if it's different from the one that service.bat is supposed to control.

So the native management port for the instance you wish to control should be specified here. This can be done with --controller option, resulting in something like

call jboss-cli.bat --connect --controller=localhost:9999 --command=:shutdown >> shutdown.log 2>&1

As this needs to set in both stop and restart commands, it's better to make variable out of the native management address.

More info on CLI for those interested, can be found in the docs