# Index naming after upgrade

**URL:** <https://discuss.elastic.co/t/index-naming-after-upgrade/201116>\
**Category:** Elasticsearch\
**Created:** [September 25, 2019, 11:09pm UTC](https://discuss.elastic.co/t/index-naming-after-upgrade/201116 "2019-09-25T23:09:52Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![alexclifford](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/alexclifford/32/54957_2.png) [@alexclifford](https://discuss.elastic.co/u/alexclifford)\
**Post date:** [September 25, 2019, 11:09pm UTC](https://discuss.elastic.co/t/index-naming-after-upgrade/201116/1 "2019-09-25T23:09:52Z")

</div>

I've upgraded from 6.8 to 7.3 on Elastic Cloud (I mainly use APM) but the index names have changed, how do I change them back?

Originally I had apm-6.8.3-transaction-2019.09.23 etc, rotating daily. Now I have apm-7.3.2-transaction-0000001 and it doesn't appear to be rotating at all. I'd prefer a new index each day and then I can delete indexes after X days.

---

<div class="post-metadata">

**Author:** ![alexclifford](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/alexclifford/32/54957_2.png) [@alexclifford](https://discuss.elastic.co/u/alexclifford)\
**Post date:** [October 13, 2019, 11:48am UTC](https://discuss.elastic.co/t/index-naming-after-upgrade/201116/2 "2019-10-13T11:48:54Z")

</div>

For anyone else who comes across this, it was the new Index Lifecycle Policy automation kicking in.

I do this manually with a top level inheriting policy of my own. I give it a high order number to make it run last.

Disabling `setup.ilm.enabled` in both Filebeat and Functionbeat allows it to revert to its default daily index naming and then I can manage it from there.

For APM it was a little different as the configuration from the Go APM agent isn't as customisable. I set this for the Elasticsearch server config itself:

```auto
output.elasticsearch:
  indices:
   - index: "apm-%{[observer.version]}-sourcemap"
     when.contains:
       processor.event: "sourcemap"
   - index: "apm-%{[observer.version]}-error-%{+yyyy.MM.dd}"
     when.contains:
       processor.event: "error"
   - index: "apm-%{[observer.version]}-transaction-%{+yyyy.MM.dd}"
     when.contains:
       processor.event: "transaction"
   - index: "apm-%{[observer.version]}-span-%{+yyyy.MM.dd}"
     when.contains:
       processor.event: "span"
   - index: "apm-%{[observer.version]}-metric-%{+yyyy.MM.dd}"
     when.contains:
       processor.event: "metric"
   - index: "apm-%{[observer.version]}-onboarding-%{+yyyy.MM.dd}"
     when.contains:
       processor.event: "onboarding"

```

---

<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:** [November 10, 2019, 11:49am UTC](https://discuss.elastic.co/t/index-naming-after-upgrade/201116/3 "2019-11-10T11:49:05Z")

</div>

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