Hello. I found the solution - problem was in stickysession=jsessionid|JSESSIONID. When I switch value to stickysession=JSESSIONID|jsessionid the session affinity is OK. Jarda ______________________________________________________________ > Od: "Jaroslav Fikker" <fikker@xxxxxxxx> > Komu: <users@xxxxxxxxxxxxxxxx>, <users@xxxxxxxxxxxxxxxx> > Datum: 27.09.2012 09:26 > Předmět: Re: Apache httpd + Tomcat - session affinity > >Hello Igor. > >Thank you very much for your tip. Unfortunately the behavior is the same with ProxyPassReverse statement. Do you have another recommendation? > >Jarda > >______________________________________________________________ >> Od: "Igor Cicimov" <icicimov@xxxxxxxxx> >> Komu: <users@xxxxxxxxxxxxxxxx> >> Datum: 24.09.2012 11:45 >> Předmět: Re: Apache httpd + Tomcat - session affinity >> >>Missing ProxyPassReverse statement? >> >>Igor Cicimov >>Sent from my Android tablet >>On Sep 21, 2012 3:30 PM, "Jaroslav Fikker" <fikker@xxxxxxxx> wrote: >> >>> Hello everybody, >>> >>> I encountered problem with session affinity in combination Apache httpd >>> 2.2.21 and Tomcat 7.0.23.0. I have next directives in httpd.conf file: >>> >>> <Proxy balancer://PRED_CL01> >>> BalancerMember ajp://smtt01:8023 route=PRED_TT01 >>> BalancerMember ajp://smtt02:8023 route=PRED_TT02 >>> </Proxy> >>> >>> ProxyPass /pred/ balancer://PRED_CL01/pred/ lbmethod=bytraffic >>> maxattempts=1 stickysession=jsessionid|JSESSIONID nofailover=off >>> >>> And next directives in Tomcat server.xml file: >>> >>> <Engine name="PRED" defaultHost="localhost" jvmRoute="PRED_TT01"> >>> … >>> <Connector allowTrace="false" >>> backlog="16" >>> connectionTimeout="30000" >>> enableLookups="false" >>> keepAliveTimeout="30000" >>> maxPostSize="10485760" >>> maxSavePostSize="4096" >>> maxThreads="64" >>> port="8023" >>> protocol="AJP/1.3" >>> proxyName="testportal " >>> proxyPort="443" >>> redirectPort="443" >>> tcpNoDelay="true" >>> tomcatAuthentication="false" >>> URIEncoding="UTF-8" >>> useIPVHosts="false"> >>> </Connector> >>> >>> A also configured this LogFormat for Apache httpd: >>> LogFormat "%t %a %u %{jsessionid}C %{Set-Cookie}o >>> %{BALANCER_SESSION_STICKY}e %{BALANCER_SESSION_ROUTE}e >>> %{BALANCER_WORKER_ROUTE}e %{BALANCER_ROUTE_CHANGED}e %s %Tsec %r %Bbytes" >>> access >>> >>> I can see in Apache httpd log file for example these rows: >>> >>> [21/Sep/2012:15:02:04 +0200] 10.217.116.41 - >>> AA716816AFEAF58F93B552B3503B9D14.PRED_TT02 >>> JSESSIONID=7381C948FE38E0912A10B8FE8A3DF5EE.PRED_TT01; Path=/pred/; Secure; >>> HttpOnly - - PRED_TT01 1 200 4sec GET /pred/ HTTP/1.1 13081bytes >>> [21/Sep/2012:15:02:08 +0200] 10.217.116.41 - >>> 7381C948FE38E0912A10B8FE8A3DF5EE.PRED_TT01 - - - PRED_TT02 1 200 0sec GET >>> /pred/styles/application.css HTTP/1.1 7574bytes >>> >>> From these you can see that variables BALANCER_SESSION_STICKY and >>> BALANCER_SESSION_ROUTE are empty. Result is that user requests migrate >>> between two Tomcat servers (PRED_TT01 and PRED_TT02). >>> >>> Do you have anyone any idea where could be the cause of problem? Thank you >>> very much in advance. >>> >>> Jarda F. >>> >>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx >>> For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx >>> >>> >> > >--------------------------------------------------------------------- >To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx >For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx > > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx