OpenSearch/docs/reference/cluster/update-settings.asciidoc

52 lines
1.3 KiB
Plaintext

[[cluster-update-settings]]
== Cluster Update Settings
Allows to update cluster wide specific settings. Settings updated can
either be persistent (applied cross restarts) or transient (will not
survive a full cluster restart). Here is an example:
[source,js]
--------------------------------------------------
curl -XPUT localhost:9200/_cluster/settings -d '{
"persistent" : {
"discovery.zen.minimum_master_nodes" : 2
}
}'
--------------------------------------------------
Or:
[source,js]
--------------------------------------------------
curl -XPUT localhost:9200/_cluster/settings -d '{
"transient" : {
"discovery.zen.minimum_master_nodes" : 2
}
}'
--------------------------------------------------
The cluster responds with the settings updated. So the response for the
last example will be:
[source,js]
--------------------------------------------------
{
"persistent" : {},
"transient" : {
"discovery.zen.minimum_master_nodes" : "2"
}
}'
--------------------------------------------------
Cluster wide settings can be returned using:
[source,js]
--------------------------------------------------
curl -XGET localhost:9200/_cluster/settings
--------------------------------------------------
A list of dynamically updatable settings can be found in the
<<modules,Modules>> documentation.