Limit to number of web applications
I was wondering if there is any type of limit to how many web applications you can run with tomcat. I am only looking at about 5 concurrent users per application. I have 5 deployed right now and was wondering if I should keep deploying or install another tomcat. I am going to eventually need to have about 25 applications altogether. Thanks,
Any Known File Descriptor Issue?
Our system exports multiple files at a time, by export we mean generate the files in pure html and download them. The number of files generated can be anywhere from 10 - unlimited number of html files. The export and html generation works fine as long as we don't run out of file descriptors on the Solaris box. But as soon as we reach 1024 file descriptors the application dies. We could increase the file descriptors but we know that's not efficient and practical. What we don't understand is why the file descriptors are being left open. We close all the files after they are created and the application garbage collects all the objects too. If we run the same code as a stand alone java app through the command line it works great. Creates the files and leaves no file descriptors open. It seems to only happen when we run it through Tomcat 4.1.24. Is there a file descriptor leak in Tomcat 4.1.24? Can anyone explain why we are having this problem or recommend a solution for us?
catalina.out log
I am getting these odd logs in the Catalina.out. 67928 7830 1 67928 7830 1 I am not sure what they are but I get them often and they always come in groups of three numbers. Thanks,
Odd Memory Problem
I have been battling a memory problem for a few months now with no luck. I have used profilers and everything else you could imagine. The problem is we have never been able to duplicate it on the testing servers it only happens on production which does not see much load at all (100 users a day). I noticed something very odd yesterday though. I am using the -XX:+UseConcMarkSweepGC and -Xms512m. I was monitoring the garbage collection activity very closely and I was receiving good performance for 3 days. I was seeing one garbage collection about every 5 minutes in the Catalina.out. Then out of nowhere the garbage collection starting going crazy, about one garbage collection a second, I checked the cpu usage and it was stuck around 60% used. There were only 2-4 people logged in at a time. The crazy garbage collection went on for a couple of hours before it eventually crapped out with Out of Memory errors. It almost seems like a section of the app caused this sudden outburst but there is no way our QA department hasn't went over the same section. I was hoping some one seen or heard of this before. Below is my environment. Thanks, Apache2.0.47 using mod_jk2 2 * tomcat4.1.24 J2sdk1.4.2_04
Garbage Collection
Can anybody tell me if these look like healthy garbage collections. [GC [ParNew: 3968K-0K(4032K), 0.0132890 secs] 25349K-22156K(56072K), 0.0134572 secs] [GC [ParNew: 3952K-0K(4032K), 0.0086222 secs] 26109K-22649K(56072K), 0.0087891 secs] [GC [ParNew: 3953K-0K(4032K), 0.0092634 secs] 26602K-23133K(56072K), 0.0094345 secs] [GC [ParNew: 3967K-0K(4032K), 0.0094125 secs] 27101K-23289K(56072K), 0.0095833 secs] [GC [ParNew: 3961K-0K(4032K), 0.0474236 secs] 27250K-23491K(56072K), 0.0476528 secs] [GC [ParNew: 3966K-0K(4032K), 0.0101857 secs] 27458K-23644K(56072K), 0.0103671 secs] [GC [ParNew: 3968K-0K(4032K), 0.0088548 secs] 27612K-23776K(56072K), 0.0090263 secs] [GC [ParNew: 3968K-0K(4032K), 0.0075491 secs] 27744K-23842K(56072K), 0.0077127 secs] [GC [ParNew: 3967K-0K(4032K), 0.0107583 secs] 27810K-24144K(56072K), 0.0109381 secs] [GC [ParNew: 3967K-0K(4032K), 0.0588864 secs] 28112K-24470K(56072K), 0.0591110 secs] [GC [ParNew: 3964K-0K(4032K), 0.0076312 secs] 28435K-24576K(56072K), 0.0077934 secs] [GC [ParNew: 3967K-0K(4032K), 0.0076016 secs] 28544K-24659K(56072K), 0.0077809 secs] [GC [ParNew: 3967K-0K(4032K), 0.0094214 secs] 28627K-24907K(56072K), 0.0095959 secs] [GC [ParNew: 3967K-0K(4032K), 0.0081766 secs] 28875K-25413K(56072K), 0.0083235 secs] [GC [ParNew: 3964K-0K(4032K), 0.0476766 secs] 29378K-25736K(56072K), 0.0478634 secs] [GC [ParNew: 3967K-0K(4032K), 0.0131406 secs] 29704K-26056K(56072K), 0.0133119 secs] [GC [ParNew: 3967K-0K(4032K), 0.0127321 secs] 30024K-26486K(56072K), 0.0128994 secs] [GC [ParNew: 3967K-0K(4032K), 0.0170908 secs] 30453K-27044K(56072K), 0.0172648 secs] [GC [ParNew: 3946K-0K(4032K), 0.0258431 secs] 30991K-28401K(56072K), 0.0260299 secs] [GC [ParNew: 3967K-0K(4032K), 0.0097711 secs] 32368K-29151K(56072K), 0.0099655 secs] [GC [ParNew: 3967K-0K(4032K), 0.0277493 secs] 33119K-30963K(56072K), 0.0279320 secs] [GC [ParNew: 3967K-0K(4032K), 0.0148470 secs] 34931K-31791K(56072K), 0.0150112 secs] [GC [ParNew: 3961K-0K(4032K), 0.0252186 secs] 35753K-33458K(56072K), 0.0253967 secs] [GC [ParNew: 3956K-0K(4032K), 0.0094682 secs] 37414K-34072K(56072K), 0.0096453 secs] [GC [ParNew: 3967K-0K(4032K), 0.0086307 secs] 38040K-34737K(56072K), 0.0088139 secs] [GC [ParNew: 3961K-0K(4032K), 0.0085751 secs] 38699K-35289K(56072K), 0.0087476 secs] [GC [ParNew: 3967K-0K(4032K), 0.0092369 secs] 39257K-35818K(56072K), 0.0095723 secs] [GC [1 CMS-initial-mark: 35818K(52040K)] 35818K(56072K), 0.0051687 secs] [CMS-concurrent-mark: 0.414/0.414 secs] [CMS-concurrent-preclean: 0.004/0.004 secs] [GC[Rescan (parallel) , 0.0071662 secs][weak refs processing, 0.0076101 secs] [1 CMS-remark: 35818K(52040K)] 3 5879K(56072K), 0.0157375 secs] [CMS-concurrent-sweep: 0.131/0.131 secs] [CMS-concurrent-reset: 0.124/0.124 secs] [GC [ParNew: 3967K-0K(4032K), 0.0108625 secs] 20393K-16549K(56072K), 0.0110341 secs]
RE: Garbage Collection
The weird thing is everything will be running fine for a few hours (or days, very inconsistent) then it seems like the garbage collector cannot keep up with the used space and the heap gets bigger and bigger while nearly nothing gets cleared, when this happens I have noticed the CPU stuck around 60% used, eventually it will crash with (Out of Memory not enough Swap Space). I have used JProfiler to try and find memory issues but the odd thing is we have never been able to duplicate this problem in our testing environment only in production. -Original Message- From: Peter Lin [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 30, 2004 1:08 PM To: Tomcat Users List Subject: Re: Garbage Collection your heap size remains stable according to the verbose GC. That in itself doesn't tell you if there is a problem or not. Is there some slowness in your jsp? you might want to d/l borland optimizeIt trial version and get a better picture of what is happening. peter Rob Wichterman [EMAIL PROTECTED] wrote: Can anybody tell me if these look like healthy garbage collections. [GC [ParNew: 3968K-0K(4032K), 0.0132890 secs] 25349K-22156K(56072K), 0.0134572 secs] [GC [ParNew: 3952K-0K(4032K), 0.0086222 secs] 26109K-22649K(56072K), 0.0087891 secs] [GC [ParNew: 3953K-0K(4032K), 0.0092634 secs] 26602K-23133K(56072K), 0.0094345 secs] [GC [ParNew: 3967K-0K(4032K), 0.0094125 secs] 27101K-23289K(56072K), 0.0095833 secs] [GC [ParNew: 3961K-0K(4032K), 0.0474236 secs] 27250K-23491K(56072K), 0.0476528 secs] [GC [ParNew: 3966K-0K(4032K), 0.0101857 secs] 27458K-23644K(56072K), 0.0103671 secs] [GC [ParNew: 3968K-0K(4032K), 0.0088548 secs] 27612K-23776K(56072K), 0.0090263 secs] [GC [ParNew: 3968K-0K(4032K), 0.0075491 secs] 27744K-23842K(56072K), 0.0077127 secs] [GC [ParNew: 3967K-0K(4032K), 0.0107583 secs] 27810K-24144K(56072K), 0.0109381 secs] [GC [ParNew: 3967K-0K(4032K), 0.0588864 secs] 28112K-24470K(56072K), 0.0591110 secs] [GC [ParNew: 3964K-0K(4032K), 0.0076312 secs] 28435K-24576K(56072K), 0.0077934 secs] [GC [ParNew: 3967K-0K(4032K), 0.0076016 secs] 28544K-24659K(56072K), 0.0077809 secs] [GC [ParNew: 3967K-0K(4032K), 0.0094214 secs] 28627K-24907K(56072K), 0.0095959 secs] [GC [ParNew: 3967K-0K(4032K), 0.0081766 secs] 28875K-25413K(56072K), 0.0083235 secs] [GC [ParNew: 3964K-0K(4032K), 0.0476766 secs] 29378K-25736K(56072K), 0.0478634 secs] [GC [ParNew: 3967K-0K(4032K), 0.0131406 secs] 29704K-26056K(56072K), 0.0133119 secs] [GC [ParNew: 3967K-0K(4032K), 0.0127321 secs] 30024K-26486K(56072K), 0.0128994 secs] [GC [ParNew: 3967K-0K(4032K), 0.0170908 secs] 30453K-27044K(56072K), 0.0172648 secs] [GC [ParNew: 3946K-0K(4032K), 0.0258431 secs] 30991K-28401K(56072K), 0.0260299 secs] [GC [ParNew: 3967K-0K(4032K), 0.0097711 secs] 32368K-29151K(56072K), 0.0099655 secs] [GC [ParNew: 3967K-0K(4032K), 0.0277493 secs] 33119K-30963K(56072K), 0.0279320 secs] [GC [ParNew: 3967K-0K(4032K), 0.0148470 secs] 34931K-31791K(56072K), 0.0150112 secs] [GC [ParNew: 3961K-0K(4032K), 0.0252186 secs] 35753K-33458K(56072K), 0.0253967 secs] [GC [ParNew: 3956K-0K(4032K), 0.0094682 secs] 37414K-34072K(56072K), 0.0096453 secs] [GC [ParNew: 3967K-0K(4032K), 0.0086307 secs] 38040K-34737K(56072K), 0.0088139 secs] [GC [ParNew: 3961K-0K(4032K), 0.0085751 secs] 38699K-35289K(56072K), 0.0087476 secs] [GC [ParNew: 3967K-0K(4032K), 0.0092369 secs] 39257K-35818K(56072K), 0.0095723 secs] [GC [1 CMS-initial-mark: 35818K(52040K)] 35818K(56072K), 0.0051687 secs] [CMS-concurrent-mark: 0.414/0.414 secs] [CMS-concurrent-preclean: 0.004/0.004 secs] [GC[Rescan (parallel) , 0.0071662 secs][weak refs processing, 0.0076101 secs] [1 CMS-remark: 35818K(52040K)] 3 5879K(56072K), 0.0157375 secs] [CMS-concurrent-sweep: 0.131/0.131 secs] [CMS-concurrent-reset: 0.124/0.124 secs] [GC [ParNew: 3967K-0K(4032K), 0.0108625 secs] 20393K-16549K(56072K), 0.0110341 secs] - Do you Yahoo!? Yahoo! Finance Tax Center - File online. File on time. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Connection is Closed
I keep receiving a Connection is Closed error in my tomcat localhost_log. After receiving this error I have to restart tomcat to reconnect to oracle. Is there any type of auto reconnect parameter? Thanks,
RE: Connection is Closed
I am connecting to Oracle 9i not MySql. Sorry I should've mentioned this in my original message. Thanks, -Original Message- From: Tom K [mailto:[EMAIL PROTECTED] Sent: Monday, March 29, 2004 9:14 AM To: 'Tomcat Users List' Subject: RE: Connection is Closed In your server.xml file if you are using connection pooling you can put a line in like this: valuejdbc:mysql://localhost:3306/Classifieds?autoReconnect=true/value -- - parameter nameurl/name valuejdbc:mysql://localhost:3306/Classifieds?autoReconnect=true/value /parameter /ResourceParams /Context /Host /Engine /Service /Server Hope that does the trick. Tom Kochanowicz -Original Message- From: Rob Wichterman [mailto:[EMAIL PROTECTED] Sent: Monday, March 29, 2004 7:36 AM To: 'Tomcat Users List' Subject: Connection is Closed I keep receiving a Connection is Closed error in my tomcat localhost_log. After receiving this error I have to restart tomcat to reconnect to oracle. Is there any type of auto reconnect parameter? Thanks, --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.557 / Virus Database: 349 - Release Date: 12/30/2003 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.557 / Virus Database: 349 - Release Date: 12/30/2003 - 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]
Connection Closed
I had a weird connection problem with Tomcat4.1.24 today. Here is the error: Mar 26, 2004 8:44:45 AM org.apache.jk.server.JkCoyoteHandler action INFO: RESET I received about 10 of these during which I could not login to my application. The index page came up with out any problems but it seems that the database connection was closed. I restarted one of my 2 Tomcat servers and everything was fine. I am using the following connection pooler and assumed it would automatically reconnect. Any help would be appreciated. Thanks parameter namefactory/name valueorg.apache.commons.dbcp.BasicDataSourceFactory/value /parameter
Garbage collector
I was wondering if anyone had a preference in which garbage collector to use. I am currently using -XX:+UseConcMarkSweepGC but I was wondering which would be considered the best or most commonly used. Thanks
tomcat4.1.30 compiler problem
Has anyone had a problem with tomcat4.1.30 that was crashing the jvm? I am running Solaris 8 with j2sdk1.4.2_04. Tomcat4.1.24 has no problem compiling the jsp's but 4.1.30 crashes after 4 or 5 compiled pages. I tried different jvm's, patched my OS and even deployed other webapps with the same problem. Below is the error in Catalina.out: Unexpected Signal : 10 occurred at PC=0xF989BF40 Function=java.lang.String.startsWith(Ljava/lang/String;I)Z (compiled Java code) Library=(N/A) Current Java thread: Dynamic libraries: 0x1 /usr/j2sdk1.4.2_04/bin/java 0xff36 /usr/lib/libthread.so.1 0xff3a /usr/lib/libdl.so.1 0xff20 /usr/lib/libc.so.1 0xff34 /usr/platform/SUNW,Sun-Blade-1000/lib/libc_psr.so.1 0xfe00 /usr/j2sdk1.4.2_04/jre/lib/sparc/client/libjvm.so 0xff2e /usr/lib/libCrun.so.1 0xff1e /usr/lib/libsocket.so.1 0xff10 /usr/lib/libnsl.so.1 0xff0d /usr/lib/libm.so.1 0xff1c /usr/lib/libsched.so.1 0xff31 /usr/lib/libw.so.1 0xff0a /usr/lib/libmp.so.2 0xff07 /usr/j2sdk1.4.2_04/jre/lib/sparc/native_threads/libhpi.so 0xfe7d /usr/j2sdk1.4.2_04/jre/lib/sparc/libverify.so 0xfe79 /usr/j2sdk1.4.2_04/jre/lib/sparc/libjava.so 0xff02 /usr/j2sdk1.4.2_04/jre/lib/sparc/libzip.so 0xfe4b /usr/lib/locale/en_US.ISO8859-1/en_US.ISO8859-1.so.2 0xf969 /usr/j2sdk1.4.2_04/jre/lib/sparc/libnet.so Heap at VM Abort: Heap par new generation total 4032K, used 2395K [0xd540, 0xd580, 0xd5c0) eden space 3968K, 60% used [0xd540, 0xd5656d08, 0xd57e) from space 64K, 0% used [0xd57f, 0xd57f, 0xd580) to space 64K, 0% used [0xd57e, 0xd57e, 0xd57f) concurrent mark-sweep generation total 23296K, used 18406K [0xd5c0, 0xd72c, 0xf540) concurrent-mark-sweep perm gen total 13576K, used 13033K [0xf540, 0xf6142000, 0xf940) Local Time = Mon Mar 15 10:59:42 2004 Elapsed Time = 66 # # HotSpot Virtual Machine Error : 10 # Error ID : 4F530E43505002EF 01 # Please report this error at # http://java.sun.com/cgi-bin/bugreport.cgi # # Java VM: Java HotSpot(TM) Client VM (1.4.2_04-b05 mixed mode) # # An error report file has been saved as hs_err_pid1883.log. # Please refer to the file for further information. # #
Stable Version
I am trying to get tomcat4.1.30 to work with my webapp. It keeps dying with thefollowing error: This seems to happen while it is compiling the jsp's. Any help would be appreciated. Which release is the most stable? Unexpected Signal : 10 occurred at PC=0xFE2315BC Function=[Unknown. Nearest: JVM_IsSameClassPackage+0x86150] Library=/usr/j2sdk1.4.2_02/jre/lib/sparc/client/libjvm.so Dynamic libraries: 0x1 /usr/j2sdk1.4.2_02/bin/java 0xff35 /usr/lib/libthread.so.1 0xff39 /usr/lib/libdl.so.1 0xff20 /usr/lib/libc.so.1 0xff34 /usr/platform/SUNW,Sun-Blade-1000/lib/libc_psr.so.1 0xfe00 /usr/j2sdk1.4.2_02/jre/lib/sparc/client/libjvm.so 0xff2e /usr/lib/libCrun.so.1 0xff1e /usr/lib/libsocket.so.1 0xff10 /usr/lib/libnsl.so.1 0xff0d /usr/lib/libm.so.1 0xff1c /usr/lib/libsched.so.1 0xff31 /usr/lib/libw.so.1 0xff0a /usr/lib/libmp.so.2 0xff06 /usr/j2sdk1.4.2_02/jre/lib/sparc/native_threads/libhpi.so 0xfe7d /usr/j2sdk1.4.2_02/jre/lib/sparc/libverify.so 0xfe79 /usr/j2sdk1.4.2_02/jre/lib/sparc/libjava.so 0xff02 /usr/j2sdk1.4.2_02/jre/lib/sparc/libzip.so 0xfe4b /usr/lib/locale/en_US.ISO8859-1/en_US.ISO8859-1.so.2 0xf979 /usr/j2sdk1.4.2_02/jre/lib/sparc/libnet.so Heap at VM Abort: Heap par new generation total 4032K, used 654K [0xd540, 0xd580, 0xd5c0) eden space 3968K, 16% used [0xd540, 0xd54a38c0, 0xd57e) from space 64K, 0% used [0xd57e, 0xd57e, 0xd57f) to space 64K, 0% used [0xd57f, 0xd57f, 0xd580)
Tomcat JProfiler
I setup JProfiler to run on my tomcat and I am running into 2 issues I was hoping someone else has also had. 1. I am passing the JProfiler parameters through my JAVA_OPTS in Catelina.sh and when I also try to set my heap size and/or garbage collection parameters tomcat doesn't seem to start. It works fine with one or the other. 2. If I shutdown tomcat the Jprofiler process will not shutdown unless I manually kill it. Thanks in advance, Rob
Broken Pipe
I received this error twice before my tomcat 4.1.24 server died. Does anyone know what this error is: 2003-12-04 16:37:45 StandardWrapperValve[default]: Servlet.service() for servlet default threw exception java.net.SocketException: Broken pipe at java.net.SocketOutputStream.socketWrite0(Native Method) at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92) at java.net.SocketOutputStream.write(SocketOutputStream.java:136) at org.apache.jk.common.ChannelSocket.send(ChannelSocket.java:407) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:599) at org.apache.jk.server.JkCoyoteHandler.doWrite(JkCoyoteHandler.java:216) at org.apache.coyote.Response.doWrite(Response.java:524) at org.apache.coyote.tomcat4.OutputBuffer.realWriteBytes(OutputBuffer.java: 384) at org.apache.tomcat.util.buf.ByteChunk.flushBuffer(ByteChunk.java:439) at org.apache.tomcat.util.buf.ByteChunk.append(ByteChunk.java:359) at org.apache.coyote.tomcat4.OutputBuffer.writeBytes(OutputBuffer.java:411) at org.apache.coyote.tomcat4.OutputBuffer.write(OutputBuffer.java:398) at org.apache.coyote.tomcat4.CoyoteOutputStream.write(CoyoteOutputStream.ja va:110) at org.apache.catalina.servlets.DefaultServlet.copyRange(DefaultServlet.jav a:1996) at org.apache.catalina.servlets.DefaultServlet.copy(DefaultServlet.java:174 5) at org.apache.catalina.servlets.DefaultServlet.serveResource(DefaultServlet .java:1073) at org.apache.catalina.servlets.DefaultServlet.doGet(DefaultServlet.java:50 6) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica tionFilterChain.java:247) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt erChain.java:193) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv e.java:256) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i nvokeNext(StandardPipeline. java:643) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4 80) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv e.java:191) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i nvokeNext(StandardPipeline. java:643) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4 80) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:241 5) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java :180) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i nvokeNext(StandardPipeline. java:643) at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherVa lve.java:171) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i nvokeNext(StandardPipeline. java:641) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java :172) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i nvokeNext(StandardPipeline. java:641) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4 80) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve. java:174) at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.i nvokeNext(StandardPipeline. java:643) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4 80) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995) at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:223) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:261) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:360) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:604) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java: 562) at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:679) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool .java:619) at java.lang.Thread.run(Thread.java:534) Rob Wichterman Systems Analyst Nuventive 3996 Mount Royal Blvd. Allison Park, PA 15101 Tel: 412-487-7424 Fax: 412-487-3355 Email: [EMAIL PROTECTED] Website: file:///C:\Documents%20and%20Settings\dmoriarty\Application%20Data\Micr osoft\Signatures\www.nuventive.com www.nuventive.com
OutOfMemory Exception initializing page context
Hello, I am having major memory problem that I have been fighting through. Has any body ever seen this one. Here are the errors that always come up in my logs. 1. java.lang.IllegalStateException: getAttribute: Session already invalidated 2. JspFactoryImpl: Exception initializing page context java.lang.IllegalStateException: Cannot create a session after the response has been committed 3. JspFactoryImpl: Exception initializing page context java.lang.OutOfMemoryError Any help at all would be greatly appreciated. Thanks, Rob Wichterman
RE: OutOfMemory Exception initializing page context
Well I have had my -Xmx set to as high as 1gb and I still receive these errors. The site will stay running for at best 1 day without crashing. I was just hoping one of these could point me in a direction while I work on looking at memory leaks. Thanks, Rob -Original Message- From: Christopher Schultz [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 02, 2003 10:25 AM To: Tomcat Users List Subject: Re: OutOfMemory Exception initializing page context What's with all the OOM questions this week? I've noticed that topics tend to come in waves. I wonder if there are only like 5 people out there that post to the newsgroup, but they have all kinds of alias and alternate personalities so that the average response is what they use to solve their problems :) Just an amusing thought to make me smile. :) There. I did it. -chris Shapira, Yoav wrote: Howdy, Once you're out of memory, the system is in a bad state and must be restarted. You will see error messages that are at best meaningless and at worst misleading, because they will make you look in the wrong places. You want to fix the memory issue first, by adding more memory (via the -Xmx java command-line parameter) or fixing a memory leak if there's one in your application. Do not assume, for example, that the IllegalStateException you cite has anything to do with the OutOfMemory error: it may be a misleading message thrown by the system after it ran out of memory (even though it shows up before the OutOfMemoryError in the log) while it was thrashing to GC stuff by invalidating your sessions. Yoav Shapira Millennium ChemInformatics -Original Message- From: Rob Wichterman [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 02, 2003 9:57 AM To: [EMAIL PROTECTED] Subject: OutOfMemory Exception initializing page context Hello, I am having major memory problem that I have been fighting through. Has any body ever seen this one. Here are the errors that always come up in my logs. 1.java.lang.IllegalStateException: getAttribute: Session already invalidated 2.JspFactoryImpl: Exception initializing page context java.lang.IllegalStateException: Cannot create a session after the response has been committed 3.JspFactoryImpl: Exception initializing page context java.lang.OutOfMemoryError Any help at all would be greatly appreciated. Thanks, Rob Wichterman This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - 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: OutOfMemory Exception initializing page context
I consulted with the developers and they said we don't use or do anything that you suggested except we do use tomcat's connection pooling for oracle. We are running Sun j2sdk1.4.2_02 with the Concurrent Mark Sweep GC with -Xmx512m. I currently use the verbose logging for GC times. The odd thing is that it does not seem to progressively go up but rather spike up with high GC times and the full GC will not clean anything out. Thanks, Rob Rob Wichterman Systems Analyst Nuventive 3996 Mount Royal Blvd. Allison Park, PA 15101 Tel: 412-487-7424 Fax: 412-487-3355 Email: [EMAIL PROTECTED] Website: www.nuventive.com -Original Message- From: Christopher Schultz [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 02, 2003 11:00 AM To: Tomcat Users List Subject: Re: OutOfMemory Exception initializing page context Rob, Well I have had my -Xmx set to as high as 1gb and I still receive these errors. The site will stay running for at best 1 day without crashing. I was just hoping one of these could point me in a direction while I work on looking at memory leaks. Sorry for the levity. Try this: Turn on verbose GCs, and make sure you're sending stdout to a log file (Tomcat does this by default, I think). Empty the stdout log file, restart Tomcat and then let it run out of memory. Take a look at the GC output (they are prettty obvious) and see what's happening to memory. I've done this in the past, and I even wrote a (long lost) Perl script to parse the log file and generate X-Y coordinates that I could plot using Excel. We could plainly see that there was a memory leak of some kind because the graph kept going up and up. It does take a long time to find memory leaks but there are a couple of things you can check. First of all, what JSK are you using? Check some of the following: - Are you starting any of your own threads? If so, are they dying when the context reloads? - Are you reloading the context a lot? - Do any of your container objects like hashtables or whatever keep references to things like the ServletContext, etc.? - Do you regularly remove old objects from users' sessions? - Are you doing any XSLT? - Are you using a database connection pool or are you creating new connections for each user? - Do you keep any persistent connections like sockets or anything open? -chris - 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: OutOfMemory Exception initializing page context
We have tried setting the heap as high as 1024 with the same results. It actually seemed to make the tomcat die sooner with the higher setting. We currently have an average of 250 logins a day. Thanks, Rob Wichterman Systems Analyst Nuventive 3996 Mount Royal Blvd. Allison Park, PA 15101 Tel: 412-487-7424 Fax: 412-487-3355 Email: [EMAIL PROTECTED] Website: www.nuventive.com -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 02, 2003 12:43 PM To: Tomcat Users List Subject: RE: OutOfMemory Exception initializing page context Howdy, How was 512MB determined to be the correct heap size for the application? Could it be that 512MB is too little for your application when faced with a high load? Yoav Shapira Millennium ChemInformatics -Original Message- From: Rob Wichterman [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 02, 2003 12:40 PM To: 'Tomcat Users List' Subject: RE: OutOfMemory Exception initializing page context I consulted with the developers and they said we don't use or do anything that you suggested except we do use tomcat's connection pooling for oracle. We are running Sun j2sdk1.4.2_02 with the Concurrent Mark Sweep GC with -Xmx512m. I currently use the verbose logging for GC times. The odd thing is that it does not seem to progressively go up but rather spike up with high GC times and the full GC will not clean anything out. Thanks, Rob Rob Wichterman Systems Analyst Nuventive 3996 Mount Royal Blvd. Allison Park, PA 15101 Tel: 412-487-7424 Fax: 412-487-3355 Email: [EMAIL PROTECTED] Website: www.nuventive.com -Original Message- From: Christopher Schultz [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 02, 2003 11:00 AM To: Tomcat Users List Subject: Re: OutOfMemory Exception initializing page context Rob, Well I have had my -Xmx set to as high as 1gb and I still receive these errors. The site will stay running for at best 1 day without crashing. I was just hoping one of these could point me in a direction while I work on looking at memory leaks. Sorry for the levity. Try this: Turn on verbose GCs, and make sure you're sending stdout to a log file (Tomcat does this by default, I think). Empty the stdout log file, restart Tomcat and then let it run out of memory. Take a look at the GC output (they are prettty obvious) and see what's happening to memory. I've done this in the past, and I even wrote a (long lost) Perl script to parse the log file and generate X-Y coordinates that I could plot using Excel. We could plainly see that there was a memory leak of some kind because the graph kept going up and up. It does take a long time to find memory leaks but there are a couple of things you can check. First of all, what JSK are you using? Check some of the following: - Are you starting any of your own threads? If so, are they dying when the context reloads? - Are you reloading the context a lot? - Do any of your container objects like hashtables or whatever keep references to things like the ServletContext, etc.? - Do you regularly remove old objects from users' sessions? - Are you doing any XSLT? - Are you using a database connection pool or are you creating new connections for each user? - Do you keep any persistent connections like sockets or anything open? -chris - 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] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - 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]
SEVERE: Error in action code
I am getting this error in my Catalina.out file and I can seem to find anything good about it. SEVERE: Error in action code java.net.SocketException: Broken pipe at java.net.SocketOutputStream.socketWrite0(Native Method) at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92) at java.net.SocketOutputStream.write(SocketOutputStream.java:136) at org.apache.jk.common.ChannelSocket.send(ChannelSocket.java:407) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:599) at org.apache.jk.server.JkCoyoteHandler.action(JkCoyoteHandler.java:372) at org.apache.coyote.Response.action(Response.java:222) at org.apache.coyote.Response.finish(Response.java:343) at org.apache.coyote.tomcat4.OutputBuffer.close(OutputBuffer.java:326) at org.apache.coyote.tomcat4.CoyoteResponse.finishResponse(CoyoteResponse.j ava:500) at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:224) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:261) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:360) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:604) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java: 562) at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:679) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool .java:619) at java.lang.Thread.run(Thread.java:534) Thanks, Rob Wichterman Systems Analyst Nuventive 3996 Mount Royal Blvd. Allison Park, PA 15101 Tel: 412-487-7424 Fax: 412-487-3355 Email: [EMAIL PROTECTED] Website: file:///C:\Documents%20and%20Settings\dmoriarty\Application%20Data\Micr osoft\Signatures\www.nuventive.com www.nuventive.com
RE: Tomcat Dies
The Developers swear they do not use large collection objects. I also noticed that the Garbage collection times start to get to be over a second or to before they die. Another strange thing is that we have two tomcat instances running on separate servers and they both die at the same time with the same error (Exception java.lang.OutOfMemoryError: requested 24 bytes forpromotion. Out of swap space?). When I run top it shows that there is over 14 Gig free of swap. Is there a swap setting for tomcat? \ Any clues would be extremely helpful. Thanks, -Original Message- From: Peter Guyatt [mailto:[EMAIL PROTECTED] Sent: Monday, November 24, 2003 10:49 AM To: Tomcat Users List Subject: RE: Tomcat Dies Hi There, It looks like there is a memory lieak in your code, do you have any listeners, and if so are you storing the session objects in a collection and not removing them from the collection when they are being invalidated. Thanks Pete -Original Message- From: Rob Wichterman [mailto:[EMAIL PROTECTED] Sent: 24 November 2003 15:44 To: 'Tomcat Users List' Subject: Tomcat Dies I have two tomcat instances each on a separate folder. My problem is that after a few days we get one the following errors in Catalina.out 1. Exception java.lang.OutOfMemoryError: requested 24 bytes for promotion. Out of swap space? 2. SEVERE: Caught exception executing [EMAIL PROTECTED], terminating thread java.lang.OutOfMemoryError Any help would be appreciated. Thanks, - 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 Dies
Thanks for the reply. Here is how I have the JAVA_OPTS set up(-Xmx256m -XX:+UseConcMarkSweepGC -XX:+PrintGCDetails) I wanted you to see this incase there is a problem with the concurrent GC collector. Also how large of a Heap should we try? We have 4 Gig with 3.5 free of RAM. One last question if we higher the heap size won't that just mean it will eventually die when it gets to that limit? Thanks again, Rob Rob Wichterman Systems Analyst Nuventive 3996 Mount Royal Blvd. Allison Park, PA 15101 Tel: 412-487-7424 Fax: 412-487-3355 Email: [EMAIL PROTECTED] Website: www.nuventive.com -Original Message- From: Shapira, Yoav [mailto:[EMAIL PROTECTED] Sent: Tuesday, November 25, 2003 1:27 PM To: Tomcat Users List Subject: RE: Tomcat Dies Howdy, The Developers swear they do not use large collection objects. I also Great. Use a profiler to see for yourself where memory is allocated. noticed that the Garbage collection times start to get to be over a second or to before they die. Another strange thing is that we have two So your heap is nearly full and big. GC times of over a second are not by themselves a definitive indication that something is wrong. tomcat instances running on separate servers and they both die at the same time with the same error (Exception java.lang.OutOfMemoryError: requested 24 bytes forpromotion. Out of swap space?). When I run top it shows that there is over 14 Gig free of swap. Is there a swap setting for tomcat? \ There's no swap setting for tomcat, nor for Java, as that's not something the JVM controls: it's an OS-level issue. The requested for promotion part means the JVM wanted to promote objects from the new generation to the older one, but had no room. It could be that your apps are fine, there's no leak, and you just need to allocate more memory to the heap using the -Xmx parameter. Yoav Shapira Any clues would be extremely helpful. Thanks, -Original Message- From: Peter Guyatt [mailto:[EMAIL PROTECTED] Sent: Monday, November 24, 2003 10:49 AM To: Tomcat Users List Subject: RE: Tomcat Dies Hi There, It looks like there is a memory lieak in your code, do you have any listeners, and if so are you storing the session objects in a collection and not removing them from the collection when they are being invalidated. Thanks Pete -Original Message- From: Rob Wichterman [mailto:[EMAIL PROTECTED] Sent: 24 November 2003 15:44 To: 'Tomcat Users List' Subject: Tomcat Dies I have two tomcat instances each on a separate folder. My problem is that after a few days we get one the following errors in Catalina.out 1. Exception java.lang.OutOfMemoryError: requested 24 bytes for promotion. Out of swap space? 2. SEVERE: Caught exception executing [EMAIL PROTECTED], terminating thread java.lang.OutOfMemoryError Any help would be appreciated. Thanks, - 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] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - 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 Dies
I have two tomcat instances each on a separate folder. My problem is that after a few days we get one the following errors in Catalina.out 1. Exception java.lang.OutOfMemoryError: requested 24 bytes for promotion. Out of swap space? 2. SEVERE: Caught exception executing [EMAIL PROTECTED], terminating thread java.lang.OutOfMemoryError Any help would be appreciated. Thanks,
Upload Problem!!!
Hello, I have a web application that allows users to upload files on to the server. The problem is when a user uploads a file and closes the browser before the file finished uploading the java process immediately starts to jump past 50% cpu usage. And after a while eventually crashes completely with 'out of memory errors'. We are using JSP Smart Upload. I was wondering if there is a timeout or other parameter I can set to end the processes to bring java back down. Thanks