Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RHEL: Failed to load native library jlinenative #7112

Open
hink084 opened this issue Dec 5, 2024 · 2 comments
Open

RHEL: Failed to load native library jlinenative #7112

hink084 opened this issue Dec 5, 2024 · 2 comments
Assignees
Labels
Status: Open Issue has been triaged by the front-line engineers and is being worked on verification Type: Bug Label issue as a bug defect

Comments

@hink084
Copy link

hink084 commented Dec 5, 2024

Brief Summary

On RHEL 9.4 with JDK v21.0.5+11, when upgrading from Payara v6.2024.7 to v6.2024.8, I started receiving the following error when attempting to execute the asadmin command: Failed to load native library: jlinenative ... java.langUnsatisfiedLinkError ... failed to map segment from shared object ...

...for the full error, see the Current Outcome section.

This issue originated when JLine was upgraded from v3.21.0 to v3.26.3 in Payara v6.2024.8 via Pull Request #6827
This issue still exists in Payara v6.2024.11 with JLine v3.27.0

Expected Outcome

I would expect the asadmin command to prompt as normal:
expected

Current Outcome

Error: v6.2024.8
6 2024 8

Error: v6.2024.11
6 2024 11

Reproducer

I think this issue is ultimately a JLine issue but exists when attempting to start Payara. The issue is present because the /tmp directory is mounted with the "noexec" option as is advised for security purposes. The workaround is to inadvisably remount the /tmp directory without the "noexec" option or more advisable, start Payara with a custom temp directory. You can start Payara with a custom temp directory by modifying the asadmin file to utilize the -Djava.io.tmpdir= JVM option.

tmpdir

Disabling JLine as described in the Payara Community Documentation has no effect.
https://docs.payara.fish/community/docs/5.2020.3/documentation/payara-server/asadmin-commands/disabling-jline.html

Operating System

RHEL 9.4

JDK Version

OpenJDK 21.0.5+11

Payara Distribution

Payara Server Full Profile

@hink084 hink084 added Status: Open Issue has been triaged by the front-line engineers and is being worked on verification Type: Bug Label issue as a bug defect labels Dec 5, 2024
@felixif
Copy link

felixif commented Dec 11, 2024

Hello @hink084,

I tried reproducing it under Windows 11 and Ubuntu under WSL using JDK 21, I found no issues so far. I will set up a VM using RHEL 9.4 and return with an update regarding this report.

Kind regards,
Felix Ifrim

@hink084
Copy link
Author

hink084 commented Dec 11, 2024

@felixif if you get a RHEL 9 VM running, check to see if the /tmp directory is mounted with the noexec option. I believe the noexec option is causing the issues for JLine. You can check with the findmnt command.

noexec

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Open Issue has been triaged by the front-line engineers and is being worked on verification Type: Bug Label issue as a bug defect
Projects
None yet
Development

No branches or pull requests

2 participants