# ES 5.x does not create the PID file when starting with bin/elasticsearch -d -p pid

**URL:** <https://discuss.elastic.co/t/es-5-x-does-not-create-the-pid-file-when-starting-with-bin-elasticsearch-d-p-pid/85321>\
**Category:** Elasticsearch\
**Created:** [May 11, 2017, 2:40am UTC](https://discuss.elastic.co/t/es-5-x-does-not-create-the-pid-file-when-starting-with-bin-elasticsearch-d-p-pid/85321 "2017-05-11T02:40:19Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Duy\_Do](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/duy_do/32/18114_2.png) [@Duy\_Do](https://discuss.elastic.co/u/Duy_Do)\
**Post date:** [May 11, 2017, 2:40am UTC](https://discuss.elastic.co/t/es-5-x-does-not-create-the-pid-file-when-starting-with-bin-elasticsearch-d-p-pid/85321/1 "2017-05-11T02:40:19Z")

</div>

According [the official document](https://www.elastic.co/guide/en/elasticsearch/reference/current/zip-targz.html) Elasticsearch should create a PID file when starting with the command `bin/elasticsearch -d -p pid` but it does not.

```
ES versions: 5.x
OS: macOS Sierra
Java: 1.8.0_91

```

All the versions 1.x & 2.x create the PID file when starting with that command. It seems this is a bug on 5.x.

---

<div class="post-metadata">

**Author:** ![nik9000](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nik9000/32/44947_2.png) [@nik9000](https://discuss.elastic.co/u/nik9000)\
**Post date:** [May 11, 2017, 2:54am UTC](https://discuss.elastic.co/t/es-5-x-does-not-create-the-pid-file-when-starting-with-bin-elasticsearch-d-p-pid/85321/2 "2017-05-11T02:54:22Z")

</div>

Can you have a look at the logs? We use `-p pid` all the time.

---

<div class="post-metadata">

**Author:** ![Duy\_Do](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/duy_do/32/18114_2.png) [@Duy\_Do](https://discuss.elastic.co/u/Duy_Do)\
**Post date:** [May 11, 2017, 3:50am UTC](https://discuss.elastic.co/t/es-5-x-does-not-create-the-pid-file-when-starting-with-bin-elasticsearch-d-p-pid/85321/3 "2017-05-11T03:50:06Z")

</div>

My mistake, the PID file is created when Elasticsearch started completely.

Thanks @nik9000.

---

<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:** [June 8, 2017, 3:52am UTC](https://discuss.elastic.co/t/es-5-x-does-not-create-the-pid-file-when-starting-with-bin-elasticsearch-d-p-pid/85321/4 "2017-06-08T03:52:52Z")

</div>

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