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

Jdk path points to the wrong location when run latest-nightly #311

Open
mkleen opened this issue Apr 27, 2020 · 3 comments
Open

Jdk path points to the wrong location when run latest-nightly #311

mkleen opened this issue Apr 27, 2020 · 3 comments

Comments

@mkleen
Copy link
Contributor

mkleen commented Apr 27, 2020

The jdk path points to the wrong location when starting up latest-nightly in cr8 0.18.1.dev5+g74d5c9f.d20200427 on mac os x.

> cr8 run-crate latest-nightly
Skipping download, tarball alrady extracted at /Users/mkleen/.cache/cr8/crates/crate-4.2.0-202004270003-1d3ac73
Starting Crate process
CrateDB launching:
    PID: 3913
    Logs: /Users/mkleen/.cache/cr8/crates/crate-4.2.0-202004270003-1d3ac73/logs/cr8-crate-run848645912.log
    Data: /var/folders/49/v601s_vs0rqd3lx1q7s7shsr0000gn/T/tmpnxgx8rt5 (removed on stop)
/Users/mkleen/.cache/cr8/crates/crate-4.2.0-202004270003-1d3ac73/bin/crate: line 129: /Users/mkleen/.cache/cr8/crates/crate-4.2.0-202004270003-1d3ac73/jdk/Contents/Home/bin/java: No such file or directory
/Users/mkleen/.cache/cr8/crates/crate-4.2.0-202004270003-1d3ac73/bin/crate: line 129: exec: /Users/mkleen/.cache/cr8/crates/crate-4.2.0-202004270003-1d3ac73/jdk/Contents/Home/bin/java: cannot execute: No such file or directory
CrateDB didn't start in time or couldn't form a cluster.

The path:
/Users/mkleen/.cache/cr8/crates/crate-4.2.0-202004270003-1d3ac73/jdk/Contents/Home/bin/java
should point to:
/Users/mkleen/.cache/cr8/crates/crate-4.2.0-202004270003-1d3ac73/jdk/bin/java

@mkleen mkleen changed the title The jdk path points to the wrong location when run latest-nightly Jdk path points to the wrong location when run latest-nightly Apr 27, 2020
@mfussenegger
Copy link
Owner

I think part of the reason is that the jdk included in the nightly tarballs is for x64 linux only.

I was thinking of extending the java_magic so replace the bundled jdk with a system java, but I don't have a MacOS to test it.

@jayeff
Copy link

jayeff commented Jul 22, 2020

@mfussenegger If I understand you correctly the idea for the nightly build latest-nightly is to still rely on the system java (over the bundled jdk) at least for macOS? Is Windows affected as well?

@mfussenegger
Copy link
Owner

mfussenegger commented Jul 22, 2020

@mfussenegger If I understand you correctly the idea for the nightly build latest-nightly is to still rely on the system java (over the bundled jdk) at least for macOS? Is Windows affected as well?

Yes. I was thinking of monkey patching the jdk directory that is bundled, replacing it with a symlink to the system JDK.
Both MacOS and Windows are affected because the nightly builds are only available for x64 linux and contain a x64-linux JDK.

The easier solution would be to provide nightly for all 3 platforms.

A workaround is btw. to use cr8 run-crate branch:master, but it's also slower as it will build the distribution locally.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants