RE: Session lost when app. is redeployed
> From: Martin Gainty [mailto:mgai...@hotmail.com] > Subject: RE: Session lost when app. is redeployed > > from what I've seen the normal way of handling the webapp reload > is to clean off the work folder *.ser files Don't confuse reload with undeploy; Tomcat creates the SESSIONS.ser file when a webapp is stopped, and leaves it there unless an undeploy is done. It certainly does not delete the file on a simple webapp reload. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Session lost when app. is redeployed
> From: Adriano dos Santos Fernandes [mailto:adrian...@uol.com.br] > Subject: Re: Session lost when app. is redeployed > > I mainly used Lambda Probe. I now also tried: > - stop the application > - touch the war > - start the application > - application is undeployed and deployed, and session is lost I still cannot duplicate your problem. Unless I explicitly undeploy the webapp, the session is preserved. When I followed the exact sequence given above - using both manager and LambdaProbe - no undeployment occurred, just an application reload, and the session data was properly recovered and remained intact. Try updating your logging.properties to set the logging level for your webapp to FINE, restart Tomcat, and then do your procedure again. Use something like this: org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/].level = FINE org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/].handlers = 2localhost.org.apache.juli.FileHandler - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: tomcat startup
> From: Nathan Aaron [mailto:naa...@glenraven.com] > Subject: Re: tomcat startup > > unpackWARs="true" autoDeploy="true" deployXML="true" > xmlValidation="false" xmlNamespaceAware="false" > deployOnStartup="false"> > > This had no effect. All the contexts started when Tomcat started. I don't think they did - at least they didn't in my testing with 6.0.18. However, ten seconds *after* Tomcat started, the autoDeploy monitor kicked in, and that did deploy all the webapps. I tried setting autoDeploy to false as well, restarted Tomcat, and then nothing deployed - ever. Nor could I figure out a way to deploy anything manually, since the manager webapp wasn't deployed (catch-22). One way around this is to keep your webapps in some directory other than the one pointed to by the appBase and deploy them by placing a element with the appropriate docBase setting in conf/Catalina/[host]/[appName].xml when you want the associated webapp to start. Your Tomcat shutdown script would then remove all such files to prevent their automatic redeployment on the next Tomcat startup. But let's back up one step from the original question: why do you not want the webapps to deploy when Tomcat starts? - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Serving Multiple Application Versions within the same Context
> From: behofmann [mailto:behofm...@gmail.com] > Subject: RE: Serving Multiple Application Versions within the same > Context > > My main objective is to have my client's URL not change > and have any redirection to a different version be > transparent to them. Which is why the filter in the otherwise dummy "production" application would seem to be an appropriate choice. > Since I've never seen the webapps/production#1.0.war > approach Since the 1.0 part wouldn't be used directly by the client (at least not on the initial request), the target of the forward done by the filter could be anything you want; it doesn't have to use the multi-level format. > Would a redirection filter only be sufficient? I would think so, but only you know your complete requirements. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Serving Multiple Application Versions within the same Context
Chuck, Thank you for the quick informative reply. My main objective is to have my client's URL not change and have any redirection to a different version be transparent to them. What exactly would you recommend? Since I've never seen the webapps/production#1.0.war approach, I would have to experiment to see how that exactly works. Would a redirection filter only be sufficient? Thanks again for your input! Brandon Caldarale, Charles R wrote: > >> From: behofmann [mailto:behofm...@gmail.com] >> Subject: Serving Multiple Application Versions within the same Context >> >> While designing this application, I would like the ability to serve >> multiple application versions within the same context. > > Do you really want to do that? Wouldn't it be better to have a separate > for each version? Mixing them together in the same classloader > (one per ) sounds really risky as well as being a maintenance > nightmare. > > It would be better to deploy each application version as a separate > . If you want to use the version numbering scheme you mentioned > as an example, simply name the webapp .war files (or directories) as > follows: > > webapps/production#1.0.war > webapps/production#1.1.war > > Yes, that really is a # sign in the file name (omit the .war if using > directories). > >> allowing me to direct Company A to >> www.mycompany.com/production/1.0/index.jsp and >> Company B to www.mycompany.com/production/1.1/index.jsp? > > You could have a webapp named just production that consists of nothing but > a filter that forwards the request to the appropriate version based on the > origin of the request. The standard URL rewrite filter should be able to > do that for you: > http://tuckey.org/urlrewrite/ > > - Chuck > > > THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY > MATERIAL and is thus for use only by the intended recipient. If you > received this in error, please contact the sender and delete the e-mail > and its attachments from all computers. > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > > > -- View this message in context: http://www.nabble.com/Serving-Multiple-Application-Versions-within-the-same-Context-tp22715207p22715545.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Serving Multiple Application Versions within the same Context
> From: behofmann [mailto:behofm...@gmail.com] > Subject: Serving Multiple Application Versions within the same Context > > While designing this application, I would like the ability to serve > multiple application versions within the same context. Do you really want to do that? Wouldn't it be better to have a separate for each version? Mixing them together in the same classloader (one per ) sounds really risky as well as being a maintenance nightmare. It would be better to deploy each application version as a separate . If you want to use the version numbering scheme you mentioned as an example, simply name the webapp .war files (or directories) as follows: webapps/production#1.0.war webapps/production#1.1.war Yes, that really is a # sign in the file name (omit the .war if using directories). > allowing me to direct Company A to > www.mycompany.com/production/1.0/index.jsp and > Company B to www.mycompany.com/production/1.1/index.jsp? You could have a webapp named just production that consists of nothing but a filter that forwards the request to the appropriate version based on the origin of the request. The standard URL rewrite filter should be able to do that for you: http://tuckey.org/urlrewrite/ - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Serving Multiple Application Versions within the same Context
I'm creating a web application where I want to define each region (Development, User Acceptance Testing, and Production) as separate contexts. Ultimately, clients will use www.mycompany.com/production/index.jsp to access my web application. While designing this application, I would like the ability to serve multiple application versions within the same context. This would allow me the flexibility to control access to a new release. Is there a way within Tomcat to manage multiple applications within the same context allowing me to direct Company A to www.mycompany.com/production/1.0/index.jsp and Company B to www.mycompany.com/production/1.1/index.jsp? I was thinking of creating this functionality through a database using the usersession to determine which application version to serve. I've read Tomcat documentation and haven't found a definite answer, but I'm relatively new to configuring Tomcat 6.0.18. I don't want to recreate this functionality if Tomcat already has it available. Thank you in advance for your help. Brandon -- View this message in context: http://www.nabble.com/Serving-Multiple-Application-Versions-within-the-same-Context-tp22715207p22715207.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Session lost when app. is redeployed
Martin Gainty wrote: Adriano- from what I've seen the normal way of handling the webapp reload is to clean off the work folder *.ser files this would be considered 'normal behaviour' since your webapp configuration has changed the attributes for any previous serialised objects would be changed as well.. thus any serialised objects should NOT be deserialised back into the webapp does this not make sense ? I don't think so... If I'm fixing bugs that does not affect session data, what's the problem to maintain it? I still don't see an easy way to do that. If my session classes changes (depending on the changes), it could not be deserialized anyway. Adriano - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: tomcat startup
> From: Martin Gainty [mailto:mgai...@hotmail.com] > Subject: RE: tomcat startup > > did you try to update catalina.properties as rainier suggested? Rainer's comment was in a completely different thread for a completely different problem. > in any event please post your catalina.properties Totally irrelevant for this issue. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: tomcat startup
Hello Aaron did you try to update catalina.properties as rainier suggested? in any event please post your catalina.properties Martin __ Verzicht und Vertraulichkeitanmerkung / Disclaimer and confidentiality note 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. This message is confidential and may be privileged. If you are not the intended recipient, we kindly ask you to please inform the sender. Any unauthorised dissemination or copying hereof is prohibited. This message serves for information purposes only and shall not have any legally binding effect. Given that e-mails can easily be subject to manipulation, we can not accept any liability for the content provided. > Date: Wed, 25 Mar 2009 15:43:48 -0400 > From: naa...@glenraven.com > To: users@tomcat.apache.org > Subject: Re: tomcat startup > > Thanks, > > I changed the following in the server.xml: > > unpackWARs="true" autoDeploy="true" deployXML="true" > xmlValidation="false" xmlNamespaceAware="false"> > > to > > unpackWARs="true" autoDeploy="true" deployXML="true" > xmlValidation="false" xmlNamespaceAware="false" deployOnStartup="false"> > > This had no effect. All the contexts started when Tomcat started. > > Any other ideas? > > Nathan > > Caldarale, Charles R wrote: > >> From: Nathan Aaron [mailto:naa...@glenraven.com] > >> Subject: tomcat startup > >> > >> Is it possible to start Tomcat and not start deployed Contexts. > >> > > > > Set deployOnStartup in the element to false: > > http://tomcat.apache.org/tomcat-6.0-doc/config/host.html > > > > - Chuck > > > > > > THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY > > MATERIAL and is thus for use only by the intended recipient. If you > > received this in error, please contact the sender and delete the e-mail and > > its attachments from all computers. > > - > > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > > For additional commands, e-mail: users-h...@tomcat.apache.org > > > > > > > > _ Windows Live™ SkyDrive: Get 25 GB of free online storage. http://windowslive.com/online/skydrive?ocid=TXT_TAGLM_WL_skydrive_032009
Re: reversed proxy stopped working with tomcat cluster
On 20.03.2009 18:48, János Löbb wrote: Hi, I have two real machines. One of them is a Windows XP running Apache 2.2.10 + mod_jk /release date of 10/30/2008/ + Tomcat 6.0.16. The other one is a Mac with OSX 10.5.6 with Apache 2.2.9 + mod_jk 1.2.26 and Tomcat 6.0.16. The XP machine runs one instance of Tomcat /node4/. The Mac runs 3, - node1,2,3. Altogether 4 tomcats and they form a cluster. ... In front of these two machines is an Apache 2.2.10 in a VMWare Fusion virtual Machine on Windows XP in the Mac and configured as a Reverse proxy Here is the reverse proxy config from the httpd.conf ProxyRequests Off BalancerMember http://bml0039.yalepath.org loadfactor=10 BalancerMember http://bml0073.yalepath.org loadfactor=10 ProxySet lbmethod=bytraffic ProxyPass /tc/ balancer://pathCluster/ ProxyPassReverse /tc/ balancer://pathCluster/ SetHandler balancer-manager Order Deny,Allow Allow from .yalepath.org Here is the access_log from the reverse proxy: 10.84.2.195 - - [20/Mar/2009:12:09:48 -0400] "GET /tc/CassetteLabeler HTTP/1.1" 302 - Returns with a trailing slash redirect 10.84.2.195 - - [20/Mar/2009:12:09:49 -0400] "GET /tc/CassetteLabeler/ HTTP/1.1" 200 1506 Returns Content with 1506 Bytes 10.84.2.195 - - [20/Mar/2009:12:09:49 -0400] "GET /CassetteLabeler/pathology.labeler.labeler.Labeler/Labeler.html HTTP/1.1" 404 260 Wrong request, Prefix /tc/ missing. You need to find out, where this request comes from. Likely it is either generated by someone using a link in the page returned by the previous request, or that page contains a meta tag in the head, which triggers a redirect to this wrong URL. So retrieve /tc/CassetteLabeler/ and have a look at the content to identify, whether the wrong URL "/CassetteLabeler/pathology.labeler.labeler.Labeler/Labeler.html" is in the page. If no, we have to think further. If yes, you have to ask, why is this wrong URL in there. The question is, how your application generates this URL. If it generates absolute URLs instead of relative ones, then you can easily run into trouble, when the path of the real application is different from the path used from the outside. It is not unlikely though, that in such a case the app or the framework used has a configurable path prefix. But first check, if you can verify the wrong URL is somewhere in the content of the page. The request from the reverse proxy did go to the XP machine: Here are the log entries from the access log: 10.84.2.195 - - [20/Mar/2009:12:09:49 -0400] "GET /CassetteLabeler HTTP/1.1" 302 - That's only the first request, answered with the trailing slash redirect. The next request is the interesting one (the one answered with status 200). It also has to appear somewhere in your 2nd laqyer httpd logs. Here are the entries from mod_jk.log of this XP machine: [Fri Mar 20 12:09:49.254 2009] [852:1808] [debug] jk_uri_worker_map.c (682): Attempting to map URI '/CassetteLabeler' from 5 maps Again that's the first request [Fri Mar 20 12:09:49.551 2009] [852:1808] [debug] jk_ajp_common.c (608): status = 302 [Fri Mar 20 12:09:49.551 2009] [852:1808] [debug] jk_ajp_common.c (615): Number of headers is = 1 [Fri Mar 20 12:09:49.551 2009] [852:1808] [debug] jk_ajp_common.c (671): Header[0] [Location] = [http://bml0039.yalepath.org/CassetteLabeler/] Aha, we get back a redirect (302) to localtion http://bml0039.yalepath.org/CassetteLabeler/ (which will be further rewritten by ProxyPassReverse). But that we already know. The next request is the interesting one. I have a production environment - just with 3 Macs and just one tomcat per machine forming a cluster - where a very similar configuration runs fine. The only difference is that the sticky parameters are NOT with the load balancer but with the real workers in the workers.properties file, This is very likely not the cause. and the reverse proxy configuration somewhat different. Here it is: ProxyPass /apps/ balancer://balancer-group/ stickysession=JSESSIONID ProxyPassReverse /apps/ balancer://balancer-group/ BalancerMember http://pathsrv1.yalepath.org loadfactor=10 BalancerMember http://raid2b.yalepath.org loadfactor=10 BalancerMember http://reptile.yalepath.org loadfactor=10 Looks pretty analogous at first sight. Regards, Rainer - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: tomcat startup
> From: Nathan Aaron [mailto:naa...@glenraven.com] > Subject: Re: tomcat startup > > All the contexts started when Tomcat started. What version of Tomcat are you using? (You should always state that in the first post of a new thread, along with the JRE/JDK and platform you're on.) - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Training classes for Apache web server and Tomcat
I am looking for good comprehensive training courses for installing, configuring and managing the Apache web server and the Tomcat server. Do you know of such classes being offered anywhere? Thanks, Scott -- View this message in context: http://www.nabble.com/Training-classes-for-Apache-web-server-and-Tomcat-tp22711383p22711383.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Session lost when app. is redeployed
Adriano- from what I've seen the normal way of handling the webapp reload is to clean off the work folder *.ser files this would be considered 'normal behaviour' since your webapp configuration has changed the attributes for any previous serialised objects would be changed as well.. thus any serialised objects should NOT be deserialised back into the webapp does this not make sense ? Martin __ Disclaimer and confidentiality note This message is confidential and may be privileged. If you are not the intended recipient, we kindly ask you to please inform the sender. Any unauthorised dissemination or copying hereof is prohibited. This message serves for information purposes only and shall not have any legally binding effect. Given that e-mails can easily be subject to manipulation, we can not accept any liability for the content provided. > Date: Wed, 25 Mar 2009 20:11:33 +0100 > Subject: Re: Session lost when app. is redeployed > From: joseph.mil...@gmail.com > To: users@tomcat.apache.org > > Not sure this might be of use but Apache normally has a *graceful *restart > option that's normally tailored to such needs. > > On Wed, Mar 25, 2009 at 1:17 PM, Christopher Schultz < > ch...@christopherschultz.net> wrote: > > > -BEGIN PGP SIGNED MESSAGE- > > Hash: SHA1 > > > > Adriano, > > > > On 3/24/2009 7:13 AM, Adriano dos Santos Fernandes wrote: > > > So my question is how to update an application, when it have full > > > serializable sessions, and the new application classes are compatible > > > with the serialized session? > > > > > > I didn't see any way to do it with Tomcat... > > > > I use 5.5.27 and, in development where autoreload=true, I trigger > > auto-redeployments all the time by changing web.xml, adding libraries, > > or updating classes. My sessions remain in-tact without a problem > > (unless, of course, I change a class for an object that is actually in a > > live session). > > > > No logs at all, eh? > > > > What about the serialized sessions file? Under the circumstances when > > the sessions /are/ persisted, can you locate the serialized sessions > > file (while the app is stopped, that is)? Copy it to a temporary location. > > > > What about in the case where the sessions file is /not/ persisted > > (again, while the app is stopped and/or undeployed). Is the file still > > there? If not, what happens if you take the file from above and use it > > as a surrogate, placing it in the right place at the right time? > > > > I'm wondering if the problem is in saving the sessions or loading them. > > I suspect that Tomcat is not saving them when you undeploy. I'm not sure > > why, since Tomcat claims to do it: > > > > http://tomcat.apache.org/tomcat-5.5-doc/config/manager.html#Restart%20Persistence > > > > If you put in your web.xml, do you get any errors? > > > > - -chris > > -BEGIN PGP SIGNATURE- > > Version: GnuPG v1.4.9 (MingW32) > > Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ > > > > iEYEARECAAYFAknKIMoACgkQ9CaO5/Lv0PC0fQCgjGDckxzlxMrrA6RY7Yovaxpw > > sZAAoKN9qtucZn7/NlAMRJg6GJt1Be+g > > =Lcp/ > > -END PGP SIGNATURE- > > > > - > > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > > For additional commands, e-mail: users-h...@tomcat.apache.org > > > > _ Express your personality in color! Preview and select themes for Hotmail®. http://www.windowslive-hotmail.com/LearnMore/personalize.aspx?ocid=TXT_MSGTX_WL_HM_express_032009#colortheme
Re: tomcat startup
Thanks, I changed the following in the server.xml: to This had no effect. All the contexts started when Tomcat started. Any other ideas? Nathan Caldarale, Charles R wrote: From: Nathan Aaron [mailto:naa...@glenraven.com] Subject: tomcat startup Is it possible to start Tomcat and not start deployed Contexts. Set deployOnStartup in the element to false: http://tomcat.apache.org/tomcat-6.0-doc/config/host.html - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Session lost when app. is redeployed
Not sure this might be of use but Apache normally has a *graceful *restart option that's normally tailored to such needs. On Wed, Mar 25, 2009 at 1:17 PM, Christopher Schultz < ch...@christopherschultz.net> wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > Adriano, > > On 3/24/2009 7:13 AM, Adriano dos Santos Fernandes wrote: > > So my question is how to update an application, when it have full > > serializable sessions, and the new application classes are compatible > > with the serialized session? > > > > I didn't see any way to do it with Tomcat... > > I use 5.5.27 and, in development where autoreload=true, I trigger > auto-redeployments all the time by changing web.xml, adding libraries, > or updating classes. My sessions remain in-tact without a problem > (unless, of course, I change a class for an object that is actually in a > live session). > > No logs at all, eh? > > What about the serialized sessions file? Under the circumstances when > the sessions /are/ persisted, can you locate the serialized sessions > file (while the app is stopped, that is)? Copy it to a temporary location. > > What about in the case where the sessions file is /not/ persisted > (again, while the app is stopped and/or undeployed). Is the file still > there? If not, what happens if you take the file from above and use it > as a surrogate, placing it in the right place at the right time? > > I'm wondering if the problem is in saving the sessions or loading them. > I suspect that Tomcat is not saving them when you undeploy. I'm not sure > why, since Tomcat claims to do it: > > http://tomcat.apache.org/tomcat-5.5-doc/config/manager.html#Restart%20Persistence > > If you put in your web.xml, do you get any errors? > > - -chris > -BEGIN PGP SIGNATURE- > Version: GnuPG v1.4.9 (MingW32) > Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ > > iEYEARECAAYFAknKIMoACgkQ9CaO5/Lv0PC0fQCgjGDckxzlxMrrA6RY7Yovaxpw > sZAAoKN9qtucZn7/NlAMRJg6GJt1Be+g > =Lcp/ > -END PGP SIGNATURE- > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > >
Re: Setting Tomcat System Properies **without** -D on Command Line
On 25.03.2009 18:54, Mike Reidy wrote: Hello, I would like to be able to configure system properties at Tomcat start-up *without* adding them to the startup command line, for example you might add -Dxx.yyy.zzz=123 to the command line to add a system property called xxx.yyy.zzz with a value of 123. I want something other than this I was hoping that there might be a way of loading an additional properties file in a similar way to catalina.properties but I cannot see this in documentation. Does this exist? If so can someone point me at the documentation please. You can do it in exactly the same way as catalina.properties, namely all lines in catalina.properties are automatically added to the system properties. Simply add your additional properties to that file. Regards, Rainer - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Setting Tomcat System Properies **without** -D on Command Line
The custom way would be to write a startup listener that its only goal is to load a prop file and promote its properties into the System environment. It could look somethng like this: package cowbell; import org.apache.catalina.Lifecycle; import org.apache.catalina.LifecycleEvent; import org.apache.catalina.LifecycleListener; public class PropListener implements LifecycleListener { public void lifecycleEvent(LifecycleEvent event) { if (Lifecycle.INIT_EVENT.equals(event.getType())) { try { System.getProperties().load("fixMe"); } catch(Throwable evil){ } } } } And in server.xml like this: -Tim Mike Reidy wrote: Hello, I would like to be able to configure system properties at Tomcat start-up *without* adding them to the startup command line, for example you might add -Dxx.yyy.zzz=123 to the command line to add a system property called xxx.yyy.zzz with a value of 123. I want something other than this I was hoping that there might be a way of loading an additional properties file in a similar way to catalina.properties but I cannot see this in documentation. Does this exist? If so can someone point me at the documentation please. If this is not the case is there a standard way that would be the recommended way of writing a custom plugin for Tomcat to do this? - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Setting Tomcat System Properies **without** -D on Command Line
take a look at implementation in web.xml http://edocs.bea.com/wls/docs61/webapp/web_xml.html#1039383 HTH Martin __ Disclaimer and confidentiality note This message is confidential and may be privileged. If you are not the intended recipient, we kindly ask you to please inform the sender. Any unauthorised dissemination or copying hereof is prohibited. This message serves for information purposes only and shall not have any legally binding effect. Given that e-mails can easily be subject to manipulation, we can not accept any liability for the content provided. > Date: Wed, 25 Mar 2009 17:54:48 + > Subject: Setting Tomcat System Properies **without** -D on Command Line > From: mike.re...@gmail.com > To: users@tomcat.apache.org > > Hello, > > I would like to be able to configure system properties at Tomcat start-up > *without* adding them to the startup command line, for example you might add > -Dxx.yyy.zzz=123 to the command line to add a system property called > xxx.yyy.zzz with a value of 123. I want something other than this > > I was hoping that there might be a way of loading an additional properties > file in a similar way to catalina.properties but I cannot see this in > documentation. Does this exist? If so can someone point me at the > documentation please. > > If this is not the case is there a standard way that would be the > recommended way of writing a custom plugin for Tomcat to do this? > > > Thank you for your time & effort, > > M _ Hotmail® is up to 70% faster. Now good news travels really fast. http://windowslive.com/online/hotmail?ocid=TXT_TAGLM_WL_HM_70faster_032009
RE: Setting Tomcat System Properies **without** -D on Command Line
> From: Mike Reidy [mailto:mike.re...@gmail.com] > Subject: Setting Tomcat System Properies **without** -D on > Command Line > > If this is not the case is there a standard way that would be the > recommended way of writing a custom plugin for Tomcat to do this? Tomcat supports use of an admin-supplied setenv.bat or setenv.sh script in which you can specify values for the CATALINA_OPTS environment variable. This will be used on the command line that starts Tomcat. You can write the setenv script to read the values you need from anywhere. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Setting Tomcat System Properies **without** -D on Command Line
Hello, I would like to be able to configure system properties at Tomcat start-up *without* adding them to the startup command line, for example you might add -Dxx.yyy.zzz=123 to the command line to add a system property called xxx.yyy.zzz with a value of 123. I want something other than this I was hoping that there might be a way of loading an additional properties file in a similar way to catalina.properties but I cannot see this in documentation. Does this exist? If so can someone point me at the documentation please. If this is not the case is there a standard way that would be the recommended way of writing a custom plugin for Tomcat to do this? Thank you for your time & effort, M
Re: reversed proxy stopped working with tomcat cluster
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 János, On 3/25/2009 11:53 AM, János Löbb wrote: > In our production environment we have 3 Xserves, all running apache2 , > mod+jk and Tomcat. There are about 5-6 web applications running on > these 3 servers standalone, -non-clustered - and there will be more. > The there Xserves are doing other things too, not just web serving. > That is the reason I cannot reduce the number of apache2 instances. > They grandfathered in themselves :) Just because they're there doesn't mean you have to use them. As long as the Tomcat ports are directly accessible from the load balancer, you can simply skip the intermediate httpd instances. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKbBgACgkQ9CaO5/Lv0PBk7gCdG8EQqggQ1ngeRcHMUjTH+M55 c/MAoLTqMlyXNOCmj7Uu27Z1AYjd+hp4 =9lj/ -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Help with Security Manager
So, I'm trying to configure my webapp to be able to create/read/write a directory outside of the webapp directory. I start tomcat with the -security option after adding the following to the bottom of the catalina.policy file: grant codeBase "${tomcat-home}/webapps/smc-appsuite" { permission java.io.FilePermission "${tomcat.home}/webapps/smc-appsuite/-", "read"; }; grant codeBase "${tomcat-home}/webapps/smc-appsuite" { permission java.io.FilePermission "/cas/db/smc-appsuite-db", "write"; }; I added the first because enabling security resulted in this: Caused by: java.security.AccessControlException: access denied (java.io.FilePermission /apache-tomcat-5.5.27/webapps/smc-appsuite/WEB-INF/classes/logging.propertie s read) I've tried plenty of permutations with this, and no luck. Can someone help? - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: tomcat startup
> From: Nathan Aaron [mailto:naa...@glenraven.com] > Subject: tomcat startup > > Is it possible to start Tomcat and not start deployed Contexts. Set deployOnStartup in the element to false: http://tomcat.apache.org/tomcat-6.0-doc/config/host.html - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: reversed proxy stopped working with tomcat cluster
Hi Chris, In our production environment we have 3 Xserves, all running apache2 , mod+jk and Tomcat. There are about 5-6 web applications running on these 3 servers standalone, -non-clustered - and there will be more. The there Xserves are doing other things too, not just web serving. That is the reason I cannot reduce the number of apache2 instances. They grandfathered in themselves :) This CassetteLabeler app is our first application that needs to be up all the time and that is why we turned to clustering, using the existing setups on these servers and hoping that just by small config changes here and there we can get our clustered app runing without worrying about the non-clustered apps. You know, the goat has to have a full stomach and the cabbage had to remain too :) . Not to destroy accidently anything in the production environment, I created a small test environment, simulating our production environment. Because I do not have 3 machines, I used the VmWare Fussion on my Mac with Windows XP to create the third machine, and to simplify things I do not run mod_jk and Tomcat on it just Apache2. The four Tomcats are forming a Tomcat Cluster. Because the individual Apaches have to communicate to their own Tomcats via their own mod_jk for the non-clustered webapps /non-clustered because they cannot be serialized/ to reach those apps, the users connect via: http://balancemember1.yalepath.org/Standalone1 kind of URL and it goes through port 80 to mod_jk and mod_jk passes it via ajp to to the appropriate tomcat. We need to preserve this behavior for the clustered app, that is why in the reversed proxy configuration the default port 80 is used. I do not think that I can changed that one. The reason for the reverse proxy is, that two of the machines in production are behind a Pix firewall and the users of the clustered app can get to it by hitting the reverse proxy. So in theory a user would hit a url like: http://reverse_proxy.yalepath.org/tc/CassetteLabeler The reverse proxy using mod_proxy, mod_proxy_balancer, mod_proxy_http would transfer it to one of the balancemembers via port 80 by the selected lbmethod. It would arrive there as: http://balancememberX.yalepath.org/CassetteLabeler The selected balance member seeing that there is a JkMount for that request would involve mod_jk and mod_jk would forward it via the ajp connector to one of the selected tomcats from the cluster. /Or that is how I imagine it :)/ Looks like the initial request is received by the reverse proxy. It selects a balance member and sends the request to it correctly, that is stripping off the /tc. Tha balancemember involves mod_jk and mod_jk forwards it to one of the clustered tomcats. Looking the debug info tomcat is doing its job and even asks for the body and receives it. Then tomcat is closing the connection to the balance member. That is where things get out of control. Then the selected balance member instead of continue with the earlier selected tomcat instance - although stickiness is specified - selects another tomcat node and sends the SAME info to it. This second tomcat does exactly as the first one did and it closes the connection. At that point the balancemember /or the reverse proxy/ sends the non-formated URL from the reverse proxy to the Apache of the second tomcat node and of course that cannot be resolved so I get a 404 error. So, I am looking why stickiness is not working, why the selected balancemember is not satisfied with the firstly selected tomcat node and just finishing the whole session with it, so the right info can flow back on the chain to the clients browser and paint the first form of the web app. Now I configured stickyness even in ProxyPass on the reverse proxy, but no cigar. ProxyRequests Off BalancerMember http://bml0039.yalepath.org loadfactor=10 BalancerMember http://bml0073.yalepath.org loadfactor=10 ProxySet lbmethod=bytraffic ProxyPass /tc/balancer://pathCluster/ stickysession=JSESSIONID ProxyPassReverse/tc/balancer://pathCluster/ #ProxyHTMLLogVerbose On SetHandler balancer-manager Order Deny,Allow Allow from .yalepath.org I would like to emphasize that when I request the web app from the individual balance members using of course port 80, like: http://balancemember1.yalepath.org/CassetteLabeler or http://balancemember2.yalepath.org/Cassettelabeler , everything is working right. The problem is somewhere as the info is flowing back in the chain to the reverse proxy. Thanks ahead, János On Mar 25, 2009, at 9:33 AM, Christopher Schultz wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 János, On 3/20/2009 1:48 PM, János Löbb wrote: [snip] ProxyRequests Off BalancerMember http://bml0039.yalepath.org loadfactor=10 BalancerMember http://bml0073.yal
tomcat startup
Is it possible to start Tomcat and not start deployed Contexts. For example I have several statically deployed contexts. When I start Tomcat I do not want them to be available. Is this possible? Thanks, Nathan - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat and Database Problem
David, Oracle have a view named v$sqlarea that contains all SQL Queries, and in my case "Select * from dual" appears :( So validationQuery is sending this query. Christopher, I don't expect many long-time queries... So what's your opinion? Tnks all! Christopher Schultz-2 wrote: > > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > CC, > > On 3/23/2009 11:24 AM, CutKiller wrote: >> But the validationQuery was set at the Resources Tags. >> >> > debug="0" reloadable="true" crossContext="true"> > > What version of TC are you running? You shouldn't be setting the path > attribute, though this is unlikely to be causing your problem. > > Is there a testAdmin.xml file hiding somewhere under > $CATALINA_HOME/conf/[enginename]/[hostname]/ that could be overriding > your configuration? > >> removeAbandoned="true" removeAbandonedTimeout="1800" > > Do you expect many long-running queries? This configuration will only > purge abandoned connections after they've been out of the pool for 30 > /minutes/. That's a long time to wait before your connections recover. > > - -chris > -BEGIN PGP SIGNATURE- > Version: GnuPG v1.4.9 (MingW32) > Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ > > iEYEARECAAYFAknKI2cACgkQ9CaO5/Lv0PD2XgCgoOiqvDyfelUoL+zUQuBXhm0X > HbcAn2KPdmbsjMcoEsIbVJgiqqSnZFdH > =qsgv > -END PGP SIGNATURE- > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > > > -- View this message in context: http://www.nabble.com/Tomcat-and-Database-Problem-tp22658620p22703934.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: how do i configure multiple domains in one tomcat inatance
Srinivas Jonnalagadda wrote: > hi, > > I am using apache http server, openSSL, mod_jk and tomcat 5.5.9 on solaris 10 > server. I need a way to create multiple domains in the same tomcat instance > or server. for example i should be able to copy my war files into two dirs > dir1 and dir2. Same Tomcat should be able to pickup applications and host > them from both the directories. I know that this is possible in Weblogic but > not sure how to implement this in tomcat. This is for 6 but should gove you the idea. http://tomcat.apache.org/tomcat-6.0-doc/virtual-hosting-howto.html Mark - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
how do i configure multiple domains in one tomcat inatance
hi, I am using apache http server, openSSL, mod_jk and tomcat 5.5.9 on solaris 10 server. I need a way to create multiple domains in the same tomcat instance or server. for example i should be able to copy my war files into two dirs dir1 and dir2. Same Tomcat should be able to pickup applications and host them from both the directories. I know that this is possible in Weblogic but not sure how to implement this in tomcat. Sincerely, Srinivas Jonnalagadda - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Apache2 / Tomcat6 application presented while callingwww.mydomain.de
> From: Newgro [mailto:per.new...@gmx.ch] > Subject: Apache2 / Tomcat6 application presented while > callingwww.mydomain.de > > I use Apache2 Webserver infront of tomat 6.0.18. Why? Unless you have a compelling reason (e.g., PHP), just run Tomcat stanadalone. > If i call the url (www.mydomain.de) i get the tomcat manager > start page. No, that's the default Tomcat home page; the manager is a separate webapp. > 1.) Where do i have to put my homepage.war file? Delete the existing webapps/ROOT directory, and rename your war file to ROOT.war (case sensitive). There are other ways to accomplish the same thing, but that's the simplest. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Apache2 / Tomcat6 application presented while calling www.mydomain.de
Hi *, i'm looking for a solution to configure the application (war) which is responding on calling a url like www.mydomain.de I use Apache2 Webserver infront of tomat 6.0.18. I setup everything from the tutorial found here http://www.mogilowski.net/?p=121&lang=de-de http://www.mogilowski.net/?p=121&lang=de-de I simply replaced the words: vhost1 by mydomain www.testsrv.local by www.mydomain.de If i call the url (www.mydomain.de) i get the tomcat manager start page. Only if i call www.mydomain.de/homepage the homepage is displayed if it's deployed in the webapps folder. So my questions are the following: 1.) Where do i have to put my homepage.war file? tomcat/webapps or /var/www/mydomain or /var/www/mydomain/htdocs? 2.) Where can i specify that calls to www.mydomain.de goto homepage instead of root application? Cheers Per -- View this message in context: http://www.nabble.com/Apache2---Tomcat6-application-presented-while-calling-www.mydomain.de-tp22702937p22702937.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: URL: /manager/html
Hey thanks again! All of our tomcat servers run on a private network for the health service so nothing hits the internet ever so I guess we would never make it onto their stats anyway. The only reason I would like to hide it is paranoia really, as we have the pen test they will undoubtedly report that they found the tomcat version and will look around for some exploit (whether one exists I don't know!) but they do produce a report to management. ** This message may contain confidential and privileged information. If you are not the intended recipient please accept our apologies. Please do not disclose, copy or distribute information in this e-mail or take any action in reliance on its contents: to do so is strictly prohibited and may be unlawful. Please inform us that this message has gone astray before deleting it. Thank you for your co-operation. NHSmail is used daily by over 100,000 staff in the NHS. Over a million messages are sent every day by the system. To find out why more and more NHS personnel are switching to this NHS Connecting for Health system please visit www.connectingforhealth.nhs.uk/nhsmail ** - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: URL: /manager/html
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Paul, On 3/25/2009 10:10 AM, Ockleford Paul (NHS Connecting for Health) wrote: > If I set the server value to "" I am guessing this will stop the sending of > the server version. Correct, though it might send "Server: " which has the same effect. I would recommend setting it to simply "Tomcat" or even "Tomcat 5" if you don't want to disclose certain portions of the version number. I like advertising part of it so that netcraft can get good data :) Is there a particular reason you want to hide the server version? - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKPFMACgkQ9CaO5/Lv0PCJ1ACfVew5NHqMqQv9DVwH5BIenNXA w7IAnRAxeesCVLdWZoR2kARKgkDbAFua =mXeA -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: URL: /manager/html
Hi again! I got it, I was looking at the wrong connector doc.. server The Server header for the http response. Unless you are paranoid, you won't need this feature. If I set the server value to "" I am guessing this will stop the sending of the server version. Cheers -Original Message- From: Christopher Schultz [mailto:ch...@christopherschultz.net] Sent: 25 March 2009 13:38 To: Tomcat Users List Subject: Re: URL: /manager/html -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Paul, On 3/25/2009 9:24 AM, Ockleford Paul (NHS Connecting for Health) wrote: > Thanks again, we don't want to use it at all Then undeploy it: 1. Stop Tomcat 2. Remove the file $CATALINA_HOME/conf/[enginename]/[hostname]/manager.xml (I would recommend moving it somewhere, in case you want to bring it back at some point). You might want to look at any other applications that are deployed by default. Any .xml files in that directory will deploy other applications. You should remove anything you don't need. > browsing to the url reported a tomcat standard error page that > revealed the tomcat version we are using. That is something they will > pick up on during the test and is something we hadn't noticed before. Have you changed the "server" attribute of your s? If not, your HTTP headers are likely revealing the Tomcat version you are using. Is that a big deal? > How would I undeploy the entire app so that browsing to the url > /manager/ would not result in a standard error page? Unless you have deployed your own webapp as the ROOT webapp, you will get 404 errors that might contain this information. If you *do* have your webapp deployed as ROOT, then your own configuration from web.xml should be able to take care of 404 errors and show whatever page you'd rather see. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKM9IACgkQ9CaO5/Lv0PDs/gCgtUqAgtKhcr1Da6xYmICUrSuv qKMAnR4MSCfvowvjU4m0kHoxw/ApJN2J =Ynzv -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org ** This message may contain confidential and privileged information. If you are not the intended recipient please accept our apologies. Please do not disclose, copy or distribute information in this e-mail or take any action in reliance on its contents: to do so is strictly prohibited and may be unlawful. Please inform us that this message has gone astray before deleting it. Thank you for your co-operation. NHSmail is used daily by over 100,000 staff in the NHS. Over a million messages are sent every day by the system. To find out why more and more NHS personnel are switching to this NHS Connecting for Health system please visit www.connectingforhealth.nhs.uk/nhsmail ** - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: URL: /manager/html
Hi, Thanks for the replies from both of you (Chris and Chuck). One final question, what attribute of the server element would I need to change if I wanted to stop the tomcat version being reported in the http header? Looking at the docs there are only 4 attributes, is it classname? Would I need to implement a custom class if so? -Original Message- From: Christopher Schultz [mailto:ch...@christopherschultz.net] Sent: 25 March 2009 13:38 To: Tomcat Users List Subject: Re: URL: /manager/html -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Paul, On 3/25/2009 9:24 AM, Ockleford Paul (NHS Connecting for Health) wrote: > Thanks again, we don't want to use it at all Then undeploy it: 1. Stop Tomcat 2. Remove the file $CATALINA_HOME/conf/[enginename]/[hostname]/manager.xml (I would recommend moving it somewhere, in case you want to bring it back at some point). You might want to look at any other applications that are deployed by default. Any .xml files in that directory will deploy other applications. You should remove anything you don't need. > browsing to the url reported a tomcat standard error page that > revealed the tomcat version we are using. That is something they will > pick up on during the test and is something we hadn't noticed before. Have you changed the "server" attribute of your s? If not, your HTTP headers are likely revealing the Tomcat version you are using. Is that a big deal? > How would I undeploy the entire app so that browsing to the url > /manager/ would not result in a standard error page? Unless you have deployed your own webapp as the ROOT webapp, you will get 404 errors that might contain this information. If you *do* have your webapp deployed as ROOT, then your own configuration from web.xml should be able to take care of 404 errors and show whatever page you'd rather see. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKM9IACgkQ9CaO5/Lv0PDs/gCgtUqAgtKhcr1Da6xYmICUrSuv qKMAnR4MSCfvowvjU4m0kHoxw/ApJN2J =Ynzv -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org ** This message may contain confidential and privileged information. If you are not the intended recipient please accept our apologies. Please do not disclose, copy or distribute information in this e-mail or take any action in reliance on its contents: to do so is strictly prohibited and may be unlawful. Please inform us that this message has gone astray before deleting it. Thank you for your co-operation. NHSmail is used daily by over 100,000 staff in the NHS. Over a million messages are sent every day by the system. To find out why more and more NHS personnel are switching to this NHS Connecting for Health system please visit www.connectingforhealth.nhs.uk/nhsmail ** - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: URL: /manager/html
> From: Ockleford Paul (NHS Connecting for Health) > [mailto:paul.ocklef...@nhs.net] > Subject: RE: URL: /manager/html > > How would I undeploy the entire app so that browsing to the > url /manager/ would not result in a standard error page? Just delete the manager webapp: 1) remove server/webapps/manager 2) remove conf/Catalina/localhost/manager.xml 3) remove work/Catalina/localhost/manager 4) restart Tomcat - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: URL: /manager/html
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Paul, On 3/25/2009 9:24 AM, Ockleford Paul (NHS Connecting for Health) wrote: > Thanks again, we don't want to use it at all Then undeploy it: 1. Stop Tomcat 2. Remove the file $CATALINA_HOME/conf/[enginename]/[hostname]/manager.xml (I would recommend moving it somewhere, in case you want to bring it back at some point). You might want to look at any other applications that are deployed by default. Any .xml files in that directory will deploy other applications. You should remove anything you don't need. > browsing to the url reported a tomcat standard > error page that revealed the tomcat version we are using. That is > something they will pick up on during the test and is something we > hadn't noticed before. Have you changed the "server" attribute of your s? If not, your HTTP headers are likely revealing the Tomcat version you are using. Is that a big deal? > How would I undeploy the entire app so that browsing to the url > /manager/ would not result in a standard error page? Unless you have deployed your own webapp as the ROOT webapp, you will get 404 errors that might contain this information. If you *do* have your webapp deployed as ROOT, then your own configuration from web.xml should be able to take care of 404 errors and show whatever page you'd rather see. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKM9IACgkQ9CaO5/Lv0PDs/gCgtUqAgtKhcr1Da6xYmICUrSuv qKMAnR4MSCfvowvjU4m0kHoxw/ApJN2J =Ynzv -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: reversed proxy stopped working with tomcat cluster
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 János, On 3/20/2009 1:48 PM, János Löbb wrote: > connectionTimeout="2" >redirectPort="8643" /> > [snip] > ProxyRequests Off > > BalancerMember http://bml0039.yalepath.org loadfactor=10 > BalancerMember http://bml0073.yalepath.org loadfactor=10 Note that you have configured your Tomcat to listen for HTTP on port 8280, but your configuration points to port 80. This isn't going to work. > Here is the workers.property file: > > > bml0073:local janos$ cat apache2/conf/workers.properties > worker.list = lb,jkstatus This looks like workers.properties, which is a mod_jk thing. You are using mod_proxy_http. This isn't going to work for two reasons: 1. mod_proxy_http uses HTTP as the protocol and mod_jk uses AJP 2. mod_proxy_http doesn't read workers.properties, so the file is not relevant > Similar workers.properies on the XP machine but the hosts are logically > different If your Windows XP machine runs Tomcat only, then the presence of a workers.properties file is not relevant. > Well, this setup worked in December. Very unlikely. > The request from the reverse proxy did go to the XP machine: > Here are the log entries from the access log: > > > 10.84.2.195 - - [20/Mar/2009:12:09:49 -0400] "GET /CassetteLabeler > HTTP/1.1" 302 - > Wait... are you running 3 copies of Apache httpd? No wonder there's tons and tons configuration. You only need one single httpd instance: the one doing the load-balancing. Configure /all/ of the TC instances that are part of the balancing setup in that one httpd. What you've done is set up load balancing across two httpd instances that then load-balance to a set of webapp servers. I can only think of a single reason to ever do that (you want lopsided load balancing) but it still doesn't make any sense. Lose the additional httpd instances and simplify your life, man. Then there won't be so much confusion over port numbers, forwarding, proxying, etc. > Here are the entries from mod_jk.log of this XP machine: > > > [Fri Mar 20 12:09:49.254 2009] [852:1808] [debug] jk_uri_worker_map.c > (682): Attempting to map URI '/CassetteLabeler' from 5 maps Ugh. Okay, so you are using mod_proxy_http for the main httpd and mod_jk from the other ones. That's not confusing at all. I would highly recommend that you simplify your configuration unless you have a real need to complicate it. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKMrUACgkQ9CaO5/Lv0PBjrACgvAP1zKwFa2wYlx7O4cvPx7DC JhAAoLd4B7HnrjSX+8f7IcoivwJcpiDs =/8Rs -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Port range
Christopher Schultz wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Vanky, On 3/25/2009 9:09 AM, Venky Vasant wrote: I am sure this is very simple question but i could not find a proper information Where do i find the official information about what port range can be used for tomcat server port and HTTP connector port for all windows servers. There are no explicit restrictions on Microsoft Windows for what ports you can use for Tomcat ports. The only practical restriction is that you can't use a port that is already in use. Darren has a suggestion for determining which ports are already in use. It's also a good idea to avoid ports for known services like SMTP, DNS, etc. Most people stick with 80 for HTTP and 443 for HTTPS, since they are the well-known default ports for those protocols. You'll also see variations on those numbers when used in in-house apps, such as 8000 or 8080 for http, and 8443 for HTTPS. D - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: URL: /manager/html
Hi Chris, Thanks again, we don't want to use it at all, and the problem stemmed only from the fact that we have a pen test due and although the manager app wasn't actually accessible (we never changed the tomcat-users file) browsing to the url reported a tomcat standard error page that revealed the tomcat version we are using. That is something they will pick up on during the test and is something we hadnt noticed before. How would I undeploy the entire app so that browsing to the url /manager/ would not result in a standard error page? -Original Message- From: Christopher Schultz [mailto:ch...@christopherschultz.net] Sent: 25 March 2009 13:18 To: Tomcat Users List Subject: Re: URL: /manager/html -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Paul, On 3/25/2009 9:01 AM, Ockleford Paul (NHS Connecting for Health) wrote: > When I say forward on any request that is actually probably a > misleading statement, I changed the url context for the manager web > application to point to our web app that handles any contexts from > that point on. Yeah, I'm confused. Let's start over: Do you want the manager app to run at all? If not, just undeploy it. They you don't have to worry about anyone accessing it. If you do want it to run, but you want people to authenticate against your application before using it, you'll need to set up a more complicated authentication/authorization configuration. If you want the manager app available only for certain people, I would configure the security for the manager app separately from your main application, and lock it down appropriately (for instance, allow connections only from known IPs, etc.). - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKLwkACgkQ9CaO5/Lv0PCbMgCaAr4fK8O3mszC1b9LSlQtWrOj fFcAniow7ep1u621HL6si5CszDXRN427 =MRF0 -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org ** This message may contain confidential and privileged information. If you are not the intended recipient please accept our apologies. Please do not disclose, copy or distribute information in this e-mail or take any action in reliance on its contents: to do so is strictly prohibited and may be unlawful. Please inform us that this message has gone astray before deleting it. Thank you for your co-operation. NHSmail is used daily by over 100,000 staff in the NHS. Over a million messages are sent every day by the system. To find out why more and more NHS personnel are switching to this NHS Connecting for Health system please visit www.connectingforhealth.nhs.uk/nhsmail ** - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Port range
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Vanky, On 3/25/2009 9:09 AM, Venky Vasant wrote: > I am sure this is very simple question but i could not find a proper > information > > Where do i find the official information about what port range can be > used for tomcat server port and HTTP connector port for all windows > servers. There are no explicit restrictions on Microsoft Windows for what ports you can use for Tomcat ports. The only practical restriction is that you can't use a port that is already in use. Darren has a suggestion for determining which ports are already in use. It's also a good idea to avoid ports for known services like SMTP, DNS, etc. Most people stick with 80 for HTTP and 443 for HTTPS, since they are the well-known default ports for those protocols. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKL4cACgkQ9CaO5/Lv0PCruQCbBYvR1Q5kn3IOBs1ow1sIY+Vi I6gAn2BmMM6xhdNIHRC/TxNIPIUJc2lb =lIx4 -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Port range
Venky Vasant wrote: I am sure this is very simple question but i could not find a proper information Where do i find the official information about what port range can be used for tomcat server port and HTTP connector port for all windows servers. Regards Venkat You can use any port that's not already in use by something else. D - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: URL: /manager/html
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Paul, On 3/25/2009 9:01 AM, Ockleford Paul (NHS Connecting for Health) wrote: > When I say forward on any request that is actually probably a > misleading statement, I changed the url context for the manager web > application to point to our web app that handles any contexts from > that point on. Yeah, I'm confused. Let's start over: Do you want the manager app to run at all? If not, just undeploy it. They you don't have to worry about anyone accessing it. If you do want it to run, but you want people to authenticate against your application before using it, you'll need to set up a more complicated authentication/authorization configuration. If you want the manager app available only for certain people, I would configure the security for the manager app separately from your main application, and lock it down appropriately (for instance, allow connections only from known IPs, etc.). - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKLwkACgkQ9CaO5/Lv0PCbMgCaAr4fK8O3mszC1b9LSlQtWrOj fFcAniow7ep1u621HL6si5CszDXRN427 =MRF0 -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: URL: /manager/html
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Paul, On 3/25/2009 9:00 AM, Ockleford Paul (NHS Connecting for Health) wrote: > I edited the url context: What is the URL context? > http://enigmail.mozdev.org/ iEYEARECAAYFAknKLowACgkQ9CaO5/Lv0PCOUgCfVNBq0Vx/oNu0CYOrXghlwcgi HmUAoLYKke5pTBf0n8JRA8H9T3ywiwXn =VXu9 -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Cannot create PoolableConnectionFactory
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Mel, On 3/23/2009 1:24 AM, Mel McGuire wrote: > No problem seen with mysql or the mysql command line utility. > Tomcat comes up and down alright. [snip] > url="jdbc:mysql://localhost:3306/nlocalhost" > removeAbandoned="true" > removeAbandonedTimeout="120" /> I would add: logAbandoned="true" validationQuery="/* PING */ SELECT 1" Note that using 'root' is probably not the best strategy, here. ;) > HTTP Status 500 error report: > > java.lang.NullPointerException > PublicTopFrameset.doGet(PublicTopFrameset.java:109) > javax.servlet.http.HttpServlet.service(HttpServlet.java:617) > javax.servlet.http.HttpServlet.service(HttpServlet.java:717) > Obviously, your webapp should be checking for null references. I know your problem is deeper than this, but this error is obviously your code's fault. > Tomcat error report: > > AbandonedObjectPool is used > (org.apache.tomcat.dbcp.dbcp.AbandonedObjectPool&b8f8eb) > LogAbandoned: false > RemoveAbandoned: true > RemoveAbandonedTimeout: 120 > org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create > PoolableConnectionFactory (Communications link failure > Last packet sent to the server was 0 ms ago.) This indicates that Java can't contact the server. You mentioned that the mysql command-line utility connects just fine. Can you do this and see what happens: C> mysql -h 127.0.0.1 -u root -p nlocalhost and see if that connects? I don't think win32 uses anything other than TCP/IP for communication (*NIX systems can use a named pipe on the filesystem and ignore networking altogether) but using 127.0.0.1 as the host (/not/ "localhost") disables that behavior in the client. > private DataSource dataSource = null; > > public void init(ServletConfig config) >throws ServletException >{ > super.init(config); > servletContext = config.getServletContext(); > dataSource = (DataSource)servletContext.getAttribute("dataSource"); You really shouldn't do this. You should use JNDI to get the DataSource each time you need it, rather than caching a copy of that object somewhere (like the application scope, as you've done here). A JNDI fetch is cheap and more robust (you can replace the DataSource at runtime and everyone starts using it right away, instead of having to bounce the app). Also, DataSource is not guaranteed to be threadsafe so you never know if it will even work properly in a shared situation (which you have here). >{ //The error occurs here. > con = dataSource.getConnection(); Right: you need to check for null ;) > .When the mysql port is changed to 3308, the error message is the same. > I conclude that the error occurs before there is an attempt to use > the mysql port? Yes. Your machine can't contact MySQL. Stupid question: Is MySQL running? (Probably, since you said the command-line works). Also, are you running Tomcat under a security manager (i.e. with the "-security" switch)? If so, you could have a permissions problem. > .I bit on a Sun Java upgrade popup several weeks ago but I believe I tested > ok after it was installed. Anyway, the upgrade left a CLASSPATH variable > containing only jre6. I temporarily removed the CLASSPATH variable but > the problem persisted. I copied some .jar files into the new > jre6/lib/ext folder from the jre1.6.0_07/lib/ext folder. No luck. You should ignore the CLASSPATH environment variable. When you installed Tomcat, did you use the installer, or did you just unzip it? I'm asking because I think the Tomcat service points to a specific JRE version. If Tomcat is doing /anything/ (which it is), your upgrade doesn't appear to have broken anything. > .A few days ago, my computer hung at "shutting down" (first time ever) and I > pulled the electrical plug and restarted. I don't belive I tested > my app after the restart but I didn't notice anything else wrong. I thought this was just called "running Microsoft windows". ;) - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKLfQACgkQ9CaO5/Lv0PB4pgCeJtbNU3pU4OXbg02IuW7qneOZ LE0An0Wc7CvmwC+Bm6tg3GjHLQvxBtsK =JkQk -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Port range
netstat -a from a Command window, will show you all the ports in use on any Windows server. -Original Message- From: Venky Vasant [mailto:venkat...@yahoo.com] Sent: 25 March 2009 13:10 To: users@tomcat.apache.org Subject: Port range I am sure this is very simple question but i could not find a proper information Where do i find the official information about what port range can be used for tomcat server port and HTTP connector port for all windows servers. Regards Venkat Connaught plc is one of the UK's top 250 companies on the London Stock Exchange and the leading provider of integrated services operating in the compliance, social housing and public sector markets. Please visit our website to see a full list of Connaught's Registered Companies http://www.connaught.plc.uk/group/aboutconnaught/registeredcompanies Disclaimer: The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete this message. Connaught plc, Head Office 01392 444546 - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Port range
I am sure this is very simple question but i could not find a proper information Where do i find the official information about what port range can be used for tomcat server port and HTTP connector port for all windows servers. Regards Venkat
Re: root context path - war file not unwar'd
pid-2 is right in that the path shouldn't be used here, if i remove this Tomcat still deploys myapp.war as "/" as it's using the name of the ROOT.xml file to infer the actual path. i misread the tomcat context documentation http://tomcat.apache.org/tomcat-5.5-doc/config/context.html. deploying your war file without having to rename it ROOT.war or use Apache RewriteRules to rewrite "/myapp" to "/" is still preferable in my opinion though, and the real point of the article. just don't set the "path"! thanks pid-2 Pid-2 wrote: > > Andrew Eells wrote: >> If it helps it's also possible to deploy your war file with any name at >> all >> and have it deployed as the default context "/" - without the need to >> name >> it ROOT.war. >> >> The trick is to have it located outside the Tomcat directory and have the >> ROOT.xml context docBase point to it whilst setting path="". Exact >> details >> can be found here: > > This is incorrect. If you have an app located outside of the defined > webapps dir and are using the docBase attribute then merely naming the > context XML file "ROOT.xml" is enough. > > You may consider the following: a normally deployed ROOT.war causes a > ROOT.xml to be created - it is this special name that locates the web > application at the path "/". > > You may only use path="" when the context is defined in server.xml, > (when a ROOT.xml would not exist) - a practice which is very strongly > discouraged anyway. > > p > > >> http://www.andrew-eells.com/2009/03/21/tomcat-root-war/ Tomcat ROOT.war >> deployment >> > > > - > To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org > For additional commands, e-mail: users-h...@tomcat.apache.org > > > -- View this message in context: http://www.nabble.com/root-context-path---war-file-not-unwar%27d-tp21553536p22701361.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: URL: /manager/html
When I say forward on any request that is actually probably a misleading statement, I changed the url context for the manager web application to point to our web app that handles any contexts from that point on. Paul Ockleford Developer Systems and Service Delivery NHS Connecting for Health 01392 206977 paul.ocklef...@nhs.net www.connectingforhealth.nhs.uk NHS Connecting for Health supports the NHS in providing better, safer care by delivering computer systems and services which improve the way patient information is stored and accessed. -Original Message- From: Christopher Schultz [mailto:ch...@christopherschultz.net] Sent: 25 March 2009 12:39 To: Tomcat Users List Subject: Re: URL: /manager/html -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Paul, On 3/25/2009 8:35 AM, Ockleford Paul (NHS Connecting for Health) wrote: > Yes the forward for / is to our web app, I edited the file > /tomcat/conf/Catalina/localhost/manger.xml to forward on any request > to our admin login page. Exactly how did you do that? - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKJfwACgkQ9CaO5/Lv0PCFYgCeNWGCOdoQNxemo9qkRP3vdi5e 7IAAoL9OMr7gRNpgJ24YDX3mktSV9Xrw =bz3G -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org ** This message may contain confidential and privileged information. If you are not the intended recipient please accept our apologies. Please do not disclose, copy or distribute information in this e-mail or take any action in reliance on its contents: to do so is strictly prohibited and may be unlawful. Please inform us that this message has gone astray before deleting it. Thank you for your co-operation. NHSmail is used daily by over 100,000 staff in the NHS. Over a million messages are sent every day by the system. To find out why more and more NHS personnel are switching to this NHS Connecting for Health system please visit www.connectingforhealth.nhs.uk/nhsmail ** - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Fw: [OT] Tomcat 5 with HADR
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Tyson, On 3/20/2009 9:21 AM, Tyson Beffa wrote: > Do you have any suggestions for setting up db2 High-Availability Disaster > Recovery with tomcat5. This sounds like it's entirely handled by the database and the JDBC driver. I would check the documentation for com.ibm.db2.jcc.DB2Driver. I would imagine that you can simply add some parameters to the connection URL in order to configure the db failover. At least, this is how Connector/J does it. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKKw4ACgkQ9CaO5/Lv0PA0CACff4bZqugfG3gqfstjpuv5dwjZ POgAnjodumPNSAHidPSpqy81k+EFiAYD =4Xfu -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: URL: /manager/html
Hi Chris, I edited the url context: Paul Ockleford Developer Systems and Service Delivery NHS Connecting for Health 01392 206977 paul.ocklef...@nhs.net www.connectingforhealth.nhs.uk NHS Connecting for Health supports the NHS in providing better, safer care by delivering computer systems and services which improve the way patient information is stored and accessed. -Original Message- From: Christopher Schultz [mailto:ch...@christopherschultz.net] Sent: 25 March 2009 12:39 To: Tomcat Users List Subject: Re: URL: /manager/html -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Paul, On 3/25/2009 8:35 AM, Ockleford Paul (NHS Connecting for Health) wrote: > Yes the forward for / is to our web app, I edited the file > /tomcat/conf/Catalina/localhost/manger.xml to forward on any request > to our admin login page. Exactly how did you do that? - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKJfwACgkQ9CaO5/Lv0PCFYgCeNWGCOdoQNxemo9qkRP3vdi5e 7IAAoL9OMr7gRNpgJ24YDX3mktSV9Xrw =bz3G -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org ** This message may contain confidential and privileged information. If you are not the intended recipient please accept our apologies. Please do not disclose, copy or distribute information in this e-mail or take any action in reliance on its contents: to do so is strictly prohibited and may be unlawful. Please inform us that this message has gone astray before deleting it. Thank you for your co-operation. NHSmail is used daily by over 100,000 staff in the NHS. Over a million messages are sent every day by the system. To find out why more and more NHS personnel are switching to this NHS Connecting for Health system please visit www.connectingforhealth.nhs.uk/nhsmail ** - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: SEVERE: BAD packet singnature 18245
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Saju, On 3/24/2009 12:05 AM, Saju K K wrote: > I am using only one connector with tomcat( NIO connector) , In that case > also i get the same error . No, you're not: > minProcessors="5" maxProcessors="100" protocol="HTTP/1.1" > redirectPort="8443" /> That's an HTTP , and ... > worker.worker2.port=8080 /that/ is an AJP worker. I don't think HTTP would complain about getting an AJP packet (you'd just get a connection drop, or maybe a BAD REQUEST response). What is more likely is that you are sending an HTTP request to an AJP . What URL are you using to access the application? What is the full stack trace of the error? Do you get any errors in your httpd log files? What versions of everything are you running? - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKJ4oACgkQ9CaO5/Lv0PDEbACgmL3KkY5UbVh58X+LMK523qHV wvMAoKwdG7AhwyDGgx+eUfso5l0VIoZK =r9qZ -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: URL: /manager/html
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Paul, On 3/25/2009 8:35 AM, Ockleford Paul (NHS Connecting for Health) wrote: > Yes the forward for / is to our web app, I edited the file > /tomcat/conf/Catalina/localhost/manger.xml to forward on any request > to our admin login page. Exactly how did you do that? - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKJfwACgkQ9CaO5/Lv0PCFYgCeNWGCOdoQNxemo9qkRP3vdi5e 7IAAoL9OMr7gRNpgJ24YDX3mktSV9Xrw =bz3G -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat Error Message
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Conandor, On 3/23/2009 5:36 AM, conandor wrote: > > Why I keep having this error message whenever I start tomcat. > Can anyone tell me why? [snip] > INFO: Starting Servlet Engine: Apache Tomcat/5.5.20 [snip] > LifeCycleServletContextListener: contextInitialized > ---> Login with > SocNetw5:SocNetw5Prod:https://myServer/myGateway/HTTPReceiver > javax.net.ssl.SSLHandshakeException: > sun.security.validator.ValidatorException: PKIX > path building failed: sun.security.provider.certpath.SunCertPathBui > lderException: unable to find valid certification path to requested target Looks like you don't have a certificate installed that identifies the server at https://myServer/myGateway/HTTPReceiver as valid. Is that server using a self-signed certificate? If so, you need to import the site's certificate in order for Java to trust that site for communication. There are other techniques, but this is probably the best option. > at common.SessionManager.sendRequest(SessionManager.java:211) > at common.SessionManager.login(SessionManager.java:156) > at > common.LifeCycleServletContextListener.contextInitialized(LifeCycleServletContextListener.java:28) This looks like your code, not Tomcat or any 3rd-party that I know of. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKJbcACgkQ9CaO5/Lv0PCXMgCeP40IZI3w8r/Dbn7P+TOdQLhe qGwAn2p2BvP2qfZxqh0EAwhCdmFXXgko =TNUu -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: URL: /manager/html
Hi Chris, Thanks for that. Yes the forward for / is to our web app, I edited the file /tomcat/conf/Catalina/localhost/manger.xml to forward on any request to our admin login page. Thanks for the link. Paul Paul Ockleford Developer Systems and Service Delivery NHS Connecting for Health 01392 206977 paul.ocklef...@nhs.net www.connectingforhealth.nhs.uk NHS Connecting for Health supports the NHS in providing better, safer care by delivering computer systems and services which improve the way patient information is stored and accessed. -Original Message- From: Christopher Schultz [mailto:ch...@christopherschultz.net] Sent: 25 March 2009 12:06 To: Tomcat Users List Subject: Re: URL: /manager/html -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Paul, On 3/25/2009 4:34 AM, Ockleford Paul (NHS Connecting for Health) wrote: > We have tomcat 5.5.17 installed, and all requests for "/" are > forwarded to a login page that we maintain, so it was assumed that the > manager application was not accessible, however if I put > https://webapp:8443/manager/html a login prompt pops up. Do you mean you see /your/ login page, or some other one? When you say "all requests for / are redirected", do you mean this is being done in your own webapp, or at a higher-level (Tomcat or maybe a web server out front)? > I don't see any mapping for this URL in our server.xml, so where is > this being handled? If the manager application is deployed, then you are likely to be able to access it. Tomcat deploys applications in 4 ways: 1. Any defined in server.xml 2. Any APP.war found in the webapps directory, if auto-deploy is true 3. Any APP.xml found in $CATALINA_HOME/conf/[enginename]/[hostname]/ My guess is that #3 is in play, here. You can find more information on webapp deployment in the introduction section of this page: http://tomcat.apache.org/tomcat-5.5-doc/config/context.html Hope that helps, - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKHhoACgkQ9CaO5/Lv0PD1WACfbbEPKwwo8eacJrXiDQ67gHig K8YAoJqC31NjYuqCopNiFJpAkRzpU4a5 =ISf+ -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org ** This message may contain confidential and privileged information. If you are not the intended recipient please accept our apologies. Please do not disclose, copy or distribute information in this e-mail or take any action in reliance on its contents: to do so is strictly prohibited and may be unlawful. Please inform us that this message has gone astray before deleting it. Thank you for your co-operation. NHSmail is used daily by over 100,000 staff in the NHS. Over a million messages are sent every day by the system. To find out why more and more NHS personnel are switching to this NHS Connecting for Health system please visit www.connectingforhealth.nhs.uk/nhsmail ** - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat and Database Problem
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 CC, On 3/23/2009 11:24 AM, CutKiller wrote: > But the validationQuery was set at the Resources Tags. > >debug="0" reloadable="true" crossContext="true"> What version of TC are you running? You shouldn't be setting the path attribute, though this is unlikely to be causing your problem. Is there a testAdmin.xml file hiding somewhere under $CATALINA_HOME/conf/[enginename]/[hostname]/ that could be overriding your configuration? > removeAbandoned="true" removeAbandonedTimeout="1800" Do you expect many long-running queries? This configuration will only purge abandoned connections after they've been out of the pool for 30 /minutes/. That's a long time to wait before your connections recover. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKI2cACgkQ9CaO5/Lv0PD2XgCgoOiqvDyfelUoL+zUQuBXhm0X HbcAn2KPdmbsjMcoEsIbVJgiqqSnZFdH =qsgv -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Session lost when app. is redeployed
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Adriano, On 3/24/2009 7:13 AM, Adriano dos Santos Fernandes wrote: > So my question is how to update an application, when it have full > serializable sessions, and the new application classes are compatible > with the serialized session? > > I didn't see any way to do it with Tomcat... I use 5.5.27 and, in development where autoreload=true, I trigger auto-redeployments all the time by changing web.xml, adding libraries, or updating classes. My sessions remain in-tact without a problem (unless, of course, I change a class for an object that is actually in a live session). No logs at all, eh? What about the serialized sessions file? Under the circumstances when the sessions /are/ persisted, can you locate the serialized sessions file (while the app is stopped, that is)? Copy it to a temporary location. What about in the case where the sessions file is /not/ persisted (again, while the app is stopped and/or undeployed). Is the file still there? If not, what happens if you take the file from above and use it as a surrogate, placing it in the right place at the right time? I'm wondering if the problem is in saving the sessions or loading them. I suspect that Tomcat is not saving them when you undeploy. I'm not sure why, since Tomcat claims to do it: http://tomcat.apache.org/tomcat-5.5-doc/config/manager.html#Restart%20Persistence If you put in your web.xml, do you get any errors? - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKIMoACgkQ9CaO5/Lv0PC0fQCgjGDckxzlxMrrA6RY7Yovaxpw sZAAoKN9qtucZn7/NlAMRJg6GJt1Be+g =Lcp/ -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: URL: /manager/html
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Paul, On 3/25/2009 4:34 AM, Ockleford Paul (NHS Connecting for Health) wrote: > We have tomcat 5.5.17 installed, and all requests for "/" are > forwarded to a login page that we maintain, so it was assumed that > the manager application was not accessible, however if I put > https://webapp:8443/manager/html a login prompt pops up. Do you mean you see /your/ login page, or some other one? When you say "all requests for / are redirected", do you mean this is being done in your own webapp, or at a higher-level (Tomcat or maybe a web server out front)? > I don't see any mapping for this URL in our server.xml, so where is > this being handled? If the manager application is deployed, then you are likely to be able to access it. Tomcat deploys applications in 4 ways: 1. Any defined in server.xml 2. Any APP.war found in the webapps directory, if auto-deploy is true 3. Any APP.xml found in $CATALINA_HOME/conf/[enginename]/[hostname]/ My guess is that #3 is in play, here. You can find more information on webapp deployment in the introduction section of this page: http://tomcat.apache.org/tomcat-5.5-doc/config/context.html Hope that helps, - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKHhoACgkQ9CaO5/Lv0PD1WACfbbEPKwwo8eacJrXiDQ67gHig K8YAoJqC31NjYuqCopNiFJpAkRzpU4a5 =ISf+ -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 5.5.27 Pool/DBCP Locks and Configuration issues
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Chuck, On 3/23/2009 9:39 PM, Caldarale, Charles R wrote: >> From: Shaun Farrugia [mailto:sfarru...@fry.com] >> Subject: Tomcat 5.5.27 Pool/DBCP Locks and Configuration issues >> >> 4) Are there known issues on 5.5.27 when running >> abandonedobjectpool log-abandoned and remove-abandoned >> with a 30 second time out? > > No one seems to be reporting any such problems here. > >> The app isn't holding onto any connections > > How do you know that? Your symptoms seem to indicate otherwise. +1 Take a look at http://blog.christopherschultz.net/?p=68 then review a representative piece of your code. You may not be writing your code correctly. >> a lot of locked threads. > > What do you mean by "locked threads"? Post a stack trace if that would help. Also, do you see any messages in your logs about abandoned connections? I believe these messages would go into catalina.out, but you should check all logs for anything suspicious. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAknKHBgACgkQ9CaO5/Lv0PBukwCgn36tduJKLGMKxjE7NfKF5WhX yeEAoJrZu38yyM9BNE9DZ4fcqg1OO2V1 =rxRe -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: root context path - war file not unwar'd
Andrew Eells wrote: > If it helps it's also possible to deploy your war file with any name at all > and have it deployed as the default context "/" - without the need to name > it ROOT.war. > > The trick is to have it located outside the Tomcat directory and have the > ROOT.xml context docBase point to it whilst setting path="". Exact details > can be found here: This is incorrect. If you have an app located outside of the defined webapps dir and are using the docBase attribute then merely naming the context XML file "ROOT.xml" is enough. You may consider the following: a normally deployed ROOT.war causes a ROOT.xml to be created - it is this special name that locates the web application at the path "/". You may only use path="" when the context is defined in server.xml, (when a ROOT.xml would not exist) - a practice which is very strongly discouraged anyway. p > http://www.andrew-eells.com/2009/03/21/tomcat-root-war/ Tomcat ROOT.war > deployment > - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Connection errors with mod_proxy_balancer and tomcat 5.5
Hi, we encounter some strange errors with our apache (v2.2) fronting 4 tomcat (v5.5) server. We are loadbalancing with sticky sessions to our tomcats. Everything runs fine beside the fact that 0.1% of all requests get a 503 http status code. The rate raises under load, but it is at least 0.1% (way too much!!) and occurs even at the early morning hours. The request is not logged on the tomcat side (no exceptions, no access.log), only on apache access.log with 503 and error log as stated below. 1. This is from our apache log file: [Wed Mar 25 07:08:44 2009] [error] [client 74.6.22.94] (70014)End of file found: proxy: error reading status line from remote server tc1 [Wed Mar 25 07:08:44 2009] [error] [client 74.6.22.94] proxy: Error reading from remote server returned by /site.html 2. This is from our apache config (prefork engine) KeepAlive Off ServerLimit 650 ListenBackLog 50 StartServers 50 MinSpareServers 100 MaxSpareServers 200 MaxClients300 MaxRequestsPerChild 1 ProxyRequests Off BalancerMember http://tc1:80 max=100 route=tc1 BalancerMember http://tc2:80 max=100 route=tc2 BalancerMember http://tc3:80 max=100 route=tc3 BalancerMember http://tc4:80 max=100 route=tc4 Order Deny,Allow Allow from all ProxyPass / balancer://tomcatcluster/ stickysession=JSESSIONID|jsessionid ProxyPassReverse / http://tc1/ ProxyPassReverse / http://tc2/ ProxyPassReverse / http://tc3/ ProxyPassReverse / http://tc4/ ProxyPreserveHost On 3. This is our connector from our tomcat configuration I tried to investigate this problem but wasn't even able to reproduce it on my test engine. Googling it, i found some other people having this problem but no solution. As far as i understand from my investigations "BalancerMember http://tc1:80 max=100" does not make sense on "prefork". max should be 1 with prefork model. But i think this is not the reason. if max=100 is not effective, there "could" be situations where MaxClients of 300 all go to one tomcat because of session affinity. But this is rather theoretical. Maybe i can't use keepalive on the tomcat side. But it seems to work. But honestly: i am clueless. Do you have any hints why i do encounter these connection errors? Or does anybody has a running configuration with apache2.2, mod_proxy_balancer and tomcat 5.5. where these problems does not occur? kind regards Janning - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
URL: /manager/html
Hi, We have tomcat 5.5.17 installed, and all requests for "/" are forwarded to a login page that we maintain, so it was assumed that the manager application was not accessible, however if I put https://webapp:8443/manager/html a login prompt pops up. I dont see any mapping for this url in our server.xml, so where is this being handled? Can anyone explain? Thanks, Paul ** This message may contain confidential and privileged information. If you are not the intended recipient please accept our apologies. Please do not disclose, copy or distribute information in this e-mail or take any action in reliance on its contents: to do so is strictly prohibited and may be unlawful. Please inform us that this message has gone astray before deleting it. Thank you for your co-operation. NHSmail is used daily by over 100,000 staff in the NHS. Over a million messages are sent every day by the system. To find out why more and more NHS personnel are switching to this NHS Connecting for Health system please visit www.connectingforhealth.nhs.uk/nhsmail **