Moodle LMS Integration Tutorial
๐ Moodle + OpenSolr Integration Guide
Get Global Search working in Moodle LMS using the mighty power of OpenSolr
No servers? No problem. OpenSolr gives you a fully hosted Solr instance so you can focus on what matters โ teaching, not taming Java demons.
๐งฐ What Youโll Need
Before Moodle and OpenSolr can become besties, youโll need:
- An active OpenSolr account
- Your Solr endpoint details:
- Solr Hostname
- Port
- Solr Path/Core
- Username & Password (provided by Opensolr)
- Access to your Moodle site's admin interface (preferably with a cup of coffee)
๐ Step-by-Step Integration
Step 1: Prepare Your Solr Core in OpenSolr
- Log in to the OpenSolr dashboard.
- Create a new Solr Index โ name it something like
moodle_index. - Use the Moodle-provided schema.xml for best compatibility:
- Find it here:
/your/moodle/path/search/engine/solr/schema.xml
- Upload the schema to your OpenSolr core (via the control panel or API).
- Find it here:
- No need to Restart / Reload the Opensolr index, but you can also do that if you must, from the Opensolr Control Panel.
Step 2: Enable Global Search in Moodle
- Moodle Admin Panel โ Site administration > Advanced features
- Check โ๏ธ Enable global search
- Save changes (and breathe)
Step 3: Enable Solr Search Engine
- Moodle Admin Panel โ Site administration > Plugins > Search > Manage global search engines
- Enable the Solr engine
Step 4: Configure Solr Settings in Moodle
Go to:
Site administration > Plugins > Search > Solr
Now fill in the juicy bits:
| Moodle Field | What to Enter |
|---|---|
| Hostname | The OpenSolr host (e.g., search.opensolr.com) |
| Port | Usually 443 if using HTTPS |
| Index name | The name of your OpenSolr index (e.g., moodle_index) |
| Username | Your OpenSolr username |
| Password | Your OpenSolr password |
| Use SSL | Yes (you should!) |
Click Save changes, and Moodle will try to handshake with Solr like two polite British gentlemen.
Step 5: Test & Index Content
- After saving, Moodle will test the connection.
- Navigate to:
Site administration > Search > Index data - Click Start indexing
- Watch your content go zooming into Solr
๐งช Optional: Trigger Indexing via CLI
If your cron is still on vacation:
php admin/tool/task/cli/schedule_task.php --execute=\core\task\search_index_task
โ Youโre Done!
Now Moodle's search box is powered by OpenSolr โ lightning fast, globally scalable, and no server maintenance nightmares.
If Moodle search was a sleepy librarian before, now it's a caffeinated research assistant.
Need help? Holler at: [email protected]

