# Disabling machine learning does not allow Elasticsearch to stop

**URL:** <https://discuss.elastic.co/t/disabling-machine-learning-does-not-allow-elasticsearch-to-stop/88869>\
**Category:** Elasticsearch\
**Created:** [June 9, 2017, 4:42pm UTC](https://discuss.elastic.co/t/disabling-machine-learning-does-not-allow-elasticsearch-to-stop/88869 "2017-06-09T16:42:40Z")\
**Posts on this page:** 1\
**Showing post:** 10

<div class="post-metadata">

**Author:** ![droberts195](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/droberts195/32/17692_2.png) [@droberts195](https://discuss.elastic.co/u/droberts195)\
**Post date:** [June 12, 2017, 2:41pm UTC](https://discuss.elastic.co/t/disabling-machine-learning-does-not-allow-elasticsearch-to-stop/88869/10 "2017-06-12T14:41:37Z")

</div>

Thanks @yoshioiwamoto - the stack trace narrows down the problem. There are two more things you could do that would be useful for working out what's going wrong.

Firstly, while Elasticsearch is running, but _before_ you shut it down, can you also see a process called `controller` running. In other words, what does `ps -ef | grep controller` return while Elasticsearch is running?

Secondly, open 3 terminal windows. In the first terminal run this:

```auto
/usr/share/elasticsearch/plugins/x-pack/platform/linux-x86_64/bin/controller

```

When you run it with no arguments it should just wait. Leave it running, move to the next terminal and run:

```auto
ls -ltr /tmp

```

Do you see a recent entry like this one?

```auto
prw------- 1 dave dev 0 Jun 12 15:24 controller_log_908

```

The number at the end will be different, and obviously the owner too, but it should have those permissions and the name should begin with `controller_log_`. If you do see such a file, tail it like this:

```auto
tail -f /tmp/controller_log_908

```

Replace the 908 with the correct number for the file you see.

Finally, move to the next terminal and run this again:

```auto
ls -ltr /tmp

```

Now you should see a recent file that looks similar to this:

```auto
prw------- 1 dave dev 0 Jun 12 15:24 controller_command_908

```

If you do, then run this:

```auto
yes > /tmp/controller_command_908

```

Once again replace the 908 with the number you see.

Now look back to the first terminal. Is the `controller` process still running?

Now go back to the terminal running `yes`. Use `CTRL+C` to stop it. Now look back to the first terminal. The `controller` process should have stopped.

Finally, look in the terminal running `tail`. It should have printed a number of error messages. These are due to `controller` not understanding the output of `yes` and are not relevant to the problem - just `CTRL+C` the `tail` command.

If something different happens for you then please let me know what you get.

---

_[View the full topic](https://discuss.elastic.co/t/disabling-machine-learning-does-not-allow-elasticsearch-to-stop/88869)._
