2 Replies Latest reply on Oct 19, 2010 11:03 AM by asimoes

    Apache loadbalancer and XmlRpc Server

    asimoes

      Hi there.

       

      I have a JBOSS 5.10 running in cluster.

      Two instances on the same physical machine.

       

      I also have a xmlrpc server running on port 8081 of each cluster node.
      The server is working fine.


      But, when i try to access them from the apache ip, the load balancer sends data to the cluster but it return a bad answer

       

      I'm reading the apache log and from the log i can have sure that data is arriving on the cluster ip and port

       

      Does the Xml Rpc Server or the load balancer need some extra options to work in cluster?

        • 1. Re: Apache loadbalancer and XmlRpc Server
          asimoes

          One more thing.

          If I try a wget from another machine, the answer is:

           

           

          For Apache Ip and port that forwards for xmlrpcserver:

           

          wget -S 10.1.4.200:8082
          --2010-10-13 09:58:35--  http://10.1.4.200:8082/
          Connecting to 10.1.4.200:8082... connected.
          HTTP request sent, awaiting response...
            HTTP/1.1 200 OK
            Date: Wed, 13 Oct 2010 08:58:42 GMT
            Server: Apache/2.2.14 (Ubuntu)
            X-Powered-By: Servlet 2.5; JBoss-5.0/JBossWeb-2.1
            Accept-Ranges: bytes
            ETag: W/"1748-1285076814000"
            Last-Modified: Tue, 21 Sep 2010 13:46:54 GMT
            Content-Length: 1748
            Vary: Accept-Encoding
            Keep-Alive: timeout=15, max=100
            Connection: Keep-Alive
            Content-Type: text/html
          Length: 1748 (1,7K) [text/html]

           

           

          For a specific node Ip:

           

          wget -S 192.168.0.21:8081
          --2010-10-13 09:46:58--  http://192.168.0.21:8081/
          Connecting to 192.168.0.21:8081... connected.
          HTTP request sent, awaiting response... No data received.
          Retrying.

           

          The second example produces a message on jboss node. That message is the expected one.

           

           

          I think my problem is what to put on VirtualHost of apache.

          In JkMount i have:

          For general purpose:

          <VirtualHost *:80>
              ServerName 10.1.4.200
          #    LogLevel warn
              JkLogLevel debug
              CustomLog logs/vtHt80.log combined
              ErrorLog logs/vtHt80Error.log
          #    ServerSignature Off
              ServerSignature On
             
          #    JkAutoAlias /
              JkMountFile conf/uriworkermap.properties
          </VirtualHost>

           

          For XmlRpcServer

          <VirtualHost *:8082>
              ServerName 10.1.4.200
              ServerSignature Off
          #    LogLevel warn
              JkLogLevel debug
              CustomLog logs/vtHt8081.log combined
              ErrorLog logs/vtHt8081Error.log
              ServerSignature Off
             
          #    JkAutoAlias /
              JkMount /* workerXmlRpc
          </VirtualHost>

           

          The big question is:

          Does the VirtualHost 8082 have a correct JkMount?

           

          I think that the problem is there, but i can't fix it

          • 2. Re: Apache loadbalancer and XmlRpc Server
            asimoes

            I found the solution.

            Use mod_proxy for redirect traffic to clusters.

            AJP connector won't work