Elasticsearch 7.3.0 Enable Security - Windows System

Hi Team,

I have installed Elasticsearch 7.3.0 on windows machine. And I am able to use elastic url using IP. Below are configuration which I have used -

cluster.name: "my-app"
node.name: "master_node"
network.host: 192.168.2.106
http.port: 9202
node.master: true
node.data: true
node.ingest: false
cluster.initial_master_nodes: ["master_node"]
discovery.zen.ping.unicast.hosts: ["192.168.2.106", "127.0.0.1"]
reindex.remote.whitelist: "localhost:,192.168.2.106:"

Now I want to enable basic username/password authentication. For that I have added below lines in yml file -

xpack.security.enabled: true
xpack.security.transport.ssl.enabled: true

But now when I am trying to hit elastic, then it is asking me for entering username and password. I tried default username as per the document available on elastic site -

_es_anonymous_user

but not able to either login and/or create user.

I also tried to set passwords using below command -

bin> elasticsearch-setup-passwords interactive

But this also fails with below error -

Enter password for [elastic]:
Reenter password for [elastic]:
Enter password for [apm_system]:
Reenter password for [apm_system]:
Enter password for [kibana]:
Reenter password for [kibana]:
Enter password for [logstash_system]:
Reenter password for [logstash_system]:
Enter password for [beats_system]:
Reenter password for [beats_system]:
Enter password for [remote_monitoring_user]:
Reenter password for [remote_monitoring_user]:
Passwords do not match.
Try again.
Enter password for [remote_monitoring_user]:
Reenter password for [remote_monitoring_user]:

Connection failure to: http://192.168.2.106:9202/_security/user/apm_system/_password?pretty failed: Read timed out

ERROR: Failed to set password for user [apm_system].

Can anyone please help me to figure it out what step i need to follow to enable security in elasticsearch?

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