Re: JNA to activate cassandra row cache
On 08/19/2013 02:49 PM, CROCKETT, LEONARD P wrote: Must Cassandra 1.2.5 run as root for JNA jar to effectively disable swapping? It doesn't globally disable swap (which would require root), but don't swap this block of memory.
Re: JNA to activate cassandra row cache
Under the hood a process needs permissions for kernel capabilities in order to pin memory. Under linux a process needs the CAP_IPC_LOCK capability to call mlockall (which is used by C*), 99% of the time you don't have to worry about this unless you run SE linux or are messing about with your limits.conf. Under other OS's that use RBAC style permissions, for example Solaris, where capabilities are often specified according to project, role, service etc the capability may need to be explicitly set. Ben Bromhead Instaclustr | www.instaclustr.com | @instaclustr On 22/08/2013, at 5:47 AM, Chris Burroughs chris.burrou...@gmail.com wrote: On 08/19/2013 02:49 PM, CROCKETT, LEONARD P wrote: Must Cassandra 1.2.5 run as root for JNA jar to effectively disable swapping? It doesn't globally disable swap (which would require root), but don't swap this block of memory.
RE: JNA to activate cassandra row cache
Hello dev community, Must Cassandra 1.2.5 run as root for JNA jar to effectively disable swapping? Also is platform jar required? Thanks, Leonard Crockett leonard.crock...@att.com -Original Message- From: Michael Kjellman [mailto:mkjell...@barracuda.com] Sent: Wednesday, August 14, 2013 12:40 PM To: dev@cassandra.apache.org Subject: Re: JNA to activate cassandra row cache Well- as I said there isn't a reason not to. Licensing issues have even recently been worked out but I forgot about the sun.misc.unsafe work in 1.1+ so thanks Jonathan for correcting me. On Aug 14, 2013, at 12:36 PM, José Elias Queiroga da Costa Araújo je...@cesar.org.br wrote: Hi Michael, In my investigation about Cassandra cache, there is an implementation off-heap provided to RowCache, but this implementation is based on ByteBuffer mechanish to allocate native memory using JNI. However, In Datastax Cassandra documentation they say that: Installing JNA can improve Cassandra memory usage. When installed and configured, Linux does not swap out the JVM, and thus avoids related performance issues. So my question is if Cassandra cache implementation is based ByteBuffer, there is any real reason to install JNA? Regards, 2013/8/14 Michael Kjellman mkjell...@barracuda.com No- not required, but there is zero reason not to. Keep as much off heap as possible. On Aug 14, 2013, at 12:13 PM, José Elias Queiroga da Costa Araújo je...@cesar.org.br wrote: Hi all, I have a question. In order to activate cassandra row cache is necessary to have JNA installed? Regards, *Elias.*
Fwd: JNA to activate cassandra row cache
Hi all, I have a question. In order to activate cassandra row cache is necessary to have JNA installed? Regards, *Elias.*
Re: JNA to activate cassandra row cache
No- not required, but there is zero reason not to. Keep as much off heap as possible. On Aug 14, 2013, at 12:13 PM, José Elias Queiroga da Costa Araújo je...@cesar.org.br wrote: Hi all, I have a question. In order to activate cassandra row cache is necessary to have JNA installed? Regards, *Elias.*
Re: JNA to activate cassandra row cache
We only use JNA for keeping the heap from being swapped out and faster snapshotting. Off-heap allocation does not require JNA. On Wed, Aug 14, 2013 at 2:15 PM, Michael Kjellman mkjell...@barracuda.com wrote: No- not required, but there is zero reason not to. Keep as much off heap as possible. On Aug 14, 2013, at 12:13 PM, José Elias Queiroga da Costa Araújo je...@cesar.org.br wrote: Hi all, I have a question. In order to activate cassandra row cache is necessary to have JNA installed? Regards, *Elias.* -- Jonathan Ellis Project Chair, Apache Cassandra co-founder, http://www.datastax.com @spyced
Re: JNA to activate cassandra row cache
Hi Michael, In my investigation about Cassandra cache, there is an implementation off-heap provided to RowCache, but this implementation is based on ByteBuffer mechanish to allocate native memory using JNI. However, In Datastax Cassandra documentation they say that: Installing JNA can improve Cassandra memory usage. When installed and configured, Linux does not swap out the JVM, and thus avoids related performance issues. So my question is if Cassandra cache implementation is based ByteBuffer, there is any real reason to install JNA? Regards, 2013/8/14 Michael Kjellman mkjell...@barracuda.com No- not required, but there is zero reason not to. Keep as much off heap as possible. On Aug 14, 2013, at 12:13 PM, José Elias Queiroga da Costa Araújo je...@cesar.org.br wrote: Hi all, I have a question. In order to activate cassandra row cache is necessary to have JNA installed? Regards, *Elias.*
Re: JNA to activate cassandra row cache
Well- as I said there isn't a reason not to. Licensing issues have even recently been worked out but I forgot about the sun.misc.unsafe work in 1.1+ so thanks Jonathan for correcting me. On Aug 14, 2013, at 12:36 PM, José Elias Queiroga da Costa Araújo je...@cesar.org.br wrote: Hi Michael, In my investigation about Cassandra cache, there is an implementation off-heap provided to RowCache, but this implementation is based on ByteBuffer mechanish to allocate native memory using JNI. However, In Datastax Cassandra documentation they say that: Installing JNA can improve Cassandra memory usage. When installed and configured, Linux does not swap out the JVM, and thus avoids related performance issues. So my question is if Cassandra cache implementation is based ByteBuffer, there is any real reason to install JNA? Regards, 2013/8/14 Michael Kjellman mkjell...@barracuda.com No- not required, but there is zero reason not to. Keep as much off heap as possible. On Aug 14, 2013, at 12:13 PM, José Elias Queiroga da Costa Araújo je...@cesar.org.br wrote: Hi all, I have a question. In order to activate cassandra row cache is necessary to have JNA installed? Regards, *Elias.*
Re: JNA to activate cassandra row cache
I thought that When installed and configured, Linux does not swap out the JVM was pretty straightforward. On Wed, Aug 14, 2013 at 2:36 PM, José Elias Queiroga da Costa Araújo je...@cesar.org.br wrote: Hi Michael, In my investigation about Cassandra cache, there is an implementation off-heap provided to RowCache, but this implementation is based on ByteBuffer mechanish to allocate native memory using JNI. However, In Datastax Cassandra documentation they say that: Installing JNA can improve Cassandra memory usage. When installed and configured, Linux does not swap out the JVM, and thus avoids related performance issues. So my question is if Cassandra cache implementation is based ByteBuffer, there is any real reason to install JNA? Regards, 2013/8/14 Michael Kjellman mkjell...@barracuda.com No- not required, but there is zero reason not to. Keep as much off heap as possible. On Aug 14, 2013, at 12:13 PM, José Elias Queiroga da Costa Araújo je...@cesar.org.br wrote: Hi all, I have a question. In order to activate cassandra row cache is necessary to have JNA installed? Regards, *Elias.* -- Jonathan Ellis Project Chair, Apache Cassandra co-founder, http://www.datastax.com @spyced