discovery-settings.asciidoc 6.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171
  1. [[modules-discovery-settings]]
  2. === Discovery and cluster formation settings
  3. Discovery and cluster formation are affected by the following settings:
  4. `cluster.auto_shrink_voting_configuration`::
  5. Controls whether the <<modules-discovery-voting,voting configuration>>
  6. sheds departed nodes automatically, as long as it still contains at least 3
  7. nodes. The default value is `true`. If set to `false`, the voting
  8. configuration never shrinks automatically and you must remove departed
  9. nodes manually with the <<voting-config-exclusions,voting configuration
  10. exclusions API>>.
  11. [[master-election-settings]]`cluster.election.back_off_time`::
  12. Sets the amount to increase the upper bound on the wait before an election
  13. on each election failure. Note that this is _linear_ backoff. This defaults
  14. to `100ms`
  15. `cluster.election.duration`::
  16. Sets how long each election is allowed to take before a node considers it to
  17. have failed and schedules a retry. This defaults to `500ms`.
  18. `cluster.election.initial_timeout`::
  19. Sets the upper bound on how long a node will wait initially, or after the
  20. elected master fails, before attempting its first election. This defaults
  21. to `100ms`.
  22. `cluster.election.max_timeout`::
  23. Sets the maximum upper bound on how long a node will wait before attempting
  24. an first election, so that an network partition that lasts for a long time
  25. does not result in excessively sparse elections. This defaults to `10s`
  26. [[fault-detection-settings]]`cluster.fault_detection.follower_check.interval`::
  27. Sets how long the elected master waits between follower checks to each
  28. other node in the cluster. Defaults to `1s`.
  29. `cluster.fault_detection.follower_check.timeout`::
  30. Sets how long the elected master waits for a response to a follower check
  31. before considering it to have failed. Defaults to `30s`.
  32. `cluster.fault_detection.follower_check.retry_count`::
  33. Sets how many consecutive follower check failures must occur to each node
  34. before the elected master considers that node to be faulty and removes it
  35. from the cluster. Defaults to `3`.
  36. `cluster.fault_detection.leader_check.interval`::
  37. Sets how long each node waits between checks of the elected master.
  38. Defaults to `1s`.
  39. `cluster.fault_detection.leader_check.timeout`::
  40. Sets how long each node waits for a response to a leader check from the
  41. elected master before considering it to have failed. Defaults to `30s`.
  42. `cluster.fault_detection.leader_check.retry_count`::
  43. Sets how many consecutive leader check failures must occur before a node
  44. considers the elected master to be faulty and attempts to find or elect a
  45. new master. Defaults to `3`.
  46. `cluster.follower_lag.timeout`::
  47. Sets how long the master node waits to receive acknowledgements for cluster
  48. state updates from lagging nodes. The default value is `90s`. If a node does
  49. not successfully apply the cluster state update within this period of time,
  50. it is considered to have failed and is removed from the cluster. See
  51. <<cluster-state-publishing>>.
  52. `cluster.initial_master_nodes`::
  53. Sets a list of the <<node.name,node names>> or transport addresses of the
  54. initial set of master-eligible nodes in a brand-new cluster. By default
  55. this list is empty, meaning that this node expects to join a cluster that
  56. has already been bootstrapped. See <<initial_master_nodes>>.
  57. `cluster.join.timeout`::
  58. Sets how long a node will wait after sending a request to join a cluster
  59. before it considers the request to have failed and retries. Defaults to
  60. `60s`.
  61. `cluster.max_voting_config_exclusions`::
  62. Sets a limit on the number of voting configuration exclusions at any one
  63. time. The default value is `10`. See
  64. <<modules-discovery-adding-removing-nodes>>.
  65. `cluster.publish.timeout`::
  66. Sets how long the master node waits for each cluster state update to be
  67. completely published to all nodes. The default value is `30s`. If this
  68. period of time elapses, the cluster state change is rejected. See
  69. <<cluster-state-publishing>>.
  70. `discovery.cluster_formation_warning_timeout`::
  71. Sets how long a node will try to form a cluster before logging a warning
  72. that the cluster did not form. Defaults to `10s`. If a cluster has not
  73. formed after `discovery.cluster_formation_warning_timeout` has elapsed then
  74. the node will log a warning message that starts with the phrase `master not discovered` which describes the current state of the discovery process.
  75. `discovery.find_peers_interval`::
  76. Sets how long a node will wait before attempting another discovery round.
  77. Defaults to `1s`.
  78. `discovery.probe.connect_timeout`::
  79. Sets how long to wait when attempting to connect to each address. Defaults
  80. to `3s`.
  81. `discovery.probe.handshake_timeout`::
  82. Sets how long to wait when attempting to identify the remote node via a
  83. handshake. Defaults to `1s`.
  84. `discovery.request_peers_timeout`::
  85. Sets how long a node will wait after asking its peers again before
  86. considering the request to have failed. Defaults to `3s`.
  87. `discovery.zen.hosts_provider`::
  88. Specifies which type of <<built-in-hosts-providers,hosts provider>> provides
  89. the list of seed nodes. By default, it is the
  90. <<settings-based-hosts-provider,settings-based hosts provider>>.
  91. [[no-master-block]]`discovery.zen.no_master_block`::
  92. Specifies which operations are rejected when there is no active master in a
  93. cluster. This setting has two valid values:
  94. +
  95. --
  96. `all`::: All operations on the node (both read and write operations) are rejected.
  97. This also applies for API cluster state read or write operations, like the get
  98. index settings, put mapping and cluster state API.
  99. `write`::: (default) Write operations are rejected. Read operations succeed,
  100. based on the last known cluster configuration. This situation may result in
  101. partial reads of stale data as this node may be isolated from the rest of the
  102. cluster.
  103. [NOTE]
  104. ===============================
  105. * The `discovery.zen.no_master_block` setting doesn't apply to nodes-based APIs
  106. (for example, cluster stats, node info, and node stats APIs). Requests to these
  107. APIs are not be blocked and can run on any available node.
  108. * For the cluster to be fully operational, it must have an active master.
  109. ===============================
  110. --
  111. `discovery.zen.ping.unicast.hosts`::
  112. Provides a list of master-eligible nodes in the cluster. The list contains
  113. either an array of hosts or a comma-delimited string. Each value has the
  114. format `host:port` or `host`, where `port` defaults to the setting
  115. `transport.profiles.default.port`. Note that IPv6 hosts must be bracketed.
  116. The default value is `127.0.0.1, [::1]`. See <<unicast.hosts>>.
  117. `discovery.zen.ping.unicast.hosts.resolve_timeout`::
  118. Sets the amount of time to wait for DNS lookups on each round of discovery.
  119. This is specified as a <<time-units, time unit>> and defaults to `5s`.