diff --git a/server/src/main/java/org/elasticsearch/indices/IndicesService.java b/server/src/main/java/org/elasticsearch/indices/IndicesService.java index 2977cea2ae8..949fe9b4b2b 100644 --- a/server/src/main/java/org/elasticsearch/indices/IndicesService.java +++ b/server/src/main/java/org/elasticsearch/indices/IndicesService.java @@ -900,6 +900,9 @@ public class IndicesService extends AbstractLifecycleComponent final IndexMetaData metaData; try { metaData = metaStateService.loadIndexState(index); + if (metaData == null) { + return null; + } } catch (Exception e) { logger.warn(() -> new ParameterizedMessage("[{}] failed to load state file from a stale deleted index, " + "folders will be left on disk", index), e);