EC2 discovery not working with Elasticsearch v6


(Vikas Lalwani) #1

This is my ES config for discovery. Not sure what I am doing wrong here. Tried uncommenting the aws region but that did not work as well. Any help would be appreciated. Thanks

discovery.zen.hosts_provider: ec2
discovery.ec2.host_type: private_ip
discovery.zen.ping_timeout: 5s
#cloud.aws.region: us-west-2
discovery.ec2.tag.Role: prod-es
discovery.zen.minimum_master_nodes: 1


curl -XGET 'http://127.0.0.1:9200/_cluster/health?pretty=true'
{
  "cluster_name" : "prod-es",
  "status" : "yellow",
  "timed_out" : false,
  "number_of_nodes" : 1,
  "number_of_data_nodes" : 1,
  "active_primary_shards" : 45,
  "active_shards" : 45,
  "relocating_shards" : 0,
  "initializing_shards" : 0,
  "unassigned_shards" : 45,
  "delayed_unassigned_shards" : 0,
  "number_of_pending_tasks" : 0,
  "number_of_in_flight_fetch" : 0,
  "task_max_waiting_in_queue_millis" : 0,
  "active_shards_percent_as_number" : 50.0}

(David Pilato) #2

You need to configure the endpoint.

Something probably like:

discovery.ec2.endpoint: ec2.us-west-2.amazonaws.com

(Vikas Lalwani) #3

Thanks @dadoonet We also had to add network.host: 0.0.0.0
It worked


(system) #4

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