Failed step for index is not part of policy anymore or it is invalid skipping execution – How to solve this Elasticsearch error

Opster Team

Aug-23, Version: 7.6-7.15

Briefly, this error occurs when an index lifecycle management (ILM) policy step fails because the index is no longer part of the policy or the policy is invalid. To resolve this, you can check the ILM policy and ensure it’s correctly configured. If the index is not part of the policy anymore, you can re-attach it. If the policy is invalid, you can correct it or create a new one. Also, ensure that the Elasticsearch version supports the ILM feature.

This guide will help you check for common problems that cause the log ” failed step [{}] for index [{}] is not part of policy [{}] anymore; or it is invalid. skipping execution ” to appear. To understand the issues related to this log, read the explanation below about the following Elasticsearch concepts: index, plugin.

Log Context

Log “failed step [{}] for index [{}] is not part of policy [{}] anymore; or it is invalid. skipping execution” classname is IndexLifecycleRunner.java.
We extracted the following from Elasticsearch source code for those seeking an in-depth context :

        String index = indexMetadata.getIndex().getName();
        LifecycleExecutionState lifecycleState = LifecycleExecutionState.fromIndexMetadata(indexMetadata);
        Step failedStep = stepRegistry.getStep(indexMetadata; new StepKey(lifecycleState.getPhase(); lifecycleState.getAction();
            lifecycleState.getFailedStep()));
        if (failedStep == null) {
            logger.warn("failed step [{}] for index [{}] is not part of policy [{}] anymore; or it is invalid. skipping execution";
                lifecycleState.getFailedStep(); index; policy);
            return;
        }

        if (lifecycleState.isAutoRetryableError() != null && lifecycleState.isAutoRetryableError()) {

 

How helpful was this guide?

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?