Merge branch 'cassandra-2.2' into cassandra-3.0

Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/2395f9e4
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/2395f9e4
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/2395f9e4

Branch: refs/heads/trunk
Commit: 2395f9e4678c76fa288675c57496259515efef90
Parents: 7005972 3a61c10
Author: Josh McKenzie <jmcken...@apache.org>
Authored: Tue Jun 28 13:47:08 2016 -0400
Committer: Josh McKenzie <jmcken...@apache.org>
Committed: Tue Jun 28 13:47:24 2016 -0400

----------------------------------------------------------------------
 conf/cassandra-env.ps1 | 1 +
 conf/cassandra-env.sh  | 1 +
 2 files changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/2395f9e4/conf/cassandra-env.ps1
----------------------------------------------------------------------
diff --cc conf/cassandra-env.ps1
index 794189f,60d15bb..80645f9
--- a/conf/cassandra-env.ps1
+++ b/conf/cassandra-env.ps1
@@@ -327,25 -326,6 +327,26 @@@ Function SetCassandraEnvironmen
      # times. If in doubt, and if you do not particularly want to tweak, go
      # 100 MB per physical CPU core.
  
++    New-Item -Force -ItemType directory -Path $env:CASSANDRA_HOME/logs/
 +    #GC log path has to be defined here since it needs to find CASSANDRA_HOME
 +    $env:JVM_OPTS="$env:JVM_OPTS -Xloggc:""$env:CASSANDRA_HOME/logs/gc.log"""
 +
 +    # Read user-defined JVM options from jvm.options file
 +    $content = Get-Content "$env:CASSANDRA_CONF\jvm.options"
 +    for ($i = 0; $i -lt $content.Count; $i++)
 +    {
 +        $line = $content[$i]
 +        if ($line.StartsWith("-"))
 +        {
 +            $env:JVM_OPTS = "$env:JVM_OPTS $line"
 +        }
 +    }
 +
 +    $defined_xmn = $env:JVM_OPTS -like '*Xmn*'
 +    $defined_xmx = $env:JVM_OPTS -like '*Xmx*'
 +    $defined_xms = $env:JVM_OPTS -like '*Xms*'
 +    $using_cms = $env:JVM_OPTS -like '*UseConcMarkSweepGC*'
 +
      #$env:MAX_HEAP_SIZE="4096M"
      #$env:HEAP_NEWSIZE="800M"
      CalculateHeapSizes

http://git-wip-us.apache.org/repos/asf/cassandra/blob/2395f9e4/conf/cassandra-env.sh
----------------------------------------------------------------------
diff --cc conf/cassandra-env.sh
index 44fe110,5d2330c..568448b
--- a/conf/cassandra-env.sh
+++ b/conf/cassandra-env.sh
@@@ -121,30 -124,6 +121,31 @@@ case "$jvm" i
          ;;
  esac
  
++mkdir -p ${CASSANDRA_HOME}/logs/
 +#GC log path has to be defined here because it needs to access CASSANDRA_HOME
 +JVM_OPTS="$JVM_OPTS -Xloggc:${CASSANDRA_HOME}/logs/gc.log"
 +
 +# Here we create the arguments that will get passed to the jvm when
 +# starting cassandra.
 +
 +# Read user-defined JVM options from jvm.options file
 +JVM_OPTS_FILE=$CASSANDRA_CONF/jvm.options
 +for opt in `grep "^-" $JVM_OPTS_FILE`
 +do
 +  JVM_OPTS="$JVM_OPTS $opt"
 +done
 +
 +# Check what parameters were defined on jvm.options file to avoid conflicts
 +echo $JVM_OPTS | grep -q Xmn
 +DEFINED_XMN=$?
 +echo $JVM_OPTS | grep -q Xmx
 +DEFINED_XMX=$?
 +echo $JVM_OPTS | grep -q Xms
 +DEFINED_XMS=$?
 +echo $JVM_OPTS | grep -q UseConcMarkSweepGC
 +USING_CMS=$?
 +echo $JVM_OPTS | grep -q UseG1GC
 +USING_G1=$?
  
  # Override these to set the amount of memory to allocate to the JVM at
  # start-up. For production use you may wish to adjust this for your

Reply via email to