tomcat memory usage
Hello, I'm a beginner with java and I've setup tomcat (Apache Tomcat/5.0.16, jvm: 1.4.2_03-b02 Sun Microsystems Inc. on Gentoo Linux, kernel 2.4.20-gentoo-r8). I've created a context for my application and I used the manager to reload the context and now I've configured the context to be reloadable. My problem is that everytime the context is reloaded, top shows a memory usage increase with about 2Mb, until tomcat runs out of memory. What can I do ? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: tomcat memory usage
Andrei Ivanov wrote: I've created a context for my application and I used the manager to reload the context and now I've configured the context to be reloadable. First, start with using a profiler to ensure that your application isn't leaking memory. Look at http://issues.apache.org/bugzilla/ for anything on memory leaks wrt contexts. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: tomcat memory usage
I've searched bugzilla, but there doesn't seem to be any bug filled about something like this. About using a profiler... could you recommend one ? Thanks.. On Tue, 30 Dec 2003, James Black wrote: Andrei Ivanov wrote: I've created a context for my application and I used the manager to reload the context and now I've configured the context to be reloadable. First, start with using a profiler to ensure that your application isn't leaking memory. Look at http://issues.apache.org/bugzilla/ for anything on memory leaks wrt contexts. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: tomcat memory usage
About using a profiler... could you recommend one ? JProfiler JProbe __ Do you Yahoo!? Find out what made the Top Yahoo! Searches of 2003 http://search.yahoo.com/top2003 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: tomcat memory usage
Andrei Ivanov wrote: I've searched bugzilla, but there doesn't seem to be any bug filled about something like this. About using a profiler... could you recommend one ? JProfiler I like, mainly because of the cost, but also because it integrates in well with Netbeans. g Look at http://nagoya.apache.org/bugzilla/show_bug.cgi?id=20758 and see if that is your problem. This may also help: http://www.junlu.com/msg/38658.html - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: tomcat memory usage
On Tue, 30 Dec 2003, James Black wrote: Andrei Ivanov wrote: I've searched bugzilla, but there doesn't seem to be any bug filled about something like this. About using a profiler... could you recommend one ? JProfiler I like, mainly because of the cost, but also because it integrates in well with Netbeans. g I have only console access (no xfree installed) on the remote server, and as I can see, jprofiler wants X to be installed. Anyway, I have no experience with profilers, so I don't know how much would that help. Look at http://nagoya.apache.org/bugzilla/show_bug.cgi?id=20758 and see if that is your problem. This may be it, but I just reload the application context... does tomcat undeploy and then deploy the app when I reload it ? If there's more that I can do to discover the cause, using my limited experience, just tell me what... This may also help: http://www.junlu.com/msg/38658.html - 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 memory usage
Howdy, Look at http://nagoya.apache.org/bugzilla/show_bug.cgi?id=20758 and see if that is your problem. This may also help: http://www.junlu.com/msg/38658.html I clicked the above and surprisingly saw my own message ;) Anyways, note that bug 20758 is filed against tomcat 4.1.24. There's no such bug reported against tomcat 5, and work has definitely been done in this area. If you do submit a new one for tomcat 5, make sure to attach your simple test WAR file and the steps so we can reproduce this problem, or your bug will be marked as INVALID/WONTFIX. Yoav Shapira 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]
Re: Tomcat memory usage
Hmmm - looks like Brandon asked a similar question while I was writing this one! Have read replies, but would appreciate anyone offering any explanation for what we're seeing. Noticed that several of the replies uses multiple tomcats. Is this recommended? We're just using a single server. thanks, David [EMAIL PROTECTED] on 10/24/2002 03:47:45 PM Please respond to Tomcat Users List [EMAIL PROTECTED] To:Tomcat Users List [EMAIL PROTECTED] cc: Subject:Tomcat memory usage Hi. Would anyone be able to explain some details about Tomcat memory usage when it is being installed and run as a service (NT, 2000, XP). When we repeatedly upload forms, we are seeing the memory usage and Virtual Memory size in the Task Manager grow and grow and grow. Sometimes when we run another memory-hungry application, the Memory Usage for tomcat drops way down (presumably as this is the actual working set size, and it is getting swapped out), but sometimes (with dual processor machine, though not sure that makes any difference) it refuses to give up memory, or does so extremely slowly (having raised tomcat to 200 MB). We are pretty sure that there are no leaks in our java code, and only small leaks in the native libraries we are using. Does anyone have any insight / explanation / advice? Many thanks, David -- To unsubscribe, e-mail: mailto:tomcat-user-unsubscribe;jakarta.apache.org For additional commands, e-mail: mailto:tomcat-user-help;jakarta.apache.org -- To unsubscribe, e-mail: mailto:tomcat-user-unsubscribe;jakarta.apache.org For additional commands, e-mail: mailto:tomcat-user-help;jakarta.apache.org
Tomcat memory usage
Hi. Would anyone be able to explain some details about Tomcat memory usage when it is being installed and run as a service (NT, 2000, XP). When we repeatedly upload forms, we are seeing the memory usage and Virtual Memory size in the Task Manager grow and grow and grow. Sometimes when we run another memory-hungry application, the Memory Usage for tomcat drops way down (presumably as this is the actual working set size, and it is getting swapped out), but sometimes (with dual processor machine, though not sure that makes any difference) it refuses to give up memory, or does so extremely slowly (having raised tomcat to 200 MB). We are pretty sure that there are no leaks in our java code, and only small leaks in the native libraries we are using. Does anyone have any insight / explanation / advice? Many thanks, David -- To unsubscribe, e-mail: mailto:tomcat-user-unsubscribe;jakarta.apache.org For additional commands, e-mail: mailto:tomcat-user-help;jakarta.apache.org
Tomcat memory usage
Here's are tomcat version: Apache Tomcat/4.0.4-b3 We've had it running for a while now and I just noticed that it is using a lot of memory! 142MB physical and 600MB virtual. I'm wondering if there is any way I can tell what webapp is consuming this memory? I've disabled all webapps but /manager and two others, but the memory usage did not go down. Thanks, -shawn Shawn Wilson [[EMAIL PROTECTED]] Software Developer, ATMReports.com PH: 877-327-0873, FAX: 406-294-5806 -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Tomcat Memory usage(Urgent!)
Hello all Here is part of top output. Is it usual that java processes eat all of memory? ? At now there are 50 java processes started that running tomcat and each of them uses 59M memory. There is running apache server with tomcat 4 and mysql. OS is Redhat7.2 x86 . JDK 1.4 is installed. Thx 106 processes: 105 sleeping, 1 running, 0 zombie, 0 stopped CPU states: 0.3% user, 3.4% system, 0.0% nice, 96.1% idle Mem: 1028860K av, 1022352K used, 6508K free, 116K shrd, 129004K buff Swap: 1020116K av, 0K used, 1020116K free 762320K cached 3201 root 9 0 60692 59M 28164 S 0.0 5.8 0:03 java 3202 root 8 0 60692 59M 28164 S 0.0 5.8 0:00 java 3203 root 9 0 60692 59M 28164 S 0.0 5.8 0:35 java 3204 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3205 root 9 0 60692 59M 28164 S 0.0 5.8 0:01 java 3206 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3207 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3208 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3209 root 9 0 60692 59M 28164 S 0.0 5.8 0:03 java . . .
RE: Tomcat Memory usage(Urgent!)
Each of these processes correlates to a /thread/. The processes are sharing memory for the most part - something that ps or top don't make clear. Chris -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] On Behalf Of Galbayar Sent: 08 March 2002 09:24 To: Tomcat Users List Subject: Tomcat Memory usage(Urgent!) Hello all Here is part of top output. Is it usual that java processes eat all of memory? ? At now there are 50 java processes started that running tomcat and each of them uses 59M memory. There is running apache server with tomcat 4 and mysql. OS is Redhat7.2 x86 . JDK 1.4 is installed. Thx 106 processes: 105 sleeping, 1 running, 0 zombie, 0 stopped CPU states: 0.3% user, 3.4% system, 0.0% nice, 96.1% idle Mem: 1028860K av, 1022352K used, 6508K free, 116K shrd, 129004K buff Swap: 1020116K av, 0K used, 1020116K free 762320K cached 3201 root 9 0 60692 59M 28164 S 0.0 5.8 0:03 java 3202 root 8 0 60692 59M 28164 S 0.0 5.8 0:00 java 3203 root 9 0 60692 59M 28164 S 0.0 5.8 0:35 java 3204 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3205 root 9 0 60692 59M 28164 S 0.0 5.8 0:01 java 3206 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3207 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3208 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3209 root 9 0 60692 59M 28164 S 0.0 5.8 0:03 java . . . -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
Re: Tomcat Memory usage(Urgent!)
hi all , Well how is possible to give back memory ? Because after 2 days the memory is full. thx Chris Pheby wrote: Each of these processes correlates to a /thread/. The processes are sharing memory for the most part - something that ps or top don't make clear. Chris -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] On Behalf Of Galbayar Sent: 08 March 2002 09:24 To: Tomcat Users List Subject: Tomcat Memory usage(Urgent!) Hello all Here is part of top output. Is it usual that java processes eat all of memory? ? At now there are 50 java processes started that running tomcat and each of them uses 59M memory. There is running apache server with tomcat 4 and mysql. OS is Redhat7.2 x86 . JDK 1.4 is installed. Thx 106 processes: 105 sleeping, 1 running, 0 zombie, 0 stopped CPU states: 0.3% user, 3.4% system, 0.0% nice, 96.1% idle Mem: 1028860K av, 1022352K used, 6508K free, 116K shrd, 129004K buff Swap: 1020116K av, 0K used, 1020116K free 762320K cached 3201 root 9 0 60692 59M 28164 S 0.0 5.8 0:03 java 3202 root 8 0 60692 59M 28164 S 0.0 5.8 0:00 java 3203 root 9 0 60692 59M 28164 S 0.0 5.8 0:35 java 3204 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3205 root 9 0 60692 59M 28164 S 0.0 5.8 0:01 java 3206 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3207 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3208 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3209 root 9 0 60692 59M 28164 S 0.0 5.8 0:03 java . . . -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- */Sylvain Boily/* /Administrateur Linux/ cid:[EMAIL PROTECTED] /*Adresse :* 39, bd Anatole France - 93200 St-Denis - France/ /*tel :*0148131814/ /*mail :*[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] *web:*http://www.linkbynet.fr/
Re: Tomcat Memory usage(Urgent!)
within your program you might want to check out Runtime runtime = Runtime.getRuntime; runtime.freeMemory() vs runtime.totalMemory() This will let you know what it's really using.. But as top says it's only 59M then I'd be looking at other processes in your ps list Hope this helps D Boily Sylvain wrote: hi all , Well how is possible to give back memory ? Because after 2 days the memory is full. thx Chris Pheby wrote: Each of these processes correlates to a /thread/. The processes are sharing memory for the most part - something that ps or top don't make clear. Chris -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] ] On Behalf Of Galbayar Sent: 08 March 2002 09:24 To: Tomcat Users List Subject: Tomcat Memory usage(Urgent!) Hello all Here is part of top output. Is it usual that java processes eat all of memory? ? At now there are 50 java processes started that running tomcat and each of them uses 59M memory. There is running apache server with tomcat 4 and mysql. OS is Redhat7.2 x86 . JDK 1.4 is installed. Thx 106 processes: 105 sleeping, 1 running, 0 zombie, 0 stopped CPU states: 0.3% user, 3.4% system, 0.0% nice, 96.1% idle Mem: 1028860K av, 1022352K used, 6508K free, 116K shrd, 129004K buff Swap: 1020116K av, 0K used, 1020116K free 762320K cached 3201 root 9 0 60692 59M 28164 S 0.0 5.8 0:03 java 3202 root 8 0 60692 59M 28164 S 0.0 5.8 0:00 java 3203 root 9 0 60692 59M 28164 S 0.0 5.8 0:35 java 3204 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3205 root 9 0 60692 59M 28164 S 0.0 5.8 0:01 java 3206 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3207 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3208 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3209 root 9 0 60692 59M 28164 S 0.0 5.8 0:03 java . . . -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- */Sylvain Boily/* /Administrateur Linux/ cid:[EMAIL PROTECTED] /*Adresse :* 39, bd Anatole France - 93200 St-Denis - France/ /*tel :*0148131814/ /*mail :*[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] *web:*http://www.linkbynet.fr/ -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
RE: Tomcat Memory usage(Urgent!)
Are you sure that there's not old processes. I saw on AIX with TC4.0.1 that when i shutdowned TC, the java process wasn't killed. So I needed to kill it manually. Isn't there the same problem. Do all these processes disappeare when you stop TC ?? Arno -Message d'origine- De: David Cassidy [SMTP:[EMAIL PROTECTED]] Date: vendredi 8 mars 2002 12:05 A:Tomcat Users List Objet:Re: Tomcat Memory usage(Urgent!) within your program you might want to check out Runtime runtime = Runtime.getRuntime; runtime.freeMemory() vs runtime.totalMemory() This will let you know what it's really using.. But as top says it's only 59M then I'd be looking at other processes in your ps list Hope this helps D Boily Sylvain wrote: hi all , Well how is possible to give back memory ? Because after 2 days the memory is full. thx Chris Pheby wrote: Each of these processes correlates to a /thread/. The processes are sharing memory for the most part - something that ps or top don't make clear. Chris -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] ] On Behalf Of Galbayar Sent: 08 March 2002 09:24 To: Tomcat Users List Subject: Tomcat Memory usage(Urgent!) Hello all Here is part of top output. Is it usual that java processes eat all of memory? ? At now there are 50 java processes started that running tomcat and each of them uses 59M memory. There is running apache server with tomcat 4 and mysql. OS is Redhat7.2 x86 . JDK 1.4 is installed. Thx 106 processes: 105 sleeping, 1 running, 0 zombie, 0 stopped CPU states: 0.3% user, 3.4% system, 0.0% nice, 96.1% idle Mem: 1028860K av, 1022352K used, 6508K free, 116K shrd, 129004K buff Swap: 1020116K av, 0K used, 1020116K free 762320K cached 3201 root 9 0 60692 59M 28164 S 0.0 5.8 0:03 java 3202 root 8 0 60692 59M 28164 S 0.0 5.8 0:00 java 3203 root 9 0 60692 59M 28164 S 0.0 5.8 0:35 java 3204 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3205 root 9 0 60692 59M 28164 S 0.0 5.8 0:01 java 3206 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3207 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3208 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3209 root 9 0 60692 59M 28164 S 0.0 5.8 0:03 java . . . -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- */Sylvain Boily/* /Administrateur Linux/ cid:[EMAIL PROTECTED] /*Adresse :* 39, bd Anatole France - 93200 St-Denis - France/ /*tel :*0148131814/ /*mail :*[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] *web:*http://www.linkbynet.fr/ -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
RE: Tomcat Memory usage(Urgent!)
We faced this problem some time back. The memory usage seemed to increase to the point where no other application could be started. Many times we had to restart the NT machine itself. We did a thorough code-review and fixed the leaks. But even after that the Tomcat memory usage kept on increasing, although it came down, all of a sudden, to a very low value (600K). So garbage collection is being done more frequently, I would say. When there are more users connected to the Web server and accessing the Servlets/JSPs, the memory usage keeps on increasing... just to give numbers... we accessed our Web application using 50+ instances of browsers (IE, Netscape) and the memory shot to 200M. After some time (not immediately) when we stopped accessing the Web server it came down to 24M. You can find more pointers on JDC at http://java.sun.com. I remember discussing this topic there. Thanks -mb- -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of David Cassidy Sent: Friday, March 08, 2002 4:35 PM To: Tomcat Users List Subject: Re: Tomcat Memory usage(Urgent!) within your program you might want to check out Runtime runtime = Runtime.getRuntime; runtime.freeMemory() vs runtime.totalMemory() This will let you know what it's really using.. But as top says it's only 59M then I'd be looking at other processes in your ps list Hope this helps D Boily Sylvain wrote: hi all , Well how is possible to give back memory ? Because after 2 days the memory is full. thx Chris Pheby wrote: Each of these processes correlates to a /thread/. The processes are sharing memory for the most part - something that ps or top don't make clear. Chris -Original Message- From: [EMAIL PROTECTED] org [mailto:tomcat-user-return-13170-chris=tfe-group.com@jakart a.apache.org ] On Behalf Of Galbayar Sent: 08 March 2002 09:24 To: Tomcat Users List Subject: Tomcat Memory usage(Urgent!) Hello all Here is part of top output. Is it usual that java processes eat all of memory? ? At now there are 50 java processes started that running tomcat and each of them uses 59M memory. There is running apache server with tomcat 4 and mysql. OS is Redhat7.2 x86 . JDK 1.4 is installed. Thx 106 processes: 105 sleeping, 1 running, 0 zombie, 0 stopped CPU states: 0.3% user, 3.4% system, 0.0% nice, 96.1% idle Mem: 1028860K av, 1022352K used, 6508K free, 116K shrd, 129004K buff Swap: 1020116K av, 0K used, 1020116K free 762320K cached 3201 root 9 0 60692 59M 28164 S 0.0 5.8 0:03 java 3202 root 8 0 60692 59M 28164 S 0.0 5.8 0:00 java 3203 root 9 0 60692 59M 28164 S 0.0 5.8 0:35 java 3204 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3205 root 9 0 60692 59M 28164 S 0.0 5.8 0:01 java 3206 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3207 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3208 root 9 0 60692 59M 28164 S 0.0 5.8 0:00 java 3209 root 9 0 60692 59M 28164 S 0.0 5.8 0:03 java . . . -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- */Sylvain Boily/* /Administrateur Linux/ cid:[EMAIL PROTECTED] /*Adresse :* 39, bd Anatole France - 93200 St-Denis - France/ /*tel :*0148131814/ /*mail :*[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] *web:*http://www.linkbynet.fr/ -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED] -- To unsubscribe: mailto:[EMAIL PROTECTED] For additional commands: mailto:[EMAIL PROTECTED] Troubles with the list: mailto:[EMAIL PROTECTED]
Basic question about Apache+Tomcat Memory usage
hi users, i have this basic question in mind from so many days but din't get an answer for it. when i try to execute a simple JSP or Servlet , generally first time my CPU usage goes to 80-100%.I tried with default examples which comes with Tomcat. where as i have seen big application which don't use that much memory even u do some heavy jobs. Why is it so ??? System configuration: Pentium3900mHz processor 256MB Ram. Operating system: win2K Tomcat 3.2.2 Thanks in advance. -srini
Re: Basic question about Apache+Tomcat Memory usage
Are you asking about CPU usage or memory usage? For CPU, the first time you access a page (or whenever you update it), Tomcat has to translate the page into Java and then compile it. This is a pretty CPU-intensive activity, but it only happens once. For memory, there is a lot to understand about the way JVMs work -- but basically, from the operating system point of view, the JVM will start out at whatever you have configured as the minimum heap size, grow as it needs to, and never give it back (although from *inside* the JVM there will be free memory that can be reused for new Java object creation). You can control the overall memory usage with command line parameters -- see the Java documentation for more info. Craig On Fri, 7 Sep 2001, srini wrote: Date: Fri, 7 Sep 2001 12:14:28 -0700 From: srini [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Basic question about Apache+Tomcat Memory usage hi users, i have this basic question in mind from so many days but din't get an answer for it. when i try to execute a simple JSP or Servlet , generally first time my CPU usage goes to 80-100%.I tried with default examples which comes with Tomcat. where as i have seen big application which don't use that much memory even u do some heavy jobs. Why is it so ??? System configuration: Pentium3900mHz processor 256MB Ram. Operating system: win2K Tomcat 3.2.2 Thanks in advance. -srini
Re: Basic question about Apache+Tomcat Memory usage
ho sorry Craig i was talking about CPU usage. I know first time it translates JSP page in to Java and compiles it. But is it that much intensive to eat 80-100% of memory ?? Iam running my application on Apache+Tomcat. For many of the pages it takes 90-100% even though they are not first time visiting pages. It has Database connections. what is the problem ?? do i need to check the code or what ...? Thnaks Craig . -srini - Original Message - From: Craig R. McClanahan [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, September 07, 2001 12:10 PM Subject: Re: Basic question about Apache+Tomcat Memory usage Are you asking about CPU usage or memory usage? For CPU, the first time you access a page (or whenever you update it), Tomcat has to translate the page into Java and then compile it. This is a pretty CPU-intensive activity, but it only happens once. For memory, there is a lot to understand about the way JVMs work -- but basically, from the operating system point of view, the JVM will start out at whatever you have configured as the minimum heap size, grow as it needs to, and never give it back (although from *inside* the JVM there will be free memory that can be reused for new Java object creation). You can control the overall memory usage with command line parameters -- see the Java documentation for more info. Craig On Fri, 7 Sep 2001, srini wrote: Date: Fri, 7 Sep 2001 12:14:28 -0700 From: srini [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Basic question about Apache+Tomcat Memory usage hi users, i have this basic question in mind from so many days but din't get an answer for it. when i try to execute a simple JSP or Servlet , generally first time my CPU usage goes to 80-100%.I tried with default examples which comes with Tomcat. where as i have seen big application which don't use that much memory even u do some heavy jobs. Why is it so ??? System configuration: Pentium3900mHz processor 256MB Ram. Operating system: win2K Tomcat 3.2.2 Thanks in advance. -srini
Re: Basic question about Apache+Tomcat Memory usage
On Fri, 7 Sep 2001, srini wrote: Date: Fri, 7 Sep 2001 12:38:11 -0700 From: srini [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Re: Basic question about Apache+Tomcat Memory usage ho sorry Craig i was talking about CPU usage. I know first time it translates JSP page in to Java and compiles it. But is it that much intensive to eat 80-100% of memory ?? If there is nothing higher priority that needs to run, don't you *want* 100% CPU usage, so the compile gets done faster? :-) Iam running my application on Apache+Tomcat. For many of the pages it takes 90-100% even though they are not first time visiting pages. It has Database connections. what is the problem ?? do i need to check the code or what ...? There's no way to give advice based on generalities here -- the only way to figure out what inside your page is eating the time is to use tools like OptimizeIt that will help you isolate the big CPU hogs. Thnaks Craig . -srini Craig - Original Message - From: Craig R. McClanahan [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, September 07, 2001 12:10 PM Subject: Re: Basic question about Apache+Tomcat Memory usage Are you asking about CPU usage or memory usage? For CPU, the first time you access a page (or whenever you update it), Tomcat has to translate the page into Java and then compile it. This is a pretty CPU-intensive activity, but it only happens once. For memory, there is a lot to understand about the way JVMs work -- but basically, from the operating system point of view, the JVM will start out at whatever you have configured as the minimum heap size, grow as it needs to, and never give it back (although from *inside* the JVM there will be free memory that can be reused for new Java object creation). You can control the overall memory usage with command line parameters -- see the Java documentation for more info. Craig On Fri, 7 Sep 2001, srini wrote: Date: Fri, 7 Sep 2001 12:14:28 -0700 From: srini [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Basic question about Apache+Tomcat Memory usage hi users, i have this basic question in mind from so many days but din't get an answer for it. when i try to execute a simple JSP or Servlet , generally first time my CPU usage goes to 80-100%.I tried with default examples which comes with Tomcat. where as i have seen big application which don't use that much memory even u do some heavy jobs. Why is it so ??? System configuration: Pentium3900mHz processor 256MB Ram. Operating system: win2K Tomcat 3.2.2 Thanks in advance. -srini
Re: Basic question about Apache+Tomcat Memory usage
srini [EMAIL PROTECTED] wrote: ho sorry Craig i was talking about CPU usage. I know first time it translates JSP page in to Java and compiles it. But is it that much intensive to eat 80-100% of memory ?? It seem to me you're confusing again CPU usage with memory... 80%/100% IS the CPU percentile activity... I am running my application on Apache+Tomcat. For many of the pages it takes 90-100% even though they are not first time visiting pages. It has Database connections. what is the problem ?? do i need to check the code or what ...? No, it means that the baby _is_ working... It's normal for a CPU to be used when you process some data, the JVM and APACHE are using all the available CPU power to deliver the response as soon as possible... If it's a peak (meaning that after you hit the page the CPU goes back to your normal load cycle) it's normal... If it stays up at 80% 100% all the time, then, there is a problem... Pier
Re: Basic question about Apache+Tomcat Memory usage
You mean the first time you access the JSP after starting Tomcat? This is because the JSP has to be compiled into a class before it can be executed. Jon - Original Message - From: srini [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, September 07, 2001 2:14 PM Subject: Basic question about Apache+Tomcat Memory usage hi users, i have this basic question in mind from so many days but din't get an answer for it. when i try to execute a simple JSP or Servlet , generally first time my CPU usage goes to 80-100%.I tried with default examples which comes with Tomcat. where as i have seen big application which don't use that much memory even u do some heavy jobs. Why is it so ??? System configuration: Pentium3900mHz processor 256MB Ram. Operating system: win2K Tomcat 3.2.2 Thanks in advance. -srini