Index rollover with date and time

Hi Community!

I'm trying to create an index rollover with the date and hour when the new index is created because I set up the rollover every hour during the day. Having this in consideration, the format of the new index should be:


Is there a way to do this? I tried using date math and returns just the date:

PUT %3Cmy-index-%7Bnow%2Fd%7D-000001%3E

Also tried this, and it doesn't gives the actual time.


Thank you very much!


I just tried

curl -X PUT 'localhost:9200/<>'

which does not do any now/d tricks, because that will always mean the start of the day, if you use hours and minutes.

Does that help?

so you can't timestamp the time of the new index rollover?

For example,



Have you tried the above example? If not, do :slight_smile:

That said, I hope you do not aim for indices by the minute and this is just to keep the creation date in the index name :slight_smile:

Thank you very much! It worked! :slight_smile:

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