Continuing the discussion from Installation on OpenSuse fails:
Hi crate users,
unpacking the tarball for “installation” has flawlessly worked on the three systems I tested it on. Now I would like to automatically start crate at boot time and tried to build a systemd service file. It is very short – just like the error it fails with.
The error I get is:
May 27 01:06:21 tuxedo systemd: Started Crate DB (electricity monitoring)..
May 27 01:06:22 tuxedo systemd: cratedb.service: Main process exited, code=exited, status=1/FAILURE
May 27 01:06:22 tuxedo systemd: cratedb.service: Unit entered failed state.
May 27 01:06:22 tuxedo systemd: cratedb.service: Failed with result 'exit-code'.
I tried a few things, none of which worked. Would one of you mind sharing their systemd.service file with the community? I guess it would be helpful to have a template in the tarball already tor simple adaptation…
In any case: Thanks a lot for your help!
Here the copy included with the Ubuntu distro. Might help as starting point:
# default environment variables
# load environment
# Disable timeout logic and wait until process is stopped
# SIGTERM signal is used to stop the Java process
# Send the signal only to the JVM rather than its control group
# Java process is never killed
# When a JVM receives a SIGTERM signal it exits with code 143
SuccessExitStatus=143 SIGTERM SIGKILL
# Override these settings with a file called
# /etc/systemd/system/crate.service.d/crate.conf and specify any changes
# Specifies the maximum number of bytes of memory that may be locked into RAM
# Specifies the maximum file descriptor number that can be opened by this process
# Specifies the maximum number of processes
# Specifies limit of virtual memory that can be used
Funny, how things start functioning once you use them correctly. I adapted and simplified the file a bit and it works like a treat. Thanks for sharing @proddata!
Would be cool if you could share your setup steps on OpenSuse e.g. in short tutorial Tutorials - Crate.io Community