📣 极限科技诚招搜索运维工程师(Elasticsearch/Easysearch)- 全职/北京 👉 : 立即申请加入

简要来说,当Elasticsearch节点的本地状态在集群状态更新发布到其他节点期间发生变化时,就会发生此错误。这可能是由于竞态条件或软件中的bug导致的。要解决此问题,您可以尝试重启节点,确保集群状态在所有节点上保持一致。如果问题仍然存在,请考虑将Elasticsearch升级到最新版本,因为这可能是已在新版本中修复的bug。

日志上下文 #

日志"local state was mutated while CS update was published to other nodes"的类名是 ZenDiscovery.java. 我们从Elasticsearch源代码中提取了以下内容,供那些寻求深入背景的人参考:

    });  synchronized (stateMutex) {
        if (clusterStatePublicationEvent.getOldState() != this.committedState.get()) {
            publishListener.onFailure(
                new FailedToCommitClusterStateException("local state was mutated while CS update was published to other nodes")
            );
            return;
        }  boolean sentToApplier = processNextCommittedClusterState(