[ https://issues.apache.org/jira/browse/GEODE-2883?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16007221#comment-16007221 ] ASF subversion and git services commented on GEODE-2883: -------------------------------------------------------- Commit 68935caea1d158375d6bf94c73c8f685eda01211 in geode's branch refs/heads/feature/GEODE-2632-15 from [~jstewart] [ https://git-wip-us.apache.org/repos/asf?p=geode.git;h=68935ca ] GEODE-2883: Fix GFSH gc heap size output > gfsh gc reports incorrect heap sizes > ------------------------------------ > > Key: GEODE-2883 > URL: https://issues.apache.org/jira/browse/GEODE-2883 > Project: Geode > Issue Type: Bug > Components: gfsh > Affects Versions: 1.0.0-incubating, 1.1.0, 1.1.1 > Reporter: Barry Oglesby > Assignee: Jared Stewart > Fix For: 1.2.0 > > > I have 3 servers each with -Xms1g and -Xmx1g, and I load some data. > If I run a gfsh gc, it reports: > {noformat} > GC Summary > Member ID/Name | HeapSize (MB) Before GC | HeapSize(MB) After GC | Time Taken for GC in ms > --------------------------- | ----------------------- | --------------------- | ----------------------- > 192.168.2.7(98588):1025 | 2078 | 1098 | 516 > 192.168.2.7(98602):1027 | 1942 | 1110 | 530 > 192.168.2.7(98595):1026 | 2019 | 1109 | 531 > {noformat} > The heap sizes before and after are higher than they should be. > I added some debugging in the GarbageCollectionFunction, and it shows: > {noformat} > GarbageCollectionFunction.execute freeMemoryBeforeGC=765581248; totalMemoryBeforeGC=1037959168 > GarbageCollectionFunction.execute freeMemoryAfterGC=893946464; totalMemoryAfterGC=1037959168 > GarbageCollectionFunction.execute HeapSizeBeforeGC=2078 > GarbageCollectionFunction.execute HeapSizeAfterGC=1098 > GarbageCollectionFunction.execute freeMemoryBeforeGC=773307528; totalMemoryBeforeGC=1037959168 > GarbageCollectionFunction.execute freeMemoryAfterGC=892508088; totalMemoryAfterGC=1037959168 > GarbageCollectionFunction.execute HeapSizeBeforeGC=2019 > GarbageCollectionFunction.execute HeapSizeAfterGC=1109 > GarbageCollectionFunction.execute freeMemoryBeforeGC=783373464; totalMemoryBeforeGC=1037959168 > GarbageCollectionFunction.execute freeMemoryAfterGC=892349664; totalMemoryAfterGC=1037959168 > GarbageCollectionFunction.execute HeapSizeBeforeGC=1942 > GarbageCollectionFunction.execute HeapSizeAfterGC=1110 > {noformat} > The free and total memory are fine, but the heap sizes before and after are incorrect. > The function is using 131072 as its divisor > {noformat} > 1037959168-765581248=272377920 / 131072 = 2078 > 1037959168-893946464=144012704 / 131072 = 1098 > {noformat} > It should be using 1024*1024. > {noformat} > 1037959168-765581248=272377920 / (1024*1024) = 259 > 1037959168-893946464=144012704 / (1024*1024) = 137 > {noformat} -- This message was sent by Atlassian JIRA (v6.3.15#6346)