1 Reply Latest reply on May 14, 2012 3:37 PM by fjuma

    JBoss 7 AS and standalone.xml on EC2 on-demand instances

    ghep

      Hi all,

      I'm testing my Web App on Ubuntu ec2 instance with JBoss 7.1.1. Application Server but I have one problem.


      When I start instance after some hours of stop, I need to modify the standalone.xml configuration of jboss with new EC2 instance IP.


      My question is how to modify this standalone.xml tag with hostname of my ec2 instance :


      <interfaces>

      <interface name="management">

      <inet-address value="127.0.0.1"/>

      </interface>

      <interface name="public">

      <inet-address value="127.0.0.1"/>

      </interface>

      </interfaces>


      from ubuntu shell when i write hostname the result is like: ip-10.4.5.5 (that is my ec2 instance private ip and his hostname).

       

      I would like change the 127.0.0.1 in the standalone.xml with hostname command line ... but i don't know how to do it.


      I need to find a solution that is automatic to plan the autoscaling function.


      Thanks for your help.

        • 1. Re: JBoss 7 AS and standalone.xml on EC2 on-demand instances
          fjuma

          One solution might be to listen on all IPs and interfaces, i.e., either replace 127.0.0.1 with 0.0.0.0 or start the server using -b and -bmanagement (./standalone.sh -b 0.0.0.0 -bmanagement 0.0.0.0).

           

          Alternatively, another solution might be to start the server with -b `hostname` -bmanagement `hostname`.