[Support] FoxxMD - elasticsearch

28 posts in this topic Last Reply

Recommended Posts

On 9/15/2020 at 2:50 PM, rob_robot said:

For those that are stuck like me on the ingest-attachment plugin issue:


You need to stop the elasticsearch docker and restart it after you have executed the command to install the plugin so it gets loaded into elasticsearch. 


Here my steps:

1.) get elasticsearch docker (7.9.1 works) do a clean install (delete old elasticsearch in /mnt/user/appdata/)


2.) Download the full text search packages in nextcloud app store (at least 3 packages)


3.) Configure your Nextcloud search platform to "Elasticsearch" and address of Servlet to: http://YOUR_IP:9200/ 

It needs to be configured to the port of the REST API


4.) Install the plugin for elasticsearch, by either opening a console inside the elasticsearch docker and type /usr/share/elasticsearch/bin/elasticsearch-plugin install --batch ingest-attachment


through the User scripts Unraid plugin as stated above. 


5.) Restart the elasticsearch container


6.) Test everything by opening a new shell in the nextcloud container then navigate to the occ directory (/var/www/html) and type 

./occ fulltextsearch:test


If everything is ok, then you can continue with the index: ./occ fulltextsearch:index



This worked great with Nextcloud 20.0.2 and ElasticSearch 7.9.3. Do I need to re-index manually each time files are added? To get OCR working for PDF files I installed Tesseract OCR. Will that start running OCR automatically on all files once enable or needs to be run manually?

Link to post
  • 3 months later...
On 10/25/2020 at 11:21 AM, Geck0 said:


So for those following after me. I'm not very experienced with docker, but I pulled down the container manually and by doing so changed the environment variables, changing the heap size to 2g.

I changed the second set of ES_JAVA_OPTS (in red) from Xms512mb -Xmx512mb to 2g instead. However, I've just noticed that there are two ES_JAVA_OPTS entries, the other one I've marked in yellow. This was a copy and paste from the original container install. No matter what I did I couldn't get the heap size to change from 512mb to any other size by setting ES_JAVA_OPTS as a variable in the CA settings for the container or via jvm.options inside the container itself.


Anybody shed light on this? I would like to just pull the container down without all this phaff.


I also had the same heap size problem with elasticsearch. It can be solved by editing the docker, then switching to "Advanced view" and edit the EXTRA PARAMETERS line. 

Here an example to switch from 512MB to 4G of heap size:

-e "ES_JAVA_OPTS"="-Xms4g -Xmx4g" --ulimit nofile=262144:262144


Actual heap size can be checked by opening up a console inside the docker and then running following command: 

curl -sS  "localhost:9200/_cat/nodes?h=heap*&v"


Heap.max should then show 4GB instead of 512 MB.

Edited by rob_robot
Link to post
  • 1 month later...

For anyone stuck on the users and occ errors the default command for unraid is the following:


docker exec --user abc nextcloud php /config/www/nextcloud occ fulltextsearch:index


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.