Using CMS, any chance of forewarning a serial full GC is imminent?

Jon Masamitsu Jon.Masamitsu at Sun.COM
Sat Mar 20 03:43:08 UTC 2010

System.gc() will cause CMS to do a full collection.  Does that
help?  As long as you have not turned off explicit GC's nor
set flags so that CMS does System.gc() concurrently, you can
compact the tenured (CMS) gen that way.

On Mar 19, 2010, at 8:31 PM, Stack wrote:

> Or, running CMS, is there a way to trigger full serial GC?  If we
> could make it run explicitly at preordained times, this would be an
> improvement over it happening at maximum-embarrassment time.
> Thanks,
> St.Ack
> On Fri, Mar 19, 2010 at 8:21 PM, Stack <stack at> wrote:
>> Our app, a distributed database, usually does fine running CMS but
>> when we trip a full serial GC, its disruptive (speaking
>> euphemistically).
>> Monitoring the running application, watching the logs or patching  
>> into
>> the JVM-TI, is there any indicator that you know of that would give  
>> us
>> forewarning of an imminent full serial GC?  If we had this, we could
>> take evasive action.
>> Thanks,
>> St.Ack
>> P.S. G1 is what we really need but going by the response up on this
>> and by how easy our application crashes recent releases, it looks  
>> like
>> its going to be a good while before it'll work for our case (We're an
>> open source database so talking to our sun/oracle vendor is not an
>> option).
> _______________________________________________
> hotspot-gc-use mailing list
> hotspot-gc-use at

hotspot-gc-use mailing list
hotspot-gc-use at

More information about the hotspot-gc-dev mailing list