[ 
https://issues.apache.org/jira/browse/CASSANDRA-8150?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14575206#comment-14575206
 ] 

Albert P Tobey edited comment on CASSANDRA-8150 at 6/5/15 8:56 PM:
-------------------------------------------------------------------

I did some testing on EC2 with Cassandra 2.0 and G1GC and found the following 
settings to work well. Make sure to comment out the -Xmn line as shown.

{code}

MAX_HEAP_SIZE="16G"
HEAP_NEWSIZE=”2G” # placeholder, ignored

# setting -Xmn breaks G1GC, don’t do it
#JVM_OPTS="$JVM_OPTS -Xmn${HEAP_NEWSIZE}"

# G1GC support [email protected] 2015-04-03
JVM_OPTS="$JVM_OPTS -XX:+UseG1GC"

# Cassandra does not benefit from biased locking
JVM_OPTS="$JVM_OPTS -XX:-UseBiasedLocking"

# lowering the pause target will lower throughput
# 200ms is the default and lowest viable setting for G1GC
# 1000ms seems to provide good balance of throughput and latency
JVM_OPTS="$JVM_OPTS -XX:MaxGCPauseMillis=1000"

# auto-optimize thread local allocation block size
# https://blogs.oracle.com/jonthecollector/entry/the_real_thi
JVM_OPTS="$JVM_OPTS -XX:+UseTLAB -XX:+ResizeTLAB"

{code}


was (Author: [email protected]):
I did some testing on EC2 with Cassandra 2.0 and G1GC and found the following 
settings to work well. Make sure to comment out the -Xmn line as shown.

{code:sh}

MAX_HEAP_SIZE="16G"
HEAP_NEWSIZE=”2G” # placeholder, ignored

# setting -Xmn breaks G1GC, don’t do it
#JVM_OPTS="$JVM_OPTS -Xmn${HEAP_NEWSIZE}"

# G1GC support [email protected] 2015-04-03
JVM_OPTS="$JVM_OPTS -XX:+UseG1GC"

# Cassandra does not benefit from biased locking
JVM_OPTS="$JVM_OPTS -XX:-UseBiasedLocking"

# lowering the pause target will lower throughput
# 200ms is the default and lowest viable setting for G1GC
# 1000ms seems to provide good balance of throughput and latency
JVM_OPTS="$JVM_OPTS -XX:MaxGCPauseMillis=1000"

# auto-optimize thread local allocation block size
# https://blogs.oracle.com/jonthecollector/entry/the_real_thi
JVM_OPTS="$JVM_OPTS -XX:+UseTLAB -XX:+ResizeTLAB"

{code}

> Revaluate Default JVM tuning parameters
> ---------------------------------------
>
>                 Key: CASSANDRA-8150
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-8150
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: Config
>            Reporter: Matt Stump
>            Assignee: Ryan McGuire
>         Attachments: upload.png
>
>
> It's been found that the old twitter recommendations of 100m per core up to 
> 800m is harmful and should no longer be used.
> Instead the formula used should be 1/3 or 1/4 max heap with a max of 2G. 1/3 
> or 1/4 is debatable and I'm open to suggestions. If I were to hazard a guess 
> 1/3 is probably better for releases greater than 2.1.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to