Created
April 8, 2015 14:31
-
-
Save sokratisg/646a8da256f64c1e7e21 to your computer and use it in GitHub Desktop.
Shell oneliner to update replicas of all elasticsearch indices
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for i in `curl -XGET http://localhost:9200/_cat/indices | awk '{print $3}'`; do echo "curl -XPUT 'localhost:9200/$i/_settings' -d '{\"index\":{\"number_of_replicas\":1}}'"; done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment