How to manage JBoss / WildFly remotely

In this article we will learn how you can manage a JBoss / WildFly application server remotely.

There are several alternatives to access a running JBoss / WildFly server remotely.

Prerequisites

  • First, set the IP Address jboss.bind.address.management to your machine’s address
$ ./standalone.sh -Djboss.bind.address.management=192.168.0.1

As an alternative, you can use the 0.0.0.0 address which will use all the available IP Addresses on that machine.

  • Then, create a Management User

In order to access JBoss remotely, a management user is required. If you are using the default property files to store users, you can create one using the add-user.sh script:

./add-user.sh -m -u admin -p password1!

If you are relying on an external repository to store your users, add your user directly there.

Done with the basic requirements, let’s check some available options.

Managing JBooss / WildFly remotely with the Web Console

The simplest and recommended option is use the Web Console, which is available at the management address (default http://localhost:9990).

Then, enter the management Username and Password:

Managing JBooss / WildFly remotely with the CLI

The other option is to use the JBoss CLI management tool. This tool is available by default in the $JBOSS_HOME/bin folder of your installation and can be run with:

$ ./jboss-cli.sh

However, to manage JBoss remotely, you don’t need an installation. The jboss-cli-client jar (found in $JBOSS_HOME/bin/client can be used to remotely manage a WildFly instance with CLI or jconsole. Firstly, copy jboss-cli-client.jar to your client machine.

Then, run it as follows:

$ java -jar <PATH TO jboss-cli-client.jar>

Conclusion

This tutorial covered the recommended options to manage a JBoss / WildFly server runtime remotely. In addition to the default tools, you can also use exernal tools such as VisualVm or JConsole to monitor remote installations of the application server. Check the following resources:

Exit mobile version