I ran into the same issue running the same OS and same install method. While the cassandra service claims that it's starting ok, if you run service cassandra status
it would tell me that the process was dead. Here are the steps I took to fix it:
Viewing the log file at /var/log/cassandra/cassandra.log
gave told me that my heap size was too small. Manually set the heap size in /etc/cassandra/conf/cassandra-env.sh
:
MAX_HEAP_SIZE="1G"
HEAP_NEWSIZE="256M"
Tips on setting the heap size for your system can be found here
Next, the error log claimed the stack size was too small. Once again in /etc/cassandra/conf/cassandra-env.sh
find a line that looks like JVM_OPTS="$JVM_OPTS -Xss128k"
and raise that number to JVM_OPTS="$JVM_OPTS -Xss256k"
Lastly, the log complained that the local url was misformed and threw a java exception. I found the answer to the last part here. Basically, you want to manually bind your server's hostname in your /etc/hosts
file.
127.0.0.1 localhost localhost.localdomain server1.example.com
Hope this helps~