Solr is used for setups with memory >= 3.5 GiB to provide full-text search in Dovecot.
Please be aware that applications like Solr _may_ need maintenance from time to time.
Besides that, Solr will eat a lot of RAM, depending on the usage of your server. Please avoid it on machines with less than 3 GB RAM.
The default heap size (1024 M) is defined in mailcow.conf.
Since we run in Docker and create our containers with the "restart: always" flag, a oom situation will at least only trigger a restart of the container.
docker-compose exec dovecot-mailcow doveadm fts rescan -A
```
Dovecot Wiki: "Scan what mails exist in the full text search index and compare those to what actually exist in mailboxes. This removes mails from the index that have already been expunged and makes sure that the next doveadm index will index all the missing mails (if any)."
This does **not** re-index a mailbox. It basically repairs a given index.
If you want to re-index data immediately, you can run the followig command, where '*' can also be a mailbox mask like 'Sent'. You do not need to run these commands, but it will speed things up a bit: