AnsweredAssumed Answered

macos: java.lang.UnsatisfiedLinkError: no MapRClient in java.library.path

Question asked by oae on Oct 16, 2011
Latest reply on Oct 18, 2011 by sathya
Hey There,

i've installed map-r client on my mcosx like described here: http://www.mapr.com/doc/display/MapR/Setting+Up+the+Client#SettingUptheClient-macosxclient

Then i'm starting a java program:
<code>
public static void main(String[] args) throws ClassNotFoundException {
    // System.loadLibrary("MapRClient");
    Class.forName(MapRFileSystem.class.getName());
}
</code>
with the VM argument: -Djava.library.path=/opt/mapr/lib

but i still get:
<code>
    Exception in thread "main" java.lang.UnsatisfiedLinkError: no MapRClient in java.library.path
     at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1758)
     at java.lang.Runtime.loadLibrary0(Runtime.java:823)
     at java.lang.System.loadLibrary(System.java:1045)
     at com.mapr.fs.MapRFileSystem.<clinit>(MapRFileSystem.java:959)
     at java.lang.Class.forName0(Native Method)
     at java.lang.Class.forName(Class.java:169)
     at somepackage.ClassUtil.main(ClassUtil.java:234)
</code>

on the classpath i have
 - maprfs-0.1.jar
on i second try i added
 - maprcli-0.1.jar

(tried with 1.1.1 and 1.1.3)

the contents of /opt/mapr/lib look like:
<code>
    -rwxr-xr-x@  1 root  admin   7.2M Aug 19 23:31 libMapRClient.dylib.1*
    -rw-r--r--@  1 root  admin   1.2K Aug 19 23:31 maprbuildversion.jar
</code>

Any ideas ?
Johannes

Outcomes