Cannot kill ElasticSearch process (Mac OS X, es version 0.19.10)

While I wrote this message to the list, asking for help, I figured out the
solution. So here is my post as a help for others trying their luck via
Google.

I had installed ElasticSearch a while ago locally via homebrew and had
forgotten about it. Now I saw the process lying around and wanted to kill
it, but that didn't work.

It turned out it was controlled via launchd. So it needs launchd to stop or
even remove the service.

In my case the service was named "homebrew.mxcl.elasticsearch". So the
command for stopping the service is

launchctl stop homebrew.mxcl.elasticsearch

and for removing forever:

launchctl remove homebrew.mxcl.elasticsearch

I order to find the name ("homebrew.mxcl.elasticsearch" in my case) of the
process, one can use the command

launchctl list | grep elastic

Hope this helps!

--