Setting up replica shards

How can I increase the number of shard replicas? I have five nodes in the cluster, I want each node to have a copy of each shards.

I found this option on the net, is it correct?

curl -X PUT http://localhost:9200/_template/default -H 'Content-Type: application/json' -d '{"index_patterns": ["*"],"order": -1,"settings": {"number_of_shards": "1","number_of_replicas": "5"}}' 

Hello Andrew,

It is nearly correct: As the primary shard is stored on a node too I think you want to have 4 replicas. This only affects newly created indexes.
To change existing indexes have a look here.

Best regards


Thank you very much!

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