I was following my own instructions for installing elasticsearch but attempting to run the service and it ended up exiting with this rather unhelpful message in syslog.

There are probably other logs but like many applications, they are not designed to be user friendly, perhaps because the developers never have an trouble setting it up!

Anyway, after some searching, I found out that ES carries out certain bootstrap checks on start and if they fail, it exits with a status code (and presumably some message somewhere!)

In my case, by setting an explicit IP address in elasticsearch.yml for network.host, it switched ES into production mode which runs the checks.

All I had to do was set discovery.type: single-node in the same file, which sets it back into dev mode.