Skipping scheduled ML maintenance tasks because upgrade mode is enabled – How to solve this Elasticsearch error

Opster Team

Aug-23, Version: 8.8-8.9

Briefly, this error occurs when Elasticsearch’s Machine Learning (ML) feature is in upgrade mode. In this mode, all ML tasks are paused to prevent data inconsistencies during the upgrade process. To resolve this issue, you can either wait for the upgrade to complete, which will automatically disable upgrade mode, or manually disable it by setting the “upgrade_mode” parameter to “false” in the ML settings. However, be cautious about manually disabling it as it may lead to data inconsistencies if the upgrade is not fully completed.

This guide will help you check for common problems that cause the log ” skipping scheduled [ML] maintenance tasks because upgrade mode is enabled ” to appear. To understand the issues related to this log, read the explanation below about the following Elasticsearch concepts: plugin, upgrade.

Log Context

Log “skipping scheduled [ML] maintenance tasks because upgrade mode is enabled” classname is MlDailyMaintenanceService.java.
We extracted the following from Elasticsearch source code for those seeking an in-depth context :

    }

    private void triggerTasks() {
        try {
            if (MlMetadata.getMlMetadata(clusterService.state()).isUpgradeMode()) {
                logger.warn("skipping scheduled [ML] maintenance tasks because upgrade mode is enabled");
                return;
            }
            if (MlMetadata.getMlMetadata(clusterService.state()).isResetMode()) {
                logger.warn("skipping scheduled [ML] maintenance tasks because machine learning feature reset is in progress");
                return;

 

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?