The Problem
You are sending documents to your Opensolr Index, but they are not showing up in search results. You query with q=*:* and get 0 results, or fewer documents than you expected.
This is one of the most common issues, and it almost always comes down to one of a handful of causes. Let us walk through them.
What Happens When You Index a Document
When you send a document to Solr, it goes through several steps before it becomes searchable. If any step fails, the document is silently dropped or stuck in limbo.
Common Causes and Fixes
1. Missing Commit After Indexing
This is the number one cause. Solr does not make documents searchable until a commit is issued. Your documents are in memory but invisible to queries.
Fix: Make sure you commit after indexing. You have three options:
// Option 1: Append commit=true to the URL
curl "https://HOST/solr/CORE/update?commit=true" -H "Content-Type: application/json" -d '[{"id":"1","title":"Test"}]'
// Option 2: Send a separate commit command
curl "https://HOST/solr/CORE/update?commit=true"
// Option 3: Use autoCommit in solrconfig.xml (recommended)
<autoCommit>
<maxTime>15000</maxTime>
</autoCommit>
2. Field Names Do Not Match the Schema
Solr rejects documents with fields that are not defined in your schema.xml (unless you have a dynamicField rule that matches). Field names are case-sensitive — Title and title are two different fields.
Fix: Open your schema.xml in the Config Files Editor and verify every field name matches exactly what your application sends.
3. Corrupted Data Folder
Sometimes the data folder gets corrupted — especially on shared cloud infrastructure after unexpected events. The index cannot be read from or written to.
Fix: Remove your Opensolr Index and create a new one. If that does not work, contact support and we will fix it for you.
4. Authentication Issues
If your Opensolr Index uses HTTP Basic Authentication, your indexing client must send the correct credentials with every request. A failed auth returns 401 Unauthorized — but some client libraries silently swallow this error.
Fix: Verify your credentials. Test with a direct cURL call to rule out application-level issues.
5. Document Size Too Large
Individual documents with very large field values (full PDFs, raw HTML pages) may time out or exceed upload limits during indexing.
Fix: Try indexing a smaller document first to isolate the issue. See our FAQ on content length upload limits if size is the problem.
Step-by-Step Debugging
-
Check the Error Log — Click Error Log in your Opensolr Index control panel. Common errors:
unknown field,undefined field type,document size exceeds limit -
Verify Schema Fields — Open
schema.xmlin the Config Files Editor. Confirm every field in your payload is defined, and checktypeattributes (sending a string to a numeric field causes a parsing error) -
Test with a Simple cURL POST — Send a minimal test document:
curl "https://YOUR_HOST/solr/YOUR_CORE/update?commit=true" \ -H "Content-Type: application/json" \ -d '[{"id": "test-1", "title": "Test document"}]'
If this works but your application does not, the problem is in your application code.
- Check Your Document Count — Run
q=*:*&rows=0to see total documents. If the count is not increasing, documents are being rejected.
Integration-Specific Tips
| Platform | Tip |
|---|---|
| Drupal + Search API | Run drush search-api:rebuild-tracker to reset the indexing tracker, then re-index. Check drush watchdog:show for Solr errors. |
| WordPress + WPSolr | Verify endpoint URL and credentials in plugin settings. Trigger a full re-index from the plugin page. Check wp-content/debug.log. |
| Custom App | Make sure you handle the Solr response. A successful index returns HTTP 200. Any other status means the document was rejected — parse the response body for details. |
Quick Checklist
- Are you sending a commit after indexing? (or using autoCommit)
- Do all field names in your documents match the schema exactly (case-sensitive)?
- Check the Error Log in your Opensolr control panel for rejection reasons
- Test with a simple cURL POST to isolate application vs Solr issues
- Verify authentication credentials if your index uses HTTP Basic Auth
- Check document size — is any single field value extremely large?
Still stuck? Reach out to us at support@opensolr.com with the errors from your Error Log — we will help you figure out what is happening.