You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by 塗 <se...@yahoo.co.jp> on 2010/05/27 10:51:37 UTC
tomcat memory question
hi, all
there is a problem with my webapp.
by manual configuration, i allocated 1G(1024M) memory for webapp.
where the gc new capacity automatically is 262M, the gc old capacity
automatically is 699M, S0/S1 automatically is 43.6M/43.6M., PC automatically
is 42M
When my webapp is started, I use the jvm's own tools(jstat) to trace the
garbage collections.
the Utilization rate of the PC capacity is always 100%. is it normal?
Firstly the 1 Full GC is occurrenced within 1 hour,
5 hours later that took place within 1 hour 100 Full GC.
is it normal?
[web operating environment:]
tomcat5.5.27 + Apache/2.2.3 + jdk1.5.0_13 + Linux_x86_64
[blow is my manual configurations for tomcat JVM:]
CATALINA_OPTS="-Xms1024M -Xmx1024M -Dorg.apache.jasper.compiler.Parser.STRICT_QUOTE_ESCAPING=false"
[Jstat Tracking data (csv data)]
systime, S0C, S1C, S0U, S1U, EC, EU, OC, OU, PC, PU, YGC, YGCT,
FGCT, GCT
11:13:41, 9600, 3392, 0, 3369.3, 53568, 36562.3, 699072, 481787.7,
61184, 61167, 249, 3.148, 0.005, 3.153
11:48:02, 4032, 3520, 0, 3520, 39616, 0, 699072, 697526, 67712,
67573.5, 385, 4.849, 0.005, 4.854
13:23:53, 2496, 2496, 0, 0, 29568, 5620.2, 699072, 100281.5, 71360,
71236.5, 1003, 10.057, 3.48, 13.537
14:49:13, 2624, 2624, 0, 0, 27712, 12302, 679936, 74349.4, 78080,
71771.3, 1898, 15.979, 3.962, 19.941
16:07:54, 3392, 3712, 1664, 0, 50496, 28601.3, 688000, 109525.6,
78080, 74945.2, 2804, 21.46, 4.567, 26.027
16:24:03, 4480, 2304, 0, 0, 77632, 27240.9, 656960, 103414.1,
78080, 75622.1, 3107, 23.191, 4.943, 28.134
16:33:39, 4160, 2304, 0, 0, 78144, 25196.7, 658752, 98731.2, 78080,
76421.6, 3365, 24.604, 5.329, 29.933
16:41:50, 5568, 3008, 0, 2952.4, 103424, 96055.6, 606976, 69788.7,
78080, 74229.1, 3591, 25.889, 5.742, 31.631
16:42:40, 7360, 10176, 0, 0, 174464, 0, 652544, 91210.1, 86016,
86010.7, 3620, 26.067, 6.081, 32.148
16:43:25, 19520, 19200, 0, 0, 179328, 12770.2, 681728, 55882.2,
86016, 84680.4, 3637, 26.329, 7.634, 33.963
16:44:22, 21376, 20608, 0, 0, 181504, 13683.9, 681600, 55718.4,
86016, 84905.3, 3653, 26.507, 8.276, 34.784
16:47:34, 22656, 23744, 17914.8, 0, 182656, 135109.5, 687232,
56195.2, 86016, 85854.9, 3710, 27.079, 9.954, 37.032
16:51:16, 23360, 24064, 0, 0, 183872, 6675.4, 695232, 56231, 86016,
84901.6, 3784, 27.828, 13.631, 41.459
16:53:46, 24768, 23808, 0, 18298.8, 191872, 161459.7, 695616,
56960.4, 86016, 85728.5, 3833, 28.605, 15.221, 43.826
16:57:43, 28800, 26944, 0, 21923, 200768, 5245.9, 699072, 66807,
86016, 85505, 3909, 29.494, 17.746, 47.24
17:02:02, 28608, 10752, 0, 10720, 205824, 118015.1, 696128, 56332.7,
86016, 85880.8, 3999, 30.492, 22.473, 52.965
17:03:57, 32384, 32448, 17668.8, 0, 209152, 64383, 699072, 65796.8,
86016, 85142.6, 4038, 31.049, 24.71, 55.759
17:09:19, 32256, 32576, 18938.8, 0, 224512, 43783.8, 699072,
73448.4, 86016, 84862.6, 4146, 32.986, 30.05, 63.035
17:12:59, 54208, 52608, 0, 36976.4, 224640, 76931.5, 699072,
63084.4, 86016, 85367, 4221, 34.258, 33.295, 67.553
17:16:21, 45632, 45760, 26864.6, 0, 224512, 158991.5, 699072, 60327,
86016, 85273.6, 4356, 37.225, 35.458, 72.683
17:24:47, 29120, 30016, 0, 14856.2, 274944, 103582.1, 697344,
57937.4, 86016, 85176.8, 4525, 40.282, 40.071, 80.352
17:33:57, 32832, 34688, 25448.2, 0, 250560, 19438.8, 695808, 55692,
86016, 85489.8, 4686, 44.335, 44.935, 89.27
17:44:33, 29952, 28672, 0, 22952.2, 280896, 175914.9, 696512,
85648.5, 86016, 85940.8, 4845, 47.238, 47.198, 94.436
thanks..
--------------------------------------
2010 FIFA World Cup News [Yahoo!Sports/sportsnavi]
http://pr.mail.yahoo.co.jp/southafrica2010/
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: tomcat memory question
Posted by Pid <pi...@pidster.com>.
On 27/05/2010 15:40, Christopher Schultz wrote:
> W,
>
> On 5/27/2010 4:51 AM, W wrote:
>> there is a problem with my webapp.
>
>> web operating environment:
>> tomcat5.5.27 + Apache/2.2.3 + jdk1.5.0_13 + Linux_x86_64
>
>> [below] is my manual configurations for tomcat JVM:
>> CATALINA_OPTS="-Xms1024M -Xmx1024M
>> -Dorg.apache.jasper.compiler.Parser.STRICT_QUOTE_ESCAPING=false"
>
> Are you using a 64-bit or 32-bit JVM?
>
>> When my webapp is started, I use the jvm's own tools(jstat) to trace the
>> garbage collections.
>
> Ok.
>
>> the Utilization rate of the PC capacity is always 100%. is it normal?
>
> What is "PC" (sorry, the jstat man page sucks)? What is the command you
> used to produce your jstat output?
I had to look it up too.
http://java.sun.com/javase/6/docs/technotes/tools/share/jstat.html
p
>> Firstly the 1 Full GC is occurrenced within 1 hour,
>> 5 hours later that took place within 1 hour 100 Full GC.
>> is it normal?
>
> Can you clarify this last statement? When did the first full GC take
> place? When did the second? When did the third? Are you saying that you
> get one full GC in one hour, then 5 hours for the second, then 100 full
> GCs all close together?
>
> That suggests to me that your webapp is allocating memory and never
> releasing it. This could be due to many reasons such as a memory leak
> (which ought to be fixed) or caching (which may be working as designed).
>
> Is your webapp performing well? GC activity doesn't necessarily mean
> that anything is wrong.
>
> -chris
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: tomcat memory question
Posted by Rainer Jung <ra...@kippdata.de>.
On 28.05.2010 16:26, Caldarale, Charles R wrote:
>> From: Christopher Schultz [mailto:chris@christopherschultz.net]
>> Subject: Re: tomcat memory question
>>
>> Check may (will?) correct me on this
>
> -1 for spelling
>
>> I believe a full GC might be necessary to clear-out certain
>> resources such as completed Threads or other things that have
>> concrete OS-level counterparts.
>
> Not exactly; a full GC is necessary to clear out dead classes and any objects that have migrated into the tenured generation. The OS-level thread structures are gone as soon as the java.lang.Thread instance stops running (returns from the run() method), while the Java instance will hang around as long as there are references to it. Some OS resources will stay allocated until a GC happens *if* the program fails to explicitly close them before the corresponding Java object becomes unreachable (aka sloppy programming), but any kind of GC that discovers such a dead object will release the associated native resources.
>
>> If you are using a lot of (non-pooled) threads or socket
>> connections, the JVM may be performing full GCs to clean
>> up those resources.
>
> GC itself knows nothing about the relationship between Java objects and external resources; only the finalizer for such a class does.
>
>> Frequent full GCs might just mean that you are using a lot of your
>> memory. As long as you don't get any OutOfMemoryErrors, it appears
>> that your heap is adequate for the load you're experiencing.
>
> Assuming there are no memory leaks, it's an indication that the heap is undersized for the application, or that the application is behaving in an unexpected fashion with regard to expected object creation patterns. (An application that creates only long-lived objects, for example - but that's really hard to believe that could happen in a servlet container.)
There's a couple of options. We can't decide, because we only see
partial data (and none of GC logging, which is much more helpful when
enabled correctly):
- distributed GC because of RMI. That would fit the once per minute Full
GC. But the data presented looks like it's not once per minute, but
about once to twice per minute.
- full gc triggered by class unloading: but perm doesn't seem to be
close to some magic size.
- lots of allocation flooding the semi spaces and flowing over into tenured.
Did you give us only the jstat lines, which happened after the increase
of the FGC counter? The used capacity of tenured (OU/OC) seems to be
very small in all lines given, which would be normal and hide the GC
reason, if you had thrown away all data lines immediately before a FGC.
The same for Perm and class unloading.
Regards,
Rainer
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
RE: tomcat memory question
Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: Christopher Schultz [mailto:chris@christopherschultz.net]
> Subject: Re: tomcat memory question
>
> Check may (will?) correct me on this
-1 for spelling
> I believe a full GC might be necessary to clear-out certain
> resources such as completed Threads or other things that have
> concrete OS-level counterparts.
Not exactly; a full GC is necessary to clear out dead classes and any objects that have migrated into the tenured generation. The OS-level thread structures are gone as soon as the java.lang.Thread instance stops running (returns from the run() method), while the Java instance will hang around as long as there are references to it. Some OS resources will stay allocated until a GC happens *if* the program fails to explicitly close them before the corresponding Java object becomes unreachable (aka sloppy programming), but any kind of GC that discovers such a dead object will release the associated native resources.
> If you are using a lot of (non-pooled) threads or socket
> connections, the JVM may be performing full GCs to clean
> up those resources.
GC itself knows nothing about the relationship between Java objects and external resources; only the finalizer for such a class does.
> Frequent full GCs might just mean that you are using a lot of your
> memory. As long as you don't get any OutOfMemoryErrors, it appears
> that your heap is adequate for the load you're experiencing.
Assuming there are no memory leaks, it's an indication that the heap is undersized for the application, or that the application is behaving in an unexpected fashion with regard to expected object creation patterns. (An application that creates only long-lived objects, for example - but that's really hard to believe that could happen in a servlet container.)
- 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.
Re: tomcat memory question
Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
塗,
On 5/28/2010 3:11 AM, sesfei wrote:
>> Are you using a 64-bit or 32-bit JVM?
> yes, that is 64-bit JVM.
With such a modest heap (1GiB), you might consider running a 32-bit JVM:
you might even get better heap performance with smaller pointers.
> [root]# jstat -gc {tomcat pid} 3000
[snip]
> PC Current permanent space capacity (KB).
Ok.
>> Can you clarify this last statement? When did the first full GC take
>> place? When did the second? When did the third?
>
> According to the following csv data, we can see full-gc occurred at a
> time like this.
>
> The 1st full-gc tomcat takes place at tomcat is starting.
> The 2th full-gc tomcat takes place at 11:48AM
> The 3th full-gc tomcat takes place at 1:23 PM
> The 4th full-gc tomcat takes place at 2:49 PM
> The 5th full-gc tomcat takes place at 4:24 PM
> The 6th full-gc tomcat takes place at 4:33 PM
> After 7th full-gc , basically 1 full-gc at 1 minutes will be occurred.
> is it normal?
> Is it because the programm of webapp not well, leading to memory leak?
Full GCs happen either when memory is tight or just whenever the GC
feels like running. Typically, you'll have a lot of small GCs over a
long (relatively speaking) period of time, and then a full GC once and a
while.
Check may (will?) correct me on this, but I believe a full GC might be
necessary to clear-out certain resources such as completed Threads or
other things that have concrete OS-level counterparts. If you are using
a lot of (non-pooled) threads or socket connections, the JVM may be
performing full GCs to clean up those resources.
Frequent full GCs might just mean that you are using a lot of your
memory. As long as you don't get any OutOfMemoryErrors, it appears that
your heap is adequate for the load you're experiencing.
Frequent full GCs could be seen as a symptom of having a heap that is
just a little too small for your needs: everything you're doing fits in
the heap, but in order to stay running, full GC are needed frequently.
Try increasing your heap size by 20% and see if the full GCs happen less
frequently.
Again, as long as you're not running out of memory, you webapp is
probably doing just fine. More breathing room in the heap certainly
couldn't hurt.
Good luck,
- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iEYEARECAAYFAkv/y/cACgkQ9CaO5/Lv0PCQuwCgkcA4H1maoUrHucWRKO3PG6aC
PYsAn0Az7dMicym9vDEg6uTJC1gMLILz
=mWk9
-----END PGP SIGNATURE-----
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: tomcat memory question
Posted by sesfei <se...@yahoo.co.jp>.
hi,
Christopher Schultz, Pid, Jeffrey Janner
Thanks for your reply.
> Are you using a 64-bit or 32-bit JVM?
yes, that is 64-bit JVM.
> What is the command you used to produce your jstat output?
Well, the comand is
[root]# jstat -gc {tomcat pid} 3000
that command means every 3 seconds to print out the status of garbage
collections.
> What is "PC" ?
command (jstat -gc {tomcat pid} 3000) can traces the following areas
of memory what is allocated and used.
S0C Current survivor space 0 capacity (KB).
S1C Current survivor space 1 capacity (KB).
S0U Survivor space 0 utilization (KB).
S1U Survivor space 1 utilization (KB).
EC Current eden space capacity (KB).
EU Eden space utilization (KB).
OC Current old space capacity (KB).
OU Old space utilization (KB).
PC Current permanent space capacity (KB).
PU Permanent space utilization (KB).
YGC Number of young generation GC Events.
YGCT Young generation garbage collection time.
FGC Number of full GC events.
FGCT Full garbage collection time.
GCT Total garbage collection time.
> Can you clarify this last statement? When did the first full GC take
> place? When did the second? When did the third?
According to the following csv data, we can see full-gc occurred at a time
like this.
The 1st full-gc tomcat takes place at tomcat is starting.
The 2th full-gc tomcat takes place at 11:48AM
The 3th full-gc tomcat takes place at 1:23 PM
The 4th full-gc tomcat takes place at 2:49 PM
The 5th full-gc tomcat takes place at 4:24 PM
The 6th full-gc tomcat takes place at 4:33 PM
After 7th full-gc , basically 1 full-gc at 1 minutes will be occurred.
is it normal?
Is it because the programm of webapp not well, leading to memory leak?
thanks !
============================CSV data start ================================
systime,S0C,S1C,S0U,S1U,EC,EU,OC,OU,PC,PU,YGC,YGCT,FGC,FGCT,GCT
10:56
AM,9600,3392,0,3369.3,53568,36562.3,699072,481787.7,61184,61167,249,3.148,1,0.005,3.153
11:48
AM,4032,3520,0,3520,39616,0,699072,697526,67712,67573.5,385,4.849,2,0.005,4.854
1:23
PM,2496,2496,0,0,29568,5620.2,699072,100281.5,71360,71236.5,1003,10.057,3,3.48,13.537
2:49
PM,2624,2624,0,0,27712,12302,679936,74349.4,78080,71771.3,1898,15.979,4,3.962,19.941
4:07
PM,3392,3712,1664,0,50496,28601.3,688000,109525.6,78080,74945.2,2804,21.46,5,4.567,26.027
4:24
PM,4480,2304,0,0,77632,27240.9,656960,103414.1,78080,75622.1,3107,23.191,6,4.943,28.134
4:33
PM,4160,2304,0,0,78144,25196.7,658752,98731.2,78080,76421.6,3365,24.604,7,5.329,29.933
4:41
PM,5568,3008,0,2952.4,103424,96055.6,606976,69788.7,78080,74229.1,3591,25.889,8,5.742,31.631
4:42
PM,7360,10176,0,0,174464,0,652544,91210.1,86016,86010.7,3620,26.067,10,6.081,32.148
4:42
PM,15552,16448,0,5850.8,174016,0,672448,81577.6,86016,86015.8,3625,26.128,11,6.454,32.582
4:42
PM,15552,15744,0,0,176640,47946.3,681536,57596.5,86016,84716.7,3626,26.133,12,7.041,33.174
4:43
PM,19520,19200,0,0,179328,12770.2,681728,55882.2,86016,84680.4,3637,26.329,14,7.634,33.963
4:44
PM,21376,20608,0,0,181504,13683.9,681600,55718.4,86016,84905.3,3653,26.507,16,8.276,34.784
4:45
PM,19712,20416,0,0,183104,4838.1,684288,55907,86016,85078.2,3670,26.686,18,8.922,35.608
4:45
PM,18112,19264,5882.8,0,183616,116840,691264,61653.6,86016,84820.4,3680,26.769,20,9.42,36.189
4:46
PM,28032,26688,0,0,181120,5398.8,687232,56195.2,86016,84834.2,3695,26.922,22,9.954,36.876
4:47
PM,23488,24448,0,0,182208,17955.5,689728,56704.2,86016,84915,3712,27.101,24,10.467,37.568
4:48
PM,22400,6528,0,6496,182464,21955.4,691776,57561.6,86016,85184,3721,27.184,26,11.015,38.198
4:48
PM,21376,22208,0,0,182912,9686.2,691200,55718.6,86016,84904.3,3734,27.314,28,11.578,38.892
4:49
PM,23616,22720,0,0,184640,5352.7,692608,55948.2,86016,85087.2,3749,27.473,30,12.118,39.592
4:49
PM,22272,21696,0,0,185920,9033.2,693824,56161,86016,84535,3757,27.545,32,12.618,40.164
4:50
PM,23104,23936,0,0,184448,10825.1,694464,56030.5,86016,84909.3,3772,27.709,34,13.122,40.831
4:51
PM,23360,24064,0,0,183872,6675.4,695232,56231,86016,84901.6,3784,27.828,36,13.631,41.459
4:51
PM,23040,23552,0,7904,183680,0,695232,56231,86016,86015.7,3795,27.952,37,13.631,41.583
4:51
PM,23168,23808,0,5856,183488,154538.9,696192,56856.7,86016,85007.5,3797,27.963,38,14.157,42.12
4:52
PM,25536,26368,0,0,183488,9536.2,699072,70891.1,86016,84992.9,3808,28.079,40,14.679,42.757
4:52
PM,21760,22784,6688,0,189760,0,699072,70891.1,86016,86015.9,3816,28.414,41,14.679,43.093
4:52
PM,23296,22784,0,0,189760,9992.9,695616,56272.1,86016,84713.9,3817,28.418,42,15.221,43.639
4:53
PM,25408,24320,0,0,192448,4086.7,695936,56385.9,86016,84589.2,3835,28.628,44,15.728,44.356
4:54
PM,25408,24320,0,0,194624,5911.9,696320,56546.5,86016,84855.8,3853,28.834,46,16.236,45.07
4:55
PM,24320,24960,0,6408.4,197184,116985.5,695424,55662.8,86016,85013.5,3873,29.072,48,16.737,45.809
4:56
PM,27584,26624,0,0,198848,13178.7,695872,56027.9,86016,85115,3891,29.302,50,17.238,46.54
4:57
PM,24768,25344,0,6120.2,201152,11617.5,699072,66807,86016,84833.5,3903,29.415,52,17.746,47.161
4:58
PM,31360,30144,0,0,201408,15841.7,695552,56110.8,86016,84941.2,3915,29.574,54,18.28,47.854
4:58
PM,26816,27328,0,0,203968,200718.2,695552,56148.9,86016,84772.1,3924,29.66,56,18.818,48.478
4:58
PM,24640,24192,0,0,205568,6781.7,694784,55459.3,86016,84862.6,3933,29.749,58,19.334,49.083
4:59
PM,25408,24768,0,0,206656,142158.9,695936,56542.1,86016,85030.8,3945,29.879,60,19.85,49.729
4:59
PM,22272,22784,0,0,207808,32725.9,698112,58714.1,86016,85028.4,3954,29.962,62,20.333,50.295
5:00
PM,24256,26752,20616.2,0,206464,0,698112,58714.1,86016,86015.3,3958,30.029,63,20.333,50.362
5:00
PM,27072,26752,0,0,206464,177035.1,696512,57149.9,86016,85023.8,3959,30.033,64,20.881,50.914
5:00
PM,23616,25024,11541.6,0,206848,86827.7,699072,68513,86016,85068.1,3972,30.17,66,21.406,51.577
5:00
PM,45376,44608,0,0,201280,5971.1,696832,56658.2,86016,84562.1,3979,30.261,68,21.976,52.237
5:01
PM,32960,32192,0,0,205056,0,699072,56332.7,86016,84866.3,3991,30.398,70,22.202,52.6
5:02
PM,28736,27968,0,0,207168,172703.6,696960,57376.4,86016,85041.3,4003,30.55,72,22.965,53.515
5:02
PM,58304,56640,0,0,200448,17691.4,699072,73691.8,86016,85065.8,4019,30.823,74,23.586,54.409
5:03
PM,45440,45568,0,0,205440,0,699072,76301.1,86016,86015.3,4028,30.927,76,23.875,54.801
5:03
PM,35328,35008,0,0,207744,0,699072,69190.2,86016,86016,4035,31.017,78,24.439,55.456
5:04
PM,37184,36288,0,0,208384,4697.6,695360,55963.9,86016,84995,4045,31.174,80,25.276,56.45
5:04
PM,33216,31744,0,22920.2,210112,0,695360,55963.9,86016,86016,4053,31.3,81,25.276,56.576
5:04
PM,33216,33984,0,0,211840,21490.1,699072,73818.2,86016,85126.7,4054,31.304,82,25.811,57.115
5:05
PM,30336,29696,0,0,216064,12973.1,695808,56419.4,86016,84650.2,4063,31.41,84,26.383,57.793
5:05
PM,29824,28928,0,0,218432,14631.5,695168,55755.8,86016,84752.6,4079,31.628,86,26.926,58.553
5:06
PM,28288,29696,21896.2,0,219648,0,695168,55755.8,86016,86015.7,4090,31.822,87,26.926,58.748
5:06
PM,30784,29696,0,0,219648,114035.2,699072,71706.3,86016,85063.2,4091,31.826,88,27.465,59.291
5:07
PM,33600,33984,0,6492.5,220544,12372.9,697600,58186.4,86016,84697.7,4105,32.044,90,27.974,60.018
5:08
PM,53120,55296,0,0,214080,0,699072,62305.5,86016,86015.1,4120,32.646,92,28.251,60.896
5:08
PM,45184,44800,0,0,217984,11395.4,695936,56523.3,86016,85284.8,4129,32.763,94,29.026,61.789
5:08
PM,39168,39744,0,4448,219648,0,695936,56523.3,86016,86015.5,4133,32.803,95,29.026,61.829
5:08
PM,39168,39168,0,0,220288,10799.8,695168,55806.7,86016,84689,4134,32.806,96,29.519,62.326
5:09
PM,33600,35264,0,0,221632,0,699072,77192.8,86016,86015.9,4143,32.939,97,29.788,62.726
5:09
PM,35776,35264,0,0,221632,53684.3,699072,73448.4,86016,84706.1,4143,32.945,98,30.05,62.994
5:09
PM,32384,33152,0,0,224256,0,699072,76427.6,86016,86015.9,4156,33.169,100,30.327,63.496
5:10
PM,32576,33600,0,0,227264,125912.5,699072,72837.7,86016,85068.7,4168,33.341,102,31.133,64.474
5:10
PM,32384,31424,0,0,229120,0,699072,75880.8,86016,86016,4177,33.501,104,31.412,64.913
5:11
PM,30144,29312,0,0,231104,0,698944,59546.9,86016,86015.6,4189,33.649,106,31.919,65.568
5:12
PM,33536,32448,0,0,229120,63917.4,699072,73943.8,86016,84703.4,4201,33.844,108,32.732,66.576
5:12
PM,30656,31360,0,7258.8,232320,86868.5,699072,63084.4,86016,85106.6,4209,33.968,110,33.295,67.262
5:13
PM,41152,42880,0,0,240064,125620.6,699072,73671.1,86016,84806.9,4240,34.663,112,33.886,68.549
5:14
PM,39680,41216,6888.2,0,257280,7079.4,699072,69241.7,86016,84850.1,4282,35.592,114,34.422,70.014
5:15
PM,40000,39232,0,0,252352,165424.9,698240,57297.2,86016,85007.1,4317,36.319,116,34.93,71.249
5:16
PM,48320,48512,0,7802.9,220672,0,698240,81401.4,86016,86015.3,4347,37.032,117,34.93,71.962
5:16
PM,43456,45696,12794.8,0,222656,83253.6,699072,60327,86016,84892.7,4350,37.053,118,35.458,72.511
5:17
PM,44672,7040,0,7016.4,248256,14476,696896,55393.3,86016,84955.8,4393,38.08,120,35.992,74.073
5:18
PM,32832,33728,0,0,252992,5223.4,696256,55701.8,86016,84759.6,4414,38.433,122,36.486,74.92
5:19
PM,32128,33216,0,0,254912,10469.2,696320,55884.7,86016,84952.8,4432,38.718,124,36.967,75.685
5:20
PM,31488,32512,0,0,259008,8660.1,695744,55503.6,86016,84847.6,4450,39.046,126,37.468,76.515
5:21
PM,30720,31616,0,0,260416,0,698112,58288.5,86016,86015.7,4468,39.355,128,37.706,77.061
5:22
PM,29376,28544,0,0,264000,4977.9,695296,55782.2,86016,85046.7,4483,39.598,130,38.462,78.06
5:23
PM,30208,29248,0,0,266688,63835.5,695936,56502.7,86016,85099.9,4497,39.829,132,38.988,78.817
5:24
PM,30848,29888,0,0,269696,16305.1,695168,55754.6,86016,84881.5,4511,40.065,134,39.557,79.622
5:24
PM,30848,29824,0,0,272128,190589.7,697344,57937.4,86016,85159,4523,40.253,136,40.071,80.324
5:25
PM,43328,25280,0,25224.2,259200,0,697344,59665.4,86016,86015.4,4533,40.662,137,40.071,80.732
5:25
PM,44352,44800,0,7132.5,257728,114736,697152,57231.9,86016,84855.8,4535,40.673,138,40.608,81.281
5:26
PM,57344,57536,6824.4,0,234432,43051.1,699072,56547.9,86016,84826.9,4554,41.42,140,41.189,82.609
5:27
PM,40384,39552,0,0,241472,9214.1,698048,56042.8,86016,85068.4,4569,41.654,142,41.733,83.387
5:28
PM,33856,34880,0,0,246144,142425.9,699072,72538.1,86016,85050.2,4584,41.858,144,42.29,84.148
5:29
PM,34624,35840,0,0,246912,0,699072,75336.9,86016,86015.9,4600,42.124,146,42.579,84.703
5:30
PM,30528,29696,0,0,251712,8659.2,695168,55628,86016,84960.3,4619,42.419,148,43.386,85.804
5:31
PM,54976,56896,0,0,235712,46460.7,699072,55692.1,86016,84808.4,4638,43.443,150,43.882,87.324
5:32
PM,34240,34432,0,21864.2,244608,0,699072,58492.1,86016,86015.9,4659,43.833,151,43.882,87.715
5:32
PM,34240,35776,0,0,245632,218408.9,699072,70700.8,86016,85191,4660,43.837,152,44.406,88.242
5:33
PM,38528,40320,0,0,248256,2285.5,695808,55692,86016,85211,4676,44.181,154,44.935,89.116
5:34
PM,32896,34176,0,0,252800,39141,696256,56017.4,86016,85089.1,4694,44.492,156,45.527,90.018
5:35
PM,30528,31744,0,0,257792,7705.7,696320,55393.1,86016,84869,4718,44.881,158,46.092,90.973
5:36
PM,31616,32640,0,0,259200,769.5,695552,55291,86016,84766.7,4736,45.171,160,46.649,91.82
5:38
PM,31296,32576,0,0,264320,8005.1,696512,55448.5,86016,85074.6,4766,45.689,162,47.198,92.887
5:46
PM,34048,6848,0,6848,282176,0,696512,99912.5,86016,86015.9,4873,47.811,163,47.198,95.009
5:46
PM,34048,35456,0,0,278592,3379.3,696576,55326.5,86016,84954.3,4874,47.814,164,47.796,95.61
5:54
PM,31488,30336,0,0,286144,237399.7,696768,55451.5,86016,85142.3,4987,49.961,166,48.324,98.285
6:02
PM,32192,30848,0,0,274368,5980.1,696640,55332.1,86016,85108.1,5103,52.314,168,48.916,101.23
6:09
PM,38144,64,0,0,276416,15814.6,697536,56164.9,86016,85325.8,5159,53.572,170,49.522,103.094
6:11
PM,34752,33536,0,0,275456,5206.4,697280,56571.9,86016,85075.4,5167,53.733,172,50.078,103.812
============================CSV data end ================================
----- Original Message -----
From: "Jeffrey Janner" <Je...@PolyDyne.com>
To: "Tomcat Users List" <us...@tomcat.apache.org>
Sent: Friday, May 28, 2010 1:26 AM
Subject: RE: tomcat memory question
>> -----Original Message-----
>> From: Christopher Schultz [mailto:chris@christopherschultz.net]
>> Sent: Thursday, May 27, 2010 9:40 AM
>> To: Tomcat Users List
>> Subject: Re: tomcat memory question
>>
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA1
>>
>> 塗,
>>
>> On 5/27/2010 4:51 AM, 塗 wrote:
>> > there is a problem with my webapp.
>> >
>> > web operating environment:
>> > tomcat5.5.27 + Apache/2.2.3 + jdk1.5.0_13 + Linux_x86_64
>> >
>> > [below] is my manual configurations for tomcat JVM:
>> > CATALINA_OPTS="-Xms1024M -Xmx1024M
>> > -Dorg.apache.jasper.compiler.Parser.STRICT_QUOTE_ESCAPING=false"
>>
>> Are you using a 64-bit or 32-bit JVM?
>>
>> > When my webapp is started, I use the jvm's own tools(jstat) to trace
>> the
>> > garbage collections.
>>
>> Ok.
>>
>> > the Utilization rate of the PC capacity is always 100%. is it
>> normal?
>>
>> What is "PC" (sorry, the jstat man page sucks)? What is the command you
>> used to produce your jstat output?
>>
>
> Well, PC is apparently Permanent Capacity in KB, and PU is the current
> Permanent Utilization (not to be confused with PermGen apparently).
> Taking his data a sticking it in a spreadsheet (to make it readable) shows
> that PC is increasing and keeping slightly ahead of PU. I'd say nothing
> to worry about unless PC is starting to reach PGCMX (which is? Try
> including the -gccapacity option). Looks like normal GC at work to me.
>
>> > Firstly the 1 Full GC is occurrenced within 1 hour,
>> > 5 hours later that took place within 1 hour 100 Full GC.
>> > is it normal?
>>
>> Can you clarify this last statement? When did the first full GC take
>> place? When did the second? When did the third? Are you saying that you
>> get one full GC in one hour, then 5 hours for the second, then 100 full
>> GCs all close together?
>>
>
> The OPs original statement makes no sense in light of the data give.
> There is no Full GC count line in his data (though doc says there should
> be: http://java.sun.com/j2se/1.5.0/docs/tooldocs/share/jstat.html). The
> doc seems to imply that the GC times should be cumulative from start, so
> it looks like he's done some Full GC between each sample taken (about 7
> secs/hr.) It would be really helpful if he had listed his jstat options.
>
> All the actual capacity/utilization numbers appear to be rising and
> falling over time in apparent relation to normal usage. The permanent
> util number doesn't seem to drop often, so he may have a memory leak. (I'd
> seek the opinion of someone more versed than me in reading jstat output
> though.)
>
> It would have been useful if he had a specific issue he was having and
> trying to resolve.
>
>> That suggests to me that your webapp is allocating memory and never
>> releasing it. This could be due to many reasons such as a memory leak
>> (which ought to be fixed) or caching (which may be working as
>> designed).
>>
>> Is your webapp performing well? GC activity doesn't necessarily mean
>> that anything is wrong.
>>
>> - -chris
>> -----BEGIN PGP SIGNATURE-----
>> Version: GnuPG v1.4.10 (MingW32)
>> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
>>
>> iEYEARECAAYFAkv+hFoACgkQ9CaO5/Lv0PBFkgCgvqoksV7PgaqGFOI5wCgXwaIa
>> yKcAniKySqd3g8wd7paAoRBn0mWklSZY
>> =RfE/
>> -----END PGP SIGNATURE-----
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>
>
> ******************************* NOTICE *********************************
> This message is intended for the use of the individual or entity to which
> it is addressed and may contain information that is privileged,
> confidential, and exempt from disclosure under applicable law. If the
> reader of this message is not the intended recipient or the employee or
> agent responsible for delivering this message to the intended recipient,
> you are hereby notified that any dissemination, distribution, or copying
> of this communication is strictly prohibited. If you have received this
> communication in error, please notify us immediately by reply or by
> telephone (call us collect at 512-343-9100) and immediately delete this
> message and all its attachments.
>
RE: tomcat memory question
Posted by Jeffrey Janner <Je...@PolyDyne.com>.
> -----Original Message-----
> From: Christopher Schultz [mailto:chris@christopherschultz.net]
> Sent: Thursday, May 27, 2010 9:40 AM
> To: Tomcat Users List
> Subject: Re: tomcat memory question
>
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> 塗,
>
> On 5/27/2010 4:51 AM, 塗 wrote:
> > there is a problem with my webapp.
> >
> > web operating environment:
> > tomcat5.5.27 + Apache/2.2.3 + jdk1.5.0_13 + Linux_x86_64
> >
> > [below] is my manual configurations for tomcat JVM:
> > CATALINA_OPTS="-Xms1024M -Xmx1024M
> > -Dorg.apache.jasper.compiler.Parser.STRICT_QUOTE_ESCAPING=false"
>
> Are you using a 64-bit or 32-bit JVM?
>
> > When my webapp is started, I use the jvm's own tools(jstat) to trace
> the
> > garbage collections.
>
> Ok.
>
> > the Utilization rate of the PC capacity is always 100%. is it
> normal?
>
> What is "PC" (sorry, the jstat man page sucks)? What is the command you
> used to produce your jstat output?
>
Well, PC is apparently Permanent Capacity in KB, and PU is the current Permanent Utilization (not to be confused with PermGen apparently). Taking his data a sticking it in a spreadsheet (to make it readable) shows that PC is increasing and keeping slightly ahead of PU. I'd say nothing to worry about unless PC is starting to reach PGCMX (which is? Try including the -gccapacity option). Looks like normal GC at work to me.
> > Firstly the 1 Full GC is occurrenced within 1 hour,
> > 5 hours later that took place within 1 hour 100 Full GC.
> > is it normal?
>
> Can you clarify this last statement? When did the first full GC take
> place? When did the second? When did the third? Are you saying that you
> get one full GC in one hour, then 5 hours for the second, then 100 full
> GCs all close together?
>
The OPs original statement makes no sense in light of the data give. There is no Full GC count line in his data (though doc says there should be: http://java.sun.com/j2se/1.5.0/docs/tooldocs/share/jstat.html). The doc seems to imply that the GC times should be cumulative from start, so it looks like he's done some Full GC between each sample taken (about 7 secs/hr.) It would be really helpful if he had listed his jstat options.
All the actual capacity/utilization numbers appear to be rising and falling over time in apparent relation to normal usage. The permanent util number doesn't seem to drop often, so he may have a memory leak. (I'd seek the opinion of someone more versed than me in reading jstat output though.)
It would have been useful if he had a specific issue he was having and trying to resolve.
> That suggests to me that your webapp is allocating memory and never
> releasing it. This could be due to many reasons such as a memory leak
> (which ought to be fixed) or caching (which may be working as
> designed).
>
> Is your webapp performing well? GC activity doesn't necessarily mean
> that anything is wrong.
>
> - -chris
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.10 (MingW32)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
>
> iEYEARECAAYFAkv+hFoACgkQ9CaO5/Lv0PBFkgCgvqoksV7PgaqGFOI5wCgXwaIa
> yKcAniKySqd3g8wd7paAoRBn0mWklSZY
> =RfE/
> -----END PGP SIGNATURE-----
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
******************************* NOTICE *********************************
This message is intended for the use of the individual or entity to which
it is addressed and may contain information that is privileged,
confidential, and exempt from disclosure under applicable law. If the
reader of this message is not the intended recipient or the employee or
agent responsible for delivering this message to the intended recipient,
you are hereby notified that any dissemination, distribution, or copying
of this communication is strictly prohibited. If you have received this
communication in error, please notify us immediately by reply or by
telephone (call us collect at 512-343-9100) and immediately delete this
message and all its attachments.
Re: tomcat memory question
Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
塗,
On 5/27/2010 4:51 AM, 塗 wrote:
> there is a problem with my webapp.
>
> web operating environment:
> tomcat5.5.27 + Apache/2.2.3 + jdk1.5.0_13 + Linux_x86_64
>
> [below] is my manual configurations for tomcat JVM:
> CATALINA_OPTS="-Xms1024M -Xmx1024M
> -Dorg.apache.jasper.compiler.Parser.STRICT_QUOTE_ESCAPING=false"
Are you using a 64-bit or 32-bit JVM?
> When my webapp is started, I use the jvm's own tools(jstat) to trace the
> garbage collections.
Ok.
> the Utilization rate of the PC capacity is always 100%. is it normal?
What is "PC" (sorry, the jstat man page sucks)? What is the command you
used to produce your jstat output?
> Firstly the 1 Full GC is occurrenced within 1 hour,
> 5 hours later that took place within 1 hour 100 Full GC.
> is it normal?
Can you clarify this last statement? When did the first full GC take
place? When did the second? When did the third? Are you saying that you
get one full GC in one hour, then 5 hours for the second, then 100 full
GCs all close together?
That suggests to me that your webapp is allocating memory and never
releasing it. This could be due to many reasons such as a memory leak
(which ought to be fixed) or caching (which may be working as designed).
Is your webapp performing well? GC activity doesn't necessarily mean
that anything is wrong.
- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iEYEARECAAYFAkv+hFoACgkQ9CaO5/Lv0PBFkgCgvqoksV7PgaqGFOI5wCgXwaIa
yKcAniKySqd3g8wd7paAoRBn0mWklSZY
=RfE/
-----END PGP SIGNATURE-----
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org