Opensearch JNAnatives library issue

Versions (relevant - OpenSearch/Dashboard/Server OS/Browser):
2.13.0

Describe the issue:

Hello Team,

We are continuously facing JNA library issue even we change the settings as per documentation.

Configuration:

If JNA library issue , then perform this step.

Edit the jvm.options with below settings,
-Djava.io.tmpdir=${OPENSEARCH_TMPDIR}
-Djna.tmpdir=/usr/share/opensearch/tmp

Edit the /etc/sysconfig/opensearch
OPENSEARCH_TMPDIR=/usr/share/opensearch/tmp

Relevant Logs or Screenshots:
Error snippet:

[2024-07-18T08:20:10,451][ERROR][o.o.b.OpenSearchUncaughtExceptionHandler] [HOSTNAME] fatal error in thread [main], exiting
java.lang.ExceptionInInitializerError: null
at org.opensearch.bootstrap.JNANatives.definitelyRunningAsRoot(JNANatives.java:192) ~[opensearch-2.13.0.jar:2.13.0]
at org.opensearch.bootstrap.Natives.definitelyRunningAsRoot(Natives.java:83) ~[opensearch-2.13.0.jar:2.13.0]
at org.opensearch.bootstrap.Bootstrap.initializeNatives(Bootstrap.java:123) ~[opensearch-2.13.0.jar:2.13.0]
at org.opensearch.bootstrap.Bootstrap.setup(Bootstrap.java:191) ~[opensearch-2.13.0.jar:2.13.0]
at org.opensearch.bootstrap.Bootstrap.init(Bootstrap.java:404) ~[opensearch-2.13.0.jar:2.13.0]
at org.opensearch.bootstrap.OpenSearch.init(OpenSearch.java:181) ~[opensearch-2.13.0.jar:2.13.0]
at org.opensearch.bootstrap.OpenSearch.execute(OpenSearch.java:172) ~[opensearch-2.13.0.jar:2.13.0]
at org.opensearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:104) ~[opensearch-2.13.0.jar:2.13.0]
at org.opensearch.cli.Command.mainWithoutErrorHandling(Command.java:138) ~[opensearch-cli-2.13.0.jar:2.13.0]
at org.opensearch.cli.Command.main(Command.java:101) ~[opensearch-cli-2.13.0.jar:2.13.0]
at org.opensearch.bootstrap.OpenSearch.main(OpenSearch.java:138) ~[opensearch-2.13.0.jar:2.13.0]
at org.opensearch.bootstrap.OpenSearch.main(OpenSearch.java:104) ~[opensearch-2.13.0.jar:2.13.0]
Caused by: java.lang.UnsupportedOperationException: Failed to allocate closure
at com.sun.jna.Native.registerMethod(Native Method) ~[jna-5.13.0.jar:5.13.0 (b0)]
at com.sun.jna.Native.register(Native.java:1906) ~[jna-5.13.0.jar:5.13.0 (b0)]
at com.sun.jna.Native.register(Native.java:1775) ~[jna-5.13.0.jar:5.13.0 (b0)]
at com.sun.jna.Native.register(Native.java:1493) ~[jna-5.13.0.jar:5.13.0 (b0)]
at org.opensearch.bootstrap.JNACLibrary.(JNACLibrary.java:64) ~[opensearch-2.13.0.jar:2.13.0]
… 12 more

Can you please help us to resolve this permanently.

Thank you!
Mangesh Mathe

Posting for visibility, might be related to https://github.com/opensearch-project/OpenSearch/issues/14778