Troubleshooting search error 507
When you use the advanced search feature in HTML files exported from Dr.Explain, you may encounter error messages with code 507 instead of search results.
A 507 error means the search engine (Solr) is not responding correctly. This usually happens when Solr has crashed or is misconfigured.
Common causes
-
Solr crashed: usually due to insufficient memory. Increase memory limits.
-
Wrong hostname: the backend is looking for Solr at the wrong address.
-
Corrupted index: perform a cold restart to rebuild the index.
-
Resource constraints: the system doesn't have enough resources for Solr.
This step requires access to your server via SSH and Docker.
Check the status of your services:
docker compose ps
What you should see: the solr service should show "Up" in the STATUS column.
If you see "Restarting" or the service is missing: Solr has crashed. Go to Step 2.
If you see "Up": Solr is running. Go to Step 3.
This step requires access to your server via SSH and Docker.
Solr often crashes due to insufficient memory.
Check your docker-compose.yaml file:
solr:
environment:
- SOLR_HEAP=700m # Should be at least 700m
deploy:
resources:
limits:
memory: 2G # Memory limit should be at least 30% higher than SOLR_HEAP
Common mistake: setting SOLR_HEAP higher than the memory limit (e.g., SOLR_HEAP=700m with memory: 400M).
To fix memory issues:
Stop the services:
docker compose down
Update the memory settings in docker-compose.yaml:
-
Set SOLR_HEAP to about 70% of the memory limit.
-
Example: For a 2GB limit, set SOLR_HEAP=1500m.
Note: if you don't have memory limit set in docker-compose.yaml, Solr will be limited by your system's available RAM. If that is still too low, Solr might run out of memory. In that case consider upgrading your system or freeing up RAM for Solr.
Restart the services:
docker compose up -d
Wait a few minutes and test again.
This step requires access to your server via SSH and Docker.
Check if the backend can connect to Solr:
docker compose logs drexplain-search-backend-controller
Look for these messages:
-
"EOF" — Solr closed the connection unexpectedly (crashed). Go to Step 2.
-
"ConnectException" — Cannot connect to Solr. Check if Solr is running.
-
"UnresolvedAddressException" — The Solr hostname cannot be found. Go to Step 4.
This step requires access to your docker-compose.yaml file.
The backend needs to know the correct Solr hostname:
drexplain-search-backend-controller:
environment:
- DSBC_SEARCH_SERVER_HOST=solr
Common mistake: renaming the Solr service without updating the hostname:
# If you renamed the service:
search-engine:
image: ghcr.io/indigobyte/dsb-solr:latest
# Then you must update the hostname:
drexplain-search-backend-controller:
environment:
- DSBC_SEARCH_SERVER_HOST=search-engine
If the hostname is wrong: correct it and restart the services.
This step requires access to your server via SSH and Docker.
If Solr crashed during indexing, the index might be corrupted.
To perform a cold restart:
docker compose down -v
docker compose up -d
Warning: this will delete all search index data. The backend will re-index all HTML files, which may take several minutes.
Use this when:
-
Solr crashed during index creation.
-
The search index appears corrupted.
-
You've made significant configuration changes.