3 Replies Latest reply on Nov 6, 2015 7:06 AM by junaid arshad

    mod_cluster 1.3 with AS7; Cannot register node...

    junaid arshad Newbie

      Hello!

       

      I am trying to get mod_cluster1.3 work with AS7.1.1 final but for some reason the node does not register with the  mod_cluster manager. Is there anything I am missing? Any help will be much appreciated...

       

      The AS node gives the following error

       

      INFO  [org.jboss.modcluster.mcmp.impl.DefaultMCMPHandler] (ContainerBackgroundProcessor[StandardEngine[jboss.web]]) IO error sending command CONFIG to proxy

       

      However, the httpd access_log gives  "INFO / HTTP/1.1" 200 581  for this node and I get the following from error_log

       

      (111)Connection refused: AH00957: http: attempt to connect to 127.0.0.1:8080 (127.0.0.1) failed

      [proxy:error] [pid 1161:tid 140222859224832] AH00959: ap_proxy_connect_backend disabling worker for (127.0.0.1) for 60s

      [proxy:error] [pid 1162:tid 140222859224832] AH00940: http: disabled connection for (127.0.0.1)

      [proxy:error] [pid 1249:tid 140222859224832] AH00940: http: disabled connection for (127.0.0.1)

      [proxy:error] [pid 1163:tid 140222859224832] AH00940: http: disabled connection for (127.0.0.1)

      [proxy:error] [pid 1249:tid 140222859224832] AH00940: http: disabled connection for (127.0.0.1)

       

      I should also mention that I have a perfectly fine working node with Tomcat within this setup.

      I have also used the testhttpd.war tool provided with the jboss mod_cluster distro and it reports no errors.

       

      I use the minimal config for AS7 as advised in the doc (mod_cluster Documentation)

       

      My httpd.conf is as under:

       

      <IfModule manager_module>

        #change port value according to your preferences

        Listen *:6666

        ManagerBalancerName mycluster

        <VirtualHost *:6666>

              <Location />

                  #change according to the network, multiple Require entries are allowed

              Require ip 192.168.

              </Location>

              KeepAliveTimeout 300

              MaxKeepAliveRequests 0

              ServerAdvertise on http://192.168.152.132:6666

              AdvertiseFrequency 5

              AdvertiseGroup 224.0.1.106:23364

              EnableMCPMReceive

              AllowDisplay On

              <Location /mod_cluster_manager>

              SetHandler mod_cluster-manager

              Order deny,allow

              Allow from all

              </Location>

        </VirtualHost>

      </IfModule>

        • 1. Re: mod_cluster 1.3 with AS7; Cannot register node...
          Michal Karm Babacek Apprentice

          The error is that you bind AS to localhost. Do not do that, preferably ever with any mod_cluster setup.

          Furthermore, you forbade your 127.0.* worker from connecting to your balacner with this directive: Require ip 192.168.

           

          Steps:

          • start both balancer and workers on non-localhost ip addresses, e.g. 192.something
          • make sure bidirectional communication is possible, i.e. that balancer can contact worker nodes on the host:port they report and that workers can contact your balancer on its MCPM enabled VirtualHost

           

          Please, let me know it it helped.

          Cheers

          -K-

          • 2. Re: mod_cluster 1.3 with AS7; Cannot register node...
            junaid arshad Newbie

            Hi Michal,

             

            Thank you for your quick reply...

             

            I am relatively inexperienced with AS so could you please elaborate a bit more on 

             

            "The error is that you bind AS to localhost. Do not do that, preferably ever with any mod_cluster setup". and how can I bind it to the real ip of the node...

             

            the bidirectional communication is verified and as the tomcat node does connect with the balancer, I am inclined to believe that there is an issue with my AS configuration...

             

            Thanks!

             

            junaid

            • 3. Re: mod_cluster 1.3 with AS7; Cannot register node...
              junaid arshad Newbie

              UPDATE:

               

              I have changed the config in AS7 for the address binding. Please see below for two snips from my AS7 config

               

              <subsystem xmlns="urn:jboss:domain:modcluster:1.0">

                          <mod-cluster-config advertise-socket="modcluster" proxy-list="192.168.152.132:6666">

                              <dynamic-load-provider>

              and binding:

              </interface>

                      <interface name="public">

                          <any-address/>

                      </interface>

               

              Now, although I do NOT get the errors like

              (111)Connection refused: AH00957: http: attempt to connect to 127.0.0.1:8080 (127.0.0.1) failed

               

              But I still get the following on AS node

              INFO  [org.jboss.modcluster.mcmp.impl.DefaultMCMPHandler] (ContainerBackgroundProcessor[StandardEngine[jboss.web]]) IO error sending command CONFIG to proxy c152-132.localcloud/192.168.152.132:6666: java.net.SocketTimeoutException: Read timed out

               

              and

              192.168.153.180 - - [06/Nov/2015:11:58:43 +0100] "CONFIG / HTTP/1.1" 200 -

              192.168.153.180 - - [06/Nov/2015:11:57:03 +0100] "INFO / HTTP/1.1" 200 587

              on the balancer node.


              Its a bit strange that I can now see the AS node 192.168.153.180 in my mod_cluster manager GUI  outside Virtual Hosts but it says 'node undefined' for it and errors are still there....



              192.168.153.180 - -

              and 192.168.152.132 is the balancer node

               

              I stumbled across this post  mod_cluster manager does not discover JBoss nodes which reports a similar error but has not been addressed...