{"action":"closed","issue":{"url":"https://api.github.com/repos/elastic/elasticsearch/issues/29573","repository_url":"https://api.github.com/repos/elastic/elasticsearch","labels_url":"https://api.github.com/repos/elastic/elasticsearch/issues/29573/labels{/name}","comments_url":"https://api.github.com/repos/elastic/elasticsearch/issues/29573/comments","events_url":"https://api.github.com/repos/elastic/elasticsearch/issues/29573/events","html_url":"https://github.com/elastic/elasticsearch/issues/29573","id":315312534,"number":29573,"title":"IllegalArgumentException: cannot set discovery.zen.minimum_master_nodes to more than the current master nodes count [1]","user":{"login":"wuyunfeng","id":5183061,"avatar_url":"https://avatars1.githubusercontent.com/u/5183061?v=4","gravatar_id":"","url":"https://api.github.com/users/wuyunfeng","html_url":"https://github.com/wuyunfeng","followers_url":"https://api.github.com/users/wuyunfeng/followers","following_url":"https://api.github.com/users/wuyunfeng/following{/other_user}","gists_url":"https://api.github.com/users/wuyunfeng/gists{/gist_id}","starred_url":"https://api.github.com/users/wuyunfeng/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wuyunfeng/subscriptions","organizations_url":"https://api.github.com/users/wuyunfeng/orgs","repos_url":"https://api.github.com/users/wuyunfeng/repos","events_url":"https://api.github.com/users/wuyunfeng/events{/privacy}","received_events_url":"https://api.github.com/users/wuyunfeng/received_events","type":"User","site_admin":false},"labels":[{"id":881394071,"url":"https://api.github.com/repos/elastic/elasticsearch/labels/:Distributed/ZenDiscovery","name":":Distributed/ZenDiscovery","color":"0e8a16","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-04-18T03:00:18Z","updated_at":"2018-04-18T06:43:48Z","closed_at":"2018-04-18T06:43:47Z","author_association":"NONE","body":"<!--\r\n\r\n** Please read the guidelines below. **\r\n\r\nIssues that do not follow these guidelines are likely to be closed.\r\n\r\n1.  GitHub is reserved for bug reports and feature requests. The best place to\r\n    ask a general question is at the Elastic [forums](https://discuss.elastic.co).\r\n    GitHub is not the place for general questions.\r\n\r\n2.  Is this bug report or feature request for a supported OS? If not, it\r\n    is likely to be closed.  See https://www.elastic.co/support/matrix#show_os\r\n\r\n3.  Please fill out EITHER the feature request block or the bug report block\r\n    below, and delete the other block.\r\n\r\n-->\r\n\r\n<!-- Feature request -->\r\n\r\n**Describe the feature**:failed to apply cluster settings\r\njava.lang.IllegalArgumentException: can't update [discovery.zen.minimum_master_nodes] from [1] to [2]\r\n\r\n<!-- Bug report -->\r\n\r\n**Elasticsearch version** (`bin/elasticsearch --version`):5.5.0\r\n\r\n**Plugins installed**: [ik]\r\n\r\n**JVM version** (`java -version`):JDK 1.8\r\n\r\n**OS version** (`uname -a` if on a Unix-like system): Centos7.2\r\n\r\n**Description of the problem including expected versus actual behavior**: enlarge elasticsearch one node to two node failure\r\nExpected: We do not hope modify the `unicast.hosts` list manually to build the cluster\r\n**Steps to reproduce**:\r\n\r\nPlease include a *minimal* but *complete* recreation of the problem, including\r\n(e.g.) index creation, mappings, settings, query etc.  The easier you make for\r\nus to reproduce it, the more likely that somebody will take the time to look at it.\r\n\r\n 1. We start a single Elasticsearch Node A, configure the discovery.zen.ping.unicast.hosts: NodeA:port\r\n 2. Start another Elasticsearch Node B,configure the discovery.zen.ping.unicast.hosts: NodeA:port,NodeB:port\r\n 3. Dynamically update cluster setting:discovery.zen.minimum_master_nodes from 1 to 2\r\n 4. restart the Node A, Node A elect self to master and throw java.lang.IllegalArgumentException: cannot set discovery.zen.minimum_master_nodes to more than the current master nodes count [1]\r\n \r\n\r\n\r\n**Provide logs (if relevant)**:\r\n[2018-04-18T09:51:47,747][WARN ][o.e.c.s.ClusterSettings  ] [B-i9l9Q] failed to apply settings\r\njava.lang.IllegalArgumentException: illegal value can't update [discovery.zen.minimum_master_nodes] from [1] to [2]\r\n\tat org.elasticsearch.common.settings.Setting$Updater.getValue(Setting.java:610) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.settings.AbstractScopedSettings$SettingUpdater.updater(AbstractScopedSettings.java:344) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.settings.AbstractScopedSettings.applySettings(AbstractScopedSettings.java:164) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.ClusterService.publishAndApplyChanges(ClusterService.java:761) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.ClusterService.runTasks(ClusterService.java:587) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.ClusterService$ClusterServiceTaskBatcher.run(ClusterService.java:263) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.TaskBatcher.runIfNotProcessed(TaskBatcher.java:150) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.TaskBatcher$BatchedTask.run(TaskBatcher.java:188) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingRunnable.run(ThreadContext.java:569) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.runAndClean(PrioritizedEsThreadPoolExecutor.java:247) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.run(PrioritizedEsThreadPoolExecutor.java:210) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_161]\r\n\tat java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_161]\r\n\tat java.lang.Thread.run(Thread.java:748) [?:1.8.0_161]\r\nCaused by: java.lang.IllegalArgumentException: cannot set discovery.zen.minimum_master_nodes to more than the current master nodes count [1]\r\n\tat org.elasticsearch.discovery.zen.ZenDiscovery.lambda$new$2(ZenDiscovery.java:187) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.settings.Setting$Updater.getValue(Setting.java:608) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\t... 13 more\r\n[2018-04-18T09:51:47,748][WARN ][o.e.c.s.ClusterService   ] [B-i9l9Q] failed to apply cluster settings\r\njava.lang.IllegalArgumentException: illegal value can't update [discovery.zen.minimum_master_nodes] from [1] to [2]\r\n\tat org.elasticsearch.common.settings.Setting$Updater.getValue(Setting.java:610) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.settings.AbstractScopedSettings$SettingUpdater.updater(AbstractScopedSettings.java:344) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.settings.AbstractScopedSettings.applySettings(AbstractScopedSettings.java:164) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.ClusterService.publishAndApplyChanges(ClusterService.java:761) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.ClusterService.runTasks(ClusterService.java:587) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.ClusterService$ClusterServiceTaskBatcher.run(ClusterService.java:263) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.TaskBatcher.runIfNotProcessed(TaskBatcher.java:150) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.TaskBatcher$BatchedTask.run(TaskBatcher.java:188) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingRunnable.run(ThreadContext.java:569) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.runAndClean(PrioritizedEsThreadPoolExecutor.java:247) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.run(PrioritizedEsThreadPoolExecutor.java:210) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_161]\r\n\tat java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_161]\r\n\tat java.lang.Thread.run(Thread.java:748) [?:1.8.0_161]\r\nCaused by: java.lang.IllegalArgumentException: cannot set discovery.zen.minimum_master_nodes to more than the current master nodes count [1]\r\n\tat org.elasticsearch.discovery.zen.ZenDiscovery.lambda$new$2(ZenDiscovery.java:187) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.settings.Setting$Updater.getValue(Setting.java:608) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\t... 13 more\r\n[2018-04-18T09:51:47,771][WARN ][o.e.c.s.ClusterSettings  ] [B-i9l9Q] failed to prepareCommit settings for [Updater for: {\r\n  \"key\" : \"discovery.zen.minimum_master_nodes\",\r\n  \"properties\" : [\r\n    \"Dynamic\",\r\n    \"NodeScope\"\r\n  ],\r\n  \"is_group_setting\" : false,\r\n  \"default\" : \"-1\"\r\n}]\r\njava.lang.IllegalArgumentException: illegal value can't update [discovery.zen.minimum_master_nodes] from [1] to [2]\r\n\tat org.elasticsearch.common.settings.Setting$Updater.getValue(Setting.java:610) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.settings.AbstractScopedSettings$SettingUpdater.updater(AbstractScopedSettings.java:344) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.settings.AbstractScopedSettings.applySettings(AbstractScopedSettings.java:164) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.ClusterService.publishAndApplyChanges(ClusterService.java:761) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.ClusterService.runTasks(ClusterService.java:587) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.ClusterService$ClusterServiceTaskBatcher.run(ClusterService.java:263) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.TaskBatcher.runIfNotProcessed(TaskBatcher.java:150) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.TaskBatcher$BatchedTask.run(TaskBatcher.java:188) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingRunnable.run(ThreadContext.java:569) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.runAndClean(PrioritizedEsThreadPoolExecutor.java:247) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.run(PrioritizedEsThreadPoolExecutor.java:210) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_161]\r\n\tat java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_161]\r\n\tat java.lang.Thread.run(Thread.java:748) [?:1.8.0_161]\r\nCaused by: java.lang.IllegalArgumentException: cannot set discovery.zen.minimum_master_nodes to more than the current master nodes count [1]\r\n\tat org.elasticsearch.discovery.zen.ZenDiscovery.lambda$new$2(ZenDiscovery.java:187) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.settings.Setting$Updater.getValue(Setting.java:608) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\t... 13 more\r\n[2018-04-18T09:51:47,772][WARN ][o.e.c.s.ClusterSettings  ] [B-i9l9Q] failed to apply settings\r\njava.lang.IllegalArgumentException: illegal value can't update [discovery.zen.minimum_master_nodes] from [1] to [2]\r\n\tat org.elasticsearch.common.settings.Setting$Updater.getValue(Setting.java:610) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.settings.AbstractScopedSettings$SettingUpdater.updater(AbstractScopedSettings.java:344) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.settings.AbstractScopedSettings.applySettings(AbstractScopedSettings.java:164) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.ClusterService.publishAndApplyChanges(ClusterService.java:761) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.ClusterService.runTasks(ClusterService.java:587) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.ClusterService$ClusterServiceTaskBatcher.run(ClusterService.java:263) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.TaskBatcher.runIfNotProcessed(TaskBatcher.java:150) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.TaskBatcher$BatchedTask.run(TaskBatcher.java:188) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingRunnable.run(ThreadContext.java:569) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.runAndClean(PrioritizedEsThreadPoolExecutor.java:247) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.run(PrioritizedEsThreadPoolExecutor.java:210) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_161]\r\n\tat java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_161]\r\n\tat java.lang.Thread.run(Thread.java:748) [?:1.8.0_161]\r\nCaused by: java.lang.IllegalArgumentException: cannot set discovery.zen.minimum_master_nodes to more than the current master nodes count [1]\r\n\tat org.elasticsearch.discovery.zen.ZenDiscovery.lambda$new$2(ZenDiscovery.java:187) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.settings.Setting$Updater.getValue(Setting.java:608) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\t... 13 more\r\n[2018-04-18T09:51:47,773][WARN ][o.e.c.s.ClusterService   ] [B-i9l9Q] failed to apply cluster settings\r\njava.lang.IllegalArgumentException: illegal value can't update [discovery.zen.minimum_master_nodes] from [1] to [2]\r\n\tat org.elasticsearch.common.settings.Setting$Updater.getValue(Setting.java:610) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.settings.AbstractScopedSettings$SettingUpdater.updater(AbstractScopedSettings.java:344) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.settings.AbstractScopedSettings.applySettings(AbstractScopedSettings.java:164) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.ClusterService.publishAndApplyChanges(ClusterService.java:761) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.ClusterService.runTasks(ClusterService.java:587) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.ClusterService$ClusterServiceTaskBatcher.run(ClusterService.java:263) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.TaskBatcher.runIfNotProcessed(TaskBatcher.java:150) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.cluster.service.TaskBatcher$BatchedTask.run(TaskBatcher.java:188) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingRunnable.run(ThreadContext.java:569) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.runAndClean(PrioritizedEsThreadPoolExecutor.java:247) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.run(PrioritizedEsThreadPoolExecutor.java:210) [baidu-elasticsearch-5.5.0.jar:?]\r\n\tat java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_161]\r\n\tat java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_161]\r\n\tat java.lang.Thread.run(Thread.java:748) [?:1.8.0_161]\r\nCaused by: java.lang.IllegalArgumentException: cannot set discovery.zen.minimum_master_nodes to more than the current master nodes count [1]\r\n\tat org.elasticsearch.discovery.zen.ZenDiscovery.lambda$new$2(ZenDiscovery.java:187) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\tat org.elasticsearch.common.settings.Setting$Updater.getValue(Setting.java:608) ~[baidu-elasticsearch-5.5.0.jar:?]\r\n\t... 13 more\r\n"}}
{"actor":{"display_login":"bleskes"}}