[DOCS] Tidied up cluster settings docs

This commit is contained in:
Clinton Gormley 2014-01-15 14:51:18 +01:00
parent f8a427e266
commit a0b993e2dc
1 changed files with 26 additions and 39 deletions

View File

@ -12,70 +12,57 @@ handling nodes being added or removed.
The following settings may be used: The following settings may be used:
`cluster.routing.allocation.allow_rebalance`:: `cluster.routing.allocation.allow_rebalance`::
Allow to control when rebalancing will happen based on the total Allow to control when rebalancing will happen based on the total
state of all the indices shards in the cluster. `always`, state of all the indices shards in the cluster. `always`,
`indices_primaries_active`, and `indices_all_active` are allowed, `indices_primaries_active`, and `indices_all_active` are allowed,
defaulting to `indices_all_active` to reduce chatter during defaulting to `indices_all_active` to reduce chatter during
initial recovery. initial recovery.
`cluster.routing.allocation.cluster_concurrent_rebalance`:: `cluster.routing.allocation.cluster_concurrent_rebalance`::
Allow to control how many concurrent rebalancing of shards are Allow to control how many concurrent rebalancing of shards are
allowed cluster wide, and default it to `2`. allowed cluster wide, and default it to `2`.
`cluster.routing.allocation.node_initial_primaries_recoveries`:: `cluster.routing.allocation.node_initial_primaries_recoveries`::
Allow to control specifically the number of initial recoveries Allow to control specifically the number of initial recoveries
of primaries that are allowed per node. Since most times local of primaries that are allowed per node. Since most times local
gateway is used, those should be fast and we can handle more of gateway is used, those should be fast and we can handle more of
those per node without creating load. those per node without creating load.
`cluster.routing.allocation.node_concurrent_recoveries`:: `cluster.routing.allocation.node_concurrent_recoveries`::
How many concurrent recoveries are allowed to happen on a node. How many concurrent recoveries are allowed to happen on a node.
Defaults to `2`. Defaults to `2`.
added[1.0.0.RC1]
`cluster.routing.allocation.enable`:: `cluster.routing.allocation.enable`::
Controls shard allocation for all indices, by allowing specific Controls shard allocation for all indices, by allowing specific
kinds of shard to be allocated. Can be set to: kinds of shard to be allocated.
added[1.0.0.RC1,Replaces `cluster.routing.allocation.disable*`]
Can be set to:
* `all` (default) - Allows shard allocation for all kinds of shards. * `all` (default) - Allows shard allocation for all kinds of shards.
* `primaries` - Allows shard allocation only for primary shards. * `primaries` - Allows shard allocation only for primary shards.
* `new_primaries` - Allows shard allocation only for primary shards for new indices. * `new_primaries` - Allows shard allocation only for primary shards for new indices.
* `none` - No shard allocations of any kind are allowed for all indices. * `none` - No shard allocations of any kind are allowed for all indices.
`cluster.routing.allocation.disable_new_allocation`:: `cluster.routing.allocation.disable_new_allocation`::
Allows to disable new primary allocations. Note, this will prevent deprecated[1.0.0.RC1,Replaced by `cluster.routing.allocation.enable`]
allocations for newly created indices. This setting really make
sense when dynamically updating it using the cluster update
settings API. This setting has been deprecated in favour
for `cluster.routing.allocation.enable`.
`cluster.routing.allocation.disable_allocation`:: `cluster.routing.allocation.disable_allocation`::
Allows to disable either primary or replica allocation (does not deprecated[1.0.0.RC1,Replaced by `cluster.routing.allocation.enable`]
apply to newly created primaries, see `disable_new_allocation`
above). Note, a replica will still be promoted to primary if
one does not exist. This setting really make sense when
dynamically updating it using the cluster update settings API.
This setting has been deprecated in favour for `cluster.routing.allocation.enable`.
`cluster.routing.allocation.disable_replica_allocation`:: `cluster.routing.allocation.disable_replica_allocation`::
Allows to disable only replica allocation. Similar to the previous deprecated[1.0.0.RC1,Replaced by `cluster.routing.allocation.enable`]
setting, mainly make sense when using it dynamically using the
cluster update settings API. This setting has been deprecated in
favour for `cluster.routing.allocation.enable`.
`cluster.routing.allocation.same_shard.host`:: `cluster.routing.allocation.same_shard.host`::
Prevents that multiple instances of the same shard are allocated Prevents that multiple instances of the same shard are allocated
on a single host. Defaults to `false`. This setting only applies on a single host. Defaults to `false`. This setting only applies
if multiple nodes are started on the same machine. if multiple nodes are started on the same machine.
`indices.recovery.concurrent_streams`:: `indices.recovery.concurrent_streams`::
The number of streams to open (on a *node* level) to recover a The number of streams to open (on a *node* level) to recover a
shard from a peer shard. Defaults to `3`. shard from a peer shard. Defaults to `3`.
[float] [float]
[[allocation-awareness]] [[allocation-awareness]]
@ -182,8 +169,8 @@ set to `value1` and `value2` by setting
[source,js] [source,js]
-------------------------------------------------- --------------------------------------------------
curl -XPUT localhost:9200/test/_settings -d '{ curl -XPUT localhost:9200/test/_settings -d '{
"index.routing.allocation.include.tag" : "value1,value2" "index.routing.allocation.include.tag" : "value1,value2"
}' }'
-------------------------------------------------- --------------------------------------------------
On the other hand, we can create an index that will be deployed on all On the other hand, we can create an index that will be deployed on all
@ -193,11 +180,11 @@ nodes except for nodes with a `tag` of value `value3` by setting
[source,js] [source,js]
-------------------------------------------------- --------------------------------------------------
curl -XPUT localhost:9200/test/_settings -d '{ curl -XPUT localhost:9200/test/_settings -d '{
"index.routing.allocation.exclude.tag" : "value3" "index.routing.allocation.exclude.tag" : "value3"
}' }'
-------------------------------------------------- --------------------------------------------------
`index.routing.allocation.require.*` can be used to `index.routing.allocation.require.*` can be used to
specify a number of rules, all of which MUST match in order for a shard specify a number of rules, all of which MUST match in order for a shard
to be allocated to a node. This is in contrast to `include` which will to be allocated to a node. This is in contrast to `include` which will
include a node if ANY rule matches. include a node if ANY rule matches.
@ -229,7 +216,7 @@ curl -XPUT localhost:9200/test/_settings -d '{
"index.routing.allocation.include.group2" : "yyy", "index.routing.allocation.include.group2" : "yyy",
"index.routing.allocation.exclude.group3" : "zzz", "index.routing.allocation.exclude.group3" : "zzz",
"index.routing.allocation.require.group4" : "aaa" "index.routing.allocation.require.group4" : "aaa"
}' }'
-------------------------------------------------- --------------------------------------------------
The provided settings can also be updated in real time using the update The provided settings can also be updated in real time using the update
@ -246,6 +233,6 @@ address:
curl -XPUT localhost:9200/_cluster/settings -d '{ curl -XPUT localhost:9200/_cluster/settings -d '{
"transient" : { "transient" : {
"cluster.routing.allocation.exclude._ip" : "10.0.0.1" "cluster.routing.allocation.exclude._ip" : "10.0.0.1"
} }
}' }'
-------------------------------------------------- --------------------------------------------------