How to delete index before 5 days without curator


(Muthu Kumar) #1

How to delete index before 5 days without curator


(Alexander Reelsen) #2

you could specify the indices using index date math, but you still need to ensure that you sent this request at certain times.

Note, that there will be a feature named Index Lifecycle Management coming up in one of the next releases, that will help you with this requirement.


(Muthu Kumar) #3

still i am not getting ..My index name is beat-index how to delete this index before 2 days..can u pls help me curl for the same


(Christian Dahlqvist) #4

I am a bit confused. What is the index lifecycle you are looking for? Can you describe the expected behaviour? Exactly when do you want to delete it? Are you using time-based indices?


(Muthu Kumar) #5

yes I am using time based indices..and I need index lifecyle for 2 days..beyond 2 days it should get removed ..


(Christian Dahlqvist) #6

Then you will need a process or cron job that periodically determines the name of the index to be deleted and calls the API to perform the delete, just as Alexander described. This is what Curator does.


(Muthu Kumar) #7

yes i understood..can i get command for delete not for periodically..may be i ll execute through Dev tools in kibana ..to delete 2 days old indices..??


(Christian Dahlqvist) #8

Use the delete index API.


(Muthu Kumar) #9

Delete index will delete the full index. Am i right?

But i need to use the same delete index to delete indices before 2 days.


(Christian Dahlqvist) #10

It will delete the index you specify it should delete. When using time-based indices the general principle is that complete indices are deleted as this is far more efficient than deleting documents from within an index using the delete by query API.


(system) #11

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