Elaticsearch service doesn't start automatically (Windows)

Trying to install ES to a Windows 2012 R2 server from a zip file following https://www.elastic.co/guide/en/elasticsearch/reference/current/zip-windows.html.

Have set the logs and data folder to a separate location and added an environment variable for SERVICE_LOG_DIR and set ES_START_TYPE to auto (confirmed using .\bin\elasticsearch-service.bat manager).

If I restart the server the service fails to start, BUT I can start it manually, however it immediately stops again.

The Windows event logs show an error on starting but the only information is:

The Elasticsearch 6.1.0 (elasticsearch-service-x64) service terminated with the following service-specific error:

Incorrect function.

I have had a similar error if I install ES using the msi as well. Is there a problem with the Service starting automatically in ES 6.1.0?

Used ${HOSTNAME} as node name...obviously didn't like it

On Windows, use ${COMPUTERNAME} instead of ${HOSTNAME}

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.