cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Shuler <>
Subject Re: Cassandra consuming too much memory in ubuntu as compared to within windows, same machine.
Date Sat, 04 Jan 2014 17:12:44 GMT
On 01/04/2014 10:04 AM, Ertio Lew wrote:
> I run a development Cassandra single node server on both ubuntu &
> windows 8 on my dual boot 4GB(RAM) machine.
> I see that cassandra runs fine under windows without any crashes or OOMs
> however in ubuntu on same machine, it always gives an OOM message
> *$* *sudo service cassandra start*
> xss =  -ea -javaagent:/usr/share/cassandra/lib/jamm-0.2.5.jar
> -XX:+UseThreadPriorities -XX:ThreadPriorityPolicy=42 -Xms4G -Xmx4G
> -Xmn800M -XX:+HeapDumpOnOutOfMemoryError -Xss256k

The above is not a system OOM error, but is the console output of the 
JVM options being passed at startup, including one to dump the heap if 
an OOM does occur.

> Here is the memory usage for empty cassandra server in ubuntu.
> *(PID)1169 (USER)cassandr  (PR)20   (NI)0 (VIRT)2639m (RES)1.3g
>   (SHR)17m S    (%CPU)1 (%MEMORY)33.9   (TIME)0:53.80    (COMMAND)java*
> The memory usage however while running under windows is very low
> relative to this.

Windows and Linux report memory usage very differently.  Functional 
benchmarks would be much better things to look at for comparing the 
performance on different operating systems.  Memory usage patterns under 
long-running load tests, disk I/O, etc. might be far more interesting 
than simply starting the service and looking at `free` and 
$WINDOWS_EQUIVALENT.  Have a look at cassandra-stress.

> What is the reason behind this ?

Perhaps ?

> Also how can I prevent these OOMs within Ubuntu? I am running Datastax's
> DSC version 2.0.3.

Again, what you posted aren't OOMs, but if you are seeing the OS killing 
your cassandra process, then you have some tuning to do.  If you need 
help with tuning, post logs somewhere (cassandra and OS syslog).

Kind regards,

View raw message