Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot delete index, it is still part of the cluster state #18054

Closed
jasontedor opened this issue Apr 28, 2016 · 2 comments
Closed

Cannot delete index, it is still part of the cluster state #18054

jasontedor opened this issue Apr 28, 2016 · 2 comments
Assignees
Labels

Comments

@jasontedor
Copy link
Member

I've seen this a few times in the last few days. This is a fresh build off of master (72fb93e) and a fresh data directory. The node was started, had some data indexed into it, deleted those indices, and shutdown the node, and then started the node again and saw this stacktrace on startup:

[2016-04-28 19:13:59,265][WARN ][cluster.service          ] [Ape-Man] failed to notify ClusterStateListener                                                   
java.lang.IllegalStateException: Cannot delete index [[data/czEFA9CDRWSpUdU0GPzSIw]], it is still part of the cluster state.
        at org.elasticsearch.indices.IndicesService.verifyIndexIsDeleted(IndicesService.java:686)
        at org.elasticsearch.indices.cluster.IndicesClusterStateService.applyDeletedIndices(IndicesClusterStateService.java:250)
        at org.elasticsearch.indices.cluster.IndicesClusterStateService.clusterChanged(IndicesClusterStateService.java:183)
        at org.elasticsearch.cluster.service.ClusterService.runTasksForExecutor(ClusterService.java:652)
        at org.elasticsearch.cluster.service.ClusterService$UpdateTask.run(ClusterService.java:814)
        at org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingRunnable.run(ThreadContext.java:392)
        at org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.runAndClean(PrioritizedEsThreadPoolExecutor.java:237)
        at org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.run(PrioritizedEsThreadPoolExecutor.java:200)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at java.lang.Thread.run(Thread.java:745)

Another observation is that there is not a folder on disk with that UUID.

@jasontedor
Copy link
Member Author

jasontedor commented Apr 28, 2016

There is a tombstone for this index in the cluster state:

  {
        "index" : {
          "index_name" : "data",
          "index_uuid" : "czEFA9CDRWSpUdU0GPzSIw"
        },
        "delete_date_in_millis": 1461885168863
  }

@jasontedor
Copy link
Member Author

jasontedor commented Apr 28, 2016

Here's one more observation: creating an index with the same name as the deleted index appears to be related to the message here. In particular, if I delete the second index (with the same name) then that message does not appear. But if I create the index again (so a third time), the message does.

abeyad pushed a commit to abeyad/elasticsearch that referenced this issue Apr 29, 2016
name and uuid because the cluster state may contain an active index of
the same name (but different uuid).

Closes elastic#18058
Closes elastic#18054
@abeyad abeyad closed this as completed in a31b94e Apr 29, 2016
fixmebot bot referenced this issue in VectorXz/elasticsearch Apr 22, 2021
fixmebot bot referenced this issue in VectorXz/elasticsearch May 28, 2021
fixmebot bot referenced this issue in VectorXz/elasticsearch Aug 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants