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

RPM package does not list "java" as a dependency #36568

Closed
chmarr opened this issue Dec 12, 2018 · 1 comment
Closed

RPM package does not list "java" as a dependency #36568

chmarr opened this issue Dec 12, 2018 · 1 comment

Comments

@chmarr
Copy link

chmarr commented Dec 12, 2018

Elasticsearch version (bin/elasticsearch --version):

Version: 6.4.3, Build: default/rpm/fe40335/2018-10-30T23:17:19.084789Z, JVM: 1.8.0_192
Version: 6.5.3, Build: default/rpm/159a78a/2018-12-06T20:11:28.826501Z, JVM: 1.8.0_192

Plugins installed: Not relevant

JVM version: Not relevant

OS version: Not relevant

Description of the problem including expected versus actual behavior:

The elasticsearch RPM package does not have a "Requires" dependency on java. If java is not installed, but being installed in a single transaction, rpm does not know how to order those two and thus may attempt to install elasticsearch before java is installed and ready.

This results in a failure in the PREINST scripts which check for the presence of the java binary. Simply attempting a re-install after java was installed clears the issue, but does complicate automated installations.

Steps to reproduce:

Don't have java installed. Attempt to install the elasticsearch RPM using rpm or yum along with the java package in one command. This may trigger the issue, but might not, as it's dependent on the way rpm decides to order those. Installing those two along with a heap of other packages may help trigger it.

Suggested fix

Add "java", or "jre" to the Requires list in the RPM spec file. If it must be "Java 8", then use "java-1.8.0" or "jre-1.8.0". Those capabilities are given in the "Provides" section of both Oracle java RPMs and OpenJDK RPMs.

Provide logs (if relevant): Not relevant

@jasontedor
Copy link
Member

Thanks for your interest, and sorry for the trouble. We do recognize this is a problem and are still exploring how we are going to solve this. It turns out that this issue is already being considered under #31845. Would it be that you could join us there?

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

No branches or pull requests

2 participants