JNA link issue while starting cassandra RHEL 6.5
I went through the code in CLibrary.java and found following code where the exception is caught -
catch (UnsatisfiedLinkError e)
{
logger.warn("JNA link failure, one or more native method will be unavailable.");
logger.trace("JNA link failure details: {}", e.getMessage());
}
I restarted cassandra by changing the log-level in conf/logback.xml to TRACE, to print that extra detail -
<logger name="org.apache.cassandra" level="TRACE"/>
I could now see the real issue -
/tmp/jna-3506402/jna6068045839690239595.tmp: failed to map segment from shared object: Operation not permitted
This issue is caused due to noexec flag on the /tmp folder.
I then decided to change the tmp folder by changing tmpdir using option:
-Djava.io.tmpdir=/home/cassandra/tmp
That fixed the issue.
I added the options in cassandra-env.sh file. Added following statement -
JVM_OPTS="$JVM_OPTS -Djava.io.tmpdir=/home/cassandra/tmp"
Jna Linkage Error : How to solve this error while starting cassandra
As per JIRA, current latest cassandra 3.11 is still not fully supported for java 1.9. Hence, I would recommend you to try again with java 1.8.
JNA link failure Error on Cassandra Startup on OS X
JNA is used for optimizations such as disabling swapping and creating hardlinks during snapshots. It is recommended for production systems. Dev systems should also be fine without JNA support, so you can just ignore the warning.
Cassandra not using native methods
It seems that zypper only has version 3.1 of jna, while Cassandra wants 3.2.7.
I grabbed a copy here, and now it works like a charm.
When I start Cassandra server, two processes start running. Is this normal?
Yes, this is normal. We use jsvc to daemonize cleanly.
Cassandra Startup failure on ARM64 machine (java.lang.NoClassDefFoundError: Could not initialize class com.sun.jna.Native)
Seems you have hit similar issue as JNA link issue while starting cassandra RHEL 6.5
You can try:
This issue is caused due to noexec flag on the /tmp folder.
I then decided to change the tmp folder by changing tmpdir using option:
-Djava.io.tmpdir=/home/cassandra/tmp That fixed the issue.
I added the options in cassandra-env.sh file. Added following statement -
JVM_OPTS="$JVM_OPTS -Djava.io.tmpdir=/home/cassandra/tmp"
Related Topics
Read File Without Disk Caching in Linux
Sudoers Nopasswd: Sudo: No Tty Present and No Askpass Program Specified
How to Pass Command Line Parameters with Quotes Stored in Single Variable
Linux: Handling a Segmentation Fault and Getting a Core Dump
Setting Up Jenkins Slave on MAC Os
How to Set Dt_Rpath or Dt_Runpath
Does Not Work to Execute Command in Double Brackets in Bash
How to Catch Stdout Stream in Ffmpeg Then Pipe It to V4L2Loopback
Redirect Two or More Stdout to a Single Stdin
Jna Link Issue While Starting Cassandra Rhel 6.5
How Does One Determine the Page Frame Number for Device Memory
Scp: How to Find Out That Copying Was Finished
How to Fetch the Tags for Ec2-Describe-Instances in a Shell Script
<Command Line>:1:1: Error: MACro Names Must Be Identifiers
Compile Linux Kernel (2.6) Module Including Non Kernel Headers