Many hosts sharing servlets
I am moving from jserv to tomcat. I have 100+ servlets and classes that I want to be available to up to 100 virtual hosts. The server I am moving to runs RHE3 with Apache2, Plesk and Tomcat4. Plesk only supports the mod_webapp connector. I can't find much info on mod_webapp but it seems to me that each virtual host must have its own webapps deployed. So I have tried to put all the classes into /var/tomcat4/shared/classes. In each host, I deploy a servlets.war file that contains only the following WEB-INF/web.xml file - ?xml version=1.0 encoding=ISO-8859-1? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app display-nameGlogal servlets/display-name description Global servlets. /description servlet-mapping servlet-nameinvoker/servlet-name url-pattern/*/url-pattern /servlet-mapping /web-app This is working on the few hosts I tried so far. I can link to a servlet using http://a-host.com/servlets/MyServlet. Questions Is there a better way to do this ? Will tomcat be using hugely more memory than jserv was ? Should I abandon Plesk, use Cpanel and configure apache/tomcat manually (but I don't want to have to ssh in and configure each new host manually) ? Thanks Bill - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: All threads (250) are currently busy
I don't know what kind of application you are running, but most likely you have a resource leak; Do a thread dump and see what your threads are waiting for. Most likely they are just in wait state and no CPU usage. It could be cause by lots of things. One problem could be using jdbc and not closing your connection or returning it to your pool. For testing reduce your resource limit, don't increase it (reduce Max thread, and connection pool). This would cause system hangs faster. Send a SIGQUIT signal to VM and look at state of your threads and its location (don't post your thread dump!) Paul Grimwood wrote: Tomcat hangs intermittently (1 to 10 days) with the following message in catalina.out 20/04/2005 13:48:09 org.apache.tomcat.util.threads.ThreadPool logFull SEVERE: All threads (250) are currently busy, waiting. Increase maxThreads (250) or check the servlet status We are running tomcat 5.5.7 on jdk1.5.0_02 under Redhat Linux Fedora Core 2 against an Oracle9 DB. I have seen various posts to this with suggestions including setting Linux threads with LD_ASSUME_KERNEL (tried but problem still exists) and setting connection timeout in server.xml from 0 to 6 (but ours is set at 2 already). And we have already upgraded to latest Tomcat and JRE to no avail. Despite reviewing the mailing list over the past 18 to 24 months, i am none the wiser. The problem started around the time we deployed the code onto a new server running a later Linux version but this could be a red herring and I suspect it is a database connection issue. Has anyone got any ideas? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat 5.5.9 Connection Pool / JNDI / DBCP
Hi. I have some problems with Tomcat 5.5.9 Connection Pooling / JNDI / DBCP When running my java component (se below) I receive this NamingException: /NE: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial/ If I add this code: System.setProperty(java.naming.factory.initial, org.apache.naming.java.javaURLContextFactory); System.setProperty(java.naming.factory.pkgs, org.apache.naming); to the constructor in the java component, I receive this exception: /NE: Name java: is not bound in this Context/ What is wrong and what is the solution to the problem? Thanks Lars Nielsen Lind I have copied the PostgreSQL driver, commons-pool.jar, commons-collections.jar and commons-dbcp.jar to the $CATALINA_HOME/common/lib folder. I have done as specified in the JNDI Datasource HOW-TO. *Server.xml*: Context path=/ debug=1 docBase=/opt/jakarta-tomcat-5.5.9/webapps/application/test !-- PostgreSQL / JDBC / JNDI - ConnectionPooling -- Resource name=jdbc/testdatabase auth=Container type=javax.sql.DataSource driverClassName=org.postgresql.Driver url=jdbc:postgresql://localhost/testdatabase username=dbmanager password=123456 maxActive=20 maxIdle=10 maxWait=-1 removeAbandoned=true removeAbandonedTimeout=60 logAbandoned=true / /Context *Application Web.xml*: resource-ref descriptionPostgreSQL DataSource/description res-ref-namejdbc/testdatabase/res-ref-name res-typejavax.sql.DataSource/res-type res-authContainer/res-auth /resource-ref *Java component*: import java.sql.*; import java.util.*; import javax.naming.*; import javax.sql.*; public class ConnectionPool { private Connection conn; public ConnectionPool() {} public Connection getConnectionFromPool() { try { InitialContext initContext = null; try { initContext = new InitialContext(); } catch (Exception ex) { System.out.println(IC: + ex); } try { DataSource ds = (DataSource)initContext.lookup(java:/comp/env/jdbc/testdatabase); conn = ds.getConnection(); } catch (SQLException se) { System.out.println(DS: + se); } } catch (NamingException ne) { System.out.println(NE: + ne.getMessage()); } return conn; } - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: All threads (250) are currently busy
Hi, I have the same problem, I read the reply, and I want to ask, how to use SIGQUIT? regards - Original Message - From: farhad [EMAIL PROTECTED] To: Tomcat Users List tomcat-user@jakarta.apache.org Sent: Wednesday, April 20, 2005 9:50 AM Subject: Re: All threads (250) are currently busy I don't know what kind of application you are running, but most likely you have a resource leak; Do a thread dump and see what your threads are waiting for. Most likely they are just in wait state and no CPU usage. It could be cause by lots of things. One problem could be using jdbc and not closing your connection or returning it to your pool. For testing reduce your resource limit, don't increase it (reduce Max thread, and connection pool). This would cause system hangs faster. Send a SIGQUIT signal to VM and look at state of your threads and its location (don't post your thread dump!) Paul Grimwood wrote: Tomcat hangs intermittently (1 to 10 days) with the following message in catalina.out 20/04/2005 13:48:09 org.apache.tomcat.util.threads.ThreadPool logFull SEVERE: All threads (250) are currently busy, waiting. Increase maxThreads (250) or check the servlet status We are running tomcat 5.5.7 on jdk1.5.0_02 under Redhat Linux Fedora Core 2 against an Oracle9 DB. I have seen various posts to this with suggestions including setting Linux threads with LD_ASSUME_KERNEL (tried but problem still exists) and setting connection timeout in server.xml from 0 to 6 (but ours is set at 2 already). And we have already upgraded to latest Tomcat and JRE to no avail. Despite reviewing the mailing list over the past 18 to 24 months, i am none the wiser. The problem started around the time we deployed the code onto a new server running a later Linux version but this could be a red herring and I suspect it is a database connection issue. Has anyone got any ideas? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: All threads (250) are currently busy
I forgot to say that I'm using windows not linux - Original Message - From: Fadwa Barham [EMAIL PROTECTED] To: Tomcat Users List tomcat-user@jakarta.apache.org Sent: Wednesday, April 20, 2005 11:36 AM Subject: Re: All threads (250) are currently busy Hi, I have the same problem, I read the reply, and I want to ask, how to use SIGQUIT? regards - Original Message - From: farhad [EMAIL PROTECTED] To: Tomcat Users List tomcat-user@jakarta.apache.org Sent: Wednesday, April 20, 2005 9:50 AM Subject: Re: All threads (250) are currently busy I don't know what kind of application you are running, but most likely you have a resource leak; Do a thread dump and see what your threads are waiting for. Most likely they are just in wait state and no CPU usage. It could be cause by lots of things. One problem could be using jdbc and not closing your connection or returning it to your pool. For testing reduce your resource limit, don't increase it (reduce Max thread, and connection pool). This would cause system hangs faster. Send a SIGQUIT signal to VM and look at state of your threads and its location (don't post your thread dump!) Paul Grimwood wrote: Tomcat hangs intermittently (1 to 10 days) with the following message in catalina.out 20/04/2005 13:48:09 org.apache.tomcat.util.threads.ThreadPool logFull SEVERE: All threads (250) are currently busy, waiting. Increase maxThreads (250) or check the servlet status We are running tomcat 5.5.7 on jdk1.5.0_02 under Redhat Linux Fedora Core 2 against an Oracle9 DB. I have seen various posts to this with suggestions including setting Linux threads with LD_ASSUME_KERNEL (tried but problem still exists) and setting connection timeout in server.xml from 0 to 6 (but ours is set at 2 already). And we have already upgraded to latest Tomcat and JRE to no avail. Despite reviewing the mailing list over the past 18 to 24 months, i am none the wiser. The problem started around the time we deployed the code onto a new server running a later Linux version but this could be a red herring and I suspect it is a database connection issue. Has anyone got any ideas? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
war deployment problem
Hi, Sometimes when I update the war file on my tomcat 5.5.7 application, tomcat attempts to deploy the application before it has finished being transferred to the server resulting in the follow error. Can I do anything about this?? ERROR ContainerBackgroundProcessor[StandardEngine[Catalina]] org.apache.catalina.startup.HostConfig - Error deployin g web application archive web.war java.lang.InternalError: jzentry == 0, jzfile = 7513064, total = 241, name = /www/webapps/web.war, i = 74, message = invalid LOC header (bad signature) at java.util.zip.ZipFile$3.nextElement(ZipFile.java:430) at java.util.zip.ZipFile$3.nextElement(ZipFile.java:416) at java.util.jar.JarFile$1.nextElement(JarFile.java:214) at java.util.jar.JarFile$1.nextElement(JarFile.java:213) at org.apache.catalina.startup.ExpandWar.expand(ExpandWar.java:139) at org.apache.catalina.startup.ContextConfig.fixDocBase(ContextConfig.java:793) at org.apache.catalina.startup.ContextConfig.init(ContextConfig.java:905) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java: 255) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSuppor t.java:119) at org.apache.catalina.core.StandardContext.init(StandardContext.java:5035) at org.apache.catalina.core.StandardContext.start(StandardContext.java:3852) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:7 59) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524) at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:800) at at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processC hildren(ContainerBase.java:15 thx. Steve. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
AW: All threads (250) are currently busy
We had the same problem, but after configuring the apache connector correctly the problem disappeared. Zsolt -Ursprüngliche Nachricht- Von: Paul Grimwood [mailto:[EMAIL PROTECTED] Gesendet: Mittwoch, 20. April 2005 06:07 An: tomcat-user@jakarta.apache.org Betreff: All threads (250) are currently busy Tomcat hangs intermittently (1 to 10 days) with the following message in catalina.out 20/04/2005 13:48:09 org.apache.tomcat.util.threads.ThreadPool logFull SEVERE: All threads (250) are currently busy, waiting. Increase maxThreads (250) or check the servlet status We are running tomcat 5.5.7 on jdk1.5.0_02 under Redhat Linux Fedora Core 2 against an Oracle9 DB. I have seen various posts to this with suggestions including setting Linux threads with LD_ASSUME_KERNEL (tried but problem still exists) and setting connection timeout in server.xml from 0 to 6 (but ours is set at 2 already). And we have already upgraded to latest Tomcat and JRE to no avail. Despite reviewing the mailing list over the past 18 to 24 months, i am none the wiser. The problem started around the time we deployed the code onto a new server running a later Linux version but this could be a red herring and I suspect it is a database connection issue. Has anyone got any ideas? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Multiple services in single Tomcat instance
Try this Service name=RequestsFromPort6000 Connector protocol=HTTP/1.1 port=6000/ Engine debug=0 defaultHost=localhost name=Standalone Host appBase=c:\projects name=localhost unpackWARs=false autoDeploy=false deployOnStartup=false Context docBase=app6000 path=/app6000 reloadable=false/ /Host /Engine /Service Service name=RequestsFromPort7000 Connector protocol=HTTP/1.1 port=7000/ Engine debug=0 defaultHost=localhost name=Standalone Host appBase=c:\projects name=localhost unpackWARs=false autoDeploy=false deployOnStartup=false Context docBase=app7000 path=/app7000 reloadable=false/ /Host /Engine /Service -Original Message- From: Gary Hirschhorn [mailto:[EMAIL PROTECTED] Sent: 19 April 2005 16:58 To: Tomcat Users List Subject: RE: Multiple services in single Tomcat instance We are using all of the following URL formats to access Tomcat. There is a singe IP address on the machine, and a single domain name registered for the IP address. http://localhost:6000/app6000 http://localhost:7000/app7000 http://machinename.hostname.com:6000/app6000 http://machinename.hostname.com:7000/app7000 -Original Message- From: Raghupathy,Gurumoorthy [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 19, 2005 7:56 AM To: 'Tomcat Users List' Subject: RE: Multiple services in single Tomcat instance How are you accessing tomcat ? http://localhost:7000/ http://localhost:6000/ ??? -Original Message- From: Gary Hirschhorn [mailto:[EMAIL PROTECTED] Sent: 19 April 2005 15:34 To: tomcat-user@jakarta.apache.org Subject: Multiple services in single Tomcat instance We would like to have a single Tomcat instance running as a web server that allows requests received on one port to go to one context and requests on another port to go to a second context. Is there a way to do this? We tried putting the following in our server.xml, but requests meant for the first service (port 6000) were recieved by the second service (port 7000). Thank you for any help. Service name=RequestsFromPort6000 Connector protocol=HTTP/1.1 port=6000/ Engine debug=0 defaultHost=localhost name=Standalone Host appBase=c:/projects name=localhost unpackWARs=false autoDeploy=false deployOnStartup=false Context docBase=/app6000 path=/app6000 reloadable=false/ /Host /Engine /Service Service name=RequestsFromPort7000 Connector protocol=HTTP/1.1 port=7000/ Engine debug=0 defaultHost=localhost name=Standalone Host appBase=c:/projects name=localhost unpackWARs=false autoDeploy=false deployOnStartup=false Context docBase=/app7000 path=/app7000 reloadable=false/ /Host /Engine /Service - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
SingleSignOn and Form Authentication
Hello ! I'm using SSO and Form authentication. Most of it works just fine. The only problem I have, is that I have to have the login form in both apps. Every time I change it, I have to update it in two places. I use the following code in web.xml : login-config auth-methodFORM/auth-method realm-nameSIEMS-ds/realm-name form-login-config form-login-page/login.jsp/form-login-page form-error-page/loginError.jsp/form-error-page /form-login-config /login-config I'd like to use something like : form-login-page../otherServlet/login.jsp/form-login-page Or any other way to have the login form only in one place. Is there a possibility ? Thanks for your help ! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: All threads (250) are currently busy
what's the correct configuration of the connector? Regards - Original Message - From: Zsolt Koppany [EMAIL PROTECTED] To: 'Tomcat Users List' tomcat-user@jakarta.apache.org Sent: Wednesday, April 20, 2005 11:08 AM Subject: AW: All threads (250) are currently busy We had the same problem, but after configuring the apache connector correctly the problem disappeared. Zsolt -Ursprüngliche Nachricht- Von: Paul Grimwood [mailto:[EMAIL PROTECTED] Gesendet: Mittwoch, 20. April 2005 06:07 An: tomcat-user@jakarta.apache.org Betreff: All threads (250) are currently busy Tomcat hangs intermittently (1 to 10 days) with the following message in catalina.out 20/04/2005 13:48:09 org.apache.tomcat.util.threads.ThreadPool logFull SEVERE: All threads (250) are currently busy, waiting. Increase maxThreads (250) or check the servlet status We are running tomcat 5.5.7 on jdk1.5.0_02 under Redhat Linux Fedora Core 2 against an Oracle9 DB. I have seen various posts to this with suggestions including setting Linux threads with LD_ASSUME_KERNEL (tried but problem still exists) and setting connection timeout in server.xml from 0 to 6 (but ours is set at 2 already). And we have already upgraded to latest Tomcat and JRE to no avail. Despite reviewing the mailing list over the past 18 to 24 months, i am none the wiser. The problem started around the time we deployed the code onto a new server running a later Linux version but this could be a red herring and I suspect it is a database connection issue. Has anyone got any ideas? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Using digester
Hello all, I read the digester documentation and I well understand how to create a digester to read an XML file. It not seems to be very difficult. But I have 2 questions without answers: 1 - Where I indicate the XML file that my digester needs to read? 2 - Once it's done, how can I retrieve the needed value from my XML file into my code??? Hope someone can help me Regards, Manuel This e-mail and any attachment is for authorised use by the intended recipient(s) only. It may contain proprietary material, confidential information and/or be subject to legal privilege. It should not be copied, disclosed to, retained or used by, any other party. If you are not an intended recipient then please promptly delete this e-mail and any attachment and all copies and inform the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Many hosts sharing servlets
Please post a *new* message when writing to the list. Replying to an old (unrelated) message confuses thread-aware mailers, which makes your question harder to find (and thus answer). On Wed, Apr 20, 2005 at 05:06:00PM +1000, Bill Sutton wrote: : I have 100+ servlets and classes that I want to be available to up to 100 : virtual hosts. : So I have tried to put all the classes into /var/tomcat4/shared/classes. : In each host, I deploy a servlets.war file that contains only the following : [snip: web.xml with Invoker servlet] : Questions : Is there a better way to do this ? Better depends on your goals, but most a lot of people would say that using the invoker has its pros and cons. Mostly cons. =) (See the archives for why.) You could just JAR up the 100+ servlet classes and drop them in each webapp's WEB-INF/lib. Next, write something to create a set of proper servlet/ and servlet-mapping/ entries for those servlets. This is a one-time hit that will pay off long-term. : Will tomcat be using hugely more memory than jserv was ? Depends on your app. Only a load test + profiling will let you know. -QM -- software -- http://www.brandxdev.net/ tech news -- http://www.RoarNetworX.com/ code scan -- http://www.JxRef.org/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Connectors
http://jakarta.apache.org/tomcat/faq/ http://jakarta.apache.org/tomcat/connectors-doc/ -Tim edwin roberts wrote: Greetings, I need some help on testing. Please advise which connector i should use for apache 2.044 and tomcat 4.1.24. If possible, a link to a installation guide will be helpful. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OutOfMemoryError - 100 thread limit?
There are no limits in tomcat. http://jakarta.apache.org/tomcat/faq/memory.html -Tim LeeAnn Pultz wrote: I have a tomcat server with multiple copies of our web application running. We are running into what seems to be a hard-coded limit on the number of threads available to the Tomcat application. I have added code to our servlet class which prints out the number of active threads whenever I initialize the servlet. On Red Hat Linux boxes, whenever we start up enough copies of the servlet to hit 100 active threads, we reach an OutOfMemoryError - regardless of the Xms/Xmx settings (memory profiling shows that we have plenty of memory available). On Windows XP, 50 seems to be the magic number. I have tried tweaking Xss parameters, my ulimit command in Linux shows unlimited - and I have reached the same results with Tomcat 3.3.1, 4.0.28 and 5.0.28 using Java 1.4.1 and 1.4.2. When I use WebLogic 8.1 on the same Linux box, I reach 241 active threads with no problems whatsoever (stopped my testing at that number) so it does not seem to be an o/s limitation, or a java limitation - which leads me to believe there is something in Tomcat? Is the number of threads available to tomcat hard coded somewhere? Is there a parameter or configuration setting that I can change to increase this? If this question is better off posted to the developers list, please someone, let me know :) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Static field memory leak on application reload
There still might be other references keeping the class alive (Like a logging package) Some have gone as far as calling Introspector.flushCaches() http://java.sun.com/j2se/1.4.2/docs/api/java/beans/Introspector.html#flushCaches() -Tim Otgonbayar wrote: I am using some static fields in my beans, but when I am reloading application the blocks were referenced by static fields still stays in memory. I detected these using a profiler tool. I wrote a context listener to free these blocks on destroy. But it doesn't help? So what can I do? Please help me - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OutOfMemoryError - 100 thread limit?
I'm able to go up to 647 threads and 500 concurrent connections with 5.5.4 without any problems. chances are, it's a memory leak in the webapp. only way to know for sure is to profile the application. peter lin On 4/20/05, Tim Funk [EMAIL PROTECTED] wrote: There are no limits in tomcat. http://jakarta.apache.org/tomcat/faq/memory.html -Tim LeeAnn Pultz wrote: I have a tomcat server with multiple copies of our web application running. We are running into what seems to be a hard-coded limit on the number of threads available to the Tomcat application. I have added code to our servlet class which prints out the number of active threads whenever I initialize the servlet. On Red Hat Linux boxes, whenever we start up enough copies of the servlet to hit 100 active threads, we reach an OutOfMemoryError - regardless of the Xms/Xmx settings (memory profiling shows that we have plenty of memory available). On Windows XP, 50 seems to be the magic number. I have tried tweaking Xss parameters, my ulimit command in Linux shows unlimited - and I have reached the same results with Tomcat 3.3.1, 4.0.28 and 5.0.28 using Java 1.4.1 and 1.4.2. When I use WebLogic 8.1 on the same Linux box, I reach 241 active threads with no problems whatsoever (stopped my testing at that number) so it does not seem to be an o/s limitation, or a java limitation - which leads me to believe there is something in Tomcat? Is the number of threads available to tomcat hard coded somewhere? Is there a parameter or configuration setting that I can change to increase this? If this question is better off posted to the developers list, please someone, let me know :) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using digester
On Wed, Apr 20, 2005 at 12:02:44PM +0200, Henrique, Manuel wrote: : 1 - Where I indicate the XML file that my digester needs to read? : 2 - Once it's done, how can I retrieve the needed value from my XML file : into my code??? Which Digester documentation did you read? It's been a while, but I recall these points are explained (either in the main docs or in the various Digester articles on the web). The short version: 1/ Digester#parse() 2/ Digester#parse() -QM -- software -- http://www.brandxdev.net/ tech news -- http://www.RoarNetworX.com/ code scan -- http://www.JxRef.org/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: SingleSignOn and Form Authentication
Hi, are you able to redirect after login. ? Shalu Rajkumar Gupta Tata Consultancy Services Limited Ph:- 020 4042631 Mailto: [EMAIL PROTECTED] Website: http://www.tcs.com Guillaume Lederrey [EMAIL PROTECTED] 04/20/2005 02:58 PM Please respond to Tomcat Users List tomcat-user@jakarta.apache.org To Tomcat Users List tomcat-user@jakarta.apache.org cc Subject SingleSignOn and Form Authentication Hello ! I'm using SSO and Form authentication. Most of it works just fine. The only problem I have, is that I have to have the login form in both apps. Every time I change it, I have to update it in two places. I use the following code in web.xml : login-config auth-methodFORM/auth-method realm-nameSIEMS-ds/realm-name form-login-config form-login-page/login.jsp/form-login-page form-error-page/loginError.jsp/form-error-page /form-login-config /login-config I'd like to use something like : form-login-page../otherServlet/login.jsp/form-login-page Or any other way to have the login form only in one place. Is there a possibility ? Thanks for your help ! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] ForwardSourceID:NTD0CE Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the information contained in this e-mail message and/or attachments to it are strictly prohibited. If you have received this communication in error, please notify us by reply e-mail or telephone and immediately and permanently delete the message and any attachments. Thank you
Re: Many hosts sharing servlets
Thanks for your quick reply. Yes I have read the pros cons and I would prefer not to use the invoker but the work in updating many webapps each time a servlet changes is daunting, particularly using Plesk. Bill - Original Message - From: QM [EMAIL PROTECTED] To: Tomcat Users List tomcat-user@jakarta.apache.org Sent: Wednesday, April 20, 2005 8:48 PM Subject: Re: Many hosts sharing servlets On Wed, Apr 20, 2005 at 05:06:00PM +1000, Bill Sutton wrote: : I have 100+ servlets and classes that I want to be available to up to 100 : virtual hosts. : So I have tried to put all the classes into /var/tomcat4/shared/classes. : In each host, I deploy a servlets.war file that contains only the following : [snip: web.xml with Invoker servlet] : Questions : Is there a better way to do this ? Better depends on your goals, but most a lot of people would say that using the invoker has its pros and cons. Mostly cons. =) (See the archives for why.) You could just JAR up the 100+ servlet classes and drop them in each webapp's WEB-INF/lib. Next, write something to create a set of proper servlet/ and servlet-mapping/ entries for those servlets. This is a one-time hit that will pay off long-term. : Will tomcat be using hugely more memory than jserv was ? Depends on your app. Only a load test + profiling will let you know. -QM -- software -- http://www.brandxdev.net/ tech news -- http://www.RoarNetworX.com/ code scan -- http://www.JxRef.org/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 5.5.9 Connection Pool / JNDI / DBCP
You should be doing this in your code: Context initContext = null; try { initContext = new InitialContext() ; } catch ( Exception e1 ) { //... do something with the trapped exception } try { DataSource ds = (DataSource)initContext.lookup(java:/comp/env/jdbc/testdatabase); } catch ( Exception e2) { //... do something -- log it } // Store a reference to ds someplace where it can be used over and over and over. Note the only thing I really changed is to make the type of initContext Context instead of InitialContext. This is mostly straight from the Tomcat 5.5 JNDI docs located here: http://jakarta.apache.org/tomcat/tomcat-5.5-doc/jndi-resources-howto.html --David Lars Nielsen Lind wrote: Hi. I have some problems with Tomcat 5.5.9 Connection Pooling / JNDI / DBCP When running my java component (se below) I receive this NamingException: /NE: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial/ If I add this code: System.setProperty(java.naming.factory.initial, org.apache.naming.java.javaURLContextFactory); System.setProperty(java.naming.factory.pkgs, org.apache.naming); to the constructor in the java component, I receive this exception: /NE: Name java: is not bound in this Context/ What is wrong and what is the solution to the problem? Thanks Lars Nielsen Lind I have copied the PostgreSQL driver, commons-pool.jar, commons-collections.jar and commons-dbcp.jar to the $CATALINA_HOME/common/lib folder. I have done as specified in the JNDI Datasource HOW-TO. *Server.xml*: Context path=/ debug=1 docBase=/opt/jakarta-tomcat-5.5.9/webapps/application/test !-- PostgreSQL / JDBC / JNDI - ConnectionPooling -- Resource name=jdbc/testdatabase auth=Container type=javax.sql.DataSource driverClassName=org.postgresql.Driver url=jdbc:postgresql://localhost/testdatabase username=dbmanager password=123456 maxActive=20 maxIdle=10 maxWait=-1 removeAbandoned=true removeAbandonedTimeout=60 logAbandoned=true / /Context *Application Web.xml*: resource-ref descriptionPostgreSQL DataSource/description res-ref-namejdbc/testdatabase/res-ref-name res-typejavax.sql.DataSource/res-type res-authContainer/res-auth /resource-ref *Java component*: import java.sql.*; import java.util.*; import javax.naming.*; import javax.sql.*; public class ConnectionPool { private Connection conn; public ConnectionPool() {} public Connection getConnectionFromPool() { try { InitialContext initContext = null; try { initContext = new InitialContext(); } catch (Exception ex) { System.out.println(IC: + ex); } try { DataSource ds = (DataSource)initContext.lookup(java:/comp/env/jdbc/testdatabase); conn = ds.getConnection(); } catch (SQLException se) { System.out.println(DS: + se); } } catch (NamingException ne) { System.out.println(NE: + ne.getMessage()); } return conn; } - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Can't get Tomcat to use account other than System
In addition to Logon as a service, the account will also need to Act as part of the operating system. Again, these are the two minimum requirements. Depending on what you're trying to access, you may need to assign additional user rights. Darryl --- Mark Leone [EMAIL PROTECTED] wrote: Thanks. That's useful information, but unfortunately it didn't solve my problem. The account I'm trying to use was already mapped to the Logon as a Service right. I looked at all other rights that didn't have either the account or its group mapped to them, and I couldn't see any that seemed to be needed. I searched through the MS knowledge base as well, and didn't find anything relevant to this problem. I found a better way to accomplish what I was trying to do; but I'd like to find out why I can't run Tomcat as an account other than System, in case I have a need for it at some later point. Thanks for trying. Darryl Wilburn wrote: In Administrative Tools, go to Local Security Policy and navigate to Local Policies User Rights Assignment. This lists all the assignable user rights. At the very least, this account will need to be assigned to Logon On as a Service. Don't mess around with the Net Logon service. The only service you need to mess with is Apache Tomcat. The other services aren't broken, so don't try to fix them. You might also consider looking here: http://support.microsoft.com/default.aspx?scid=fh;EN-US;kbhowtosd=TECHln=EN-USFR=0 Darryl --- Mark Leone [EMAIL PROTECTED] wrote: Can you tell me how to check for that? The only options I can find for defining account properties are in Control Panel -- Users and Administrative Tools -- Computer Management; and neither of those have any settings beyond very basic things like Admin vs. limited priviliges. I played around a bit with the Net Logon service. I specified the desired account credentials in the Log On tab of the Service Properties, and then when I tried to start the service I got the following error. Could Not start the Net Logon service on local computer. Error 1079: The accout specified for this service is different from the account specified for other services running in the same process. Not sure what to make of this, or if I'm barking up the wrong tree. Please enlighten me. Darryl Wilburn wrote: Mark, Does the account you're trying to use have all the correct user rights (act as part of the operating system, run as a service, etc.)? Darryl --- Mark Leone [EMAIL PROTECTED] wrote: I think this is a pretty basic question, but I couldn't find an answer in the archives. I've been using Tomcat for a while, with Tomcat logging on as the local System account. Now I'd like Tomcat to have some additional access rights, so I'm trying to get it to log on as a privileged user. I have Tomcat 5.5.8 installed as a Service on Windows XP. I launch the Service properties window, go to the Log On tab, check the This Account radio button, and then enter the account credentials. The credentials seem to be accepted, but if I close the Service properties window and re-launch it, the Log On tab has reverted to its default configuration, i.e. Log on as Local System Account is enabled instead of the account I specified. And Tomcat doesn't have the access rights I'd like it to have, even after restart. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] __ Yahoo! Mail Mobile Take Yahoo! Mail with you! Check email on your mobile phone. http://mobile.yahoo.com/learn/mail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] __ Do you Yahoo!? Plan great trips with Yahoo! Travel: Now over 17,000 guides! http://travel.yahoo.com/p-travelguide - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL
Re: SingleSignOn and Form Authentication
On 4/20/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Hi, are you able to redirect after login. ? I'm not sure I understand the question ... The default FORM authentication redirects after the login to the page initially requested. I think I would more need to redirect BEFORE login to get to the right login page ... Sorry if I understood your question completely wrong ... it's not on purpose ! Guillaume - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: jk 1.2.10 + apache 1.3 issue
Guernsey, Byron (GE Consumer Industrial) wrote: It uses a urimap.properties file instead of JkMounts. OK. The config directives in httpd.conf look like: IfDefine MOD_JK JkLogLeveldebug JkShmSize 300 JkShmFile /usr/local/apache/logs/jk1-ssodev.shm JkWorkersFile /usr/local/apache/conf/workers_sso.properties JkMountFile /usr/local/apache/conf/uriworkermap_sso.properties JkLogFile /usr/local/apache/logs/mod_jk-ssodev.log JkLogStampFormat [%a %b %d %H:%M:%S %Y] JkRequestLogFormat %w %V %T Location /jkstatus/ JkMount jkstatus Order deny,allow Deny from all Allow from 3. Allow from 127. /Location /IfDefine As you can see from my previous posting, not even jkstatus works, nor do any workers. Yet, they are configured properly and the jk log shows that it finds them: Well, just try the worker names without a colon. The reason for why we are forcing the alnum chars only is because the special chars needs to be url encoded if the client does not support the cookies. So it's easier and safer anyhow to rename the jvmRoutes in server.xml. Also for jkstatus. If you are calling that from some virtual host, you will need to have 'JkMountCopy On' directive in root, or define the Location in that virtual host. Also any workers.propeties directive should not exceed the 1024 chars. Regards, Mladen. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Running two tomcat in the same time
Hello All, I have a question but before that let me give you a brief about our setup: We have tomcat 5.0.24. It is installed on Solaris 8 under user root using the port 80; we installed another tomcat instance under different directory and different user (username: tomcat) and new port 8080. The problem is we couldn't run both of them in the same time, if we start one of them the other one will stop???!!! Do we have to do any customization in the configuration?? Thanks and Regards, Dani Al-Hasan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Heap not expanding beyond -Xms512m
Hello Tomcat-oids, I'd really appreciate any help with this...Thanks in advance. We've been running performance tests against Tomcat 4.1.26 on Linux and Windows. We've tuned heap sizes to -Xms512m -Xmx1024m. Monitoring the JVM memory usage with a daemon thread calling Runtime.getRuntime().freeMemory() / totalMemory() / maxMemory(), we've noticed memory was never expanded beyond 512MB. Instead, when usage was getting close to 512MB, we could see the garbage collector kick in. We never got OOM errors. Can anyone share experiences about this? Do I have to use -Xms1024m -Xmx1024m (which seems to defeat the purpose of having ms and mx...)? Guillaume - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Heap not expanding beyond -Xms512m
This is expected behaviour. The heap will not grow if the memory required can be gained through a garbage collection. The heap will only grow if after a garbage collection it still cannot allocate the required memory or is over a certain percentage (I forget what the default is). I would suggest that you don't in fact need 512MB if your app runs fine with no OOM in 512MB. If you really want to use the full 1GB the you'll have to use -Xms as you suggested. Ta Matt -Original Message- From: Guillaume Lahitette [mailto:[EMAIL PROTECTED] Sent: 20 April 2005 13:54 To: tomcat-user@jakarta.apache.org Subject: Heap not expanding beyond -Xms512m Hello Tomcat-oids, I'd really appreciate any help with this...Thanks in advance. We've been running performance tests against Tomcat 4.1.26 on Linux and Windows. We've tuned heap sizes to -Xms512m -Xmx1024m. Monitoring the JVM memory usage with a daemon thread calling Runtime.getRuntime().freeMemory() / totalMemory() / maxMemory(), we've noticed memory was never expanded beyond 512MB. Instead, when usage was getting close to 512MB, we could see the garbage collector kick in. We never got OOM errors. Can anyone share experiences about this? Do I have to use -Xms1024m -Xmx1024m (which seems to defeat the purpose of having ms and mx...)? Guillaume - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Heap not expanding beyond -Xms512m
I agree, it's always a good idea to let the JVM do what it is supposed to do instead of creating a growing overhead. The only exception to that rule is if you think you'll reach 1024 MB, but as you say yourself, 512 seems to do fine as -Xms. btw, here is an article that goes into detail (ratio's etc.) using jvm 1.4.2 http://java.sun.com/docs/hotspot/gc1.4.2/index.html Q -Original Message- From: Dale, Matt [mailto:[EMAIL PROTECTED] Sent: 20 April 2005 15:24 To: Tomcat Users List Subject: RE: Heap not expanding beyond -Xms512m This is expected behaviour. The heap will not grow if the memory required can be gained through a garbage collection. The heap will only grow if after a garbage collection it still cannot allocate the required memory or is over a certain percentage (I forget what the default is). I would suggest that you don't in fact need 512MB if your app runs fine with no OOM in 512MB. If you really want to use the full 1GB the you'll have to use -Xms as you suggested. Ta Matt -Original Message- From: Guillaume Lahitette [mailto:[EMAIL PROTECTED] Sent: 20 April 2005 13:54 To: tomcat-user@jakarta.apache.org Subject: Heap not expanding beyond -Xms512m Hello Tomcat-oids, I'd really appreciate any help with this...Thanks in advance. We've been running performance tests against Tomcat 4.1.26 on Linux and Windows. We've tuned heap sizes to -Xms512m -Xmx1024m. Monitoring the JVM memory usage with a daemon thread calling Runtime.getRuntime().freeMemory() / totalMemory() / maxMemory(), we've noticed memory was never expanded beyond 512MB. Instead, when usage was getting close to 512MB, we could see the garbage collector kick in. We never got OOM errors. Can anyone share experiences about this? Do I have to use -Xms1024m -Xmx1024m (which seems to defeat the purpose of having ms and mx...)? Guillaume - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Heap not expanding beyond -Xms512m
Ooops, I meant -Xmx512 ;) -Original Message- From: Quinten Verheyen Sent: 20 April 2005 15:32 To: 'Tomcat Users List' Subject: RE: Heap not expanding beyond -Xms512m I agree, it's always a good idea to let the JVM do what it is supposed to do instead of creating a growing overhead. The only exception to that rule is if you think you'll reach 1024 MB, but as you say yourself, 512 seems to do fine as -Xms. btw, here is an article that goes into detail (ratio's etc.) using jvm 1.4.2 http://java.sun.com/docs/hotspot/gc1.4.2/index.html Q -Original Message- From: Dale, Matt [mailto:[EMAIL PROTECTED] Sent: 20 April 2005 15:24 To: Tomcat Users List Subject: RE: Heap not expanding beyond -Xms512m This is expected behaviour. The heap will not grow if the memory required can be gained through a garbage collection. The heap will only grow if after a garbage collection it still cannot allocate the required memory or is over a certain percentage (I forget what the default is). I would suggest that you don't in fact need 512MB if your app runs fine with no OOM in 512MB. If you really want to use the full 1GB the you'll have to use -Xms as you suggested. Ta Matt -Original Message- From: Guillaume Lahitette [mailto:[EMAIL PROTECTED] Sent: 20 April 2005 13:54 To: tomcat-user@jakarta.apache.org Subject: Heap not expanding beyond -Xms512m Hello Tomcat-oids, I'd really appreciate any help with this...Thanks in advance. We've been running performance tests against Tomcat 4.1.26 on Linux and Windows. We've tuned heap sizes to -Xms512m -Xmx1024m. Monitoring the JVM memory usage with a daemon thread calling Runtime.getRuntime().freeMemory() / totalMemory() / maxMemory(), we've noticed memory was never expanded beyond 512MB. Instead, when usage was getting close to 512MB, we could see the garbage collector kick in. We never got OOM errors. Can anyone share experiences about this? Do I have to use -Xms1024m -Xmx1024m (which seems to defeat the purpose of having ms and mx...)? Guillaume - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Running two tomcat in the same time
From: Dani Al-Hasan [mailto:[EMAIL PROTECTED] Subject: Running two tomcat in the same time We have tomcat 5.0.24. It is installed on Solaris 8 under user root using the port 80; we installed another tomcat instance under different directory and different user (username: tomcat) and new port 8080. You also have to configure a different shutdown port (the port attribute at the beginning of the Server part of server.xml). - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: can't see a tomcat installation on home network
Nikola Milutinovic wrote: Try SSH, instead of Telnet. Download PuTTY and install it. Sheesh, no, don't confuse the issue. This is not about the OP trying to open a shell on a remote system, it's about *using telnet* as a command-line tool to try to connect to an arbitrary remote port -- in this case port 8080, (hopefully) opened by Tomcat. SSH isn't part of this picture. FWIW! -- Hassan Schroeder - [EMAIL PROTECTED] Webtuitive Design === (+1) 408-938-0567 === http://webtuitive.com dream. code. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
using manager with apache virtual host
Hi, I have a Jakarta 5.0.28 standalone and manager is working just fine. when I try to operate manager (on Solaris 9) with Jakarta connected to apache 2. the apache is redirecting the requests to the apache webapp root. How can I use manager with apache virtual host? Regards, Amir S
RE: can't see a tomcat installation on home network
Yes, this is what I wanted to convey telnet to linux mahcine on port 8080 to check if it responding -Original Message- From: Hassan Schroeder [mailto:[EMAIL PROTECTED] Sent: 20 April 2005 15:00 To: Tomcat Users List Subject: Re: can't see a tomcat installation on home network Nikola Milutinovic wrote: Try SSH, instead of Telnet. Download PuTTY and install it. Sheesh, no, don't confuse the issue. This is not about the OP trying to open a shell on a remote system, it's about *using telnet* as a command-line tool to try to connect to an arbitrary remote port -- in this case port 8080, (hopefully) opened by Tomcat. SSH isn't part of this picture. FWIW! -- Hassan Schroeder - [EMAIL PROTECTED] Webtuitive Design === (+1) 408-938-0567 === http://webtuitive.com dream. code. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
To find user name
Hi All, Could any one of you please let me know how to get the username? For example, let's assume that I use BASIC authentication to authorize the users of my site and I have a user who has logged in successfully. During the coarse of this user's session, if I need to know the username with which he logged in then what should I do? Is it stored in the session object? Or should we build a customized code such as a ServletFilter to trap the username/password? Any suggestions will be of great help to me. Thanks, VinodRamu - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: To find user name
request.getRemoteUser() Please read the spec -Original Message- From: Ramu, Vinod [mailto:[EMAIL PROTECTED] Sent: 20 April 2005 15:17 To: tomcat-user@jakarta.apache.org Subject: To find user name Hi All, Could any one of you please let me know how to get the username? For example, let's assume that I use BASIC authentication to authorize the users of my site and I have a user who has logged in successfully. During the coarse of this user's session, if I need to know the username with which he logged in then what should I do? Is it stored in the session object? Or should we build a customized code such as a ServletFilter to trap the username/password? Any suggestions will be of great help to me. Thanks, VinodRamu - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Running two tomcat in the same time
Thanks .now it is perfect.. Best Regards, Dani Al-Hasan _ From: Tomcat Users List [mailto:[EMAIL PROTECTED] Sent: Wednesday, 20 April, 2005 4:55 PM To: Tomcat Users List tomcat-user@jakarta.apache.org Subject: RE: Running two tomcat in the same time Importance: Low From: Dani Al-Hasan [mailto:[EMAIL PROTECTED] Subject: Running two tomcat in the same time We have tomcat 5.0.24. It is installed on Solaris 8 under user root using the port 80; we installed another tomcat instance under different directory and different user (username: tomcat) and new port 8080. You also have to configure a different shutdown port (the port attribute at the beginning of the Server part of server.xml). - 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: [EMAIL PROTECTED] mailto: For additional commands, e-mail: [EMAIL PROTECTED] mailto:
RE: using manager with apache virtual host
Send me the httpd.conf -Original Message- From: Amir S [mailto:[EMAIL PROTECTED] Sent: 20 April 2005 16:02 To: tomcat-user@jakarta.apache.org Subject: using manager with apache virtual host Hi, I have a Jakarta 5.0.28 standalone and manager is working just fine. when I try to operate manager (on Solaris 9) with Jakarta connected to apache 2. the apache is redirecting the requests to the apache webapp root. How can I use manager with apache virtual host? Regards, Amir S - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: To find user name
request.getRemoteUser(); - --- Original Message --- - From: Ramu, Vinod [EMAIL PROTECTED] To: tomcat-user@jakarta.apache.org Sent: Wed, 20 Apr 2005 10:16:36 Hi All, Could any one of you please let me know how to get the username? For example, let's assume that I use BASIC authentication to authorize the users of my site and I have a user who has logged in successfully. During the coarse of this user's session, if I need to know the username with which he logged in then what should I do? Is it stored in the session object? Or should we build a customized code such as a ServletFilter to trap the username/password? Any suggestions will be of great help to me. Thanks, VinodRamu --- -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: To find user name
Thanks guys..life is so easy :-) -Original Message- From: Darren Govoni [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 20, 2005 10:23 AM To: tomcat-user@jakarta.apache.org Subject: RE: To find user name request.getRemoteUser(); - --- Original Message --- - From: Ramu, Vinod [EMAIL PROTECTED] To: tomcat-user@jakarta.apache.org Sent: Wed, 20 Apr 2005 10:16:36 Hi All, Could any one of you please let me know how to get the username? For example, let's assume that I use BASIC authentication to authorize the users of my site and I have a user who has logged in successfully. During the coarse of this user's session, if I need to know the username with which he logged in then what should I do? Is it stored in the session object? Or should we build a customized code such as a ServletFilter to trap the username/password? Any suggestions will be of great help to me. Thanks, VinodRamu --- -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Server Side include won't work from root context
I am trying to get server side includes to work across app contexts in Tomcat 5.5.4 My ROOT webapp has the file includer/do_include.shtml The content is: html head link rel =stylesheet type=text/css href=style.css /head body table style=color: #ff9900 tr tdh2This page shows the use of the SSI/h2/td /tr /table table style=border:1px solid; tr td !--#include virtual=/test/index.jsp -- /td /tr /table /body /html The application context test is deployed. If you type http://localhost:8080/test/, the content of index.jsp shows. Finally, SSI functionality has been turned on in TOMCAT_HOME/conf/web.xml: servlet servlet-namessi/servlet-name servlet-class org.apache.catalina.ssi.SSIServlet /servlet-class init-param param-namebuffered/param-name param-value1/param-value /init-param init-param param-namedebug/param-name param-value5/param-value /init-param init-param param-nameexpires/param-name param-value666/param-value /init-param init-param param-nameisVirtualWebappRelative/param-name param-value0/param-value /init-param load-on-startup4/load-on-startup /servlet and servlet-mapping servlet-namessi/servlet-name url-pattern*.shtml/url-pattern /servlet-mapping When I go try to do the Server include using http://localhost/includer/do_include.shtml, I get [an error occurred while processing this directive] SEVERE: ssi: #include--Couldn't include file: /test/index.jsp java.io.IOException: Couldn't get context for path: /test/index.jsp at org.apache.catalina.ssi.SSIServletExternalResolver.getServletContextAndPathFromVirtualPath(SSIServletExternal Resolver.java:273) at org.apache.catalina.ssi.SSIServletExternalResolver.getServletContextAndPath(SSIServletExternalResolver.java:3 17) at org.apache.catalina.ssi.SSIServletExternalResolver.getFileText(SSIServletExternalResolver.java:366) at org.apache.catalina.ssi.SSIMediator.getFileText(SSIMediator.java:154) at org.apache.catalina.ssi.SSIInclude.process(SSIInclude.java:40) at org.apache.catalina.ssi.SSIProcessor.process(SSIProcessor.java:145) at org.apache.catalina.ssi.SSIServlet.processSSI(SSIServlet.java:193) at org.apache.catalina.ssi.SSIServlet.requestHandler(SSIServlet.java:170) at org.apache.catalina.ssi.SSIServlet.doGet(SSIServlet.java:106) at javax.servlet.http.HttpServlet.service(HttpServlet.java:689) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:731) at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526) at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) The include does work for files within the ROOT context, though Any tips on what's still wrong would be appreciated. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: using manager with apache virtual host
Here is the file. Regards, Amir S -Original Message- From: Raghupathy,Gurumoorthy [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 20, 2005 16:33 To: 'Tomcat Users List' Subject: RE: using manager with apache virtual host Send me the httpd.conf -Original Message- From: Amir S [mailto:[EMAIL PROTECTED] Sent: 20 April 2005 16:02 To: tomcat-user@jakarta.apache.org Subject: using manager with apache virtual host Hi, I have a Jakarta 5.0.28 standalone and manager is working just fine. when I try to operate manager (on Solaris 9) with Jakarta connected to apache 2. the apache is redirecting the requests to the apache webapp root. How can I use manager with apache virtual host? Regards, Amir S - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: using manager with apache virtual host
# # Based upon the NCSA server configuration files originally by Rob McCool. # # This is the main Apache server configuration file. It contains the # configuration directives that give the server its instructions. # See URL:http://httpd.apache.org/docs-2.0/ for detailed information about # the directives. # # Do NOT simply read the instructions in here without understanding # what they do. They're here only as hints or reminders. If you are unsure # consult the online docs. You have been warned. # # The configuration directives are grouped into three basic sections: # 1. Directives that control the operation of the Apache server process as a # whole (the 'global environment'). # 2. Directives that define the parameters of the 'main' or 'default' server, # which responds to requests that aren't handled by a virtual host. # These directives also provide default values for the settings # of all virtual hosts. # 3. Settings for virtual hosts, which allow Web requests to be sent to # different IP addresses or hostnames and have them handled by the # same Apache server process. # # Configuration and logfile names: If the filenames you specify for many # of the server's control files begin with / (or drive:/ for Win32), the # server will use that explicit path. If the filenames do *not* begin # with /, the value of ServerRoot is prepended -- so logs/foo.log # with ServerRoot set to /usr/local/apache2 will be interpreted by the # server as /usr/local/apache2/logs/foo.log. # ### Section 1: Global Environment # # The directives in this section affect the overall operation of Apache, # such as the number of concurrent requests it can handle or where it # can find its configuration files. # # # ServerRoot: The top of the directory tree under which the server's # configuration, error, and log files are kept. # # NOTE! If you intend to place this on an NFS (or otherwise network) # mounted filesystem then please read the LockFile documentation (available # at URL:http://httpd.apache.org/docs-2.0/mod/mpm_common.html#lockfile); # you will save yourself a lot of trouble. # # Do NOT add a slash at the end of the directory path. # ServerRoot /usr/local/apache2 # # The accept serialization lock file MUST BE STORED ON A LOCAL DISK. # IfModule !mpm_winnt.c IfModule !mpm_netware.c #LockFile logs/accept.lock /IfModule /IfModule # # ScoreBoardFile: File used to store internal server process information. # If unspecified (the default), the scoreboard will be stored in an # anonymous shared memory segment, and will be unavailable to third-party # applications. # If specified, ensure that no two invocations of Apache share the same # scoreboard file. The scoreboard file MUST BE STORED ON A LOCAL DISK. # IfModule !mpm_netware.c IfModule !perchild.c #ScoreBoardFile logs/apache_runtime_status /IfModule /IfModule # # PidFile: The file in which the server should record its process # identification number when it starts. # IfModule !mpm_netware.c PidFile logs/httpd.pid /IfModule # # Timeout: The number of seconds before receives and sends time out. # Timeout 60 # # KeepAlive: Whether or not to allow persistent connections (more than # one request per connection). Set to Off to deactivate. # KeepAlive On # # MaxKeepAliveRequests: The maximum number of requests to allow # during a persistent connection. Set to 0 to allow an unlimited amount. # We recommend you leave this number high, for maximum performance. # MaxKeepAliveRequests 100 # # KeepAliveTimeout: Number of seconds to wait for the next request from the # same client on the same connection. # KeepAliveTimeout 10 ## ## Server-Pool Size Regulation (MPM specific) ## ### ### current MPM used: 13 May 03 ### # prefork MPM # StartServers: number of server processes to start # MinSpareServers: minimum number of server processes which are kept spare # MaxSpareServers: maximum number of server processes which are kept spare # MaxClients: maximum number of server processes allowed to start # MaxRequestsPerChild: maximum number of requests a server process serves IfModule prefork.c StartServers20 MinSpareServers 10 MaxSpareServers 20 #MaxClients 256 MaxClients 150 MaxRequestsPerChild 1 /IfModule # worker MPM # StartServers: initial number of server processes to start # MaxClients: maximum number of simultaneous client connections # MinSpareThreads: minimum number of worker threads which are kept spare # MaxSpareThreads: maximum number of worker threads which are kept spare # ThreadsPerChild: constant number of worker threads in each server process # MaxRequestsPerChild: maximum number of requests a server process serves IfModule worker.c StartServers 2 MaxClients 150 MinSpareThreads 25 MaxSpareThreads 75 ThreadsPerChild 25 MaxRequestsPerChild 1 /IfModule # Listen 10.0.0.202:80 ## ## SSL Support ## ## When we also provide SSL we have to listen to the ## standard HTTP
Launching an embedded Tomcat from Maven 1.x
Hi there! I'm working to embed a Tomcat server as a servlet container inside an Avalon Framework with a Loom engine. I looked for information how to launch the Catalina service from Java and finally I wrote the next file: package org.jlabase.framework.tomcat.startup; import java.io.File; import java.net.InetAddress; import org.apache.catalina.*; import org.apache.catalina.connector.*; import org.apache.catalina.realm.*; import org.apache.catalina.startup.*; import org.apache.tomcat.util.*; import org.jlabase.framework.tomcat.*; /** * @author a href=mailto:[EMAIL PROTECTED]A. Alonso Dominguez/a * @version 1.0 */ public class TomcatImpl implements Tomcat { private String path = null; private Embedded catalina = null; private Host host = null; private Context rootContext; private int port = 8080; public String getPath() { return path; } public void setPath(String value) { path = value; } public int getPort() { return port; } public void setPort(int value) { port = value; } public void start() throws Exception { Engine engine = null; // Create an embedded server catalina = new Embedded(); catalina.setCatalinaHome(getPath()); // Set the MemoryRealm MemoryRealm mr = new MemoryRealm(); catalina.setRealm(mr); // Create an engine engine = catalina.createEngine(); engine.setDefaultHost(localhost); // Create a default virtual host host = catalina.createHost(localhost, getPath() + /webapps); engine.addChild(host); // Create the ROOT context rootContext = catalina.createContext(, getPath() + /webapps/ROOT); rootContext.setReloadable(false); rootContext.addWelcomeFile(index.jsp); host.addChild(rootContext); // Create the Manager context Context managerCtx = catalina.createContext(/manager, getPath() + /webapps/manager); managerCtx.setPrivileged(true); host.addChild(managerCtx); // Assemble the container hierarchy catalina.addEngine(engine); // TODO Repair the Connector bug String addr = null; Connector connector = null; InetAddress address = null; try { connector = new Connector(); connector.setSecure(false); address = InetAddress.getLocalHost(); if(address != null) { IntrospectionUtils.setProperty(connector, address, address.toString()); } IntrospectionUtils.setProperty(connector, port, new Integer(getPort()).toString()); } catch(Exception e) { e.printStackTrace(); } connector.setEnableLookups(false); catalina.addConnector(connector); catalina.start(); // Starts the embedded server } public void stop() throws Exception { catalina.stop(); } public static void main(String args[]) { System.out.println(Creating server instance...); TomcatImpl tomcat = new TomcatImpl(); tomcat.setPath( new File(System.getProperty(jlbframework.tomcat.home, System.getProperty(basedir, .))).getAbsolutePath() ); try { System.out.println(Using CATALINA_HOME = + tomcat.getPath()); System.out.println(Starting server on port + tomcat.getPort()); tomcat.start(); //tomcat.catalina.setAwait(true); } catch(Exception e) { e.printStackTrace(); } } } My intention is to configure the Catalina service from this class and use a simple Ant-like script in Maven to launch the main method of this class. So, my next step was write the maven.xml file, this is: project xmlns:ant=jelly:ant xmlns:j=jelly:core xmlns:u=jelly:util default=loom:sar goal name=jlbframework:tomcat-init ant:path id=tomcat.classpath j:forEach var=artifact items=${pom.artifacts} j:set var=dependency value=${artifact.dependency} / j:if test=${dependency.getProperty('sar.bundle')=='true'}
Re: All threads (250) are currently busy
It doesn't matter what platform your running on. On linux you can use kill -s SIGQUIT pid on window box if you have cygwin you can do the same and if you do not just do a google search and there are lots of C code that does that, you can look at signal.h or sites like http://www.csl.mtu.edu/cs4411.ck/www/NOTES/signal/kill.html has actual code for you. I haven't tried their code, but I used to have one myself. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OutOfMemoryError - 100 thread limit?
This is not a memory leak in the application - we have hooked up a profiler to the application and watched the actual memory usage when causing this issue to happen. We have lots of memory available, are nowhere near the Xmx limit, and the machine has lots of memory available over and above the Xmx limit. In fact, I can cause the error to happen every single time, simply by hitting the first web page (login page) of the application - I don't have to log in, or do any work. All I have to do to get the error to happen is hit 18-19 different instances of the web application, watch the Active thread count go up to 100 and tip over the tomcat. We've gone through all of the suggested infomation out on the web - we've tweaked the Xms, Xmx and Xss parameters - none of these changes made any difference, since we're not actually running out of memory. I've reproduced this on 3 different machines, all running Red Hat Linux ES 3.0 - both with LD_ASSUME_KERNEL 2.4.19 and without, so the Linux threading model doesn't seem to affect the problem. At 04:16 AM 4/20/2005, you wrote: I'm able to go up to 647 threads and 500 concurrent connections with 5.5.4 without any problems. chances are, it's a memory leak in the webapp. only way to know for sure is to profile the application. peter lin On 4/20/05, Tim Funk [EMAIL PROTECTED] wrote: There are no limits in tomcat. http://jakarta.apache.org/tomcat/faq/memory.html -Tim LeeAnn Pultz wrote: I have a tomcat server with multiple copies of our web application running. We are running into what seems to be a hard-coded limit on the number of threads available to the Tomcat application. I have added code to our servlet class which prints out the number of active threads whenever I initialize the servlet. On Red Hat Linux boxes, whenever we start up enough copies of the servlet to hit 100 active threads, we reach an OutOfMemoryError - regardless of the Xms/Xmx settings (memory profiling shows that we have plenty of memory available). On Windows XP, 50 seems to be the magic number. I have tried tweaking Xss parameters, my ulimit command in Linux shows unlimited - and I have reached the same results with Tomcat 3.3.1, 4.0.28 and 5.0.28 using Java 1.4.1 and 1.4.2. When I use WebLogic 8.1 on the same Linux box, I reach 241 active threads with no problems whatsoever (stopped my testing at that number) so it does not seem to be an o/s limitation, or a java limitation - which leads me to believe there is something in Tomcat? Is the number of threads available to tomcat hard coded somewhere? Is there a parameter or configuration setting that I can change to increase this? If this question is better off posted to the developers list, please someone, let me know :) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: jk 1.2.10 + apache 1.3 issue
Why have worker.list? The goal of the worker.list is to publish a worker to make it available to JkMount, correct? Why not have: worker.jvmRoute.type=ajp13 worker.jvmRoute.host=10.0.0.1 worker.jvmRoute.port=8009 worker.jvmRoute.mountable=1 And then construct the available workers for jkmount after the initialization of each worker, eliminating the worker.list altogether? Thanks for the response. I haven't found the issue yet. There is no VirtualHost setup on this particular server. I had changed JK1 to allow for long worker.list lines by increasing the LINE_LENGTH to 4K. This worked just fine under Apache 2 and we haven't seen any issues in the JK1 code or cookies with respect to the ':' in the JVM Routes. To you it might seem easier to change the jvmRoute, but unfortunately there are literally 100's of production app servers that would need changed and restarted. It wouldn't be easy at all and would require every app to be retested- which is quite a task with this many applications. We face some large scale problems that most users of tomcat/jk don't see because we have so many applications. I'm going to try loading the same jk config files on an apache 2 build of JK1 and see if I have the same issues- if so then I'll know its somewhere in my config. If not, then I'll know that there is some difference in behavior between jk1 on apache 1.3 and apache 2.0. As I mentioned before, the error I saw in the logs NULL factory for ajp13*ajp13 makes me believe there was a problem during parsing of the config since I never explicitly specify ajp13*ajp13 as a value anywhere. So perhaps the modified LINE_LENGTH of 4K works fine with apache 2, but runs into issues on Apache 1.3. Byron -Original Message- From: Mladen Turk [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 20, 2005 8:19 AM To: Tomcat Users List Subject: Re: jk 1.2.10 + apache 1.3 issue Guernsey, Byron (GE Consumer Industrial) wrote: It uses a urimap.properties file instead of JkMounts. OK. The config directives in httpd.conf look like: IfDefine MOD_JK JkLogLeveldebug JkShmSize 300 JkShmFile /usr/local/apache/logs/jk1-ssodev.shm JkWorkersFile /usr/local/apache/conf/workers_sso.properties JkMountFile /usr/local/apache/conf/uriworkermap_sso.properties JkLogFile /usr/local/apache/logs/mod_jk-ssodev.log JkLogStampFormat [%a %b %d %H:%M:%S %Y] JkRequestLogFormat %w %V %T Location /jkstatus/ JkMount jkstatus Order deny,allow Deny from all Allow from 3. Allow from 127. /Location /IfDefine As you can see from my previous posting, not even jkstatus works, nor do any workers. Yet, they are configured properly and the jk log shows that it finds them: Well, just try the worker names without a colon. The reason for why we are forcing the alnum chars only is because the special chars needs to be url encoded if the client does not support the cookies. So it's easier and safer anyhow to rename the jvmRoutes in server.xml. Also for jkstatus. If you are calling that from some virtual host, you will need to have 'JkMountCopy On' directive in root, or define the Location in that virtual host. Also any workers.propeties directive should not exceed the 1024 chars. Regards, Mladen. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OutOfMemoryError - 100 thread limit?
that sounds very odd. so if I understand correctly. this happens when you hit the login page. I assume this don't happen with a static html page? by any chance are you using jsp tags or some web framework? peter On 4/20/05, LeeAnn Pultz [EMAIL PROTECTED] wrote: This is not a memory leak in the application - we have hooked up a profiler to the application and watched the actual memory usage when causing this issue to happen. We have lots of memory available, are nowhere near the Xmx limit, and the machine has lots of memory available over and above the Xmx limit. In fact, I can cause the error to happen every single time, simply by hitting the first web page (login page) of the application - I don't have to log in, or do any work. All I have to do to get the error to happen is hit 18-19 different instances of the web application, watch the Active thread count go up to 100 and tip over the tomcat. We've gone through all of the suggested infomation out on the web - we've tweaked the Xms, Xmx and Xss parameters - none of these changes made any difference, since we're not actually running out of memory. I've reproduced this on 3 different machines, all running Red Hat Linux ES 3.0 - both with LD_ASSUME_KERNEL 2.4.19 and without, so the Linux threading model doesn't seem to affect the problem. At 04:16 AM 4/20/2005, you wrote: I'm able to go up to 647 threads and 500 concurrent connections with 5.5.4 without any problems. chances are, it's a memory leak in the webapp. only way to know for sure is to profile the application. peter lin On 4/20/05, Tim Funk [EMAIL PROTECTED] wrote: There are no limits in tomcat. http://jakarta.apache.org/tomcat/faq/memory.html -Tim LeeAnn Pultz wrote: I have a tomcat server with multiple copies of our web application running. We are running into what seems to be a hard-coded limit on the number of threads available to the Tomcat application. I have added code to our servlet class which prints out the number of active threads whenever I initialize the servlet. On Red Hat Linux boxes, whenever we start up enough copies of the servlet to hit 100 active threads, we reach an OutOfMemoryError - regardless of the Xms/Xmx settings (memory profiling shows that we have plenty of memory available). On Windows XP, 50 seems to be the magic number. I have tried tweaking Xss parameters, my ulimit command in Linux shows unlimited - and I have reached the same results with Tomcat 3.3.1, 4.0.28 and 5.0.28 using Java 1.4.1 and 1.4.2. When I use WebLogic 8.1 on the same Linux box, I reach 241 active threads with no problems whatsoever (stopped my testing at that number) so it does not seem to be an o/s limitation, or a java limitation - which leads me to believe there is something in Tomcat? Is the number of threads available to tomcat hard coded somewhere? Is there a parameter or configuration setting that I can change to increase this? If this question is better off posted to the developers list, please someone, let me know :) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat/Integration Problems
What's wrong here: The intergration of Tomcat and Apache is working fine locally (Localhost). However, when I try to attach to the server by putting in the IP address (192.168.1.200) i cant see the tomcat java/servelet items. What shall i do? __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com
Re: OutOfMemoryError - 100 thread limit?
On 4/20/05, LeeAnn Pultz [EMAIL PROTECTED] wrote: This is not a memory leak in the application - we have hooked up a profiler to the application and watched the actual memory usage when causing this issue to happen. We have lots of memory available, are nowhere near the Xmx limit, and the machine has lots of memory available over and above the Xmx limit. In fact, I can cause the error to happen every single time, simply by hitting the first web page (login page) of the application - I don't have to log in, or do any work. All I have to do to get the error to happen is hit 18-19 different instances of the web application, watch the Active thread count go up to 100 and tip over the tomcat. This isn't related to the minProcessors, maxProcessors acceptCount settings for your connector in your server.xml by any chance? Regards, -- Jason Bainbridge http://kde.org - [EMAIL PROTECTED] Personal Site - http://jasonbainbridge.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OutOfMemoryError - 100 thread limit?
We have no jsps in the application. The index.html page loads our servlet class, and I've put logging of active number of threads at the beginning of the servlet ini() and the very end of the service() methods in that servlet class. The application initializes, but we aren't doing any of the real work of rendering dynamic pages or talking to the database at this point. I get the same results whether my Xmx is 84 megs or 512 megs - we're just not using that much memory. At 08:48 AM 4/20/2005, Peter Lin wrote: that sounds very odd. so if I understand correctly. this happens when you hit the login page. I assume this don't happen with a static html page? by any chance are you using jsp tags or some web framework? peter On 4/20/05, LeeAnn Pultz [EMAIL PROTECTED] wrote: This is not a memory leak in the application - we have hooked up a profiler to the application and watched the actual memory usage when causing this issue to happen. We have lots of memory available, are nowhere near the Xmx limit, and the machine has lots of memory available over and above the Xmx limit. In fact, I can cause the error to happen every single time, simply by hitting the first web page (login page) of the application - I don't have to log in, or do any work. All I have to do to get the error to happen is hit 18-19 different instances of the web application, watch the Active thread count go up to 100 and tip over the tomcat. We've gone through all of the suggested infomation out on the web - we've tweaked the Xms, Xmx and Xss parameters - none of these changes made any difference, since we're not actually running out of memory. I've reproduced this on 3 different machines, all running Red Hat Linux ES 3.0 - both with LD_ASSUME_KERNEL 2.4.19 and without, so the Linux threading model doesn't seem to affect the problem. At 04:16 AM 4/20/2005, you wrote: I'm able to go up to 647 threads and 500 concurrent connections with 5.5.4 without any problems. chances are, it's a memory leak in the webapp. only way to know for sure is to profile the application. peter lin On 4/20/05, Tim Funk [EMAIL PROTECTED] wrote: There are no limits in tomcat. http://jakarta.apache.org/tomcat/faq/memory.html -Tim LeeAnn Pultz wrote: I have a tomcat server with multiple copies of our web application running. We are running into what seems to be a hard-coded limit on the number of threads available to the Tomcat application. I have added code to our servlet class which prints out the number of active threads whenever I initialize the servlet. On Red Hat Linux boxes, whenever we start up enough copies of the servlet to hit 100 active threads, we reach an OutOfMemoryError - regardless of the Xms/Xmx settings (memory profiling shows that we have plenty of memory available). On Windows XP, 50 seems to be the magic number. I have tried tweaking Xss parameters, my ulimit command in Linux shows unlimited - and I have reached the same results with Tomcat 3.3.1, 4.0.28 and 5.0.28 using Java 1.4.1 and 1.4.2. When I use WebLogic 8.1 on the same Linux box, I reach 241 active threads with no problems whatsoever (stopped my testing at that number) so it does not seem to be an o/s limitation, or a java limitation - which leads me to believe there is something in Tomcat? Is the number of threads available to tomcat hard coded somewhere? Is there a parameter or configuration setting that I can change to increase this? If this question is better off posted to the developers list, please someone, let me know :) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OutOfMemoryError - 100 thread limit?
No, unfortunately, changing those options doesn't seem to make any difference either. On tomcat 3, I even tried manipulating the thread pool settings (since in 4 and 5 those are handled inside tomcat). But I'm seeing the same problems on 3, 4 and 5.0 In fact, I can cause the error to happen every single time, simply by hitting the first web page (login page) of the application - I don't have to log in, or do any work. All I have to do to get the error to happen is hit 18-19 different instances of the web application, watch the Active thread count go up to 100 and tip over the tomcat. This isn't related to the minProcessors, maxProcessors acceptCount settings for your connector in your server.xml by any chance? Regards, -- Jason Bainbridge http://kde.org - [EMAIL PROTECTED] Personal Site - http://jasonbainbridge.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Can't do logout in basic authentication
You can try google: http://www.modpython.org/pipermail/mod_python/2001-August/012120.html Otgonbayar wrote: I am using basic authentication in my application and I need to create logout link in my JSP that does LOGOUT. It seems session.invalidate() doesn't work. How can I do this? Please help me! Thanks Otgo - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Robert r. Sanders Chief Technologist iPOV (334) 821-5412 www.ipov.net - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Heap not expanding beyond -Xms512m
Quinten, Matt, Thank you for your feedback and the JVM reference. Guillaume - Original Message - From: Quinten Verheyen [EMAIL PROTECTED] To: Tomcat Users List tomcat-user@jakarta.apache.org Subject: RE: Heap not expanding beyond -Xms512m Date: Wed, 20 Apr 2005 15:32:12 +0200 I agree, it's always a good idea to let the JVM do what it is supposed to do instead of creating a growing overhead. The only exception to that rule is if you think you'll reach 1024 MB, but as you say yourself, 512 seems to do fine as -Xms. btw, here is an article that goes into detail (ratio's etc.) using jvm 1.4.2 http://java.sun.com/docs/hotspot/gc1.4.2/index.html Q -Original Message- From: Dale, Matt [mailto:[EMAIL PROTECTED] Sent: 20 April 2005 15:24 To: Tomcat Users List Subject: RE: Heap not expanding beyond -Xms512m This is expected behaviour. The heap will not grow if the memory required can be gained through a garbage collection. The heap will only grow if after a garbage collection it still cannot allocate the required memory or is over a certain percentage (I forget what the default is). I would suggest that you don't in fact need 512MB if your app runs fine with no OOM in 512MB. If you really want to use the full 1GB the you'll have to use -Xms as you suggested. Ta Matt -Original Message- From: Guillaume Lahitette [mailto:[EMAIL PROTECTED] Sent: 20 April 2005 13:54 To: tomcat-user@jakarta.apache.org Subject: Heap not expanding beyond -Xms512m Hello Tomcat-oids, I'd really appreciate any help with this...Thanks in advance. We've been running performance tests against Tomcat 4.1.26 on Linux and Windows. We've tuned heap sizes to -Xms512m -Xmx1024m. Monitoring the JVM memory usage with a daemon thread calling Runtime.getRuntime().freeMemory() / totalMemory() / maxMemory(), we've noticed memory was never expanded beyond 512MB. Instead, when usage was getting close to 512MB, we could see the garbage collector kick in. We never got OOM errors. Can anyone share experiences about this? Do I have to use -Xms1024m -Xmx1024m (which seems to defeat the purpose of having ms and mx...)? Guillaume - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OutOfMemoryError - 100 thread limit?
that is some really odd behavior coming from Tomcat. I've probably run over 1K benchmarks on Tomcat over the last 3 years and I've yet to see that kind of behavior. Here are some random ideas to try, which I've used in the past. They may not help, but I figure it wouldn't hurt to suggest them. use jmeter to send 250 requests with 25 threads against the index page. then view the status in tomcat 5.5.4. Over time, you should see the number of threads drop to the minimum. Under normal conditions, tomcat will create enough threads to service those threads. after a few minutes, the thread count should drop. If it doesn't, it means something is keeping the connection open. if you see that, it is most likley an application bug. Another idea is to do netstat and see what the status of the connections are. It might be some of the connections are not closing. peter On 4/20/05, LeeAnn Pultz [EMAIL PROTECTED] wrote: We have no jsps in the application. The index.html page loads our servlet class, and I've put logging of active number of threads at the beginning of the servlet ini() and the very end of the service() methods in that servlet class. The application initializes, but we aren't doing any of the real work of rendering dynamic pages or talking to the database at this point. I get the same results whether my Xmx is 84 megs or 512 megs - we're just not using that much memory. At 08:48 AM 4/20/2005, Peter Lin wrote: that sounds very odd. so if I understand correctly. this happens when you hit the login page. I assume this don't happen with a static html page? by any chance are you using jsp tags or some web framework? peter On 4/20/05, LeeAnn Pultz [EMAIL PROTECTED] wrote: This is not a memory leak in the application - we have hooked up a profiler to the application and watched the actual memory usage when causing this issue to happen. We have lots of memory available, are nowhere near the Xmx limit, and the machine has lots of memory available over and above the Xmx limit. In fact, I can cause the error to happen every single time, simply by hitting the first web page (login page) of the application - I don't have to log in, or do any work. All I have to do to get the error to happen is hit 18-19 different instances of the web application, watch the Active thread count go up to 100 and tip over the tomcat. We've gone through all of the suggested infomation out on the web - we've tweaked the Xms, Xmx and Xss parameters - none of these changes made any difference, since we're not actually running out of memory. I've reproduced this on 3 different machines, all running Red Hat Linux ES 3.0 - both with LD_ASSUME_KERNEL 2.4.19 and without, so the Linux threading model doesn't seem to affect the problem. At 04:16 AM 4/20/2005, you wrote: I'm able to go up to 647 threads and 500 concurrent connections with 5.5.4 without any problems. chances are, it's a memory leak in the webapp. only way to know for sure is to profile the application. peter lin On 4/20/05, Tim Funk [EMAIL PROTECTED] wrote: There are no limits in tomcat. http://jakarta.apache.org/tomcat/faq/memory.html -Tim LeeAnn Pultz wrote: I have a tomcat server with multiple copies of our web application running. We are running into what seems to be a hard-coded limit on the number of threads available to the Tomcat application. I have added code to our servlet class which prints out the number of active threads whenever I initialize the servlet. On Red Hat Linux boxes, whenever we start up enough copies of the servlet to hit 100 active threads, we reach an OutOfMemoryError - regardless of the Xms/Xmx settings (memory profiling shows that we have plenty of memory available). On Windows XP, 50 seems to be the magic number. I have tried tweaking Xss parameters, my ulimit command in Linux shows unlimited - and I have reached the same results with Tomcat 3.3.1, 4.0.28 and 5.0.28 using Java 1.4.1 and 1.4.2. When I use WebLogic 8.1 on the same Linux box, I reach 241 active threads with no problems whatsoever (stopped my testing at that number) so it does not seem to be an o/s limitation, or a java limitation - which leads me to believe there is something in Tomcat? Is the number of threads available to tomcat hard coded somewhere? Is there a parameter or configuration setting that I can change to increase this? If this question is better off posted to the developers list, please someone, let me know :) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: jk 1.2.10 + apache 1.3 issue
Guernsey, Byron (GE Consumer Industrial) wrote: worked just fine under Apache 2 and we haven't seen any issues in the JK1 code or cookies with respect to the ':' in the JVM Routes. To you it might seem easier to change the jvmRoute, but unfortunately there are literally 100's of production app servers that would need changed and restarted. Well, there are users unlike you that do not allow cookies, so the colon in uri is invalid and needs to be encoded. Also I can give you few links to the editors that can do search and replace in multiple files at once ;). Also, just mail your workers.properties and httpd.conf. It would be much easier then guessing I suppose. If this is confidential data, then, well ... Regards, Mladen. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: jk 1.2.10 + apache 1.3 issue
I also have a problem with JkMountFile and apache 1.3 on Linux. The problem is the same if I use Virtual Hosts or not : the workers don't work. If I use JkMount : it works. For more details : In my config with Virtual Hosts (and JkMountFile), I have : in /etc/apache/httpd.conf : ... Include /usr2/web/VirtualHosts/myVhost1 Include /usr2/web/etc/mod_jk.conf ... in /usr2/web/VirtualHosts/myVhost1 : VirtualHost myHost ... ServerName myVhost1 #this works : # JkMount /testServlet/* ajp13 #this doesn't work : #JkMountFile /usr2/web/VirtualHosts/testServlet.properties JkMountFile /usr2/web/etc/testServlet.properties /VirtualHost in /usr2/web/etc/testServlet.properties : /testServlet/*.jgi=ajp13 in /usr2/web/etc/mod_jk.conf : JkWorkersFile /usr2/web/etc/workers.properties JkMountCopy On JkShmFile /usr2/web/logs/mod_jk.shm Location /jkstatus JkMount status Order deny,allow Deny from all Allow from 127.0.0.1 /Location in /usr2/web/etc/workers.properties : workers.tomcat_home=/usr/local/jonas workers.java_home=/usr/local/jdk_home ps=/ worker.list=ajp13,status worker.status.type=status worker.ajp13.type=ajp13 worker.ajp13.host=myHost worker.ajp13.port=8009 worker.ajp13.lbfactor=1 When I restart apache, it's OK (so the JkMountFile is found), But when I want to get http://myVhost1/testServlet/myServlet == 404 [Wed Apr 20 18:03:47 2005] [2940:] [debug] map_uri_to_worker::jk_uri_worker_map.c (455): Attempting to map URI '/testServlet/myServlet' from 0 maps On Wed, 20 Apr 2005 11:49:26 -0400 Guernsey, Byron \(GE Consumer Industrial\) [EMAIL PROTECTED] wrote: Why have worker.list? The goal of the worker.list is to publish a worker to make it available to JkMount, correct? Why not have: worker.jvmRoute.type=ajp13 worker.jvmRoute.host=10.0.0.1 worker.jvmRoute.port=8009 worker.jvmRoute.mountable=1 And then construct the available workers for jkmount after the initialization of each worker, eliminating the worker.list altogether? Thanks for the response. I haven't found the issue yet. There is no VirtualHost setup on this particular server. I had changed JK1 to allow for long worker.list lines by increasing the LINE_LENGTH to 4K. This worked just fine under Apache 2 and we haven't seen any issues in the JK1 code or cookies with respect to the ':' in the JVM Routes. To you it might seem easier to change the jvmRoute, but unfortunately there are literally 100's of production app servers that would need changed and restarted. It wouldn't be easy at all and would require every app to be retested- which is quite a task with this many applications. We face some large scale problems that most users of tomcat/jk don't see because we have so many applications. I'm going to try loading the same jk config files on an apache 2 build of JK1 and see if I have the same issues- if so then I'll know its somewhere in my config. If not, then I'll know that there is some difference in behavior between jk1 on apache 1.3 and apache 2.0. As I mentioned before, the error I saw in the logs NULL factory for ajp13*ajp13 makes me believe there was a problem during parsing of the config since I never explicitly specify ajp13*ajp13 as a value anywhere. So perhaps the modified LINE_LENGTH of 4K works fine with apache 2, but runs into issues on Apache 1.3. Byron -Original Message- From: Mladen Turk [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 20, 2005 8:19 AM To: Tomcat Users List Subject: Re: jk 1.2.10 + apache 1.3 issue Guernsey, Byron (GE Consumer Industrial) wrote: It uses a urimap.properties file instead of JkMounts. OK. The config directives in httpd.conf look like: IfDefine MOD_JK JkLogLeveldebug JkShmSize 300 JkShmFile /usr/local/apache/logs/jk1-ssodev.shm JkWorkersFile /usr/local/apache/conf/workers_sso.properties JkMountFile /usr/local/apache/conf/uriworkermap_sso.properties JkLogFile /usr/local/apache/logs/mod_jk-ssodev.log JkLogStampFormat [%a %b %d %H:%M:%S %Y] JkRequestLogFormat %w %V %T Location /jkstatus/ JkMount jkstatus Order deny,allow Deny from all Allow from 3. Allow from 127. /Location /IfDefine As you can see from my previous posting, not even jkstatus works, nor do any workers. Yet, they are configured properly and the jk log shows that it finds them: Well, just try the worker names without a colon. The reason for why we are forcing the alnum chars only is because the special chars needs to be url encoded if the client does not support the cookies. So it's easier and safer anyhow to rename the jvmRoutes in server.xml. Also for jkstatus. If you are calling that from some virtual host, you will need to have 'JkMountCopy On' directive in root, or define the Location in that virtual host. Also any workers.propeties
RE: Can't do logout in basic authentication
If you read the docs on BASIC authentication, you will find that the browser caches the login information and will provide it every time you return to that site. The way to log out is to close the browser. Apparently this has been a problem for web developers for some time. Browser developers have not seen this as a problem. Instead they seem to feel that the caching is a benefit to the user by not requiring them to renter the same information. Robert S. Harper 801.265.8800 ext. 255 [EMAIL PROTECTED] -Original Message- From: Robert r. Sanders [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 20, 2005 10:07 AM To: Tomcat Users List Subject: Re: Can't do logout in basic authentication You can try google: http://www.modpython.org/pipermail/mod_python/2001-August/012120.html Otgonbayar wrote: I am using basic authentication in my application and I need to create logout link in my JSP that does LOGOUT. It seems session.invalidate() doesn't work. How can I do this? Please help me! Thanks Otgo - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Robert r. Sanders Chief Technologist iPOV (334) 821-5412 www.ipov.net - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Apache_MaxClients, AJP_maxThreads and jkWorker.cachesize
Hi, I have 1 Linux Virtual Server (with round robin) + 2 apache 1.3 servers + 3 Tomcat servers load-balanced with mod_jk1.2.10. 1) If each Apache define : MaxClients=150 1.1) what must be the value for each Tomcat Connector AJP maxThread ? 1.2) is the value for each worker.cachesize have to be put ? 2) for my 2 apache 1.3 servers, I must have only 1 JkShmFile on an nfs mount RW ? Right ? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: jk 1.2.10 + apache 1.3 issue
Lionel Farbos wrote: VirtualHost myHost ServerName myVhost1 #this works : # JkMount /testServlet/* ajp13 #this doesn't work : #JkMountFile /usr2/web/VirtualHosts/testServlet.properties JkMountFile /usr2/web/etc/testServlet.properties Well, the mount files are overriden if JkMountCopy On is set. So if you have: JkMountFile A JkMountCopy On VirtualHost ... JkMountFile B # This file will never be used, because # mount copy says: Use the file from the Root /VirtualHost Regards, Mladen. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Apache_MaxClients, AJP_maxThreads and jkWorker.cachesize
cachesize is used only for threaded apache's like 1.3 on windows or netware; apache2 with worker_mpm, etc... The size must reflect the number of threads per child process that for prefork mpms like 1.3 on unixes is always 1, so there is no need to set it. Each apache instance needs it's own shared memory. 2x150=300/3 in ideal case, so each TC should have 100 maxThreads. If you expect that one of the Tomcats in the cluster can fail, then the number should be 300/2 or 150. Regards, Mladen. Lionel Farbos wrote: Hi, I have 1 Linux Virtual Server (with round robin) + 2 apache 1.3 servers + 3 Tomcat servers load-balanced with mod_jk1.2.10. 1) If each Apache define : MaxClients=150 1.1) what must be the value for each Tomcat Connector AJP maxThread ? 1.2) is the value for each worker.cachesize have to be put ? 2) for my 2 apache 1.3 servers, I must have only 1 JkShmFile on an nfs mount RW ? Right ? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: jk 1.2.10 + apache 1.3 issue
On Wed, 20 Apr 2005 18:48:24 +0200 Mladen Turk [EMAIL PROTECTED] wrote: Lionel Farbos wrote: VirtualHost myHost ServerName myVhost1 #this works : # JkMount /testServlet/* ajp13 #this doesn't work : #JkMountFile /usr2/web/VirtualHosts/testServlet.properties JkMountFile /usr2/web/etc/testServlet.properties Well, the mount files are overriden if JkMountCopy On is set. So if you have: JkMountFile A JkMountCopy On VirtualHost ... JkMountFile B # This file will never be used, because # mount copy says: Use the file from the Root /VirtualHost Thank you Mladen, but I tried also this : VirtualHost ... JkMountFile B /VirtualHost (without JkMountFile A and JkMountCopy On) and this doesn't work either :-( - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OutOfMemoryError - 100 thread limit?
We did run some code that just makes threads, on the machine and it had no effect - I'll incorporate that code inside a servlet, so we can do this test against tomcat and see if it makes a difference. We just tried the same test against tomcat 5.0 using port 8080 and not using any of the mod_jk connectors, to see if that made a difference - we found that we started with more active threads by uncommenting that section of server.xml (started with 67 active threads rather than 44) and got a bit higher (died at 118 threads rather than 100 threads) so I'm taking that result to show that the actual number of threads allocated to the application remained about the same, with or without the usage of mod_jk. At 09:08 AM 4/20/2005, you wrote: that is some really odd behavior coming from Tomcat. I've probably run over 1K benchmarks on Tomcat over the last 3 years and I've yet to see that kind of behavior. Here are some random ideas to try, which I've used in the past. They may not help, but I figure it wouldn't hurt to suggest them. use jmeter to send 250 requests with 25 threads against the index page. then view the status in tomcat 5.5.4. Over time, you should see the number of threads drop to the minimum. Under normal conditions, tomcat will create enough threads to service those threads. after a few minutes, the thread count should drop. If it doesn't, it means something is keeping the connection open. if you see that, it is most likley an application bug. Another idea is to do netstat and see what the status of the connections are. It might be some of the connections are not closing. peter On 4/20/05, LeeAnn Pultz [EMAIL PROTECTED] wrote: We have no jsps in the application. The index.html page loads our servlet class, and I've put logging of active number of threads at the beginning of the servlet ini() and the very end of the service() methods in that servlet class. The application initializes, but we aren't doing any of the real work of rendering dynamic pages or talking to the database at this point. I get the same results whether my Xmx is 84 megs or 512 megs - we're just not using that much memory. At 08:48 AM 4/20/2005, Peter Lin wrote: that sounds very odd. so if I understand correctly. this happens when you hit the login page. I assume this don't happen with a static html page? by any chance are you using jsp tags or some web framework? peter On 4/20/05, LeeAnn Pultz [EMAIL PROTECTED] wrote: This is not a memory leak in the application - we have hooked up a profiler to the application and watched the actual memory usage when causing this issue to happen. We have lots of memory available, are nowhere near the Xmx limit, and the machine has lots of memory available over and above the Xmx limit. In fact, I can cause the error to happen every single time, simply by hitting the first web page (login page) of the application - I don't have to log in, or do any work. All I have to do to get the error to happen is hit 18-19 different instances of the web application, watch the Active thread count go up to 100 and tip over the tomcat. We've gone through all of the suggested infomation out on the web - we've tweaked the Xms, Xmx and Xss parameters - none of these changes made any difference, since we're not actually running out of memory. I've reproduced this on 3 different machines, all running Red Hat Linux ES 3.0 - both with LD_ASSUME_KERNEL 2.4.19 and without, so the Linux threading model doesn't seem to affect the problem. At 04:16 AM 4/20/2005, you wrote: I'm able to go up to 647 threads and 500 concurrent connections with 5.5.4 without any problems. chances are, it's a memory leak in the webapp. only way to know for sure is to profile the application. peter lin On 4/20/05, Tim Funk [EMAIL PROTECTED] wrote: There are no limits in tomcat. http://jakarta.apache.org/tomcat/faq/memory.html -Tim LeeAnn Pultz wrote: I have a tomcat server with multiple copies of our web application running. We are running into what seems to be a hard-coded limit on the number of threads available to the Tomcat application. I have added code to our servlet class which prints out the number of active threads whenever I initialize the servlet. On Red Hat Linux boxes, whenever we start up enough copies of the servlet to hit 100 active threads, we reach an OutOfMemoryError - regardless of the Xms/Xmx settings (memory profiling shows that we have plenty of memory available). On Windows XP, 50 seems to be the magic number. I have tried tweaking Xss parameters, my ulimit command in Linux shows unlimited - and I have reached the same results with Tomcat 3.3.1, 4.0.28 and 5.0.28 using Java 1.4.1 and 1.4.2. When I use WebLogic 8.1 on the same Linux box, I
Re: OutOfMemoryError - 100 thread limit?
Perhaps this will trigger some ideas? The stack trace we get when we get the OutOfMemoryError is : 2005-04-20 09:55:33 StandardWrapperValve[ExtraView]: Allocate exception for servlet ExtraView javax.servlet.ServletException: Error allocating a servlet instance at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:691) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:144) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929) at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705) at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683) at java.lang.Thread.run(Thread.java:536) - Root Cause - java.lang.OutOfMemoryError LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Apache_MaxClients, AJP_maxThreads and jkWorker.cachesize
Thank you again. On Wed, 20 Apr 2005 18:56:06 +0200 Mladen Turk [EMAIL PROTECTED] wrote: Each apache instance needs it's own shared memory. So it means than I can have 1 local JkShmFile on my web1 and other local JkShmFile on my web2. But, if, in web1_jkStatus, I disable 1 worker from my cluster (loadbalancer), I also have to disable it from my web2_jkStatus ? Right ? Lionel Farbos wrote: Hi, I have 1 Linux Virtual Server (with round robin) + 2 apache 1.3 servers + 3 Tomcat servers load-balanced with mod_jk1.2.10. 2) for my 2 apache 1.3 servers, I must have only 1 JkShmFile on an nfs mount RW ? Right ? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: jk 1.2.10 + apache 1.3 issue
Lionel Farbos wrote: but I tried also this : VirtualHost ... JkMountFile B /VirtualHost (without JkMountFile A and JkMountCopy On) and this doesn't work either :-( Well, then it's a bug :) I'll check that, to see how it can be fixed. Regards, Mladen. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Can't do logout in basic authentication
In most applications this is one of those *perceived* problems that corporate users get uptight about. The best way to prevent abuse of an idle authenticated browser window is a screensaver with password lock -- as it protects the rest of the computer, the documents thereon, etc. The only really good case for a logout is where you have a shared computer with many different users coming and going -- and all using a single guest account on the client itself rather than separate logins. In this case a logoff button that closed down the browser would not be a half bad idea :-) -- Jess Holle P.S. Yes, I know transfering the name/password only on initial authentication and using a session key of some sort from thereon out is fractionally more secure -- but you still need HTTPS to really be secure in either case. Robert Harper wrote: If you read the docs on BASIC authentication, you will find that the browser caches the login information and will provide it every time you return to that site. The way to log out is to close the browser. Apparently this has been a problem for web developers for some time. Browser developers have not seen this as a problem. Instead they seem to feel that the caching is a benefit to the user by not requiring them to renter the same information. Robert S. Harper 801.265.8800 ext. 255 [EMAIL PROTECTED] -Original Message- From: Robert r. Sanders [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 20, 2005 10:07 AM To: Tomcat Users List Subject: Re: Can't do logout in basic authentication You can try google: http://www.modpython.org/pipermail/mod_python/2001-August/012120.html Otgonbayar wrote: I am using basic authentication in my application and I need to create logout link in my JSP that does LOGOUT. It seems session.invalidate() doesn't work. How can I do this? Please help me! Thanks Otgo - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Apache_MaxClients, AJP_maxThreads and jkWorker.cachesize
Lionel Farbos wrote: Thank you again. So it means than I can have 1 local JkShmFile on my web1 and other local JkShmFile on my web2. But, if, in web1_jkStatus, I disable 1 worker from my cluster (loadbalancer), I also have to disable it from my web2_jkStatus ? Right ? Well, you can try to use the single shm file. It won't hurt trying ;) Frankly never tested that on NSF and with multiple httpd's. So, tell us if it works. Regards, Mladen. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Per Application JNDI/JDBC Configuration
Yep. This is basically the direction I was already headed. Once I deploy my application I do get the JNDI name in the list of DataSources (as viewed from the Administration tool), but the data source has no parameters. It almost looks as if Tomcat's loader is ignoring the ResourceParams tag. My context.xml file is in the META-INF directory just under the document base directory. Parsons Technical Services wrote: For each app you have running you will need a context element in a xml file. This should reside in the war. In this file you can setup the resource which will be available only to that app. This will still give you pooling. If you follow the instructions on the Tomcat site for the JDBC How-To that will set things up. The only change is to put the elements in with the context fragment in the xml file for your app instead of the server.xml. Yeah the web site should be changed considering that the preferred way to set up app is not to put anything in the server.xml and yet this How to has you do just that. Eventually they will get to it. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Can't do logout in basic authentication
you cannot do that in basic .. you need to do a form based one ... - Original Message - From: Otgonbayar [EMAIL PROTECTED] To: 'Tomcat Users List' tomcat-user@jakarta.apache.org Sent: Wednesday, April 20, 2005 4:28 AM Subject: Can't do logout in basic authentication I am using basic authentication in my application and I need to create logout link in my JSP that does LOGOUT. It seems session.invalidate() doesn't work. How can I do this? Please help me! Thanks Otgo - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat/Integration Problems
try changing the name=localhost to 192.168.1.200 in your server.xml and restart both .. Guru - Original Message - From: edwin roberts [EMAIL PROTECTED] To: Tomcat Users List tomcat-user@jakarta.apache.org Sent: Wednesday, April 20, 2005 4:49 PM Subject: Tomcat/Integration Problems What's wrong here: The intergration of Tomcat and Apache is working fine locally (Localhost). However, when I try to attach to the server by putting in the IP address (192.168.1.200) i cant see the tomcat java/servelet items. What shall i do? __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Can't do logout in basic authentication
P.S. Freeing one's *session* on leaving works with any type of authentication and makes sense in many cases -- it's just harder to communicate this concept to the user... Jess Holle wrote: In most applications this is one of those *perceived* problems that corporate users get uptight about. The best way to prevent abuse of an idle authenticated browser window is a screensaver with password lock -- as it protects the rest of the computer, the documents thereon, etc. The only really good case for a logout is where you have a shared computer with many different users coming and going -- and all using a single guest account on the client itself rather than separate logins. In this case a logoff button that closed down the browser would not be a half bad idea :-) -- Jess Holle P.S. Yes, I know transfering the name/password only on initial authentication and using a session key of some sort from thereon out is fractionally more secure -- but you still need HTTPS to really be secure in either case.
Re: jk 1.2.10 + apache 1.3 issue
On Wed, 20 Apr 2005 19:07:28 +0200 Mladen Turk [EMAIL PROTECTED] wrote: Lionel Farbos wrote: but I tried also this : VirtualHost ... JkMountFile B /VirtualHost (without JkMountFile A and JkMountCopy On) and this doesn't work either :-( Well, then it's a bug :) I'll check that, to see how it can be fixed. When you test this feature, I think it was OK for you. So what is your test config ? Apache 2 ? Windows ? If I want to use this feature with this jk1.2.10, I have to upgrade my web server in apache 2.0.54 ? Regards. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OutOfMemoryError - 100 thread limit?
that looks really bizzare to me. From the exception, it looks like tomcat can't create a new thread to process the request. It makes me think the previous threads that are done are being held by something for some odd reason. Normally the threads should be available again. What is the ramp up time for your tests? in other words, are you throwing 100 concurrent requests at it simultaneously, or ramping it up over a few seconds? peter On 4/20/05, LeeAnn Pultz [EMAIL PROTECTED] wrote: Perhaps this will trigger some ideas? The stack trace we get when we get the OutOfMemoryError is : 2005-04-20 09:55:33 StandardWrapperValve[ExtraView]: Allocate exception for servlet ExtraView javax.servlet.ServletException: Error allocating a servlet instance at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:691) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:144) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929) at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705) at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683) at java.lang.Thread.run(Thread.java:536) - Root Cause - java.lang.OutOfMemoryError LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: OutOfMemoryError - 100 thread limit?
From: LeeAnn Pultz [mailto:[EMAIL PROTECTED] Subject: Re: OutOfMemoryError - 100 thread limit? Perhaps this will trigger some ideas? The stack trace we get when we get the OutOfMemoryError is : - Root Cause - java.lang.OutOfMemoryError It's what comes after this spot in the trace that might be really interesting... Unfortunately, OOME is somewhat of a catch-all - the JVM issues it whenever any OS-based resource is exhausted, as well as when out of heap space. Could be something simple like the limit on the number of open file descriptors being reached. It's also possible you're running out of perm gen space, which is not unusual if you have a lot of classes. Might want to turn on -verbose:gc just to see. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OutOfMemoryError - 100 thread limit?
This was first reported when we had multiple web applications running on one tomcat, and a user would be logged into the site and be using the application fine, and then if another user started working in a new site, they would get the OutOfMemory error when the first tried to load the page of their site. The first user would then start getting exceptions once the OutOfMemory error happened. When we reproduce the error, it doesn't seem to make a difference whether we simply click through a list of links, opening each site in a new window quickly, or whether we pause a few seconds in between opening new sites. So it doesn't necessarily *seem* to be dependent on multiple people firing up their sites at the same time, or over the course of several hours as different people use the system. We've identified that each instance of our application starts up with 3 active threads - we have a monitoring thread, the application thread and the user's current thread. When I start up tomcat, and hit the first site, I see about 44 active threads to start with - this seems to be affected by whether we have the Http10 connector commented out, whether the management port is set up etc. If I run the application through Jbuilder + tomcat, the active count doesn't count the tomcat' threads, and I start with 3 threads and increase by 3 threads for each new application I open in my browser, the first time. At 10:38 AM 4/20/2005, you wrote: that looks really bizzare to me. From the exception, it looks like tomcat can't create a new thread to process the request. It makes me think the previous threads that are done are being held by something for some odd reason. Normally the threads should be available again. What is the ramp up time for your tests? in other words, are you throwing 100 concurrent requests at it simultaneously, or ramping it up over a few seconds? peter On 4/20/05, LeeAnn Pultz [EMAIL PROTECTED] wrote: Perhaps this will trigger some ideas? The stack trace we get when we get the OutOfMemoryError is : 2005-04-20 09:55:33 StandardWrapperValve[ExtraView]: Allocate exception for servlet ExtraView javax.servlet.ServletException: Error allocating a servlet instance at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:691) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:144) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929) at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705) at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683) at java.lang.Thread.run(Thread.java:536) - Root Cause - java.lang.OutOfMemoryError LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To
RE: OutOfMemoryError - 100 thread limit?
At 10:43 AM 4/20/2005, you wrote: From: LeeAnn Pultz [mailto:[EMAIL PROTECTED] Subject: Re: OutOfMemoryError - 100 thread limit? Perhaps this will trigger some ideas? The stack trace we get when we get the OutOfMemoryError is : - Root Cause - java.lang.OutOfMemoryError It's what comes after this spot in the trace that might be really interesting... Unfortunately, there's nothing after this :) Unfortunately, OOME is somewhat of a catch-all - the JVM issues it whenever any OS-based resource is exhausted, as well as when out of heap space. Could be something simple like the limit on the number of open file descriptors being reached. It's also possible you're running out of perm gen space, which is not unusual if you have a lot of classes. Might want to turn on -verbose:gc just to see. We did run ulimit and the system says everything is unlimited. I'm not familiar with perm gen space - if I turn on -verbose gc could you please tell me what I might be looking for? thanks! LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: OutOfMemoryError - 100 thread limit?
Might want to turn on -verbose:gc just to see. I turned on verbose:gc and ran the test again: INFO: Server startup in 14608 ms Start Init Method. The CONFIG_FILE from web.xml is : WEB-INF/configuration/Configuration.properties Using Configuration FILE: /usr/local/extraview/stage2/jakarta-tomcat-5.0.28/webapps/site1/WEB-INF/configuration/Configuration.properties Successfully created a SesameConfig object from FILE: /usr/local/extraview/stage2/jakarta-tomcat-5.0.28/webapps/site1/WEB-INF/configuration/Configuration.properties SesameProjectDir: /usr/local/extraview/stage2/jakarta-tomcat-5.0.28/webapps/site1/WEB-INF Attempting to Open Log File: /usr/local/extraview/stage2/jakarta-tomcat-5.0.28/webapps/site1/WEB-INF/logs/EVJ.log Successfully finished init in SesameServlet. [GC 20785K-9728K(129728K), 0.0274860 secs] Threads Active : 39 [Full GC 15980K-10340K(129728K), 0.1632550 secs] [GC 22085K-11723K(129728K), 0.0286990 secs] Threads Active : 41 Threads Active : 41 Threads Active : 41 Start Init Method. The CONFIG_FILE from web.xml is : WEB-INF/configuration/Configuration.properties Using Configuration FILE: /usr/local/extraview/stage2/jakarta-tomcat-5.0.28/webapps/site2/WEB-INF/configuration/Configuration.properties Successfully created a SesameConfig object from FILE: /usr/local/extraview/stage2/jakarta-tomcat-5.0.28/webapps/site2/WEB-INF/configuration/Configuration.properties SesameProjectDir: /usr/local/extraview/stage2/jakarta-tomcat-5.0.28/webapps/site2/WEB-INF Attempting to Open Log File: /usr/local/extraview/stage2/jakarta-tomcat-5.0.28/webapps/site2/WEB-INF/logs/EVJ.log Successfully finished init in SesameServlet. [Full GC 23440K-12707K(129728K), 0.2036440 secs] [GC 24483K-13950K(129728K), 0.0181640 secs] Start Init Method. ... more like this Successfully finished init in SesameServlet. [GC 54635K-43725K(129792K), 0.0247320 secs] [GC 55562K-44967K(129792K), 0.0167680 secs] [Full GC 45254K-44666K(129792K), 0.6926680 secs] Threads Active : 93 Threads Active : 93 Start Init Method. The CONFIG_FILE from web.xml is : WEB-INF/configuration/Configuration.properties Using Configuration FILE: /usr/local/extraview/stage2/jakarta-tomcat-5.0.28/webapps/site18/WEB-INF/configuration/Configuration.properties Successfully created a SesameConfig object from FILE: /usr/local/extraview/stage2/jakarta-tomcat-5.0.28/webapps/site18/WEB-INF/configuration/Configuration.properties SesameProjectDir: /usr/local/extraview/stage2/jakarta-tomcat-5.0.28/webapps/site18/WEB-INF Attempting to Open Log File: /usr/local/extraview/stage2/jakarta-tomcat-5.0.28/webapps/site18/WEB-INF/logs/EVJ.log Successfully finished init in SesameServlet. [GC 56506K-45573K(129792K), 0.0164210 secs] [GC 57412K-46857K(129792K), 0.0237680 secs] Threads Active : 96 Threads Active : 96 Start Init Method. The CONFIG_FILE from web.xml is : WEB-INF/configuration/Configuration.properties Using Configuration FILE: /usr/local/extraview/stage2/jakarta-tomcat-5.0.28/webapps/site19/WEB-INF/configuration/Configuration.properties Successfully created a SesameConfig object from FILE: /usr/local/extraview/stage2/jakarta-tomcat-5.0.28/webapps/site19/WEB-INF/configuration/Configuration.properties SesameProjectDir: /usr/local/extraview/stage2/jakarta-tomcat-5.0.28/webapps/site19/WEB-INF Attempting to Open Log File: /usr/local/extraview/stage2/jakarta-tomcat-5.0.28/webapps/site19/WEB-INF/logs/EVJ.log Successfully finished init in SesameServlet. [Full GC 52758K-47299K(129792K), 0.6463800 secs] [Full GC 47308K-47304K(129792K), 0.6400790 secs] [Full GC 47304K-47304K(129792K), 0.6315800 secs] [Full GC 47304K-47042K(129792K), 0.6941910 secs] java.lang.OutOfMemoryError java.lang.OutOfMemoryError Threads Active : 94 Threads Active : 94 [Full GC 48357K-47096K(129792K), 0.6358540 secs] LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OutOfMemoryError - 100 thread limit?
On 4/20/05, LeeAnn Pultz [EMAIL PROTECTED] wrote: This was first reported when we had multiple web applications running on one tomcat, and a user would be logged into the site and be using the application fine, and then if another user started working in a new site, they would get the OutOfMemory error when the first tried to load the page of their site. The first user would then start getting exceptions once the OutOfMemory error happened. Okay silly question time... How are you setting -Xms and -Xmx ? Are you sure they are being picked up by Tomcat? Regards, -- Jason Bainbridge http://kde.org - [EMAIL PROTECTED] Personal Site - http://jasonbainbridge.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OutOfMemoryError - 100 thread limit?
the number of threads seems odd. unless your webapp creates a bunch of threads using ServletContextListener, the total thread count should be between 10-15. I have a webapp which creates 10 threads on startup. When tomcat is done and my webapp is loaded, I have a total of 38. if your webapp is creating threads at start, what are they doing? peter lin Threads Active : 94 Threads Active : 94 [Full GC 48357K-47096K(129792K), 0.6358540 secs] LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: OutOfMemoryError - 100 thread limit?
From: LeeAnn Pultz [mailto:[EMAIL PROTECTED] Subject: RE: OutOfMemoryError - 100 thread limit? I turned on verbose:gc and ran the test again: [Full GC 48357K-47096K(129792K), 0.6358540 secs] This shows you've given the JVM only 128 MB to work with; looks like you really are out of heap space. You probably want to increase the maximum (-Xmx) considerably. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
going nuts here
I want to see if an image exists I dont want red x's yet I cant seem to get the real path to check with File so is there another way. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: going nuts here
Try ServletContext.getRealPath(relativePath) Didier McGillis wrote: I want to see if an image exists I dont want red x's yet I cant seem to get the real path to check with File so is there another way. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Robert r. Sanders Chief Technologist iPOV (334) 821-5412 www.ipov.net - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: jk 1.2.10 + apache 1.3 issue
The problem was a duplicate worker entry. Apparently, in JK2, duplicates were ignored. I've written a perl script that converts the JK2 config to a JK1 config because of the large number of entries- I'll just need to have it validate that there are no duplicate workers. Jk1 should probably handle this failure mode a little different- like with a 'duplicate worker' message/test. If it were as easy as a global search and replace on a single system, then I'd have no problem doing it. If I were at liberty to go into the details of all the impacts such a simple change causes at a megacorporation, you'd understand why its such a big deal. Its a huge/costly chain of events. Lets just say I'd be writing patches for Apache httpd long before we'd make such a change across all the servers because the overall cost per change is far less. Imagine coordinating 20 or more teams to test hundreds of applications because of strict change control procedures. Substituting the value in all of the files is the easy part... Thanks for the responses though. Is there a separate mailing list for jk1 development where I should post the suggestion to add a simple test/error message when parsing a duplicate worker? Byron -Original Message- From: Mladen Turk [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 20, 2005 12:20 PM To: Tomcat Users List Subject: Re: jk 1.2.10 + apache 1.3 issue Guernsey, Byron (GE Consumer Industrial) wrote: worked just fine under Apache 2 and we haven't seen any issues in the JK1 code or cookies with respect to the ':' in the JVM Routes. To you it might seem easier to change the jvmRoute, but unfortunately there are literally 100's of production app servers that would need changed and restarted. Well, there are users unlike you that do not allow cookies, so the colon in uri is invalid and needs to be encoded. Also I can give you few links to the editors that can do search and replace in multiple files at once ;). Also, just mail your workers.properties and httpd.conf. It would be much easier then guessing I suppose. If this is confidential data, then, well ... Regards, Mladen. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: going nuts here
In HTML use the 'alt' feature with the 'img' tag. -Original Message- From: Didier McGillis [EMAIL PROTECTED] Sent: Apr 20, 2005 2:35 PM To: tomcat-user@jakarta.apache.org Subject: going nuts here I want to see if an image exists I dont want red x's yet I cant seem to get the real path to check with File so is there another way. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OutOfMemoryError - 100 thread limit?
We tried a new test :) We added code that spins up 8 threads inside just a plain servlet that doesn't do anything else. When I fire up 10 different instances of that servlet, I get hundreds of threads printing out as being active - and no out of memory errors. So we added the same code to our (slightly more complex) application servlet, and did the same thing. Now the reported number of threads is much higher, but I still get an OutOfMemory error at the same number of new instances fired up (between 17-18 sites started up). Active Threads : WHEN STARTING INIT() 617 [GC 57193K-46096K(129792K), 0.0353880 secs] [GC 57936K-47554K(129792K), 0.0238210 secs] [Full GC 49312K-47441K(129792K), 0.6546550 secs] [Full GC 47732K-47129K(129792K), 0.7706500 secs] [Full GC 48310K-47256K(129792K), 0.6425030 secs] [Full GC 47276K-47263K(129792K), 0.6445770 secs] [Full GC 47263K-47263K(129792K), 0.6368020 secs] [Full GC 47263K-47241K(129792K), 0.7775600 secs] java.lang.OutOfMemoryError [Full GC 47295K-47242K(129792K), 0.6301470 secs] [Full GC 47248K-47245K(129792K), 0.6451800 secs] [Full GC 47257K-47250K(129792K), 0.6454320 secs] [Full GC 47271K-47262K(129792K), 0.7056980 secs] java.lang.OutOfMemoryError java.lang.OutOfMemoryError So it looks like it isn't just a thread issue. If I fire up the simple servlet 18 times, I don't get the error. In fact, I can then go on to fire up our main servlet another 17-18 times before we get the OutOfMemory error - this time at 844 threads before it dies. There must be something else going on within our application that is consuming something that the simple servlet doesn't. If anyone has any suggestions on other things that I could check for ? Someone said OOM errors can mean out of file descriptors as well? thanks for all your help so far - I'm really hoping we can figure this out! At 11:20 AM 4/20/2005, you wrote: the number of threads seems odd. unless your webapp creates a bunch of threads using ServletContextListener, the total thread count should be between 10-15. I have a webapp which creates 10 threads on startup. When tomcat is done and my webapp is loaded, I have a total of 38. if your webapp is creating threads at start, what are they doing? peter lin Threads Active : 94 Threads Active : 94 [Full GC 48357K-47096K(129792K), 0.6358540 secs] LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: jk 1.2.10 + apache 1.3 issue
Guernsey, Byron (GE Consumer Industrial) wrote: The problem was a duplicate worker entry. Apparently, in JK2, duplicates were ignored. I've written a perl script that converts the JK2 config to a JK1 config because of the large number of entries- I'll just need to have it validate that there are no duplicate workers. Yes. That would be the reason for '*' in between. Thanks for the responses though. Is there a separate mailing list for jk1 development where I should post the suggestion to add a simple test/error message when parsing a duplicate worker? Sure, tomcat-dev@ Regards, Mladen. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: OutOfMemoryError - 100 thread limit?
From: LeeAnn Pultz [mailto:[EMAIL PROTECTED] Subject: Re: OutOfMemoryError - 100 thread limit? [Full GC 47271K-47262K(129792K), 0.7056980 secs] If anyone has any suggestions on other things that I could check for ? It still looks like your heap size is too small - 128MB isn't much these days. Assuming you're using a Sun 1.4 JVM or later, try specifying -XX:+PrintGCDetails on the command line to see data about the individual generations of the heap to see which one is becoming exhausted. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: OutOfMemoryError - 100 thread limit?
Thanks - I'll try that - we do have CATALINA_OPTS set in catalina.sh of -Xms128m and -Xmx512m. At 02:12 PM 4/20/2005, you wrote: From: LeeAnn Pultz [mailto:[EMAIL PROTECTED] Subject: Re: OutOfMemoryError - 100 thread limit? [Full GC 47271K-47262K(129792K), 0.7056980 secs] If anyone has any suggestions on other things that I could check for ? It still looks like your heap size is too small - 128MB isn't much these days. Assuming you're using a Sun 1.4 JVM or later, try specifying -XX:+PrintGCDetails on the command line to see data about the individual generations of the heap to see which one is becoming exhausted. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
How to enable GC with Tomcat Service Manager
Hi, I'm running Tomcat as a Windows service using Tomcat Service Manager 0.2.8 (http://web.bvu.edu/staff/david/index.jsp?section=softwaresubsection=tcservcfgpage=overview). I'm now trying to enable the garbage collector output but am simply not getting any GC info in /cygdrive/D/jakarta-tomcat-4.1.24/logs/Tomcat4124_out.log. I've pasted the config below. Has anyone got any success with it? Guillaume. - Configuration Service name Tomcat4124 Catalina home D:\jakarta-tomcat-4.1.24 Catalina base D:\jakarta-tomcat-4.1.24 Tomcat config file D:\jakarta-tomcat-4.1.24\conf\server.xml Use security manager 0 Security policy file D:\jakarta-tomcat-4.1.24\conf\catalina.policy Java home c:\j2sdk1.4.1 JVM Path c:\j2sdk1.4.1\jre\bin\server\jvm.dll Classpath D:\jakarta-tomcat-4.1.24\bin\bootstrap.jar;D:\jakarta-tomcat-4.1.24\common\lib;c:\j2sdk1.4.1\lib\tools.jar Temp directory D:\jakarta-tomcat-4.1.24\temp System.out file D:\jakarta-tomcat-4.1.24\logs System.err file D:\jakarta-tomcat-4.1.24\logs Initial heap Max heap Stack size JVM server Additional JVM option -verbose:gc - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Logging setup in Embedded mode
Hi, Has anyone tried setting up tomcat logging using log4j or java logging when running tomcat 5.5.9 in embedded mode? In tomcat 4.1, I used FileLogger but this has changed in 5.5.9. Any help would be appreciated... Thanks, Sandeep - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: OutOfMemoryError - 100 thread limit?
After you've started your application, do a ps ax|grep java and see if that value is really making it into the command line; I'm doubting it is. To set these options, I added a the following the the .bash_profile of my tomcat user: export JAVA_OPTS=-Xmx1000m -ryan -Original Message- From: LeeAnn Pultz [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 20, 2005 4:35 PM To: Tomcat Users List Subject: RE: OutOfMemoryError - 100 thread limit? Thanks - I'll try that - we do have CATALINA_OPTS set in catalina.sh of -Xms128m and -Xmx512m. At 02:12 PM 4/20/2005, you wrote: From: LeeAnn Pultz [mailto:[EMAIL PROTECTED] Subject: Re: OutOfMemoryError - 100 thread limit? [Full GC 47271K-47262K(129792K), 0.7056980 secs] If anyone has any suggestions on other things that I could check for ? It still looks like your heap size is too small - 128MB isn't much these days. Assuming you're using a Sun 1.4 JVM or later, try specifying -XX:+PrintGCDetails on the command line to see data about the individual generations of the heap to see which one is becoming exhausted. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: AW: All threads (250) are currently busy
Zsolt, looks like i am not alone in this continuing problem, and thanks for the post. I should probably add that we use Tomcat in standalone mode as both web server and servlet engine and don't go though an apache web server. Here are the relevant bits from the Tomcat server xml. N.B Apache connector is still specified even though we are not going through an Apache web server. !-- Define a non-SSL HTTP/1.1 Connector on port 80 -- Connector port=80 maxThreads=250 minSpareThreads=25 maxSpareThreads=75 enableLookups=false redirectPort=8443 acceptCount=100 connectionTimeout=2 disableUploadTimeout=true / !-- Define an AJP 1.3 Connector on port 8009 -- Connector port=8009 enableLookups=false redirectPort=8443 protocol=AJP/1.3 / Does this look correct? Paul Zsolt Koppany [EMAIL PROTECTED] 20/04/2005 21:08 Please respond to Tomcat Users List To: 'Tomcat Users List' tomcat-user@jakarta.apache.org cc: Subject:AW: All threads (250) are currently busy We had the same problem, but after configuring the apache connector correctly the problem disappeared. Zsolt -Ursprüngliche Nachricht- Von: Paul Grimwood [mailto:[EMAIL PROTECTED] Gesendet: Mittwoch, 20. April 2005 06:07 An: tomcat-user@jakarta.apache.org Betreff: All threads (250) are currently busy Tomcat hangs intermittently (1 to 10 days) with the following message in catalina.out 20/04/2005 13:48:09 org.apache.tomcat.util.threads.ThreadPool logFull SEVERE: All threads (250) are currently busy, waiting. Increase maxThreads (250) or check the servlet status We are running tomcat 5.5.7 on jdk1.5.0_02 under Redhat Linux Fedora Core 2 against an Oracle9 DB. I have seen various posts to this with suggestions including setting Linux threads with LD_ASSUME_KERNEL (tried but problem still exists) and setting connection timeout in server.xml from 0 to 6 (but ours is set at 2 already). And we have already upgraded to latest Tomcat and JRE to no avail. Despite reviewing the mailing list over the past 18 to 24 months, i am none the wiser. The problem started around the time we deployed the code onto a new server running a later Linux version but this could be a red herring and I suspect it is a database connection issue. Has anyone got any ideas? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat/Integration Problems
Guru, Thanks for responding. what you suggested didnt seem to work completely. Quick review:192.168.1.200 is the local server address. here is what happens Locally Remotely: 192.168.1.200 Displays Apache web page remotely: 192.168.1.200:8080 Displays tomcat page. Locally: times out remotely 192.168.1.200:8080/examples/servlets/index.html. Displays tomcat page. Locally: times out remotely 192.168.1.200/examples/servlets/index.html. Returns http 404: Locally: times out Locally: http://localhost Displays Apache page Locally; Http//localhost/8080 displays tomcat page locally: http://localhost/examples/servlets/index.html displays tomcat page locally: http://localhost:8080/examples/servlets/index.html I think i maybe the mod_jk is having trouble porting to 192.168.1.200, i am not sure what to do with this. any other ideas? Gurumoorthy [EMAIL PROTECTED] wrote: try changing the name=localhost to 192.168.1.200 in your server.xml and restart both .. Guru - Original Message - From: edwin roberts To: Tomcat Users List Sent: Wednesday, April 20, 2005 4:49 PM Subject: Tomcat/Integration Problems __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com
RE: OutOfMemoryError - 100 thread limit?
The memory parameters as well as the other CATALINA_OPTS that we set do appear on the process: [EMAIL PROTECTED] webapps]$ ps ax|grep stage2_java 866 pts/1R 0:10 /home/sesame/stage2_java/bin/java -verbose:gc -server -Xms128m -Xmx512m -Djava.awt.headless=true -Djava.endorsed.dirs=/usr/local/extraview/stage2/tomcat/common/endorsed -classpath /home/sesame/stage2_java/lib/tools.jar:/usr/local/extraview/stage2/tomcat/bin/bootstrap.jar:/usr/local/extraview/ At 03:00 PM 4/20/2005, you wrote: After you've started your application, do a ps ax|grep java and see if that value is really making it into the command line; I'm doubting it is. To set these options, I added a the following the the .bash_profile of my tomcat user: export JAVA_OPTS=-Xmx1000m -ryan -Original Message- From: LeeAnn Pultz [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 20, 2005 4:35 PM To: Tomcat Users List Subject: RE: OutOfMemoryError - 100 thread limit? Thanks - I'll try that - we do have CATALINA_OPTS set in catalina.sh of -Xms128m and -Xmx512m. At 02:12 PM 4/20/2005, you wrote: From: LeeAnn Pultz [mailto:[EMAIL PROTECTED] Subject: Re: OutOfMemoryError - 100 thread limit? [Full GC 47271K-47262K(129792K), 0.7056980 secs] If anyone has any suggestions on other things that I could check for ? It still looks like your heap size is too small - 128MB isn't much these days. Assuming you're using a Sun 1.4 JVM or later, try specifying -XX:+PrintGCDetails on the command line to see data about the individual generations of the heap to see which one is becoming exhausted. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] LeeAnn Pultz ExtraView Corporation [EMAIL PROTECTED] 831-461-7100 x115 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat SSO with other web servers
Hi All, What Single-Sign-On strategy do you guys use for Tomcat? I know the tomcat docs support SSO within webapps on the same in-process tomcat instance, but what SSO techniques are you guys using to authenticate with other webservers like WebSphere and IIS? Is there a SAML implementation used for Tomcat?? I'm fairly new to the SSO game so any suggestions, links, whitepapers, etc.. would be very helpful. Thanks, Patrick - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Britta Albrecht/HKG/HELLA ist außer Haus.
Ich werde ab 21.04.2005 nicht im Büro sein. Ich kehre zurück am 25.04.2005. Ich werde Ihre Nachricht nach meiner Rückkehr beantworten. In dringenden Fällen wenden Sie sich bitte an Frau Dagmar Ernst (0 29 41/38 67 17, [EMAIL PROTECTED]). - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: AW: All threads (250) are currently busy
Can you share your apache connector config? On Wed, 20 Apr 2005, Zsolt Koppany wrote: Date: Wed, 20 Apr 2005 11:08:33 +0200 From: Zsolt Koppany [EMAIL PROTECTED] Reply-To: Tomcat Users List tomcat-user@jakarta.apache.org To: 'Tomcat Users List' tomcat-user@jakarta.apache.org Subject: AW: All threads (250) are currently busy We had the same problem, but after configuring the apache connector correctly the problem disappeared. Zsolt -Ursprüngliche Nachricht- Von: Paul Grimwood [mailto:[EMAIL PROTECTED] Gesendet: Mittwoch, 20. April 2005 06:07 An: tomcat-user@jakarta.apache.org Betreff: All threads (250) are currently busy Tomcat hangs intermittently (1 to 10 days) with the following message in catalina.out 20/04/2005 13:48:09 org.apache.tomcat.util.threads.ThreadPool logFull SEVERE: All threads (250) are currently busy, waiting. Increase maxThreads (250) or check the servlet status We are running tomcat 5.5.7 on jdk1.5.0_02 under Redhat Linux Fedora Core 2 against an Oracle9 DB. I have seen various posts to this with suggestions including setting Linux threads with LD_ASSUME_KERNEL (tried but problem still exists) and setting connection timeout in server.xml from 0 to 6 (but ours is set at 2 already). And we have already upgraded to latest Tomcat and JRE to no avail. Despite reviewing the mailing list over the past 18 to 24 months, i am none the wiser. The problem started around the time we deployed the code onto a new server running a later Linux version but this could be a red herring and I suspect it is a database connection issue. Has anyone got any ideas? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
localhost Context files and path = /
Hi all, I've been trying to deploy Sakai 1.5 on my Tomcat 5.5.7. One of the Contexts, sakai-dispatch, is supposed to replace the ROOT Context. My CATALINA_HOME/conf/catalina/localhost/sakai-dispatch.xml file contains the following code: Context path=/ docBase=f:/usr/local/sakai/sakai-dispatch crossContext=true Realm className=org.sakaiproject.dav.DavRealm / /Context When I move this code into my CATALINA_HOME/conf/server.xml file, Sakai works. At first I thought sakai-dispatch.xml is not being read, so I added some garbage to sakai-dispatch.xml, but upon running CATALINA_HOME/bin/startup.bat the output window gave me some error messages based on the Digester. My conclusion is this: sakai-dispatch.xml is working, but for some reason it's not letting me set the path to /. Any ideas? Joe Bautista Fuller Seminary Programmer/Analyst - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: OutOfMemoryError - 100 thread limit?
if your application is thread heavy, I would recommend changing it so that one thread can manage several processes. creating 800+ threads is going to hit a scalability and reliability wall very quickly. In general, you want to make sure the number of threads remain constant under constant load. If it doesn't the server will eventually crash as you currently see. I'm guessing the application is using threads to handle async processes, which is good, but spawning new threads with every request isn't going to work. hope that helps peter On 4/20/05, LeeAnn Pultz [EMAIL PROTECTED] wrote: We tried a new test :) We added code that spins up 8 threads inside just a plain servlet that doesn't do anything else. When I fire up 10 different instances of that servlet, I get hundreds of threads printing out as being active - and no out of memory errors. So we added the same code to our (slightly more complex) application servlet, and did the same thing. Now the reported number of threads is much higher, but I still get an OutOfMemory error at the same number of new instances fired up (between 17-18 sites started up). Active Threads : WHEN STARTING INIT() 617 [GC 57193K-46096K(129792K), 0.0353880 secs] [GC 57936K-47554K(129792K), 0.0238210 secs] [Full GC 49312K-47441K(129792K), 0.6546550 secs] [Full GC 47732K-47129K(129792K), 0.7706500 secs] [Full GC 48310K-47256K(129792K), 0.6425030 secs] [Full GC 47276K-47263K(129792K), 0.6445770 secs] [Full GC 47263K-47263K(129792K), 0.6368020 secs] [Full GC 47263K-47241K(129792K), 0.7775600 secs] java.lang.OutOfMemoryError [Full GC 47295K-47242K(129792K), 0.6301470 secs] [Full GC 47248K-47245K(129792K), 0.6451800 secs] [Full GC 47257K-47250K(129792K), 0.6454320 secs] [Full GC 47271K-47262K(129792K), 0.7056980 secs] java.lang.OutOfMemoryError java.lang.OutOfMemoryError So it looks like it isn't just a thread issue. If I fire up the simple servlet 18 times, I don't get the error. In fact, I can then go on to fire up our main servlet another 17-18 times before we get the OutOfMemory error - this time at 844 threads before it dies. There must be something else going on within our application that is consuming something that the simple servlet doesn't. If anyone has any suggestions on other things that I could check for ? Someone said OOM errors can mean out of file descriptors as well? thanks for all your help so far - I'm really hoping we can figure this out! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: localhost Context files and path = /
This is not allowed in Tomcat 5.5.x http://jakarta.apache.org/tomcat/tomcat-5.5-doc/config/context.html Do not declare the path if the path is null or / in the context unless you are doing a static in the server.xml With that in mind think about the fact that there is already a context element in the server.xml This is the context element for the app you are trying to deploy. Modify it to suit your needs. Unlike the others that are declared in the war, the context for the ROOT app is in the server.xml and nowhere else. Doug - Original Message - From: Joe Bautista [EMAIL PROTECTED] To: Tomcat Users List tomcat-user@jakarta.apache.org Sent: Wednesday, April 20, 2005 8:02 PM Subject: localhost Context files and path = / Hi all, I've been trying to deploy Sakai 1.5 on my Tomcat 5.5.7. One of the Contexts, sakai-dispatch, is supposed to replace the ROOT Context. My CATALINA_HOME/conf/catalina/localhost/sakai-dispatch.xml file contains the following code: Context path=/ docBase=f:/usr/local/sakai/sakai-dispatch crossContext=true Realm className=org.sakaiproject.dav.DavRealm / /Context When I move this code into my CATALINA_HOME/conf/server.xml file, Sakai works. At first I thought sakai-dispatch.xml is not being read, so I added some garbage to sakai-dispatch.xml, but upon running CATALINA_HOME/bin/startup.bat the output window gave me some error messages based on the Digester. My conclusion is this: sakai-dispatch.xml is working, but for some reason it's not letting me set the path to /. Any ideas? Joe Bautista Fuller Seminary Programmer/Analyst - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: localhost Context files and path = /
Joe, Have you tried adding that context element to your host element in server.xml? Also I think you need path= in order to specify the root of the server. Fritz -Original Message- From: Joe Bautista [mailto:[EMAIL PROTECTED] Sent: Wednesday, April 20, 2005 5:02 PM To: Tomcat Users List Subject: localhost Context files and path = / Hi all, I've been trying to deploy Sakai 1.5 on my Tomcat 5.5.7. One of the Contexts, sakai-dispatch, is supposed to replace the ROOT Context. My CATALINA_HOME/conf/catalina/localhost/sakai-dispatch.xml file contains the following code: Context path=/ docBase=f:/usr/local/sakai/sakai-dispatch crossContext=true Realm className=org.sakaiproject.dav.DavRealm / /Context When I move this code into my CATALINA_HOME/conf/server.xml file, Sakai works. At first I thought sakai-dispatch.xml is not being read, so I added some garbage to sakai-dispatch.xml, but upon running CATALINA_HOME/bin/startup.bat the output window gave me some error messages based on the Digester. My conclusion is this: sakai-dispatch.xml is working, but for some reason it's not letting me set the path to /. Any ideas? Joe Bautista Fuller Seminary Programmer/Analyst - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]