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

简而言之,当 Elasticsearch 无法检索存储文件的元数据时会发生此错误。这可能是由于文件损坏、磁盘空间不足或权限问题等原因造成的。要解决此问题,您可以尝试以下方法:1) 检查并释放磁盘空间(如果空间不足)。2) 验证文件权限,确保 Elasticsearch 具有必要的访问权限。3) 如果文件已损坏,考虑从备份中恢复。4) 重启 Elasticsearch 服务,这在某些情况下可能会有所帮助。

版本: 6.8-8.9

日志上下文 #

日志 “Failed to get store file metadata” 类名是 BlobStoreRepository.java. 我们从 Elasticsearch 源代码中提取了以下内容,以便为寻求深入上下文的人提供参考:

    final IndexCommit snapshotIndexCommit = context.indexCommit();
    logger.trace("[{}] [{}] Loading store metadata using index commit [{}]"; shardId; snapshotId; snapshotIndexCommit);
    metadataFromStore = store.getMetadata(snapshotIndexCommit);
    fileNames = snapshotIndexCommit.getFileNames();
} catch (IOException e) {
    throw new IndexShardSnapshotFailedException(shardId; "Failed to get store file metadata"; e);
}
    }
    for (String fileName : fileNames) {
        if (snapshotStatus.isAborted()) {
            logger.debug("[{}] [{}] Aborted on the file [{}]; exiting"; shardId; snapshotId; fileName);