[mod_cluster-issues] [JBoss JIRA] Commented: (MODCLUSTER-146) Quotes in jsessionId causing sticky sessions to fail
Wim Vandenhaute (JIRA)
jira-events at lists.jboss.org
Fri Apr 30 04:30:05 EDT 2010
[ https://jira.jboss.org/jira/browse/MODCLUSTER-146?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12528186#action_12528186 ]
Wim Vandenhaute commented on MODCLUSTER-146:
--------------------------------------------
The workaround for this issue btw is not leaving the jvmRoute default in jbossweb.sar/server.xml but setting it to something like node01.
Its the ':' in t he jvmRoute that triggers the quotes around the jsessionid ( e.g. node01:foo )
> Quotes in jsessionId causing sticky sessions to fail
> ----------------------------------------------------
>
> Key: MODCLUSTER-146
> URL: https://jira.jboss.org/jira/browse/MODCLUSTER-146
> Project: mod_cluster
> Issue Type: Bug
> Environment: JBoss 6 M2, mod_cluster's httpd
> Reporter: Wim Vandenhaute
> Assignee: Jean-Frederic Clere
>
> I am having an issue trying to setup sticky sessions for following configuration:
> 1 httpd front end
> 2 backend jboss instances
> What I am noticing is when running in a cluster, the JSESSIONID contains quotes like:
> Set-Cookie: JSESSIONID="DE0F7EEA2A5E90497D729DB27DDB4B25.192.168.7.11:8009:jboss.web"; Version=1; Path=/f00
> Whilst not in a cluster:
> Set-Cookie: JSESSIONID=355F9E370912DC10187A15E8B02260CD; Path=/foo
> Now when I am looking in the httpd logging I see:
> mod_proxy_cluster.c(1681): cluster: Found value "54F0CFC4961C9ED14A64335B40645392.192.168.7.11:8009:jboss.web" for stickysession JSESSIONID
> In my opinion the quotes around the jsessionid is causing mod_proxy_cluster to fail in finding the jboss node to which to "stick" to.
> I recompiled mod_proxy_cluster with "HAVE_CLUSTER_EX_DEBUG" set for more debugging info and this confirmed my suspicion:
> mod_proxy_cluster.c(1739): find_nodedomain: finding node for 192.168.7.11:8009:jboss.web": mycluster
> mod_proxy_cluster.c(1752): find_nodedomain: finding domain for 192.168.7.11:8009:jboss.web": mycluster
> Looking in the code this shows that it was unable to find the node, due to the ending quote in the route.
> As for my JBoss Setup:
> * Uncommented ModClusterListener in jbossweb.sar/META-INF/jboss-beans.xml
> * mod_cluster.sar/META-INF/mod_cluster-jboss-beans.xml
> - changed ModClusterService to HAModClusterService
> - changed ${jboss.mod_cluster.advertise.enabled:false} to true
> As for my httpd setup:
> LoadModule proxy_module /opt/jboss/httpd/lib/httpd/modules/mod_proxy.so
> LoadModule proxy_ajp_module /opt/jboss/httpd/lib/httpd/modules/mod_proxy_ajp.so
> LoadModule slotmem_module /opt/jboss/httpd/lib/httpd/modules/mod_slotmem.so
> LoadModule manager_module /opt/jboss/httpd/lib/httpd/modules/mod_manager.so
> LoadModule proxy_cluster_module /opt/jboss/httpd/lib/httpd/modules/mod_proxy_cluster.so
> LoadModule advertise_module /opt/jboss/httpd/lib/httpd/modules/mod_advertise.so
> LogLevel debug
> CreateBalancers 0
> <VirtualHost *:80>
> <Location /mod_cluster-manager>
> SetHandler mod_cluster-manager
> Order deny,allow
> Deny from all
> Allow from all
> # Allow from 192.168.7.
> </Location>
> <Directory />
> Order deny,allow
> Deny from all
> Allow from all
> </Directory>
> ProxyPass /foo balancer://mycluster/foo stickysession=JSESSIONID scolonpathdelim=On nofailover=On
> KeepAliveTimeout 60
> MaxKeepAliveRequests 0
> ManagerBalancerName mycluster
> AdvertiseFrequency 5
>
> </VirtualHost>
> Listen sebeco-dev-11:443
> <VirtualHost *:443>
> ServerName sebeco-dev-11:443
> SSLEngine on
> SSLProxyEngine on
> SSLCipherSuite ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL
> SSLCertificateFile "/opt/jboss/httpd/httpd/server.crt"
> SSLCertificateKeyFile "/opt/jboss/httpd/httpd/server.key"
> SSLCertificateChainFile "/opt/jboss/httpd/httpd/server-ca.crt"
> <FilesMatch "\.(cgi|shtml|phtml|php)$">
> SSLOptions +StdEnvVars
> </FilesMatch>
> <Location />
> Order allow,deny
> Allow from all
> </Location>
> ProxyPass /foo balancer://mycluster/foo stickysession=JSESSIONID scolonpathdelim=On nofailover=On
> </VirtualHost>
> As my setup is not really complex at this point my gut says I am doing something wrong in the setup, but digging in the code shows the opposite.
> Any thougts?
> Best regards,
> Wim.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the mod_cluster-issues
mailing list