diff options
Diffstat (limited to 'content/tech/scaling-elasticsearch.md')
| -rw-r--r-- | content/tech/scaling-elasticsearch.md | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/content/tech/scaling-elasticsearch.md b/content/tech/scaling-elasticsearch.md index 88ab1e6..fc4b9b0 100644 --- a/content/tech/scaling-elasticsearch.md +++ b/content/tech/scaling-elasticsearch.md @@ -1,6 +1,4 @@ --- -categories: -- software date: 2017-08-26 title: Scaling down an Elasticsearch cluster --- @@ -13,8 +11,8 @@ Taking nodes out of the cluster is more challenging. First, make sure that the c ```bash curl -XPUT 'localhost:9200/_cluster/settings' -d '{ - "transient" : { - "cluster.routing.allocation.enable" : "none" + "transient" : { + "cluster.routing.allocation.enable" : "none" } }' ``` @@ -34,7 +32,7 @@ Finally, force the reallocation: ```bash curl -XPOST 'localhost:9200/_cluster/reroute' -d '{ "commands": - [{ "move" : + [{ "move" : { "index" : "yourindex", "shard" : 1, "from_node": "anothernode", "to_node": "laptop" } }] }' @@ -44,8 +42,8 @@ Take the node down as soon as the cluster status is green again and reactivate b ```bash curl -XPUT 'localhost:9200/_cluster/settings' -d '{ - "transient" : { - "cluster.routing.allocation.enable" : "all" + "transient" : { + "cluster.routing.allocation.enable" : "all" } }' ``` |
