Wildfly remotely access administration console doesnt work

[亡魂溺海] 提交于 2019-12-03 06:51:09

问题


I am new to WildFly/JBOSS. I am using WildFly 8.2.0. I have installed it as a service on Linux using an installation script from http://sukharevd.net/wildfly-8-installation.html. Everything works fine. I connect to my Linux remotely using SSH. It doesnt have GUI. So I need to be able to remotely connect to administration console. I cannot connect and it shows the following message:

"An automatic redirect to the Administration Console is not currently available. This is most likely due to the administration console being exposed over a network interface different from the one to which you are connected to."

I see the same issue mentioned in the following link

https://github.com/jboss-dockerfiles/wildfly/issues/3

The link has solution to it but it uses "docker". How can I do it without using docker? I am using standalone configuration. What configuraiton do I need to change?


回答1:


You should start WildFly using following command. Use of 0.0.0.0 will bind WildFly to all the available IP addresses on your linux box. If you want to bind to specific IP address; you can replace 0.0.0.0 with the relevant IP address.

$WILDFLY_HOME/bin/standalone.sh -b=0.0.0.0 -bmanagement=0.0.0.0

EDIT : Once the installation was complete using the script. We have to go to /etc/init.d/service and change JBOSS_SCRIPT=$JBOSS_HOME/bin/standalone.sh to JBOSS_SCRIPT="$JBOSS_HOME/bin/standalone.sh -b=0.0.0.0 -bmanagement=0.0.0.0"




回答2:


The Second Possible Solution

As an alternative to adding parameters do your start command, you can edit your standalone.xml to enable remote access from any source. This approach is more useful if you need the remote access enabled most of the time, this way, you don’t need to remember to pass additional parameters to the start command, as shown above.

First, go to your Wildfly configuration folder:

terminal

cd /opt/wildfly-8.2.0.Final/standalone/configuration

Next, edit the standalone.xml file using your preferred file editor and do the changes below: Replace this:

standalone.xml

<interface name="management">
    <inet-address value="${jboss.bind.address.management:127.0.0.1}"/>
</interface>
<interface name="public">
    <inet-address value="${jboss.bind.address:0.0.0.0}"/>
</interface>

With this:

standalone.xml

<interface name="management">
    <any-address/>
</interface>
<interface name="public">
    <any-address/>
</interface>

Make sure to save your changes and restart your Wildfly:

on terminal

/opt/wildfly-8.2.0.Final/bin/jboss-cli.sh --connect --command=:reload

Done.




回答3:


A better approach is edit JBOSS_HOME/standalone/configuration/standalone.xml editing the piece of code above and changing the address to 0.0.0.0.

<interfaces>
    <interface name="management">
        <inet-address value="${jboss.bind.address.management:127.0.0.1}"/>
    </interface>


来源:https://stackoverflow.com/questions/29150643/wildfly-remotely-access-administration-console-doesnt-work

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!