Failed to start elastic image search service

I am trying to start the Elastic Search service on a Windows 2008 R2 server, but it does not start. Previously, he worked for several months without any problems.

In services, I get the message:

"Windows could not run Elasticsearch 1.7.2 (ELASTIC_POC) on the local computer. For more information, look at the system event log. If it is a non_Microsoft service, contact your service provider and contact the service with error code 1."

The event log was very useless, showing the following error:

"The Elasticsearch 1.7.2 service (ELASTIC_POC) has entered a stop state.

"Elasticsearch 1.7.2 service (ELASTIC_POC) terminated with a service-specific error. Invalid function .."

However, I get more information in the Elastic Search log files:

[2016-03-30 10:47:22] [info] [ 3988] Running 'ELASTIC_POC' Service... [2016-03-30 10:47:22] [info] [ 3760] Starting service... [2016-03-30 10:47:22] [error] [ 3760] Failed creating java C:\Progra~2\Java\jre1.8.0_60\bin\client\jvm.dll [2016-03-30 10:47:22] [error] [ 3760] The system cannot find the path specified. [2016-03-30 10:47:22] [error] [ 3760] ServiceStart returned 1 [2016-03-30 10:47:22] [error] [ 3760] The system cannot find the path specified. [2016-03-30 10:47:22] [info] [ 3988] Run service finished. [2016-03-30 10:47:22] [info] [ 3988] Commons Daemon procrun finished 

Checking C: \ Program Files (x86) \ Java \ jre1.8.0_60, it contains only a folder named lib (which is empty). There is a folder "jre1.8.0_73" with several files "including \ bin \ client \ jvm.dll"

How can I get Elastic Search to use a later version of Java or return the contents of the jre1.8.0_60 folder? It seems I can not find (safe to download) the installer for this.

Any help is greatly appreciated.

+10
windows-server-2008-r2 elasticsearch
source share
4 answers

There is a very high chance that your Java runtime has been automatically updated.

This will break Elastic Search, because you have the JAVA_HOME environment variable, which is now in the wrong place.

First go to the / java program files and find the new JRE folder. This is probably a later version number. Example: instead of jre1.8.0_73, perhaps jre1.8.090 or some larger number attached to the end.

Update the JAVA_HOME environment variable accordingly.

Then, after making the appropriate backups of your search files, on the command line with administrator support, navigate to the folder with flexible search.

enter the following commands

  service remove service install 

Then you probably want to go to services.msc and switch the service from “manual start” to “automatic” or “automatic delayed”

You might think that reinstalling the service after updating the JAVA_HOME environment variable would be unnecessary, but it was necessary for my installation.

+19
source share

Solved, install the service again ..

Open

{path to elastic search} \ Bin \

on the command line

and run

service installation

This did not allow me to run

delete the service, so now, as shown by the two lists of search services, this is a test server, so great.

+2
source share

For me, this was caused by a problem in my registry after updating Java. It seemed that older versions of the service installer hardcoded the java path in the registry keys, while they should depend on the JAVA_HOME environment variable.

Locate the following key in your registry: HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Apache Software Foundation\Procrun 2.0\elasticsearch-service-x64\Parameters\Java\Jvm . If this looks like a hardcoded path to jvm.dll, change the value to %JAVA_HOME%\bin\server\jvm.dll and try to start the service.

0
source share

Just follow these steps, step by step, and then your flexible search installation will work: advanced system settings >> Environment Variables >> System Variables >> path >> New, and then insert your last java jdk path. like this: C: \ Program Files \ Java \ jdk-11.0.3 \ bin

0
source share

All Articles