# Issues on rollover in the datastream

**URL:** <https://discuss.elastic.co/t/issues-on-rollover-in-the-datastream/374979>\
**Category:** Elastic Search\
**Created:** [February 25, 2025, 2:07am UTC](https://discuss.elastic.co/t/issues-on-rollover-in-the-datastream/374979 "2025-02-25T02:07:21Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Iron](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/iron/32/139499_2.png) [@Iron](https://discuss.elastic.co/u/Iron)\
**Post date:** [February 25, 2025, 2:07am UTC](https://discuss.elastic.co/t/issues-on-rollover-in-the-datastream/374979/1 "2025-02-25T02:07:21Z")

</div>

I'm currently using Elasticsearch version 8.7.1.  
Some indexes are converted to datastreams, and are set to rollover every 200 GB and per day.  
The problem is that every day there should be a rollover by date, and the index should be created, but after it is created in 200GB increments, the rollover is carried out according to the date.  
I'm wondering if we can increase the priority of being rollover to dates.

"hot": {  
"min\_age": "0ms",  
"actions": {  
"rollover": {  
"max\_size": "200gb",  
"max\_primary\_shard\_size": "200gb",  
"max\_age": "1d"  
},  
"set\_priority": {  
"priority": 100  
}  
}  
}

---

<div class="post-metadata">

**Author:** ![Musab\_Dogan](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/musab_dogan/32/70691_2.png) [@Musab\_Dogan](https://discuss.elastic.co/u/Musab_Dogan)\
**Post date:** [February 25, 2025, 7:02am UTC](https://discuss.elastic.co/t/issues-on-rollover-in-the-datastream/374979/2 "2025-02-25T07:02:00Z")

</div>

Here are some clarifications from the official document:

1. A rollover action must specify **at least one** `max_*` condition, it may include zero or more `min_*` conditions. An empty rollover action is invalid.
2. The index will roll over once **any** `max_*` condition is satisfied and all `min_*` conditions are satisfied. Note, however, that empty indices are not rolled over by default.
3. When you specify multiple rollover conditions, the index is rolled over when any of the `max_*` and all of the `min_*` conditions are met.

> **[Rollover | Elasticsearch Guide \[8.17\] | Elastic](https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-rollover.html)**

So in your case, a new index will be created after max\_size reaches 200GB or 24 hours after index creation.

> I'm wondering if we can increase the priority of being rollover to dates.

There is no priority for that but you can add the `min_age: 1d` condition. In that way, the index can't be rollover if it's not older than 1 day.

**Caution!** Please keep in mind that, if the index grows too big it will still wait one day for rollover.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [March 25, 2025, 7:02am UTC](https://discuss.elastic.co/t/issues-on-rollover-in-the-datastream/374979/3 "2025-03-25T07:02:17Z")

</div>

Closed on March 25, 2025, 7:02am UTC

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