2 Replies Latest reply on Nov 18, 2014 1:40 AM by Scott Bass

    Problems configuring domain on JBoss AS 7.1.1

    Scott Bass Newbie

      We're migrating from JBoss 4.2.3 to JBoss 7.1.1.  We need to have three JBoss servers running on one machine, using different ports.  These JBoss servers also need to run as a service.  The servers are just dev/test/prod of the same web application.

       

      I'm unsure whether three standalone servers vs. a managed domain is the way to go in AS 7.1, but I'm currently trying to configure this as a domain.  I like the centralized management model of a domain, esp. since the three servers are just running different versions of the same application.  I'm assuming domain.bat can be installed as a service.

       

      So, in summary, I need a single host controller, also acting as the master domain controller, starting three JBoss instances, all on the same machine.

       

      I've unzipped jboss-as-7.1.1.Final, unzipped jboss-native-2.0.10-windows-x64-ssl (to install as a service), and installed Java JDK jdk1.7.0_72.  Standalone.bat starts fine.

       

      However, domain.bat is giving me this error in the console window:

       

      D:\Program Files\jboss-as-7.1.1.Final\bin>domain
      Calling "D:\Program Files\jboss-as-7.1.1.Final\bin\domain.conf.bat"
      ===============================================================================
      
      
        JBoss Bootstrap Environment
      
      
        JBOSS_HOME: D:\Program Files\jboss-as-7.1.1.Final
      
      
        JAVA: D:\Program Files\Java\jdk1.7.0_72\bin\java
      
      
        JAVA_OPTS: -Dprogram.name=domain.bat -Xms64M -Xmx512M -XX:MaxPermSize=256M -Dsun.rmi.dgc.client.gcInterval=3600000 -Dsun.rmi.dgc.server.gcInterval=3600000 -Djava.net.preferIPv4Stack=true -Dorg.jboss
      .resolver.warning=true -Djboss.modules.system.pkgs=org.jboss.byteman -Djboss.domain.default.config=domain.xml -Djboss.host.default.config=host.xml
      
      
      ===============================================================================
      
      
      14:23:53,331 INFO  [org.jboss.modules] (main) JBoss Modules version 1.1.1.GA
      14:23:53,675 INFO  [org.jboss.as.process.Host Controller.status] (main) JBAS012017: Starting process 'Host Controller'
      [Host Controller] 14:23:54,831 INFO  [org.jboss.modules] (main) JBoss Modules version 1.1.1.GA
      [Host Controller] 14:23:54,972 INFO  [org.jboss.msc] (main) JBoss MSC version 1.0.2.GA
      [Host Controller] 14:23:55,035 INFO  [org.jboss.as] (MSC service thread 1-3) JBAS015899: JBoss AS 7.1.1.Final "Brontes" starting
      [Host Controller] 14:23:55,191 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-2) MSC00001: Failed to start service jboss.host.controller.process-controller-connection: org.jboss.msc.service.
      StartException in service jboss.host.controller.process-controller-connection: java.net.SocketException: Network is unreachable: connect
      [Host Controller]       at org.jboss.as.host.controller.ProcessControllerConnectionService.start(ProcessControllerConnectionService.java:174) [jboss-as-host-controller-7.1.1.Final.jar:7.1.1.Final]
      [Host Controller]       at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
      [Host Controller]       at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
      [Host Controller]       at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_72]
      [Host Controller]       at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_72]
      [Host Controller]       at java.lang.Thread.run(Thread.java:745) [rt.jar:1.7.0_72]
      [Host Controller] Caused by: java.net.SocketException: Network is unreachable: connect
      [Host Controller]       at java.net.TwoStacksPlainSocketImpl.socketConnect(Native Method) [rt.jar:1.7.0_72]
      [Host Controller]       at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339) [rt.jar:1.7.0_72]
      [Host Controller]       at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200) [rt.jar:1.7.0_72]
      [Host Controller]       at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182) [rt.jar:1.7.0_72]
      [Host Controller]       at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172) [rt.jar:1.7.0_72]
      [Host Controller]       at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) [rt.jar:1.7.0_72]
      [Host Controller]       at java.net.Socket.connect(Socket.java:579) [rt.jar:1.7.0_72]
      [Host Controller]       at org.jboss.as.process.protocol.ProtocolClient.connect(ProtocolClient.java:92) [jboss-as-process-controller-7.1.1.Final.jar:7.1.1.Final]
      [Host Controller]       at org.jboss.as.process.ProcessControllerClient.connect(ProcessControllerClient.java:153) [jboss-as-process-controller-7.1.1.Final.jar:7.1.1.Final]
      [Host Controller]       at org.jboss.as.host.controller.ProcessControllerConnectionService.start(ProcessControllerConnectionService.java:90) [jboss-as-host-controller-7.1.1.Final.jar:7.1.1.Final]
      [Host Controller]       ... 5 more
      [Host Controller]
      

       

      Any pointers on how to diagnose and fix this issue?

       

      I've also attached my domain.xml and hosts.xml files in case that helps.  Other than setting JAVA_HOME, domain.bat and domain.conf.bat are unchanged from the default files.

       

      Thanks...

        • 1. Re: Problems configuring domain on JBoss AS 7.1.1
          Scott Bass Newbie

          Hi All,

           

          Further information:  this migration from JBoss 4.2.3 to JBoss 7.1.1 also involves a migration to a new server, from Windows Server 2008 R2 Enterprise to Windows Server 2012 Standard.  I believe my IT department has hardened the new server in a way that's different from the old server.

           

          As a test/debugging step, I installed JBoss 7.1.1 on the old server.  Standalone.bat and domain.bat started fine on that server with minimal configuration (just set JAVA_HOME).  I was then able to configure domain.xml and host.xml to suit my target environment.

           

          I then copied the jboss-as-7.1.1.Final directory from the old to new machine.  Standalone.bat runs fine, but domain.bat has the above error.  So, I have to conclude that there is some system setting on the new machine that is causing domain.bat to fail.

           

          As a last debugging step, I added the NTFS permission "Everyone" with Full Access to jboss-as-7.1.1.Final and downstream files, added a catch all inbound and outbound firewall rule to allow all connections on all ports (to be removed later!), and started the command console with "Run as administrator".  None of these steps fixed the above error.

           

          If you have any ideas of system hardening steps that would cause the java.net.SocketException: Network is unreachable: connect error, please let me know.

           

          Thanks...

          • 2. Re: Problems configuring domain on JBoss AS 7.1.1
            Scott Bass Newbie

            In case anyone finds this thread in the future...

             

            The issue was caused by an incorrect local hosts file.  Once the hosts file was corrected (or renamed), JBoss worked as expected.