Hi Jean,
I had the same problem, I removed the lines in /etc/init.d/cassandra template 
(we use Chef to deploy) and now the HeapDumpPath is not overridden anymore.The 
same goes for -XX:ErrorFile. 
Best,
Romain

    Le Mardi 4 octobre 2016 9h25, Jean Carlo <jean.jeancar...@gmail.com> a 
écrit :
 

 Yes, we did it. 

So if the parameter in cassandra-env.sh is used only if we have a OOM, what is 
for the definition of -XX:HeapDumpPath=/var/lib/ cassandra/java_1475461286. 
hprof in /etc/init.d/cassandra for?


Saludos

Jean Carlo
"The best way to predict the future is to invent it" Alan Kay

On Tue, Oct 4, 2016 at 2:58 AM, Yabin Meng <yabinm...@gmail.com> wrote:

Have you restarted Cassandra after making changes in cassandra-env.sh?
Yabin
On Mon, Oct 3, 2016 at 7:44 AM, Jean Carlo <jean.jeancar...@gmail.com> wrote:

OK I got the response to one of my questions. In the script 
/etc/init.d/cassandra we set the path for the heap dump by default in the 
cassandra_home.

Now the thing I don't understand is, why do the dumps are located by the file 
set by /etc/init.d/cassandra and not by the  conf file cassandra-env.sh?

Anyone any idea?


Saludos

Jean Carlo
"The best way to predict the future is to invent it" Alan Kay

On Mon, Oct 3, 2016 at 12:00 PM, Jean Carlo <jean.jeancar...@gmail.com> wrote:


Hi

I see in the log of my node cassandra that the parameter -XX:HeapDumpPath is 
charged two times.

INFO  [main] 2016-10-03 04:21:29,941 CassandraDaemon.java:205 - JVM Arguments: 
[-ea, -javaagent:/usr/share/cassandr a/lib/jamm-0.3.0.jar, 
-XX:+CMSClassUnloadingEnabled, -XX:+UseThreadPriorities, 
-XX:ThreadPriorityPolicy=42, -Xms6G, -Xmx6G, -Xmn600M, 
-XX:+HeapDumpOnOutOfMemoryErro r, -XX:HeapDumpPath=/cassandra/du 
mps/cassandra-1475461287-pid34 435.hprof, -Xss256k, 
-XX:StringTableSize=1000003, -XX:+UseParNewGC, -XX:+UseConcMarkSweepGC, 
-XX:+CMSParallelRemarkEnabled, -XX:SurvivorRatio=8, -XX:MaxTenuringThreshold=1, 
-XX:CMSInitiatingOccupancyFrac tion=30, -XX:+UseCMSInitiatingOccupancy Only, 
-XX:+UseTLAB, -XX:CompileCommandFile=/etc/ca ssandra/hotspot_compiler, 
-XX:CMSWaitDuration=10000, -XX:+CMSParallelInitialMarkEna bled, 
-XX:+CMSEdenChunksRecordAlways , -XX:CMSWaitDuration=10000, 
-XX:+UseCondCardMark, -XX:+PrintGCDetails, -XX:+PrintGCDateStamps, 
-XX:+PrintGCApplicationStopped Time, -Xloggc:/var/opt/hosting/log/c 
assandra/gc.log, -XX:+UseGCLogFileRotation, -XX:NumberOfGCLogFiles=20, 
-XX:GCLogFileSize=20M, -Djava.net.preferIPv4Stack=tru e, 
-Dcom.sun.management.jmxremote .port=7199, -Dcom.sun.management.jmxremote 
.rmi.port=7199, -Dcom.sun.management.jmxremote .ssl=false, 
-Dcom.sun.management.jmxremote .authenticate=false, 
-Dcom.sun.management.jmxremote .password.file=/etc/cassandra/ 
jmxremote.password, -Djava.io.tmpdir=/var/opt/host ing/db/cassandra/tmp, 
-javaagent:/usr/share/cassandr a/lib/jolokia-jvm-1.0.6-agent. 
jar=port=8778,host=0.0.0.0, -Dcassandra.auth_bcrypt_gensal t_log2_rounds=4, 
-Dlogback.configurationFile=lo gback.xml, -Dcassandra.logdir=/var/log/ca 
ssandra, -Dcassandra.storagedir=, -Dcassandra-pidfile=/var/run/c 
assandra/cassandra.pid, -XX:HeapDumpPath=/var/lib/cass 
andra/java_1475461286.hprof, -XX:ErrorFile=/var/lib/cassand 
ra/hs_err_1475461286.log]

This option is defined in cassandra-env.sh

if [ "x$CASSANDRA_HEAPDUMP_DIR" != "x" ]; then
    JVM_OPTS="$JVM_OPTS -XX:HeapDumpPath=$CASSANDRA_HE 
APDUMP_DIR/cassandra-`date +%s`-pid$$.hprof"
fi
 and we defined before the value of CASSANDRA_HEAPDUMP_DIR before to 
/cassandra/dumps/

It is seems that cassandra does not care about the conf in cassandra-env.sh and 
he only takes in account the last set for HeapDumpPath 
/var/lib/cassandra/java_147546 1286.hprof

This causes problems when we have to dump the heap because cassandra uses the 
disk not suitable to do it.

Is  XX:HeapDumpPath set in another place/file that I dont know?

Thxs

Jean Carlo
"The best way to predict the future is to invent it" Alan Kay








   

Reply via email to