Giter VIP home page Giter VIP logo

Comments (17)

karmi avatar karmi commented on May 31, 2024

It depends on how you've built it and how are you starting elasticsearch. The ES_CLASSPATH environment variable is set in https://github.com/karmi/cookbook-elasticsearch/blob/master/templates/default/elasticsearch-env.sh.erb.

from elasticsearch.

johnbeynon avatar johnbeynon commented on May 31, 2024

I've just added the elasticsearch recipe to my run_list - sudo elasticsearch start results in the error. I can see it's put a file in the /etc/rc5.d folder. Any help would be much appreciated.

from elasticsearch.

karmi avatar karmi commented on May 31, 2024

You can do several things.

First, check the /usr/local/etc/elasticsearch/elasticsearch-env.sh file, if it contains proper locations. Then, check the service init file, if it contains correct ES_INCLUDE. If you made some customized configs (different paths etc.), check for them.

If the problem still persists, please store the content of the elasticsearch-env.sh and the init file in a gist/pastie/hastebin/etc and post here... Or try the #elasticsearch IRC channel, I'm there most of the time.

from elasticsearch.

johnbeynon avatar johnbeynon commented on May 31, 2024

that's the thing - I haven't changed any paths, custom configs or anything...I'll dig some more and come back.

from elasticsearch.

karmi avatar karmi commented on May 31, 2024

@johnbeynon Any news, or closing?

from elasticsearch.

johnbeynon avatar johnbeynon commented on May 31, 2024

closing - no news, no further on - ended up hacking it together.

from elasticsearch.

vjpr avatar vjpr commented on May 31, 2024

I'm having same problem.

Running sudo elasticsearch shows that message.

Running /etc/init.d/elasticsearch start shows this message:

{0.19.8}: Initialization Failed ...
- NoClassSettingsException[Failed to load class setting [discovery.type] with value [ec2]]
    ClassNotFoundException[ec2]

from elasticsearch.

karmi avatar karmi commented on May 31, 2024

@vjpr I need more info then. First thing, try to build a test machine with Vagrant (see https://github.com/karmi/cookbook-elasticsearch#testing-with-vagrant). Then, pastie/gist/hastebin/etc your Chef config (run_list, node config, etc)

from elasticsearch.

vjpr avatar vjpr commented on May 31, 2024

The issue seems to be that running 'elasticsearch' instead of
'/etc/init.d/elasticsearch start' after cookbook doesn't correctly set the
env vars. I don't think this is an issue.

I think my second error came from the 'elasticsearch::default' recipe
trying to install cloud aws plugin. I'll investigate further, I could have
messed it up with some manual commands.

On 21/08/2012, at 3:00 AM, Karel Minarik [email protected] wrote:

@vjpr https://github.com/vjpr I need more info then. First thing, try to
build a test machine with Vagrant (see
https://github.com/karmi/cookbook-elasticsearch#testing-with-vagrant).
Then, pastie/gist/hastebin/etc your Chef config (run_list, node config, etc)


Reply to this email directly or view it on
GitHubhttps://github.com/karmi/cookbook-elasticsearch/issues/20#issuecomment-7875881.

from elasticsearch.

karmi avatar karmi commented on May 31, 2024

The issue seems to be that running 'elasticsearch' instead of
'/etc/init.d/elasticsearch start' after cookbook doesn't correctly set the
env vars.

Absolutely -- the elasticsearch script won't set any ENV variables. You have to use the service or the init script.

I think my second error came from the 'elasticsearch::default' recipe
trying to install cloud aws plugin. I'll investigate further, I could have
messed it up with some manual commands.

That would be very surprising. Report it please if that would be the case.

from elasticsearch.

maanas avatar maanas commented on May 31, 2024

Even with service wrapper i m getting this error.
Starting ElasticSearch...
Waiting for ElasticSearch...............................
WARNING: ElasticSearch may have failed to start.
service elasticsearch status
ElasticSearch is not running.
Please help.
On Command line i get this
bin/elasticsearch -f
bin/elasticsearch.in.sh: line 3: $ES_CLASSPATH:$ES_HOME/lib/${project.build.finalName}.jar:$ES_HOME/lib/:$ES_HOME/lib/sigar/: bad substitution
You must set the ES_CLASSPATH var

from elasticsearch.

rjurney avatar rjurney commented on May 31, 2024

I have this problem too. bin/elasticsearch -f should 'just work.' That it stopped working since 0.18.6 is a bug.

Can you please fix this bug? This makes elasticsearch much harder to use, especially for new users.

from elasticsearch.

karmi avatar karmi commented on May 31, 2024

@rjurney I'm afraid I don't know what specific problem you have. Could you describe it in more detail so I can understand and reproduce it?

from elasticsearch.

Juul avatar Juul commented on May 31, 2024

This "bug" appears if you download the source release via e.g. http://www.elasticsearch.org/download/master/ instead of the release from http://www.elasticsearch.org/download/ and try to run elasticsearch without compiling.

Maybe adding some kind of notice on the http://www.elasticsearch.org/download/master/ page will avoid this being reported as an issue in the future.

from elasticsearch.

karmi avatar karmi commented on May 31, 2024

@Juul Good point, but I can't figure out how it's related to the Chef cookbook? People change the download URL to master?

from elasticsearch.

rjurney avatar rjurney commented on May 31, 2024

My bad, it's not a cookbook issue. This is the only place I've seen it discussed, though.

from elasticsearch.

 avatar commented on May 31, 2024

To any one who arrives here on the boat that I did ( compile ocd),
Ubuntu 12.04.2 LTS
Java version "1.6.0_26" ( installed via the file jre-6u34-linux-i586.bin)

Pull from git
Check what the official elasticsearch website says is release version ( or not )
check it out ( at least a stable one )
build using the command mvn clean package -DskipTests

When you run it you will run into some problems that I worked through by ( admittedly I don`t know what things fixed what problems )

Changing /bin/sh to /bin/bash in the files bin/elasticsearch bin/elasticsearch.in.sh
Checking that you are happy with line 50 of file /elasticsearch ( you may may not be )

Noticing that the file bin/elasticsearch.in.sh is a config file for the java machine and adding the line ES_CLASSPATH="target/classes:target/lib/*" BEFORE ES_CLASSPATH=$ES_CLASSPATH:$ES_HOME/lib/*:$ES_HOME/lib/sigar/*

now you should be able to bring it up.


P.s
Elastic search is one of my favorite projects ever. TY for having have worked on it there is not a lot of source code you can read through thats is as exactly what it should be

Thank you

  • James

from elasticsearch.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.