incubator-cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Viktor Jevdokimov <>
Subject RE: How to enable JNA for Cassandra on Windows?
Date Fri, 23 Sep 2011 09:07:17 GMT
I found that there's no C library under Windows, and msvcrt does not provide mlockall function,
so currently there's no way to use JNA under Windows. That way mmap is not a good idea?

Best regards/ Pagarbiai

Viktor Jevdokimov

Senior Developer


Phone: +370 5 212 3063. Fax: +370 5 261 0453

J. Jasinskio 16C, LT-01112 Vilnius, Lithuania





Visit our blog<>

Disclaimer: The information contained in this message and attachments is intended solely for
the attention and use of the named addressee and may be confidential. If you are not the intended
recipient, you are reminded that the information remains the property of the sender. You must
not use, disclose, distribute, copy, print or rely on this e-mail. If you have received this
message in error, please contact the sender immediately and irrevocably delete this message
and any copies.

From: Viktor Jevdokimov []
Sent: Thursday, September 22, 2011 15:01
Subject: How to enable JNA for Cassandra on Windows?


I'm trying without success to enable JNA for Cassandra on Windows.

Tried to place JNA 3.3.0 libs jna.jar and platform.jar into Cassandra 0.8.6 lib dir, but getting
in log:
Unable to link C library. Native methods will be disabled.

What is missed or what is wrong?

One thing I've found on inet about JNA and Windows is this sample:

// Library is c for unix and msvcrt for windows
String libName = "c";
if (System.getProperty("<>").contains("Windows"))
  libName = "msvcrt";


// Loading dynamically the library
CInterface demo = (CInterface) Native.loadLibrary(libName, CInterface.class);


while in Cassandra:





    catch (NoClassDefFoundError e)

    {<>("JNA not found. Native methods will be disabled.");


    catch (UnsatisfiedLinkError e)

    {<>("Unable to link C library. Native methods will
be disabled.");


    catch (NoSuchMethodError e)


        logger.warn("Obsolete version of JNA present; unable to register C library. Upgrade
to JNA 3.2.7 or later");


Is it true that for Windows Cassandra should do something like:

if (System.getProperty("<>").contains("Windows"))





View raw message