Hi,
I have an yellow health cluster. We have gone through several phases to go green but none have worked so far.
get _cluster/health?pretty=true
{
"cluster_name": "ElasticSearch",
"status": "yellow",
"timed_out": false,
"number_of_nodes": 7,
"number_of_data_nodes": 3,
"active_primary_shards": 1481,
"active_shards": 2924,
"relocating_shards": 0,
"initializing_shards": 0,
"unassigned_shards": 38,
"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": 98.71708305199189
}
First I added a 3rd data node so replica data could be on a different node.
Second I tried moving the replicas
PUT /_settings
{
"index" : {
"number_of_replicas" : 0
}
}
This turned the cluster Green! but i had no data replication. and for some reason all the shards were on the same nodes (very few spread out to other nodes).
I then added the replicas back
PUT /_settings
{
"index" : {
"number_of_replicas" : 1
}
}
And went from 300-400 unassigned shards to my new 38...
My Questions are:
Should a 5 shard index put all data into 1 node (I thought it would spread them out)?
Can replicas be on the same node as the shard data (I believe no just want a confirm)?
What is an unassigned shard?
How do you fix an unassigned shard?
Cheers