Configure the GC logs directory to be the same as other C* log directories, as defined by $CASSANDRA_LOG_DIR

patch by Angelo Polo; reviewed by Mick Semb Wever for CASSANDRA-14306
This commit is contained in:
Mick Semb Wever 2020-01-01 13:19:18 +01:00
parent de4e2504f4
commit 3edbb09e02
No known key found for this signature in database
GPG Key ID: E91335D77E3E87CB
2 changed files with 7 additions and 1 deletions

View File

@ -1,4 +1,5 @@
3.0.20
* GC logs are also put under $CASSANDRA_LOG_DIR (CASSANDRA-14306)
* Fix sstabledump's position key value when partitions have multiple rows (CASSANDRA-14721)
* Avoid over-scanning data directories in LogFile.verify() (CASSANDRA-15364)
* Bump generations and document changes to system_distributed and system_traces in 3.0, 3.11

View File

@ -121,8 +121,13 @@ case "$jvm" in
;;
esac
# Sets the path where logback and GC logs are written.
if [ "x$CASSANDRA_LOG_DIR" = "x" ] ; then
CASSANDRA_LOG_DIR="$CASSANDRA_HOME/logs"
fi
#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"
JVM_OPTS="$JVM_OPTS -Xloggc:${CASSANDRA_LOG_DIR}/gc.log"
# Here we create the arguments that will get passed to the jvm when
# starting cassandra.