I have installed Elasticsearch on TrueNAS using dpkg.
I have setup fs2es-indexer to index my files.
I have indexed the files and tested that all works.
After reboot, the user elasticsearch is lost.
id elasticsearch
id: ‘elasticsearch’: no such user
I have reinstall Elasticsearch via dpkg again and run the following commands to get it working.
Forgot to clarify that this is installed on TrueNAS Scale which is a debian based distribution.
This is what I get from more syslog | grep elasticsearch
elasticsearch.service: Consumed 1min 38.836s CPU time.
Feb 7 10:15:20 truenas systemd-tmpfiles[3859]: /usr/lib/tmpfiles.d/elasticsearch.conf:1: Failed to resolve user 'elasticsearch': No such file or directory
Feb 7 10:15:20 truenas systemd[3922]: elasticsearch.service: Failed to determine user credentials: No such file or directory
Feb 7 10:15:20 truenas systemd[3922]: elasticsearch.service: Failed at step USER spawning /usr/share/elasticsearch/bin/systemd-entrypoint: No such file or directory
Feb 7 10:15:20 truenas systemd[1]: elasticsearch.service: Main process exited, code=exited, status=217/USER
Feb 7 10:15:20 truenas systemd[1]: elasticsearch.service: Failed with result 'exit-code'.
It is debian based, but it behaves like an appliance and you should not use it as it was a normal debian server.
You need to check on with the TrueNAS community, your issue is not with elasticsearch.
As an example, on this post about adding packages you have this comment:
TrueNAS is not intended to be a general purpose system for you to manipulate as you see fit. It is an appliance, and is carefully designed to accomplish a particular function. You are not supposed to be running "apt", or adding packages, or making changes to the system, unless you are able to do this through the GUI's configuration options or the API.
I do not use TrueNAS, but if I got it right you should be able to run elasticsearch using containers.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.