Not find java in JAVA_HOME or bundled for elasticsearch

"could not find java in JAVA_HOME or bundled at D:\ESQELK\elasticsearch-7.2.0-windows-x86_64\elasticsearch-7.2.0\jdk"

and JAVA_HOME is set to C:\Users\mehak\Documents\

What is the issue. please help!

Does this directory contain a bin directory in which java.exe can be found? I think that's what the process ultimately looks for

Yes, java.exe can be found in C:\Users\mehak\Documents\\java-1.8.0-openjdk-\bin

I think it is definitely a java issue because of which elasticsearch isnt running. What should be my next approach?

This has an extra directory, java-1.8.0-openjdk-, in which the bin directory is found. In light of this, I think JAVA_HOME should be set to


For example, with PowerShell

[Environment]::SetEnvironmentVariable("JAVA_HOME", "C:\Users\mehak\Documents\java-1.8.0-openjdk-1.8\java-1.8.0-openjdk-", "Machine")

Then open a new session, and start Elasticsearch.

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