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

elasticsearch default /usr/local/elasticsearch is no good for elasticsearch-env.sh #157

Closed
mythicalprogrammer opened this issue Nov 4, 2013 · 1 comment

Comments

@mythicalprogrammer
Copy link

There a few people having problem with the default and getting this error:

You must set the ES_CLASSPATH var

The problem is the default is installation path is /usr/local/elasticsearch

Why is this a problem?

Well looking in vim /usr/local/bin/elasticsearch

71 # If an include wasn't specified in the environment, then search for one...
72 if [ "x$ES_INCLUDE" = "x" ]; then
73 # Locations (in order) to use when searching for an include file.
74 for include in /usr/share/elasticsearch/elasticsearch.in.sh
75 /usr/local/share/elasticsearch/elasticsearch.in.sh
76 /opt/elasticsearch/elasticsearch.in.sh
77 ~/.elasticsearch.in.sh \

74 to 77 are the default locations where it expect elasticsearch-env.sh is at.

It doesn't expect it to be in /usr/local/bin/elasticsearch

I believe the solution is check if it's a deb flavor linux and change the default to /usr/share/elasticsearch which what their .deb does anyway. I'm not entirely sure if this affect any other flavor linux such as rpm.

@karmi
Copy link
Contributor

karmi commented Nov 4, 2013

You can install ES in whatever location is appropriate -- just set the relevant paths in node attributes.

The "include" file is renamed in the cookbook anyway.

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