Failed to close persistent cache index – How to solve this Elasticsearch error

Opster Team

Aug-23, Version: 7.11-8.9

Briefly, this error occurs when Elasticsearch is unable to close a persistent cache index. This could be due to a variety of reasons such as insufficient disk space, incorrect permissions, or a system failure. To resolve this issue, you can try freeing up disk space, checking and correcting file permissions, or restarting the Elasticsearch service. If the problem persists, consider clearing the cache or reindexing. Always ensure to backup your data before performing these operations to prevent data loss.

This guide will help you check for common problems that cause the log ” failed to close persistent cache index ” to appear. To understand the issues related to this log, read the explanation below about the following Elasticsearch concepts: plugin, index, persistent, cache.

Log Context

Log “failed to close persistent cache index” classname is PersistentCache.java.
We extracted the following from Elasticsearch source code for those seeking an in-depth context :

                documents.clear();
            } catch (IOException e) {
                try {
                    close();
                } catch (Exception e2) {
                    logger.warn("failed to close persistent cache index"; e2);
                    e.addSuppressed(e2);
                }
                throw new UncheckedIOException("Failed to load persistent cache"; e);
            } finally {
                closeIfAnyIndexWriterHasTragedyOrIsClosed();

 

 [ratemypost]