Which Do I SSL - httpd or Tomcat?
Hello All I have a clustered/load-balanced Apache httpd and Tomcat setup. I have one httpd front end that load balances for two Tomcat back ends. I now want to add SSL to the mix but I am confused. Do I add the SSL to the httpd server, to the two Tomcat servers, or to all of them? Thank you for reading. Have a good day - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Which Do I SSL - httpd or Tomcat?
Hi, Thank you for reading and replying. Can I assume from your reply that if I am not on a secure LAN that I should SSL httpd and both Tomcat servers? Thank You From: Zeeshan Ahmad [zah...@i2cinc.com] Sent: Tuesday, June 02, 2009 9:15 AM To: 'Tomcat Users List' Subject: RE: Which Do I SSL - httpd or Tomcat? Hello, If your web and application servers are on a secure LAN then this would be better technique if you will add SSL on httpd rather then on all of them, your communication will be over ssl from the client to web server and vice versa. Best Regards, Zeeshan Ahmad. P Save a tree...pls don't print this e-mail unless necessary -Original Message- From: Alston, Brian (US SSA) [mailto:brian.als...@baesystems.com] Sent: Tuesday, June 02, 2009 7:03 PM To: users@tomcat.apache.org Subject: Which Do I SSL - httpd or Tomcat? Hello All I have a clustered/load-balanced Apache httpd and Tomcat setup. I have one httpd front end that load balances for two Tomcat back ends. I now want to add SSL to the mix but I am confused. Do I add the SSL to the httpd server, to the two Tomcat servers, or to all of them? Thank you for reading. Have a good day - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Which Do I SSL - httpd or Tomcat?
All Well ... I believe I have my answer. Thank you all very much for reading and replying. Have a good day From: Zeeshan Ahmad [zah...@i2cinc.com] Sent: Tuesday, June 02, 2009 10:05 AM To: 'Tomcat Users List' Subject: RE: Which Do I SSL - httpd or Tomcat? if your tomcats are accessible from out side world then, you have to add ssl on Tomcats as well otherwise its ok and there should be some security (e.g Firewall) on the network level, thanks. Best Regards, Zeeshan Ahmad. Associate Manager SCM. P Save a tree...pls don't print this e-mail unless necessary -Original Message- From: Alston, Brian (US SSA) [mailto:brian.als...@baesystems.com] Sent: Tuesday, June 02, 2009 7:25 PM To: Tomcat Users List Subject: RE: Which Do I SSL - httpd or Tomcat? Hi, Thank you for reading and replying. Can I assume from your reply that if I am not on a secure LAN that I should SSL httpd and both Tomcat servers? Thank You From: Zeeshan Ahmad [zah...@i2cinc.com] Sent: Tuesday, June 02, 2009 9:15 AM To: 'Tomcat Users List' Subject: RE: Which Do I SSL - httpd or Tomcat? Hello, If your web and application servers are on a secure LAN then this would be better technique if you will add SSL on httpd rather then on all of them, your communication will be over ssl from the client to web server and vice versa. Best Regards, Zeeshan Ahmad. P Save a tree...pls don't print this e-mail unless necessary -Original Message- From: Alston, Brian (US SSA) [mailto:brian.als...@baesystems.com] Sent: Tuesday, June 02, 2009 7:03 PM To: users@tomcat.apache.org Subject: Which Do I SSL - httpd or Tomcat? Hello All I have a clustered/load-balanced Apache httpd and Tomcat setup. I have one httpd front end that load balances for two Tomcat back ends. I now want to add SSL to the mix but I am confused. Do I add the SSL to the httpd server, to the two Tomcat servers, or to all of them? Thank you for reading. Have a good day - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Which Do I SSL - httpd or Tomcat?
What I have is 3 virtual servers (VMWare - Windows Server 2003). One server has Apache httpd v2.2.11 and two other servers running Apache Tomcat v6.0.18. The Tomcat servers are independently accessible from outside of the httpd server; so, I assume that I will need to place SSL on all three servers. From: Martin Gainty [mgai...@hotmail.com] Sent: Tuesday, June 02, 2009 10:27 AM To: Tomcat Users List Subject: RE: Which Do I SSL - httpd or Tomcat? Brian if you're running TC standalone (without Apache or any other webserver FE) an excellent tutorial on implementing SSL in TC available to read at http://tomcat.apache.org/tomcat-6.0-doc/ssl-howto.html Q:does outside world assume outside the uk? Martin Gainty __ Verzicht und Vertraulichkeitanmerkung/Note de déni et de confidentialité Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene Empfaenger sein, so bitten wir hoeflich um eine Mitteilung. Jede unbefugte Weiterleitung oder Fertigung einer Kopie ist unzulaessig. Diese Nachricht dient lediglich dem Austausch von Informationen und entfaltet keine rechtliche Bindungswirkung. Aufgrund der leichten Manipulierbarkeit von E-Mails koennen wir keine Haftung fuer den Inhalt uebernehmen. Ce message est confidentiel et peut être privilégié. Si vous n'êtes pas le destinataire prévu, nous te demandons avec bonté que pour satisfaire informez l'expéditeur. N'importe quelle diffusion non autorisée ou la copie de ceci est interdite. Ce message sert à l'information seulement et n'aura pas n'importe quel effet légalement obligatoire. Étant donné que les email peuvent facilement être sujets à la manipulation, nous ne pouvons accepter aucune responsabilité pour le contenu fourni. From: brian.als...@baesystems.com To: users@tomcat.apache.org Date: Tue, 2 Jun 2009 10:15:47 -0400 Subject: RE: Which Do I SSL - httpd or Tomcat? All Well ... I believe I have my answer. Thank you all very much for reading and replying. Have a good day From: Zeeshan Ahmad [zah...@i2cinc.com] Sent: Tuesday, June 02, 2009 10:05 AM To: 'Tomcat Users List' Subject: RE: Which Do I SSL - httpd or Tomcat? if your tomcats are accessible from out side world then, you have to add ssl on Tomcats as well otherwise its ok and there should be some security (e.g Firewall) on the network level, thanks. Best Regards, Zeeshan Ahmad. Associate Manager SCM. P Save a tree...pls don't print this e-mail unless necessary -Original Message- From: Alston, Brian (US SSA) [mailto:brian.als...@baesystems.com] Sent: Tuesday, June 02, 2009 7:25 PM To: Tomcat Users List Subject: RE: Which Do I SSL - httpd or Tomcat? Hi, Thank you for reading and replying. Can I assume from your reply that if I am not on a secure LAN that I should SSL httpd and both Tomcat servers? Thank You From: Zeeshan Ahmad [zah...@i2cinc.com] Sent: Tuesday, June 02, 2009 9:15 AM To: 'Tomcat Users List' Subject: RE: Which Do I SSL - httpd or Tomcat? Hello, If your web and application servers are on a secure LAN then this would be better technique if you will add SSL on httpd rather then on all of them, your communication will be over ssl from the client to web server and vice versa. Best Regards, Zeeshan Ahmad. P Save a tree...pls don't print this e-mail unless necessary -Original Message- From: Alston, Brian (US SSA) [mailto:brian.als...@baesystems.com] Sent: Tuesday, June 02, 2009 7:03 PM To: users@tomcat.apache.org Subject: Which Do I SSL - httpd or Tomcat? Hello All I have a clustered/load-balanced Apache httpd and Tomcat setup. I have one httpd front end that load balances for two Tomcat back ends. I now want to add SSL to the mix but I am confused. Do I add the SSL to the httpd server, to the two Tomcat servers, or to all of them? Thank you for reading. Have a good day - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e
Does this look correct to everybody?
All I am attempting to cluster 3 Apache Tomcat 6 servers behind a load balancing Apache httpd server. I say attempting because I am having no success. I wanted to post some of my configurations here to see if what I have is correct. My setup is as follows: Apache httpd: 192.168.1.10 - (version 2.2.3) Apache Tomcat: 192.168.1.20 - (version 6.0.18) Apache Tomcat: 192.168.1.21 - (version 6.0.18) Apache Tomcat: 192.168.1.22 - (version 6.0.18) Here is the configuration that I may need help with: IfModule proxy_balancer_module ProxyRequests off Proxy balancer://my_cluster BalancerMember http://192.168.1.20:8080 loadfactor=1 BalancerMember http://192.168.1.21:8080 loadfactor=1 BalancerMember http://192.168.1.22:8080 loadfactor=1 Order Deny,Allow Allow from all /Proxy Location /balancer-manager SetHandler balancer-manager Order Deny,Allow Allow from all /Location Location /examples ProxyPass balancer://my_cluster/examples stickysession=JSESSIONID ProxyPassReverse balancer://my_cluster/examples Order Deny,Allow Allow from all Location Location /my_application ProxyPass balancer://my_cluster/my_application stickysession=JSESSIONID ProxyPassReverse balancer://my_cluster/my_application Order Deny,Allow Allow from all Location /IfModule I thought that this was correct but I am having issues with sessions and some kind person on an earlier post of mine suggested that it could be my configuration so I figured I would post it for all to see and critique. Thank you all for reading and replying. Have a great day. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Does this look correct to everybody?
All This is too weird, I am hoping somebody can explain it to me. If I change my configuration to the following: IfModule proxy_balancer_module ProxyRequests off Proxy balancer://my_cluster BalancerMember http://192.168.1.20:8080 loadfactor=1 BalancerMember http://192.168.1.21:8080 loadfactor=1 BalancerMember http://192.168.1.22:8080 loadfactor=1 Order Deny,Allow Allow from all /Proxy SetHandler balancer-manager ProxyPass /examples balancer://my_cluster/examples stickysession=JSESSIONID ProxyPassReverse /examples balancer://my_cluster/examples ProxyPass /my_application balancer://my_cluster/my_application stickysession=JSESSIONID ProxyPassReverse /my_application balancer://my_cluster/my_application /IfModule Everything appears to work exactly as expected. My sessions are acting like they are supposed and everything seems to be playing nice. So why does taking the ProxyPass and ProxyPassReverse out of the Location tags make it work??? Thanks for reading and replying. From: Alston, Brian (US SSA) [brian.als...@baesystems.com] Sent: Tuesday, March 24, 2009 11:23 AM To: users@tomcat.apache.org Subject: Does this look correct to everybody? All I am attempting to cluster 3 Apache Tomcat 6 servers behind a load balancing Apache httpd server. I say attempting because I am having no success. I wanted to post some of my configurations here to see if what I have is correct. My setup is as follows: Apache httpd: 192.168.1.10 - (version 2.2.3) Apache Tomcat: 192.168.1.20 - (version 6.0.18) Apache Tomcat: 192.168.1.21 - (version 6.0.18) Apache Tomcat: 192.168.1.22 - (version 6.0.18) Here is the configuration that I may need help with: IfModule proxy_balancer_module ProxyRequests off Proxy balancer://my_cluster BalancerMember http://192.168.1.20:8080 loadfactor=1 BalancerMember http://192.168.1.21:8080 loadfactor=1 BalancerMember http://192.168.1.22:8080 loadfactor=1 Order Deny,Allow Allow from all /Proxy Location /balancer-manager SetHandler balancer-manager Order Deny,Allow Allow from all /Location Location /examples ProxyPass balancer://my_cluster/examples stickysession=JSESSIONID ProxyPassReverse balancer://my_cluster/examples Order Deny,Allow Allow from all Location Location /my_application ProxyPass balancer://my_cluster/my_application stickysession=JSESSIONID ProxyPassReverse balancer://my_cluster/my_application Order Deny,Allow Allow from all Location /IfModule I thought that this was correct but I am having issues with sessions and some kind person on an earlier post of mine suggested that it could be my configuration so I figured I would post it for all to see and critique. Thank you all for reading and replying. Have a great day. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Need Help With Clustered Tomcat Sessions
I feel I must apologise. Upon closer examination, it appears I am having the same problem with my Linux load-balancer as well. It looks like I may a compound issue. The initial confusion started with the different way that Linux and Windows Apache servers handle the trailing slash for a URL. The Windows Apache would not see the trailing slash and break, so I was able to notice the problem. The Linux Apache server would not see the trailing slash, but would gracefully work around it. The other issue may also be connected to the trailing slash issue but I'm not sure, I'll try to explain it as best I can. When I go to http://192.168.1.100/examples (no trailing slash), I actually get forwarded to a Tomcat server and end up at http://192.168.1.110:8080/examples . If this happens, the Session ID stays the same and all my name/value pairs accumulate in the session example. However, If I keep adding a trailing slash: http://192.168.1.100/examples/ http://192.168.1.100/examples/servlets/ etc. Then the URL in the address bar stays that of the load-balancer, BUT, every time I add a new name/value pair to the session example I get a new Session ID and my name/value pairs keep getting overwritten. This, of course, wont work because there is now no more load balancing or failover protection. So ... I am now not sure if this is a trailing slash issue or a sessions issue, both or neither. If I use a static page placed in: C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps\examples\test.html the load-balancing and failover work perfectly. It appears to only break if there is some kind of session/dynamic content on the page. So what does everybody think? Is this a simple issue or more complex? Is this simply a URL Rewrite issue or something else? Thank you so much for reading and replying. From: Alston, Brian (US SSA) [brian.als...@baesystems.com] Sent: Thursday, March 19, 2009 3:32 PM To: Tomcat Users List Subject: RE: Need Help With Clustered Tomcat Sessions Yes I am. The frustrating thing is I have 2 Tomcat servers and 2 Apache load balancers. One load balancer is Linux and one load balancer is Windows Server 2003 (I never have them both on at the same time). I can turn off my Windows load balancer, turn on my Linux load balancer, and the sessions work perfectly. It is some kind of issue with the Windows load balancer but I just cannot figure it out. My Apache load balancing configurations are the same between the Linux and Windows servers; the only difference is that the Linux load balancer works and the Windows one does not work, so you can see why I want to pull my hair out. I would simply stick with the Linux load balancer but they want me to use the Windows one, so I'm stuck. From: Jorge Medina [jmed...@e-dialog.com] Sent: Thursday, March 19, 2009 3:13 PM To: Tomcat Users List Subject: RE: Need Help With Clustered Tomcat Sessions Are you maintaining session stickyness? Did you configure Tomcat to replicate the sessions? -Original Message- From: Alston, Brian (US SSA) [mailto:brian.als...@baesystems.com] Sent: Thursday, March 19, 2009 1:40 PM To: users@tomcat.apache.org Subject: Need Help With Clustered Tomcat Sessions Hello All I am having trouble with my Tomcat cluster that I hope you can help with. First my setup: Apache Load Balancer: Windows Server 2003 - Apache 2.2.11 - 192.168.1.100 Tomcat Server 1: Windows Server 2003 - Tomcat 6.0.18 - 192.168.1.110 Tomcat Server 2: Windows Server 2003 - Tomcat 6.0.18 - 192.168.1.120 When I go to the Apache load balancer (http://192.168.1.100) the page comes up fine. When I go to the Java examples (http://192.168.1.100/examples/) and click on Servlets Examples and then on Sessions - Execute the page also comes up fine. It is here when I start to have problems. First, let me explain how I know I have problems. Here is another setup I have: Apache Load Balancer: RedHat Enterprise Linux 5 - Apache 2.2.3 - 192.168.2.100 Tomcat Server 1: Windows Server 2003 - Tomcat 6.0.18 - 192.168.2.110 Tomcat Server 2: Windows Server 2003 - Tomcat 6.0.18 - 192.168.2.120 When I go to my Linux load-balanced cluster and enter Name/Value Session Attributes into the Sessions Servlet Examples, they accumulate and I maintain the exact same Session ID. For example: Session ID: CCAE9F2E90A5311166E7B67CE003A727.tomcat1 The following data is in your session: color-sky = blue color-grass = green color-firetruck = red color-cloud = white No matter what I enter, I get an additional Name/Value Session Attribute pair and the exact same Session ID. Now, back to my Windows Server 2003 load-balanced cluster. Whenever I enter any Name/Value Session Attribute pairs, the new name/value pair always replaces the old, and I end up with an entirely new Session ID to boot: Session ID
Need Help With Clustered Tomcat Sessions
Hello All I am having trouble with my Tomcat cluster that I hope you can help with. First my setup: Apache Load Balancer: Windows Server 2003 - Apache 2.2.11 - 192.168.1.100 Tomcat Server 1: Windows Server 2003 - Tomcat 6.0.18 - 192.168.1.110 Tomcat Server 2: Windows Server 2003 - Tomcat 6.0.18 - 192.168.1.120 When I go to the Apache load balancer (http://192.168.1.100) the page comes up fine. When I go to the Java examples (http://192.168.1.100/examples/) and click on Servlets Examples and then on Sessions - Execute the page also comes up fine. It is here when I start to have problems. First, let me explain how I know I have problems. Here is another setup I have: Apache Load Balancer: RedHat Enterprise Linux 5 - Apache 2.2.3 - 192.168.2.100 Tomcat Server 1: Windows Server 2003 - Tomcat 6.0.18 - 192.168.2.110 Tomcat Server 2: Windows Server 2003 - Tomcat 6.0.18 - 192.168.2.120 When I go to my Linux load-balanced cluster and enter Name/Value Session Attributes into the Sessions Servlet Examples, they accumulate and I maintain the exact same Session ID. For example: Session ID: CCAE9F2E90A5311166E7B67CE003A727.tomcat1 The following data is in your session: color-sky = blue color-grass = green color-firetruck = red color-cloud = white No matter what I enter, I get an additional Name/Value Session Attribute pair and the exact same Session ID. Now, back to my Windows Server 2003 load-balanced cluster. Whenever I enter any Name/Value Session Attribute pairs, the new name/value pair always replaces the old, and I end up with an entirely new Session ID to boot: Session ID: .tomcat1 Session ID: .tomcat2 Session ID: .tomcat1 Session ID: .tomcat2 Session ID: .tomcat1 Session ID: .tomcat1 . . . I am hoping that there is a simple fix for this because I have no clue. My Apache httpd.conf file and Tomcat server.xml files are exactly the same between the Linux load-balanced cluster and the Windows Server 2003 load-balanced cluster, so I assume that cannot be the cause. Any help will be greatly appreciated. Thanks for reading and have a good day. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Need Help With Clustered Tomcat Sessions
Yes I am. The frustrating thing is I have 2 Tomcat servers and 2 Apache load balancers. One load balancer is Linux and one load balancer is Windows Server 2003 (I never have them both on at the same time). I can turn off my Windows load balancer, turn on my Linux load balancer, and the sessions work perfectly. It is some kind of issue with the Windows load balancer but I just cannot figure it out. My Apache load balancing configurations are the same between the Linux and Windows servers; the only difference is that the Linux load balancer works and the Windows one does not work, so you can see why I want to pull my hair out. I would simply stick with the Linux load balancer but they want me to use the Windows one, so I'm stuck. From: Jorge Medina [jmed...@e-dialog.com] Sent: Thursday, March 19, 2009 3:13 PM To: Tomcat Users List Subject: RE: Need Help With Clustered Tomcat Sessions Are you maintaining session stickyness? Did you configure Tomcat to replicate the sessions? -Original Message- From: Alston, Brian (US SSA) [mailto:brian.als...@baesystems.com] Sent: Thursday, March 19, 2009 1:40 PM To: users@tomcat.apache.org Subject: Need Help With Clustered Tomcat Sessions Hello All I am having trouble with my Tomcat cluster that I hope you can help with. First my setup: Apache Load Balancer: Windows Server 2003 - Apache 2.2.11 - 192.168.1.100 Tomcat Server 1: Windows Server 2003 - Tomcat 6.0.18 - 192.168.1.110 Tomcat Server 2: Windows Server 2003 - Tomcat 6.0.18 - 192.168.1.120 When I go to the Apache load balancer (http://192.168.1.100) the page comes up fine. When I go to the Java examples (http://192.168.1.100/examples/) and click on Servlets Examples and then on Sessions - Execute the page also comes up fine. It is here when I start to have problems. First, let me explain how I know I have problems. Here is another setup I have: Apache Load Balancer: RedHat Enterprise Linux 5 - Apache 2.2.3 - 192.168.2.100 Tomcat Server 1: Windows Server 2003 - Tomcat 6.0.18 - 192.168.2.110 Tomcat Server 2: Windows Server 2003 - Tomcat 6.0.18 - 192.168.2.120 When I go to my Linux load-balanced cluster and enter Name/Value Session Attributes into the Sessions Servlet Examples, they accumulate and I maintain the exact same Session ID. For example: Session ID: CCAE9F2E90A5311166E7B67CE003A727.tomcat1 The following data is in your session: color-sky = blue color-grass = green color-firetruck = red color-cloud = white No matter what I enter, I get an additional Name/Value Session Attribute pair and the exact same Session ID. Now, back to my Windows Server 2003 load-balanced cluster. Whenever I enter any Name/Value Session Attribute pairs, the new name/value pair always replaces the old, and I end up with an entirely new Session ID to boot: Session ID: .tomcat1 Session ID: .tomcat2 Session ID: .tomcat1 Session ID: .tomcat2 Session ID: .tomcat1 Session ID: .tomcat1 . . . I am hoping that there is a simple fix for this because I have no clue. My Apache httpd.conf file and Tomcat server.xml files are exactly the same between the Linux load-balanced cluster and the Windows Server 2003 load-balanced cluster, so I assume that cannot be the cause. Any help will be greatly appreciated. Thanks for reading and have a good day. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Need Hellp With Tomcat 6 / Apache 2.2 Cluster Problem
Ok ... I feel like a moron but I cannot figure out how to use disablereuse option. When I google for examples on disablereuse, what I find is that in my httpd.conf file I need to add the line JkOptions +DisableReuse. However, reading the information here (http://httpd.apache.org/docs/2.2/mod/mod_proxy.html) it looks like I need to add disablereuse=On to the end of the line BalancerMember http://192.168.1.101:8080 loadfactor=1. I am extremely new at this Tomcat clustering process, so any leniency and help will be very much appreciated. Thanks Have a great day. From: Filip Hanik - Dev Lists [devli...@hanik.com] Sent: Tuesday, March 10, 2009 1:22 PM To: Tomcat Users List Subject: Re: Need Hellp With Tomcat 6 / Apache 2.2 Cluster Problem Alston, Brian (US SSA) wrote: Filip Thank you for your help. I made the changes like you suggested: changed stickysession-jsessionid to stickysession=JSESSIONID|jsessionid I already had stickysession=jsessionid (it was a typo here in my post) but I added the pipe and uppercase JSESSIONID my server.xml already had the line you suggested. If I use disablereuse=On won't I then have problems with my cookies and sessions? disable reuse will not affect your cookies or sessions Filip Again, thank you very much for your help. From: Filip Hanik - Dev Lists [devli...@hanik.com] Sent: Tuesday, March 10, 2009 12:42 PM To: Tomcat Users List Subject: Re: Need Hellp With Tomcat 6 / Apache 2.2 Cluster Problem hi Brian, your stickysession attribute is wrong, it should look like |stickysession=JSESSIONID|jsessionid then you must set jvmRoute in server.xml (Engine name=xxx jvmRoute=tc1) the jvmRoute has to be unique across the tc nodes. stickyness will only apply to request that have sessions remove smax/max, better to use the defaults I would also set the property disablereuse to On if it is supported in your httpd version, right now it may try to use a connection that is dead, and it seems its not trying another node, there may be some other attributes that can help with that too documentation is here http://httpd.apache.org/docs/2.2/mod/mod_proxy.html Filip |Alston, Brian (US SSA) wrote: Like the example in the book, I created a file called proxy-balancer.conf and put it in the conf.d directory. Here is what the file looks like (I retyped it so there may be mistakes): IfModule !proxy_module LoadModule proxy_module modules/mod_proxy.so /IfModule # IfModule !proxy_ajp_module # LoadModule proxy_ajp_module modules/mod_proxy_ajp.so # /IfModule IfModule !proxy_http_module LoadModule proxy_http_module modules/mod_proxy_http.so /IfModule IfModule !proxy_balancer_module LoadModule proxy_balancer_module modules/mod_proxy_balancer.so /IfModule IfModule !status_module LoadModule status_module modules/mod_status.so /IfModule IfModule !proxy_balancer_module ProxyRequests Off Proxy balancer://tccluster BalancerMember http://192.168.1.101:8080 loadfactor=1 max=150 smax=145 BalancerMember http://192.168.1.102:8080 loadfactor=1 max=150 smax=145 BalancerMember http://192.168.1.103:8080 loadfactor=1 max=150 smax=145 Order Deny,Allow Allow from all /Proxy Location /balancer-manager SetHandler balancer-manager Order Deny,Allow Allow from all /Location Location /my-webapp ProxyPass balancer://tccluster/my-webapp stickysession-jsessionid ProxyPassReverse balancer://tccluster/my-webapp Order Deny,Allow Allow from all /Location Location /examples ProxyPass balancer://tccluster/examples stickysession-jsessionid ProxyPassReverse balancer://tccluster/examples Order Deny,Allow Allow from all /Location /IfModule From: Filip Hanik - Dev Lists [devli...@hanik.com] Sent: Tuesday, March 10, 2009 11:29 AM To: Tomcat Users List Subject: Re: Need Hellp With Tomcat 6 / Apache 2.2 Cluster Problem what does the cluster section of your httpd look like? Alston, Brian (US SSA) wrote: I have one Apache http server version 2.2.3 (on Red Hat Enterprise Linux 5) and three Tomcat 6 version 6.0.18 servers (on Windows Server 2003) running in my cluster. Everything appears to be working well. It looks like it is using RoundRobin because every time I refresh the page it goes from web001 - web002 - web003 - web001 - etc. I used some of the examples that are provided with Tomcat in the examples directory - specifically the Sessions servlet and it looks like my sessions are staying the same and holding information. My issue is this. When I stop one of the Tomcat servers (let's say web002), I will sometimes get the following error message when I refresh the page: - - - - - - - - - - Proxy Error The proxy server received an invalid response from an upstream server. The proxy server could not handle the request GET /examples
RE: Need Hellp With Tomcat 6 / Apache 2.2 Cluster Problem
Filip I was under the assumption, from my reading, that load balancing was a component of clustering. At least that's how the O'Reilly book makes me feel. I added the option to the end of the line and it now looks like this: BalancerMember http://192.168.1.101:8080 loadfactor=1 disablereuse=On BalancerMember http://192.168.1.102:8080 loadfactor=1 disablereuse=On BalancerMember http://192.168.1.103:8080 loadfactor=1 disablereuse=On I restarted Apache and got the following error: - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Starting httpd: Syntax error on line 25 of /etc/httpd/conf.d/proxy-balancer.conf: BalancerMember unknown Worker parameter - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Thank you From: Filip Hanik - Dev Lists [devli...@hanik.com] Sent: Wednesday, March 11, 2009 11:10 AM To: Tomcat Users List Subject: Re: Need Hellp With Tomcat 6 / Apache 2.2 Cluster Problem hi Brian, this is not really tomcat clustering, but more httpd load balancing. Disable reuse is available on two modules, mod_jk and mod_proxy, that is why you get hits for mod_jk as well when you google. syntax is case sensitive, and yes, you would add it to the end of the BalancerMember Filip Alston, Brian (US SSA) wrote: Ok ... I feel like a moron but I cannot figure out how to use disablereuse option. When I google for examples on disablereuse, what I find is that in my httpd.conf file I need to add the line JkOptions +DisableReuse. However, reading the information here (http://httpd.apache.org/docs/2.2/mod/mod_proxy.html) it looks like I need to add disablereuse=On to the end of the line BalancerMember http://192.168.1.101:8080 loadfactor=1. I am extremely new at this Tomcat clustering process, so any leniency and help will be very much appreciated. Thanks Have a great day. From: Filip Hanik - Dev Lists [devli...@hanik.com] Sent: Tuesday, March 10, 2009 1:22 PM To: Tomcat Users List Subject: Re: Need Hellp With Tomcat 6 / Apache 2.2 Cluster Problem Alston, Brian (US SSA) wrote: Filip Thank you for your help. I made the changes like you suggested: changed stickysession-jsessionid to stickysession=JSESSIONID|jsessionid I already had stickysession=jsessionid (it was a typo here in my post) but I added the pipe and uppercase JSESSIONID my server.xml already had the line you suggested. If I use disablereuse=On won't I then have problems with my cookies and sessions? disable reuse will not affect your cookies or sessions Filip Again, thank you very much for your help. From: Filip Hanik - Dev Lists [devli...@hanik.com] Sent: Tuesday, March 10, 2009 12:42 PM To: Tomcat Users List Subject: Re: Need Hellp With Tomcat 6 / Apache 2.2 Cluster Problem hi Brian, your stickysession attribute is wrong, it should look like |stickysession=JSESSIONID|jsessionid then you must set jvmRoute in server.xml (Engine name=xxx jvmRoute=tc1) the jvmRoute has to be unique across the tc nodes. stickyness will only apply to request that have sessions remove smax/max, better to use the defaults I would also set the property disablereuse to On if it is supported in your httpd version, right now it may try to use a connection that is dead, and it seems its not trying another node, there may be some other attributes that can help with that too documentation is here http://httpd.apache.org/docs/2.2/mod/mod_proxy.html Filip |Alston, Brian (US SSA) wrote: Like the example in the book, I created a file called proxy-balancer.conf and put it in the conf.d directory. Here is what the file looks like (I retyped it so there may be mistakes): IfModule !proxy_module LoadModule proxy_module modules/mod_proxy.so /IfModule # IfModule !proxy_ajp_module # LoadModule proxy_ajp_module modules/mod_proxy_ajp.so # /IfModule IfModule !proxy_http_module LoadModule proxy_http_module modules/mod_proxy_http.so /IfModule IfModule !proxy_balancer_module LoadModule proxy_balancer_module modules/mod_proxy_balancer.so /IfModule IfModule !status_module LoadModule status_module modules/mod_status.so /IfModule IfModule !proxy_balancer_module ProxyRequests Off Proxy balancer://tccluster BalancerMember http://192.168.1.101:8080 loadfactor=1 max=150 smax=145 BalancerMember http://192.168.1.102:8080 loadfactor=1 max=150 smax=145 BalancerMember http://192.168.1.103:8080 loadfactor=1 max=150 smax=145 Order Deny,Allow Allow from all /Proxy Location /balancer-manager SetHandler balancer-manager Order Deny,Allow Allow from all /Location Location /my-webapp ProxyPass balancer://tccluster/my-webapp stickysession-jsessionid ProxyPassReverse balancer://tccluster/my-webapp Order Deny,Allow Allow from all /Location Location
Need Hellp With Tomcat 6 / Apache 2.2 Cluster Problem
I have one Apache http server version 2.2.3 (on Red Hat Enterprise Linux 5) and three Tomcat 6 version 6.0.18 servers (on Windows Server 2003) running in my cluster. Everything appears to be working well. It looks like it is using RoundRobin because every time I refresh the page it goes from web001 - web002 - web003 - web001 - etc. I used some of the examples that are provided with Tomcat in the examples directory - specifically the Sessions servlet and it looks like my sessions are staying the same and holding information. My issue is this. When I stop one of the Tomcat servers (let's say web002), I will sometimes get the following error message when I refresh the page: - - - - - - - - - - Proxy Error The proxy server received an invalid response from an upstream server. The proxy server could not handle the request GET /examples/instance.html. Reason: Error reading from remote server Apache/2.2.3 (Red Hat) Server at 150.37.0.20 Port 80 - - - - - - - - - - I don't receive this error message every single time I refresh the page but I do get it often. It looks like Apache http server is still trying to access the Tomcat server web002 even though it is down. Does this sound like I have an incorrect configuration to anybody or is this normal? I would not think that it was normal, as clustering is supposed to prevent errors like this. I have been following the examples in the O'Reilly book Tomcat: The Definitive Guide in chapter 10 - Tomcat Clustering. Any help anybody can provide will be greatly appreciated. Thank you for reading, have a good day. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Need Hellp With Tomcat 6 / Apache 2.2 Cluster Problem
Like the example in the book, I created a file called proxy-balancer.conf and put it in the conf.d directory. Here is what the file looks like (I retyped it so there may be mistakes): IfModule !proxy_module LoadModule proxy_module modules/mod_proxy.so /IfModule # IfModule !proxy_ajp_module # LoadModule proxy_ajp_module modules/mod_proxy_ajp.so # /IfModule IfModule !proxy_http_module LoadModule proxy_http_module modules/mod_proxy_http.so /IfModule IfModule !proxy_balancer_module LoadModule proxy_balancer_module modules/mod_proxy_balancer.so /IfModule IfModule !status_module LoadModule status_module modules/mod_status.so /IfModule IfModule !proxy_balancer_module ProxyRequests Off Proxy balancer://tccluster BalancerMember http://192.168.1.101:8080 loadfactor=1 max=150 smax=145 BalancerMember http://192.168.1.102:8080 loadfactor=1 max=150 smax=145 BalancerMember http://192.168.1.103:8080 loadfactor=1 max=150 smax=145 Order Deny,Allow Allow from all /Proxy Location /balancer-manager SetHandler balancer-manager Order Deny,Allow Allow from all /Location Location /my-webapp ProxyPass balancer://tccluster/my-webapp stickysession-jsessionid ProxyPassReverse balancer://tccluster/my-webapp Order Deny,Allow Allow from all /Location Location /examples ProxyPass balancer://tccluster/examples stickysession-jsessionid ProxyPassReverse balancer://tccluster/examples Order Deny,Allow Allow from all /Location /IfModule From: Filip Hanik - Dev Lists [devli...@hanik.com] Sent: Tuesday, March 10, 2009 11:29 AM To: Tomcat Users List Subject: Re: Need Hellp With Tomcat 6 / Apache 2.2 Cluster Problem what does the cluster section of your httpd look like? Alston, Brian (US SSA) wrote: I have one Apache http server version 2.2.3 (on Red Hat Enterprise Linux 5) and three Tomcat 6 version 6.0.18 servers (on Windows Server 2003) running in my cluster. Everything appears to be working well. It looks like it is using RoundRobin because every time I refresh the page it goes from web001 - web002 - web003 - web001 - etc. I used some of the examples that are provided with Tomcat in the examples directory - specifically the Sessions servlet and it looks like my sessions are staying the same and holding information. My issue is this. When I stop one of the Tomcat servers (let's say web002), I will sometimes get the following error message when I refresh the page: - - - - - - - - - - Proxy Error The proxy server received an invalid response from an upstream server. The proxy server could not handle the request GET /examples/instance.html. Reason: Error reading from remote server Apache/2.2.3 (Red Hat) Server at 150.37.0.20 Port 80 - - - - - - - - - - I don't receive this error message every single time I refresh the page but I do get it often. It looks like Apache http server is still trying to access the Tomcat server web002 even though it is down. Does this sound like I have an incorrect configuration to anybody or is this normal? I would not think that it was normal, as clustering is supposed to prevent errors like this. I have been following the examples in the O'Reilly book Tomcat: The Definitive Guide in chapter 10 - Tomcat Clustering. Any help anybody can provide will be greatly appreciated. Thank you for reading, have a good day. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Need Hellp With Tomcat 6 / Apache 2.2 Cluster Problem
Filip Thank you for your help. I made the changes like you suggested: changed stickysession-jsessionid to stickysession=JSESSIONID|jsessionid I already had stickysession=jsessionid (it was a typo here in my post) but I added the pipe and uppercase JSESSIONID my server.xml already had the line you suggested. If I use disablereuse=On won't I then have problems with my cookies and sessions? Again, thank you very much for your help. From: Filip Hanik - Dev Lists [devli...@hanik.com] Sent: Tuesday, March 10, 2009 12:42 PM To: Tomcat Users List Subject: Re: Need Hellp With Tomcat 6 / Apache 2.2 Cluster Problem hi Brian, your stickysession attribute is wrong, it should look like |stickysession=JSESSIONID|jsessionid then you must set jvmRoute in server.xml (Engine name=xxx jvmRoute=tc1) the jvmRoute has to be unique across the tc nodes. stickyness will only apply to request that have sessions remove smax/max, better to use the defaults I would also set the property disablereuse to On if it is supported in your httpd version, right now it may try to use a connection that is dead, and it seems its not trying another node, there may be some other attributes that can help with that too documentation is here http://httpd.apache.org/docs/2.2/mod/mod_proxy.html Filip |Alston, Brian (US SSA) wrote: Like the example in the book, I created a file called proxy-balancer.conf and put it in the conf.d directory. Here is what the file looks like (I retyped it so there may be mistakes): IfModule !proxy_module LoadModule proxy_module modules/mod_proxy.so /IfModule # IfModule !proxy_ajp_module # LoadModule proxy_ajp_module modules/mod_proxy_ajp.so # /IfModule IfModule !proxy_http_module LoadModule proxy_http_module modules/mod_proxy_http.so /IfModule IfModule !proxy_balancer_module LoadModule proxy_balancer_module modules/mod_proxy_balancer.so /IfModule IfModule !status_module LoadModule status_module modules/mod_status.so /IfModule IfModule !proxy_balancer_module ProxyRequests Off Proxy balancer://tccluster BalancerMember http://192.168.1.101:8080 loadfactor=1 max=150 smax=145 BalancerMember http://192.168.1.102:8080 loadfactor=1 max=150 smax=145 BalancerMember http://192.168.1.103:8080 loadfactor=1 max=150 smax=145 Order Deny,Allow Allow from all /Proxy Location /balancer-manager SetHandler balancer-manager Order Deny,Allow Allow from all /Location Location /my-webapp ProxyPass balancer://tccluster/my-webapp stickysession-jsessionid ProxyPassReverse balancer://tccluster/my-webapp Order Deny,Allow Allow from all /Location Location /examples ProxyPass balancer://tccluster/examples stickysession-jsessionid ProxyPassReverse balancer://tccluster/examples Order Deny,Allow Allow from all /Location /IfModule From: Filip Hanik - Dev Lists [devli...@hanik.com] Sent: Tuesday, March 10, 2009 11:29 AM To: Tomcat Users List Subject: Re: Need Hellp With Tomcat 6 / Apache 2.2 Cluster Problem what does the cluster section of your httpd look like? Alston, Brian (US SSA) wrote: I have one Apache http server version 2.2.3 (on Red Hat Enterprise Linux 5) and three Tomcat 6 version 6.0.18 servers (on Windows Server 2003) running in my cluster. Everything appears to be working well. It looks like it is using RoundRobin because every time I refresh the page it goes from web001 - web002 - web003 - web001 - etc. I used some of the examples that are provided with Tomcat in the examples directory - specifically the Sessions servlet and it looks like my sessions are staying the same and holding information. My issue is this. When I stop one of the Tomcat servers (let's say web002), I will sometimes get the following error message when I refresh the page: - - - - - - - - - - Proxy Error The proxy server received an invalid response from an upstream server. The proxy server could not handle the request GET /examples/instance.html. Reason: Error reading from remote server Apache/2.2.3 (Red Hat) Server at 150.37.0.20 Port 80 - - - - - - - - - - I don't receive this error message every single time I refresh the page but I do get it often. It looks like Apache http server is still trying to access the Tomcat server web002 even though it is down. Does this sound like I have an incorrect configuration to anybody or is this normal? I would not think that it was normal, as clustering is supposed to prevent errors like this. I have been following the examples in the O'Reilly book Tomcat: The Definitive Guide in chapter 10 - Tomcat Clustering. Any help anybody can provide will be greatly appreciated. Thank you for reading, have a good day. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h