tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rainer Jung <rainer.j...@kippdata.de>
Subject Re: Tomcat 7 (7.0.54) memory consuption is very high(3 times) than Tomcat 6 (6.0.28)
Date Mon, 23 Mar 2015 17:13:08 GMT
Am 23.03.2015 um 17:16 schrieb Caldarale, Charles R:
>> From: Rainer Jung [mailto:rainer.jung@kippdata.de]
>> Subject: Re: Tomcat 7 (7.0.54) memory consuption is very high(3 times) than Tomcat
6 (6.0.28)
>
>> Also interesting is "cat /proc/PID/maps" but here one would need to
>> calculate sizes per line from the two hex addresses given at the start
>> of each line.
>
> /proc/<pid>/smaps gives a bit more info (including various sizes), but produces
multiple lines per record, making sorting more difficult.

At least on my variant of Linux the following puts the data in one line 
and sorts by first size ("Size"). Choosing another columnwould mean 
changing the "2" in the sort command.

cat /proc/PID/smaps | \
   perl -n -e 'END {print $line, "\n"} chomp(); if ($_ =~ /^[0-9a-f]+-/) 
{print $line, "\n"; $line=$_} else {$_ =~ s/.* ([0-9]+ )/$1/; $line = 
$line . " | " . $_;}' | \
   sort -t '|' -n -k 2

Regards,

Rainer



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message