Hi,

If you have not tuned your heap, it will default to 512m. THe lines in 
solr.in.sh prefixed with hash # are comments and do nothing.
If you experience OOME during use that is likely not enough for your use case.
So edit the file, remove the hash and set SOLR_HEAP=1024m to give yourself some 
more headroom, then restart the service.
You may want to add some monitoring 
<https://solr.apache.org/guide/solr/latest/deployment-guide/monitoring-with-prometheus-and-grafana.html>
 on your service to gain insight into hotspots and performance to do a more 
informed tuning 
<https://solr.apache.org/guide/solr/latest/deployment-guide/jvm-settings.html#choosing-memory-heap-settings>.
Since 9.2 the solr process should actually exit on OOM, thus if you installed 
Solr as a daemon service it should restart automatically?

Jan

> 6. mai 2024 kl. 11:32 skrev Imran Chaudhry <ichaud...@gmail.com>:
> 
> Hello Solr users crew,
> 
> I have a single-node Solr 9.x instance running on a hosted virtual Debian
> Stable server.
> 
> The server technical specs are as follows:
> 
> 2 vCPU
> 4Gb RAM
> 
> The Solr instance has about 180,000 documents which get refreshed once a
> day via an automated script. Each day about a few thousand documents may
> get added, a few thousand may get deleted. The amount of docs will stay
> pretty stable or grow slowly.
> 
> I have a Python/Django app using Solr as a backend for document search.
> What I'm finding is that at least once a week, the Solr process gets reaped
> by the Linux kernel due to an "out of memory" condition.
> 
> My app produces an Error 500 and
> I then have to manually restart Solr.
> 
> My Solr instance is pretty much vanilla, it's configured using the
> following params:
> 
> /etc/default# grep -i heap solr.in.sh
> # Increase Java Heap as needed to support your indexing / query needs
> #SOLR_HEAP="256m"
> 
> /etc/default# grep -i mem solr.in.sh
> # Expert: If you want finer control over memory options, specify them
> directly
> #SOLR_JAVA_MEM="-Xms512m -Xmx512m"
> 
> In the Solr web dashboard the JVM-Memory graph is currently showing:
> 
> JVM-Memory 20.9% / 107.13 MB
> Then in grey:
> 512.00 MB
> 512.00 MB
> 
> What can I do to stabilise things?
> 
> Kind regards,
> Imran

Reply via email to