Welcome! Log In Create A New Profile

Advanced

Using nginx in front of tomcat

Posted by Belenor 
Using nginx in front of tomcat
October 16, 2012 05:16AM
Hello everyone,

I'd like to set up nginx as reverse proxy and software loadbalancer in front of several tomcat servers.
The applications running on the tomcats is written using the GRAILS framework and just doing well, while using Apache as frontendwebserver.

When I use nginx, there are always two JSESSION-ids added to the URL. They are equal, but the first one is url-encoded. Also I get the same sessionid a third time as a cookie.

Could anyone give me a hint where the error in my configuration could be?
My config is attached.

Have a nice day.
Belenor
Attachments:
open | download - nginxConfig.txt (4.3 KB)
Re: Using nginx in front of tomcat
October 17, 2012 07:07AM
Hi,

I found one error after all.

Changing the Line set $co "jsessionid=$1"; in mysite.conf to set $co "JSESSIONID=$1"; was obviously a good idea.

As long as cookies are accepted by the browser, the config is working. Turning off cookies in the browser results in doubled sessionids in the URL like described before.
Could anyone give me a hint?

Have a nice day
Belenor
Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 278
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready