ElasticSearch: Difference between revisions

From neuromatch
No edit summary
No edit summary
Line 16: Line 16:
idk if we should put this part online but there is some config here too
idk if we should put this part online but there is some config here too
</pre>
</pre>
=== Service ===
Use the default service, except we also make it restart when it dies:
<code>/lib/systemd/system/elasticsearch.service</code>
<syntaxhighlight lang="ini">
[Service]
# Other stuff....
ExecStart=/usr/share/elasticsearch/bin/systemd-entrypoint -p ${PID_DIR}/elasticsearch.pid --quiet
Restart=always
RestartSec=30
# ...
</syntaxhighlight>


=== Memory ===
=== Memory ===

Revision as of 01:16, 26 November 2023

Up to: Tech WG, Search

Config

List any changed config values here!!!

/etc/elasticsearch/elasticsearch.yml:

network.host: localhost
discovery.type: single-node
xpack.security.enabled: true

/home/mastodon/.env.production

idk if we should put this part online but there is some config here too

Service

Use the default service, except we also make it restart when it dies:

/lib/systemd/system/elasticsearch.service

[Service]
# Other stuff....
ExecStart=/usr/share/elasticsearch/bin/systemd-entrypoint -p ${PID_DIR}/elasticsearch.pid --quiet
Restart=always
RestartSec=30 
# ...

Memory

the ES docs say to allocate half your available memory to the heap. At the moment (23-10-26) we are using 2.5G/8G memory at rest. Going to try allocating 3GB and see what happens

/etc/elasticsearch/jvm.options.d/heap.options

-Xms3g
-Xmx3g

Creds havers

References

Docs:

Since we are running on a small VPS, we might need to configure it for a low memory environment!

See also


History

Threads

Discord

sneakers.the.rat#elasticsearch23-10-27 02:29:48

OK yet again starting thread on getting ElasticSearch running