Hi KK,
I checked the ports. They are open. I also tried the sequence you mentioned
below. It did not make any difference.
But the good news is that I kept trying things and found that when I comment
the sticky session setting for CoWTraining, the error disappears!
I do not understand exactly what is happening here but it really is confusing.
I do want the sticky session feature. Is there a workaround for this?
This is what I tried:
---------------------------------------------------------------------------
<Location /CoWTraining>
ProxyPass balancer://cluster-
CoWTraining/CoWTraining
#stickysession=JSESSIONID nofailover=On
ProxyPassReverse balancer://cluster-CoWTraining/CoWTraining
</Location>
---------------------------------------------------------------------------
Thanks,
Pradeep
________________________________________
From: KK CHN [mailto:[email protected]]
Sent: Wednesday, July 22, 2009 3:37 PM
To: Pradeep Phalgunan Kalliat
Subject: Re: [us...@httpd] proxy : AJP Errors
Try Reordering the setup also
<Location /CoW>
ProxyPass balancer://cluster-CoW/CoW
stickysession=JSESSIONID nofailover=On
ProxyPassReverse balancer://cluster-CoW/CoW
</Location>
<Proxy balancer://cluster-CoW>
BalancerMember ajp://localhost:9209 route=tomcat70 retry=60 loadfactor=50
BalancerMember ajp://localhost:9309 route=tomcat71 retry=60 loadfactor=50
ProxySet lbmethod=bytraffic
</Proxy>
<Location /CoWTraining>
ProxyPass balancer://cluster-
CoWTraining/CoWTraining stickysession=JSESSIONID nofailover=On
ProxyPassReverse balancer://cluster-CoWTraining/CoWTraining
</Location>
<Proxy balancer://cluster-CoWTraining>
BalancerMember ajp://localhost:9409 route=tomcat72 retry=60 loadfactor=50
BalancerMember ajp://localhost:9509 route=tomcat73 retry=60 loadfactor=50
ProxySet lbmethod=bytraffic
</Proxy>
RewriteEngine on
RewriteRule ^/CoW$ /CoW/ [R]
RewriteRule ^/CoWTraining$ /CoWTraining/ [R]
On Wed, Jul 22, 2009 at 3:13 PM, KK CHN <[email protected]> wrote:
are you sure the 9509 & 9409 ports are open in your server box ?
On Tue, Jul 21, 2009 at 8:01 PM, Pradeep Phalgunan Kalliat
<[email protected]> wrote:
Hi Andre,
Thanks for the response.
Here are the details you wanted.
As I mentioned before there are two tomcat nodes serving this app.
Details for Tomcat Node 72:
--------------------------------------------------------------------------
<Connector port="9480" maxHttpHeaderSize="8192" maxThreads="150"
minSpareThreads="25" maxSpareThreads="75" enableLookups="false"
redirectPort="8443" acceptCount="100" connectionTimeout="20000"
disableUploadTimeout="true" />
<Connector port="9409" enableLookups="false" redirectPort="8443"
protocol="AJP/1.3" />
<Engine name="Catalina" defaultHost="localhost" debug="0" jvmRoute="tomcat72">
---------------------------------------------------------------------------
Details for Tomcat Node 73:
---------------------------------------------------------------------------
<Connector port="9580" maxHttpHeaderSize="8192" maxThreads="150"
minSpareThreads="25" maxSpareThreads="75" enableLookups="false"
redirectPort="8443" acceptCount="100" connectionTimeout="20000"
disableUploadTimeout="true" />
<Connector port="9509" enableLookups="false" redirectPort="8443"
protocol="AJP/1.3" />
<Engine name="Catalina" defaultHost="localhost" debug="0" jvmRoute="tomcat73">
---------------------------------------------------------------------------
I really appreciate the help.
Thanks,
Pradeep
-----Original Message-----
From: André Warnier [mailto:[email protected]]
Sent: Tuesday, July 21, 2009 5:17 PM
To: [email protected]
Subject: Re: [us...@httpd] proxy : AJP Errors
Pradeep Phalgunan Kalliat wrote:
> Hi All,
>
> I've two webapps CoW and CoWTraining, each of which are load balanced by
> Apache 2.2.4 over two tomcat nodes running as services. i.e. two nodes for
> CoW and two for the other. This is set up in one server machine. Both the
> webapps are identical in functionality and operation but just that they are
> served by different hosts.
>
> The problem is that when I try to access CoWTraining in the same window after
> I access CoW, the server throws a 'Service Temporarily Unavailable' message.
> However, if I access CoWTraining first and then CoW, there are no problems.
> Also in this case, if I go further and access CoWTraining again there are
> still no problems. The error occurs only if I try to access CoWTraining in a
> window in which I've accessed CoW. There are no problems trying to access
> other applications in the same window.
>
> The reason I think this is related to apache is because I had both these
> webapps installed on one tomcat node and tested without the load balancing.
>
> My httpd.conf file has the following references to these applications in the
> same sequence.
>
> --------------------------------------------------------------------------
> <Location /CoW>
> ProxyPass balancer://cluster-CoW/CoW
> stickysession=JSESSIONID nofailover=On
> ProxyPassReverse balancer://cluster-CoW/CoW
> </Location>
>
> <Location /CoWTraining>
> ProxyPass balancer://cluster-CoWTraining/CoWTraining
> stickysession=JSESSIONID nofailover=On
> ProxyPassReverse balancer://cluster-CoWTraining/CoWTraining
> </Location>
>
>
> <Proxy balancer://cluster-CoW>
> BalancerMember ajp://localhost:9209 route=tomcat70 retry=60
> loadfactor=50
> BalancerMember ajp://localhost:9309 route=tomcat71 retry=60
> loadfactor=50
> ProxySet lbmethod=bytraffic
> </Proxy>
>
> <Proxy balancer://cluster-CoWTraining>
> BalancerMember ajp://localhost:9409 route=tomcat72 retry=60
> loadfactor=50
> BalancerMember ajp://localhost:9509 route=tomcat73 retry=60
> loadfactor=50
> ProxySet lbmethod=bytraffic
> </Proxy>
>
> RewriteEngine on
> RewriteRule ^/CoW$ /CoW/ [R]
> RewriteRule ^/CoWTraining$ /CoWTraining/ [R]
>
> --------------------------------------------------------------------------
>
> There are no errors in the tomcat logs. The apache logs have a lot of these
> kind of errors
>
> --------------------------------------------------------------------------
> [error] (OS 10061)No connection could be made because the target machine
> actively refused it. : proxy: AJP: attempt to connect to 127.0.0.1:9509
> (localhost) failed
> [error] (OS 10061)No connection could be made because the target machine
> actively refused it. : proxy: AJP: attempt to connect to 127.0.0.1:9409
> (localhost) failed
> [error] ap_proxy_connect_backend disabling worker for (localhost)
> [error] proxy: AJP: failed to make connection to backend: localhost
> [error] proxy: BALANCER: (balancer://cluster-cowtraining). All workers are in
> error state for route (tomcat73)
> --------------------------------------------------------------------------
>
> Any help would be greatly appreciated. I've already done a lot of googling
> with not much results.
>
Hi.
That is a very good problem description.
Just to be complete, could you post also the content of the active
corresponding <Connector> tags of your Tomcat servers ?
(since they are apparently the side that refuses the connection).
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: [email protected]
" from the digest: [email protected]
For additional commands, e-mail: [email protected]
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: [email protected]
" from the digest: [email protected]
For additional commands, e-mail: [email protected]
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: [email protected]
" from the digest: [email protected]
For additional commands, e-mail: [email protected]