How to recover a closed Index


(Pakan Angel) #1

I am using elasticsearch 5.6.1 with Fess. Unfortunately my server ran out of memory. After restarting the server and running Elasticsearch realized that the main index is closed. First tried to re-open it but no success. Also have tried to repair it but no success at all. I am new to Elasticsearch and don't know what to do next to recover all my indexed data. How can I prevent to run into out of memory?


(Fram Souza) #2

Hello @PakanAngel

can you paste here part of the elasticsearch log and also the _cluster / health output?


(Pakan Angel) #3

Thanks Fram.

This is what I get when trying to recover the corrupted index.

[root@localhost elasticsearch]# curl 'localhost:9200/fess.20171224/_index/health/?pretty'
{
"error" : {
"root_cause" : [
{
"type" : "index_closed_exception",
"reason" : "closed",
"index_uuid" : "9WUbb1GfQJChHc6l9mkuBw",
"index" : "fess.20171224"
}
],
"type" : "index_closed_exception",
"reason" : "closed",
"index_uuid" : "9WUbb1GfQJChHc6l9mkuBw",
"index" : "fess.20171224"
},
"status" : 403
}

This is part of the elasticsearch.log file.

path: /fess.20171224/_open, params: {pretty=, index=fess.20171224}
org.elasticsearch.ElasticsearchException: Failed to verify index [fess.20171224/9WUbb1GfQJChHc6l9mkuBw]
at org.elasticsearch.cluster.metadata.MetaDataIndexStateService$2.execute(MetaDataIndexStateService.java:175) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.cluster.ClusterStateUpdateTask.execute(ClusterStateUpdateTask.java:45) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.cluster.service.ClusterService.executeTasks(ClusterService.java:634) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.cluster.service.ClusterService.calculateTaskOutputs(ClusterService.java:612) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.cluster.service.ClusterService.runTasks(ClusterService.java:571) [elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.cluster.service.ClusterService$ClusterServiceTaskBatcher.run(ClusterService.java:263) [elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.cluster.service.TaskBatcher.runIfNotProcessed(TaskBatcher.java:150) [elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.cluster.service.TaskBatcher$BatchedTask.run(TaskBatcher.java:188) [elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingRunnable.run(ThreadContext.java:569) [elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.runAndClean(PrioritizedEsThreadPoolExecutor.java:247) [elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.run(PrioritizedEsThreadPoolExecutor.java:210) [elasticsearch-5.6.1.jar:5.6.1]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_151]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_151]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_151]
Caused by: java.lang.IllegalArgumentException: match "ي" was already added
at org.apache.lucene.analysis.charfilter.NormalizeCharMap$Builder.add(NormalizeCharMap.java:97) ~[lucene-analyzers-common-6.6.1.jar:6.6.1 9aa465a89b64ff2dabe7b4d50c472de32c298683 - varunthacker - 2017-08-29 21:55:17]
at org.elasticsearch.index.analysis.MappingCharFilterFactory.parseRules(MappingCharFilterFactory.java:70) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.index.analysis.MappingCharFilterFactory.(MappingCharFilterFactory.java:46) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.indices.analysis.AnalysisModule$1.get(AnalysisModule.java:353) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.index.analysis.AnalysisRegistry.buildMapping(AnalysisRegistry.java:342) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.index.analysis.AnalysisRegistry.buildCharFilterFactories(AnalysisRegistry.java:181) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.index.analysis.AnalysisRegistry.build(AnalysisRegistry.java:153) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.index.IndexService.(IndexService.java:145) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.index.IndexModule.newIndexService(IndexModule.java:363) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.indices.IndicesService.createIndexService(IndicesService.java:448) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.indices.IndicesService.verifyIndexMetadata(IndicesService.java:481) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.cluster.metadata.MetaDataIndexStateService$2.execute(MetaDataIndexStateService.java:173) ~[elasticsearch-5.6.1.jar:5.6.1]
... 13 more
[2017-12-29T00:28:52,958][INFO ][o.e.c.m.MetaDataIndexStateService] [rsbzOti] opening indices [[[fess.20171224/9WUbb1GfQJChHc6l9mkuBw]]]
[2017-12-29T00:28:52,985][DEBUG][o.e.a.a.i.o.TransportOpenIndexAction] [rsbzOti] failed to open indices [[[fess.20171224/9WUbb1GfQJChHc6l9mkuBw]]]
org.elasticsearch.ElasticsearchException: Failed to verify index [fess.20171224/9WUbb1GfQJChHc6l9mkuBw]
at org.elasticsearch.cluster.metadata.MetaDataIndexStateService$2.execute(MetaDataIndexStateService.java:175) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.cluster.ClusterStateUpdateTask.execute(ClusterStateUpdateTask.java:45) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.cluster.service.ClusterService.executeTasks(ClusterService.java:634) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.cluster.service.ClusterService.calculateTaskOutputs(ClusterService.java:612) ~[elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.cluster.service.ClusterService.runTasks(ClusterService.java:571) [elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.cluster.service.ClusterService$ClusterServiceTaskBatcher.run(ClusterService.java:263) [elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.cluster.service.TaskBatcher.runIfNotProcessed(TaskBatcher.java:150) [elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.cluster.service.TaskBatcher$BatchedTask.run(TaskBatcher.java:188) [elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingRunnable.run(ThreadContext.java:569) [elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.runAndClean(PrioritizedEsThreadPoolExecutor.java:247) [elasticsearch-5.6.1.jar:5.6.1]
at org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.run(PrioritizedEsThreadPoolExecutor.java:210) [elasticsearch-5.6.1.jar:5.6.1]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_151]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_151]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_151]
Caused by: java.lang.IllegalArgumentException: match "ي" was already added
at org.apache.lucene.analysis.charfilter.NormalizeCharMap$Builder.add(NormalizeCharMap.java:97) ~[lucene-analyzers-common-6.6.1.jar:6.6.1 9aa465a89b64ff2dabe7b4d50c472de32c298683 - varunthacker - 2017-08-29 21:55:17]


(Thiago Souza) #4

That's a very weird problem there. I think @Adrien_Grand will find this interesting.


(andy_zhou) #5

output the cluster health
localhost:9200/_cluster/health/?pretty'


(system) #6

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.