Uploaded image for project: 'mod_cluster'
  1. mod_cluster
  2. MODCLUSTER-198

Can only rewrite from the root context in httpd if there is a root context deployed in JBoss

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Minor Minor
    • 1.0.8, 1.1.1.Final
    • 1.0.4.GA, 1.1.0.Final
    • None
    • None

      See: http://community.jboss.org/thread/159462

      ====
      I have a working mod_cluster 1.0.4 in front of EAP 5.1 (.com). I have been advised to use mod_rewrite and it works well. But i'm curious about the following scenario:

      mod_cluster set to expose ROOT. ROOT.war removed from JBoss. /sample deployed to jboss. mod_cluster INFO looks like:

      Node: [1],Name: redcloud:8009:jboss.web,Balancer: uat,Domain: ,Host: 192.168.235.128,Port: 8009,Type: ajp,Flushpackets: Off,Flushwait: 10000,Ping: 10000000,Smax: 1,Ttl: 60000000,Elected: 0,Read: 0,Transfered: 0,Connected: 0,Load: 88
      Vhost: [1:1:1], Alias: localhost
      Context: [1:1:1], Context: /sample, Status: ENABLED

      When i do:

      RewriteRule ^/sample/(.*)$ balancer://uat/sample/$1 [P,L]

      and ask for my.url/sample/ it works perfectly.

      If i do:

      RewriteRule ^/(.*)$ balancer://uat/sample/$1 [P,L]

      and go to my.url/ i get a 503 from apache and see

      [Wed Dec 01 07:37:20 2010] [debug] mod_proxy_cluster.c(962): get_balancer_by_node balancer NOT found
      [Wed Dec 01 07:37:20 2010] [debug] mod_proxy_cluster.c(962): get_balancer_by_node balancer NOT found
      [Wed Dec 01 07:37:20 2010] [debug] mod_proxy_cluster.c(1137): proxy: byrequests balancer FAILED
      [Wed Dec 01 07:37:20 2010] [error] proxy: CLUSTER: (balancer://uat). All workers are in error state

      in the apache logs.

      If i put ROOT.war back in, mod_cluster-manager INFO shows:

      Node: [1],Name: redcloud:8009:jboss.web,Balancer: uat,Domain: ,Host: 192.168.235.128,Port: 8009,Type: ajp,Flushpackets: Off,Flushwait: 10000,Ping: 10000000,Smax: 1,Ttl: 60000000,Elected: 0,Read: 0,Transfered: 0,Connected: 0,Load: 92
      Vhost: [1:1:1], Alias: localhost
      Context: [1:1:1], Context: /sample, Status: ENABLED
      Context: [1:1:2], Context: /, Status: ENABLED

      and my.url/ works (and serves the sameple app under root context).

      So, my question is has anyone seen this behavior with mod_cluster and mod_rewrite? I don't mind having a "dummy" app in to make ROOT visible but i don't necessarily want to have to.
      ====

              rhn-engineering-jclere Jean-Frederic Clere
              sjmenden_jira Samuel Mendenhall (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: