我需要删除在 curl 中制作的 cluster.routing.allocation.awareness.force

I need to remove the cluster.routing.allocation.awareness.force made in curl

我最近向我的弹性集群发出了 curl 请愿书以强制意识:

cluster.routing.allocation.awareness.force

但我没有在设置文件中、在卷曲请愿书中这样做,而且我有很多未分配的碎片。有谁知道去除力意识的curl语句吗?

请帮忙..

谢谢

没有好的方法可以将 elasticsearch 2.x 中的动态设置恢复为默认值,如此 github-issue

documentation

中所述,elasticsearch 5.x 支持它

Resetting persistent or transient settings can be done by assigning a null value. If a transient setting is reset, the persistent setting is applied if available. Otherwise Elasticsearch will fallback to the setting defined at the configuration file or, if not existent, to the default value. Here is an example:

curl -XPUT localhost:9200/_cluster/settings -d '{
    "transient" : {
        "discovery.zen.minimum_master_nodes" : null
    }

在 elasticsearch 2.x 中,您有以下选项:

  • 如果 cluster.routing.allocation.awareness.forcetransient 可以重启集群的设置。
  • 如果persistent那么解决方法是停止集群删除 global-X.st 个文件位于 0/_state/.
    下 注意:如果你走这条路要小心,因为你会丢失所有其他动态设置,还有模板。