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

java driver fails to run jar when chroot #331

Closed
roivanov opened this issue Oct 24, 2015 · 2 comments
Closed

java driver fails to run jar when chroot #331

roivanov opened this issue Oct 24, 2015 · 2 comments

Comments

@roivanov
Copy link

java driver fails to run jar when chroot

Running nomad on Amazon Linux
AMI ami-52978200 (Amazon Linux AMI 2015.09.0 x86_64 HVM GP2)

removed java-1.7.0 and installed java-1.8.0

# yum remove java-1.7.0
# yum install java-1.8.0

Got the following error when running java job

[ERR] client: failed to complete task 'stats' for alloc '60c23451-078e-92bf-baee-e44b8543523a': 1 error(s) occurred:
* Wait failed on pid 6905: exit status 1
# cat stats.stderr
Error: dl failure on line 893
Error: failed /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.51-1.b16.6.amzn1.x86_64/jre/lib/amd64/server/libjvm.so, because libstdc++.so.6: cannot open shared object file: No such file or directory

Java location is

[ec2-user@ip ~]$ ls -l /usr/bin/java
lrwxrwxrwx 1 root root 22 окт 22 06:30 /usr/bin/java -> /etc/alternatives/java
[ec2-user@ip ~]$ ls -l /etc/alternatives/java
lrwxrwxrwx 1 root root 46 окт 22 06:30 /etc/alternatives/java -> /usr/lib/jvm/jre-1.8.0-openjdk.x86_64/bin/java

When Oracle jdk is installed

[ERR] client: failed to start task 'stats' for alloc '348bc36a-29ab-7c2c-0005-350d8b1be0a9': failed to start source: Failed to execute user command: Error starting user command: fork/exec /usr/bin/java: no such file or directory

Java location is

[ec2-user@ip ~]$ ls -l /usr/bin/java
lrwxrwxrwx 1 root root 22 окт 21 14:08 /usr/bin/java -> /etc/alternatives/java
[ec2-user@ip ~]$ ls -l /etc/alternatives/java
lrwxrwxrwx 1 root root 34 окт 21 14:08 /etc/alternatives/java -> /usr/java/jdk1.8.0_45/jre/bin/java
[ec2-user@ip ~]$ ls -l /usr/java/jdk1.8.0_45/jre/bin/java
-rwxr-xr-x 1 root root 7734 апр 10  2015 /usr/java/jdk1.8.0_45/jre/bin/java
@dadgar
Copy link
Contributor

dadgar commented Mar 30, 2016

Just tested and is currently working. Also PR #1009 will fix the Oracle JDK problem

@dadgar dadgar closed this as completed Mar 30, 2016
benbuzbee pushed a commit to benbuzbee/nomad that referenced this issue Jul 21, 2022
Merging PR for docstring change.
@github-actions
Copy link

I'm going to lock this issue because it has been closed for 120 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 24, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants