You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@accumulo.apache.org by "Adam Fuchs (JIRA)" <ji...@apache.org> on 2012/05/18 23:01:07 UTC

[jira] [Created] (ACCUMULO-599) investigate permgen collection and class unloading with concurrent mark and sweep garbage collector

Adam Fuchs created ACCUMULO-599:
-----------------------------------

             Summary: investigate permgen collection and class unloading with concurrent mark and sweep garbage collector
                 Key: ACCUMULO-599
                 URL: https://issues.apache.org/jira/browse/ACCUMULO-599
             Project: Accumulo
          Issue Type: Bug
          Components: scripts
    Affects Versions: 1.3.6, 1.4.0
            Reporter: Adam Fuchs
            Assignee: John Vines


The Java concurrent mark and sweep garbage collector appears to default to not unloading classes or sweeping the permgen storage space. Accumulo reloads classes dynamically, potentially contributing a lot to the permgen space. It is important that these classes be garbage collected when we're done with them. Since we use -XX:+UseConcMarkSweepGC by default for all Accumulo processes, should we also use -XX:+CMSClassUnloadingEnabled and -XX:+CMSPermGenSweepingEnabled? Are there other flags or parameters that we should set to really do java garbage collection properly in a long-lived instance?

These should be set in conf/accumulo-env.sh as part of ACCUMULO_GENERAL_OPTS.


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (ACCUMULO-599) investigate permgen collection and class unloading with concurrent mark and sweep garbage collector

Posted by "John Vines (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ACCUMULO-599?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

John Vines updated ACCUMULO-599:
--------------------------------

    Assignee:     (was: John Vines)
    
> investigate permgen collection and class unloading with concurrent mark and sweep garbage collector
> ---------------------------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-599
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-599
>             Project: Accumulo
>          Issue Type: Bug
>          Components: scripts
>    Affects Versions: 1.3.6, 1.4.0
>            Reporter: Adam Fuchs
>
> The Java concurrent mark and sweep garbage collector appears to default to not unloading classes or sweeping the permgen storage space. Accumulo reloads classes dynamically, potentially contributing a lot to the permgen space. It is important that these classes be garbage collected when we're done with them. Since we use -XX:+UseConcMarkSweepGC by default for all Accumulo processes, should we also use -XX:+CMSClassUnloadingEnabled and -XX:+CMSPermGenSweepingEnabled? Are there other flags or parameters that we should set to really do java garbage collection properly in a long-lived instance?
> These should be set in conf/accumulo-env.sh as part of ACCUMULO_GENERAL_OPTS.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (ACCUMULO-599) investigate permgen collection and class unloading with concurrent mark and sweep garbage collector

Posted by "Adam Fuchs (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-599?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13283364#comment-13283364 ] 

Adam Fuchs commented on ACCUMULO-599:
-------------------------------------

Sounds like we ought to reach out to a Java GC guru with this question.

My philosophy would be that we should pull in whatever configs we think make sense and then thoroughly test. Waiting for bugs to show up could mask the potential for performance improvement.
                
> investigate permgen collection and class unloading with concurrent mark and sweep garbage collector
> ---------------------------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-599
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-599
>             Project: Accumulo
>          Issue Type: Bug
>          Components: scripts
>    Affects Versions: 1.3.6, 1.4.0
>            Reporter: Adam Fuchs
>            Assignee: John Vines
>
> The Java concurrent mark and sweep garbage collector appears to default to not unloading classes or sweeping the permgen storage space. Accumulo reloads classes dynamically, potentially contributing a lot to the permgen space. It is important that these classes be garbage collected when we're done with them. Since we use -XX:+UseConcMarkSweepGC by default for all Accumulo processes, should we also use -XX:+CMSClassUnloadingEnabled and -XX:+CMSPermGenSweepingEnabled? Are there other flags or parameters that we should set to really do java garbage collection properly in a long-lived instance?
> These should be set in conf/accumulo-env.sh as part of ACCUMULO_GENERAL_OPTS.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (ACCUMULO-599) investigate permgen collection and class unloading with concurrent mark and sweep garbage collector

Posted by "John Vines (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-599?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13281136#comment-13281136 ] 

John Vines commented on ACCUMULO-599:
-------------------------------------

Reading through http://www.oracle.com/technetwork/java/javase/tech/vmoptions-jsp-140102.html and some flags which catch my eye-
-XX:MaxGCPauseMillis=n - Sets a target for the maximum GC pause time. This is a soft goal, and the JVM will make its best effort to achieve it. - May be worthwhile to encourage the GC to limit it's GC rounds to 15-20 seconds top to prevent stops?
-XX:+UseLargePages - Use large page memory. (Introduced in 5.0 update 5.) For details, see Java Support for Large Memory Pages. - Not sure if this would be worthwhile or not. But seems interesting
-XX:+UseTLAB - Uses thread-local object allocation blocks. This improves concurrency by reducing contention on the shared heap lock. - May be worthwhile with the amount of multithreading we do, at least in the tservers (and possibly clients, though we don't typically do object creation within them)
-XX:MaxTenuringThreshold=0 - Makes the full NewSize available to every NewGC cycle, and reduces the pause time by not evaluating tenured objects. Technically, this setting promotes all live objects to the older generation, rather than copying them - This would allow objects to only be handled by the concurrent mark and sweet collector. Unfortunately, if our assumption about old-stop-the-world GC kicking off if the CMS can't keep up, then this will only amplify it's problems.

Part of me says we should try some out, but part of me says we should only fix that which we find to be broken. I think if no one has anything to say, we should only do the suggested class unloading and perm gen sweeping.


                
> investigate permgen collection and class unloading with concurrent mark and sweep garbage collector
> ---------------------------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-599
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-599
>             Project: Accumulo
>          Issue Type: Bug
>          Components: scripts
>    Affects Versions: 1.3.6, 1.4.0
>            Reporter: Adam Fuchs
>            Assignee: John Vines
>
> The Java concurrent mark and sweep garbage collector appears to default to not unloading classes or sweeping the permgen storage space. Accumulo reloads classes dynamically, potentially contributing a lot to the permgen space. It is important that these classes be garbage collected when we're done with them. Since we use -XX:+UseConcMarkSweepGC by default for all Accumulo processes, should we also use -XX:+CMSClassUnloadingEnabled and -XX:+CMSPermGenSweepingEnabled? Are there other flags or parameters that we should set to really do java garbage collection properly in a long-lived instance?
> These should be set in conf/accumulo-env.sh as part of ACCUMULO_GENERAL_OPTS.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (ACCUMULO-599) investigate permgen collection and class unloading with concurrent mark and sweep garbage collector

Posted by "John Vines (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ACCUMULO-599?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13279191#comment-13279191 ] 

John Vines commented on ACCUMULO-599:
-------------------------------------

Perhaps this should be a generic look into java garbage collection
configurations. It's been a while since we have done research into that
subject.

Sent from my phone, so pardon the typos and brevity.


                
> investigate permgen collection and class unloading with concurrent mark and sweep garbage collector
> ---------------------------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-599
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-599
>             Project: Accumulo
>          Issue Type: Bug
>          Components: scripts
>    Affects Versions: 1.3.6, 1.4.0
>            Reporter: Adam Fuchs
>            Assignee: John Vines
>
> The Java concurrent mark and sweep garbage collector appears to default to not unloading classes or sweeping the permgen storage space. Accumulo reloads classes dynamically, potentially contributing a lot to the permgen space. It is important that these classes be garbage collected when we're done with them. Since we use -XX:+UseConcMarkSweepGC by default for all Accumulo processes, should we also use -XX:+CMSClassUnloadingEnabled and -XX:+CMSPermGenSweepingEnabled? Are there other flags or parameters that we should set to really do java garbage collection properly in a long-lived instance?
> These should be set in conf/accumulo-env.sh as part of ACCUMULO_GENERAL_OPTS.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira