# Index lifecycle error, security\_exception: Adding an alias is not allowed when the alias has more permissions than any of the indices

**URL:** <https://discuss.elastic.co/t/index-lifecycle-error-security-exception-adding-an-alias-is-not-allowed-when-the-alias-has-more-permissions-than-any-of-the-indices/258275>\
**Category:** Elasticsearch\
**Created:** [December 10, 2020, 1:05pm UTC](https://discuss.elastic.co/t/index-lifecycle-error-security-exception-adding-an-alias-is-not-allowed-when-the-alias-has-more-permissions-than-any-of-the-indices/258275 "2020-12-10T13:05:41Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![SergiiZagrunnyi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/sergiizagrunnyi/32/77283_2.png) [@SergiiZagrunnyi](https://discuss.elastic.co/u/SergiiZagrunnyi)\
**Post date:** [December 10, 2020, 1:05pm UTC](https://discuss.elastic.co/t/index-lifecycle-error-security-exception-adding-an-alias-is-not-allowed-when-the-alias-has-more-permissions-than-any-of-the-indices/258275/1 "2020-12-10T13:05:41Z")

</div>

Hi here

We have elastic cloud deployment and configured ILM for the APM indexes  
The policy fails on shrink action, failed step - aliases

Its not clear why that happens and what can we do with that?

ILM policy

```auto
  "apm-rollover-30-days": {
    "version": 11,
    "modified_date": "2020-12-01T08:27:55.131Z",
    "policy": {
      "phases": {
        "hot": {
          "min_age": "0ms",
          "actions": {
            "rollover": {
              "max_size": "50gb",
              "max_age": "1d"
            },
            "set_priority": {
              "priority": 100
            }
          }
        },
        "delete": {
          "min_age": "24d",
          "actions": {
            "delete": {
              "delete_searchable_snapshot": true
            }
          }
        },
        "warm": {
          "min_age": "4d",
          "actions": {
            "allocate": {
              "number_of_replicas": 0,
              "include": {},
              "exclude": {},
              "require": {
                "data": "warm"
              }
            },
            "readonly": {},
            "set_priority": {
              "priority": 50
            },
            "shrink": {
              "number_of_shards": 1
            }
          }
        }
      }
    }
  }
}

```

Error:

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/c/7/c704bf5595b3e8c18dd894fed7a3e3c980b43bbb.png)

---

<div class="post-metadata">

**Author:** ![SergiiZagrunnyi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/sergiizagrunnyi/32/77283_2.png) [@SergiiZagrunnyi](https://discuss.elastic.co/u/SergiiZagrunnyi)\
**Post date:** [December 16, 2020, 3:22pm UTC](https://discuss.elastic.co/t/index-lifecycle-error-security-exception-adding-an-alias-is-not-allowed-when-the-alias-has-more-permissions-than-any-of-the-indices/258275/2 "2020-12-16T15:22:00Z")

</div>

The issue was solved. It was related somehow to the permission of user that managed/changed ILM policy in kibana (there was less privileged custom user used)

We edited policy with `elastic` user, and triggered ILM step retry with `elastic` user for problematic indexes - that helped, no more errors after

---

<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:** [January 13, 2021, 3:22pm UTC](https://discuss.elastic.co/t/index-lifecycle-error-security-exception-adding-an-alias-is-not-allowed-when-the-alias-has-more-permissions-than-any-of-the-indices/258275/3 "2021-01-13T15:22:05Z")

</div>

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