Installing elasticsearch 8.6.2 on a windows server with ealsticserach 7.6.1

In our company we have been using Elasticsearch 7.6.1 for two years, right now we need to update it to version 8.6.2, however, we can not move to version 8.6.2 immediately, we need first run Elasticsearch 8.6.2 beside the older version and changing beats and agents configs, move to the newest version, however when I run \elasticserach8.6.2\bin\elastichserach.bat, I faced with the following error:

[ELK] fatal exception while booting Elasticsearch
java.lang.RuntimeException: org.elasticsearch.cli.UserException: will not overwrite keystore at [E:\Config\elasticsearch.keystore], because this incurs changing the file owner
at org.elasticsearch.bootstrap.Elasticsearch.initPhase2( ~[elasticsearch-8.6.2.jar:?]

The mentioned directory is where contains my previous Elasticsearch config files, I don't know how to make Elasticsearch 8.6.2 read configs from its own config files.

in additional I have installed ElasticSerach 7.6.1 with .msi file on windows operating system

It'd help if you could share your elasticsearch.yml from both versions.

Elasticserach 7.6.2
Address: E:\config\elasticsearch.yml

bootstrap.memory_lock: false
cluster.initial_master_nodes:ELK elasticsearch
http.port: 8606 true
node.ingest: true
node.master: true
node.max_local_storage_nodes: 1 ELK E:\Data
path.logs: E:\Logs
transport.tcp.port: 8300
xpack.license.self_generated.type: basic false

For ElasticSerach 8.6.2 I have no configs and all lines are comments, because elasticsearch.bat have not been run yet.

Did you see Install Elasticsearch with .zip on Windows | Elasticsearch Guide [8.7] | Elastic?

I faced the following error when I run elasticsearch-8.7.0\bin>.\elasticsearch.bat

ERROR: will not overwrite keystore at [E:\Config\elasticsearch.keystore], because this incurs changing the file owner

the mentioned address belongs to elasticsearch 7.6.1, should I create a new Java environment manualy for new elasticsearch?

Does anyone know what i should do in order to resolve this error?

Are you trying to run both these on the same windows server? That is probably dangerous and this error is preventing your new system from destroying the old system!

You probably need to use a new path for everything, maybe E:/NewConfig, also E:NewData, E:/NewLogs.

Many configuration options have defaults if not specified in elasticsearch.yml. There used to be an elasticsearch_reference.yml (or simlar) file that listed all options, but it seems to have disappeared in current versions. It may get the location from the startup option location for elasticsearch.yml, yours seems to match.

But, don't trust your production data to net advise!

1 Like

My problem has been solved by following command on cmd prompt

set ES_PATH_CONF=D:\ELK8\elasticsearch-8.7.0\config

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