Fresh install Ubuntu server 18.04 and I am trying to use Elasticserach, Kibana, Logstash. I used command "apt-get install" so the system will detect/install all dependencies for the software. Also installed Java Openjdk 8 (apparently Elasticsearch needs it).
The installation ran smoothly, but Elasticsearch service won't start (error message + log link below).
Q:
1- By installing Elasticsearch, the apps Kibana and Logstash are already included by default or do I need to install each app separately (that's what I did last time)?
2- Any ideas or advice about this error?
[2020-03-05T15:34:12,057][ERROR][o.e.b.Bootstrap ] [server1] Exception
org.elasticsearch.ElasticsearchException: Failure running machine learning native code. This could be due to running on an unsupported OS or distribution, missing OS libraries, or a problem with the temp directory. To bypass this problem by running Elasticsearch without machine learning functionality set [xpack.ml.enabled: false].
It's odd that it'd complain though, what's uname -a return?
Elasticsearch is stand alone, you need to install Kibana and Logstash separately.
Just to be sure that nothing else is interfering with Elasticsearch, I installed a new machine, which only has the OS, updates, Java and Elasticsearch.
The steps were:
Any ideas about what could be causing this issue? Am I missing something like libraries, plugins or setup steps?
Of course, I would prefer to use the last version of Elasticsearch but, should I try a previous version?
I am thinking this may be a Java issue. Per official documentation:
" Elasticsearch is built using Java, and includes a bundled version of OpenJDK from the JDK maintainers (GPLv2+CE) within each distribution. The bundled JVM is the recommended JVM and is located within the jdk directory of the Elasticsearch home directory."
I have been installing "openjdk-8-jdk" or the "default-jdk" previous to install Elasticsearch and that could create some kind of conflict. I will try a fresh installation without installing additional version of Java.
But my questions would be:
1- Does Logstash include a bundled version of [OpenJDK] as well?
2- Would Logstash be able to use the Java included in the Elasticserach installation, if it does not have a bundled version within?
3- Would it be better or recommended to install Oracle/OpenJDK 11 to be used by both Elasticsearch and Logstash instead of the included bundled version of Java?
Another fresh OS install, now without installing the HTTPS transport and also using the bundled OpenJDK. There is nothing else installed but the OS and Elastic search. OS and JDK versions were found in the Support Matrix for Elasticsearch. This should be enough for Elasticsearch to function. Issue persist, but error is different (timeout). If there is anything else I can try to help narrowing the issue, please let me now.
Install OS Ubuntu Server 18.04.4
apt-get update
apt-get upgrade
reboot
(using bundled version of OpenJDK included in the distribution)
Even when only Elasticsearch will be running on this PC, is it mandatory to configure variables "Xms1g" and "Xmx1g" in the jvm.options file, or the app will use all available memory if no limit is established?
Hey, You wanna trying running Elasticsearch with Docker to see if you get it up? There are plentiful of working dockerized Elasticsearch to begin with.
Before going to download Elasticsearch file we need to install java
Because Elasticsearch uses java for internal process.
And also we need to set home path for java as below command. Command :-
Thank you for sharing these steps, which I will be testing shortly and let you know the results.
I already knew that Elasticsearch needs Java to run, but the developers recommends using the bundled Java version included with the Elasticsearch installation. It would be logical to think that this version should already be tested and ensure that it works.
Even so I will try the external installation of Java, as you suggest.
org.elasticsearch.ElasticsearchException: Failure running machine learning native code. This could be due to running on an unsupported OS or distribution, missing OS libraries, or a problem with the temp directory. To bypass this problem by running Elasticsearch without machine learning functionality set [xpack.ml.enabled: false].
at org.elasticsearch.xpack.ml.MachineLearning.createComponents(MachineLearning.java:587) ~[?:?]
at org.elasticsearch.node.Node.lambda$new$9(Node.java:456) ~[elasticsearch-7.6.1.jar:7.6.1]
at java.util.stream.ReferencePipeline$7$1.accept(ReferencePipeline.java:271) ~[?:?]
at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1621) ~[?:?]
at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:484) ~[?:?]
at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474) ~[?:?]
at java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:913) ~[?:?]
at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234) ~[?:?]
at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:578) ~[?:?]
at org.elasticsearch.node.Node.<init>(Node.java:459) ~[elasticsearch-7.6.1.jar:7.6.1]
at org.elasticsearch.node.Node.<init>(Node.java:257) ~[elasticsearch-7.6.1.jar:7.6.1]
at org.elasticsearch.bootstrap.Bootstrap$5.<init>(Bootstrap.java:221) ~[elasticsearch-7.6.1.jar:7.6.1]
at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:221) ~[elasticsearch-7.6.1.jar:7.6.1]
at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:349) [elasticsearch-7.6.1.jar:7.6.1]
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:170) [elasticsearch-7.6.1.jar:7.6.1]
at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:161) [elasticsearch-7.6.1.jar:7.6.1]
at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:86) [elasticsearch-7.6.1.jar:7.6.1]
at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:125) [elasticsearch-cli-7.6.1.jar:7.6.1]
at org.elasticsearch.cli.Command.main(Command.java:90) [elasticsearch-cli-7.6.1.jar:7.6.1]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:126) [elasticsearch-7.6.1.jar:7.6.1]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:92) [elasticsearch-7.6.1.jar:7.6.1]
[2020-03-11T13:58:13,433][ERROR][o.e.b.ElasticsearchUncaughtExceptionHandler] [server1] uncaught exception in thread [main]
org.elasticsearch.bootstrap.StartupException: ElasticsearchException[Failure running machine learning native code. This could be due to running on an unsupported OS or distribution, missing OS libraries, or a problem with the temp directory. To bypass this problem by running Elasticsearch without machine learning functionality set [xpack.ml.enabled: false].]
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:174) ~[elasticsearch-7.6.1.jar:7.6.1]
at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:161) ~[elasticsearch-7.6.1.jar:7.6.1]
at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:86) ~[elasticsearch-7.6.1.jar:7.6.1]
at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:125) ~[elasticsearch-cli-7.6.1.jar:7.6.1]
at org.elasticsearch.cli.Command.main(Command.java:90) ~[elasticsearch-cli-7.6.1.jar:7.6.1]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:126) ~[elasticsearch-7.6.1.jar:7.6.1]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:92) ~[elasticsearch-7.6.1.jar:7.6.1]
Caused by: org.elasticsearch.ElasticsearchException: Failure running machine learning native code. This could be due to running on an unsupported OS or distribution, missing OS libraries, or a problem with the temp directory. To bypass this problem by running Elasticsearch without machine learning functionality set [xpack.ml.enabled: false].
A soon I disabled the machine learning functionality in elasticsearch.yml, the service was able to start. Even without defining anything else like node name, role, IP. Everything has default settings.
So, machine learning is not compatible with Ubuntu Server 18.04.4 LTS? Or is it perhaps the CPU AMD Phenom(tm) II X4 955 at 3.21 GHz?
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.