0
votes

I change some configuration and need to restart nodemanager. I get the following error message:

Error starting NodeManager
java.lang.UnsatisfiedLinkError: Could not load library. Reasons: [no leveldbjni64-1.8 in java.library.path, no leveldbjni-1.8 in java.library.path, no leveldbjni in java.library.path, /tmp/libleveldbjni-64-1-1006449310407885041.8: /tmp/libleveldbjni-64-1-1006449310407885041.8: failed to map segment from shared object: Operation not permitted]
at org.fusesource.hawtjni.runtime.Library.doLoad(Library.java:182)
at org.fusesource.hawtjni.runtime.Library.load(Library.java:140)
at org.fusesource.leveldbjni.JniDBFactory.<clinit>(JniDBFactory.java:48)
at org.apache.hadoop.yarn.server.nodemanager.recovery.NMLeveldbStateStoreService.initStorage(NMLeveldbStateStoreService.java:864)
at org.apache.hadoop.yarn.server.nodemanager.recovery.NMStateStoreService.serviceInit(NMStateStoreService.java:195)
at org.apache.hadoop.service.AbstractService.init(AbstractService.java:163)
at org.apache.hadoop.yarn.server.nodemanager.NodeManager.initAndStartRecoveryStore(NodeManager.java:155)
at org.apache.hadoop.yarn.server.nodemanager.NodeManager.serviceInit(NodeManager.java:193)
at org.apache.hadoop.service.AbstractService.init(AbstractService.java:163)
at org.apache.hadoop.yarn.server.nodemanager.NodeManager.initAndStartNodeManager(NodeManager.java:462)
at org.apache.hadoop.yarn.server.nodemanager.NodeManager.main(NodeManager.java:509)

It seems like my /tmp folder is mounted as noexec. But for security problem I can't remount it. What should I do to start nodemanager, is there any work around?

Thanks

2

2 Answers

0
votes

maybe, downloading the leveldbjniwin64-1.8 and leveldbjni-1.8 into your java.library.path could work

ps. you can run code System.out.println(System.getProperty("java.library.path")); to get your java.library.path.

0
votes

Yes there is a workaround. You can go in the YARN configuration and change the tmp directory that java uses. In YARN configuration append '-Djava.io.tmpdir=/path/to/other/temp/dir' to the following properties: 1. ApplicationMaster Java Opts Base 2. Java Configuration Options for JobHistory Server 3. Java Configuration Options for NodeManager 4. Java Configuration Options for ResourceManager

For jobs: Cloudera Manager --> YARN --> search for: Gateway Client Environment Advanced Configuration Snippet (Safety Valve) for hadoop-env.sh and add this: HADOOP_CLIENT_OPTS="-Djava.io.tmpdir=/path/to/other/temp/dir"

Now redeploy YARN client configuration.