# Broken Elasticsearch after each upgrade

**URL:** <https://discuss.elastic.co/t/broken-elasticsearch-after-each-upgrade/198909>\
**Category:** Elasticsearch\
**Created:** [September 10, 2019, 1:26pm UTC](https://discuss.elastic.co/t/broken-elasticsearch-after-each-upgrade/198909 "2019-09-10T13:26:12Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![tomx1](https://avatars.discourse-cdn.com/v4/letter/t/779978/32.png) [@tomx1](https://discuss.elastic.co/u/tomx1)\
**Post date:** [September 10, 2019, 1:26pm UTC](https://discuss.elastic.co/t/broken-elasticsearch-after-each-upgrade/198909/1 "2019-09-10T13:26:13Z")

</div>

We are running Elasticsearch on Debian 9. Everytime we upgrade the elasticsearch package using the [elastic.co](http://elastic.co) repo, the installation is broken. The reason is, that the systemd file is replaced against the vendor version (without asking) and that file (`/usr/lib/systemd/system/elasticsearch.service`) is missing a configuration entry. This one:

`LimitMEMLOCK=infinity`

This leads to the following error when restarting after the upgrade:  
`[1] bootstrap checks failed [1]: memory locking requested for elasticsearch process but memory is not locked`

After adding the option above and doing a 'systemctl daemon-reload' elasticsearch is starting again.

This is really annoying, I can't belive that this is an issue everyone has which is using the Debian repo. Does somebody have an idea why this is happening.

---

<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:** [October 8, 2019, 1:26pm UTC](https://discuss.elastic.co/t/broken-elasticsearch-after-each-upgrade/198909/2 "2019-10-08T13:26:20Z")

</div>

Closed on October 8, 2019, 1:26pm UTC

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