MediaHub Settings: Maintenance
The Maintenance page lets you reconcile and clean up MediaHub's assets and storage. Each asset is stored in two parts: the asset record (the item you see listed in MediaHub) and the actual file in storage, along with its generated preview and thumbnail files, which are held separately. These two can get out of sync, leaving orphaned files, missing files, or mismatches. Maintenance reports these, and removes or regenerates what it can. This applies to all assets in MediaHub, whether they were uploaded directly or brought in through auto-ingest.
Where to Find It
Open the user menu in the top-right corner of MediaHub, choose Admin Settings, then select Maintenance from the left-hand menu. The direct address is http://[serverIP]:5600/admin/maintenance.
Running maintenance
Tick the tasks you want to run, then use the buttons at the bottom of the page:
- Evaluate scans the library and reports what it finds, without changing anything.
- Execute carries out the selected tasks. It stays disabled until at least one task is ticked.
The available tasks are:
| Task | What it does |
|---|---|
| Remove Unknown Files In Storage | Deletes files that exist in storage but have no matching asset record (orphaned files), and removes asset records whose path can no longer be resolved. |
| Remove Missing Files In Storage | Reports asset records whose file is missing from storage. |
| Data Does Not Match Storage | Reports assets whose record does not match the file in storage - for example a size mismatch left by a file that was not updated properly. |
| Create Missing Thumbnails | Queues a job to generate a thumbnail for every asset that is missing one. |
| Create Missing Preview Files | Queues a job to generate a preview file for every asset that is missing one. |
| Re-Index Search Engine | Clears the search index and rebuilds it from the current assets. Use it when items are not showing up in search results. |
| Compact Database | Removes orphaned file chunks, then compacts the database collections and their indexes to reclaim space. |
| Restart Server | Restarts the MediaHub server. |
Info
The thumbnail is the small image shown in the asset list. The preview is the larger file opened when you click an asset.
Warning
The first three tasks all run the same reconciliation pass, so ticking any one of them is enough to trigger the deletions described under Remove Unknown Files In Storage. Run Evaluate first and read the report before you execute any of them.
Reading the Evaluate report
Evaluate always scans the whole library - it ignores which boxes are ticked - and then fills in the first five tasks with what it found. Expand a task to see the individual files, each with its path and size:
- rows under Remove Unknown Files In Storage and Data Does Not Match Storage have a action, which downloads the file so you can inspect it before it is removed;
- rows under Create Missing Thumbnails and Create Missing Preview Files have a action, which opens the asset in MediaHub in a new tab.
When a task has nothing to report it expands to a single line - No unknown files in Storage, No missing files in Storage, No files with different sizes in Storage, No missing thumbnails or No missing preview files.
Re-Index Search Engine, Compact Database and Restart Server have nothing to evaluate, so they never expand.
Confirmations
Ticking Compact Database or Restart Server raises a confirmation before anything runs - Are you sure you would like to compact the database? This operation can take a while and Are you sure you want to restart?. Tick both and you get a single prompt listing them instead.
When the run finishes, MediaHub reports Maintenance completed successfully, re-runs the evaluation so the report reflects what is left, and clears the tick boxes.
Every run is recorded in the log: Maintenance: Evaluate and Maintenance: Execute as actions, and Maintenance Started / Maintenance Finished entries under the System category around the work itself.
Re-indexing search
Re-Index Search Engine clears the Meilisearch index and rebuilds it from every asset that is not deleted, in batches. It is the same operation as Reindex Search on the Admin Dashboard, and it needs an administrator account.
Run it when search returns nothing for assets you know exist.
Note
If re-indexing does not help, check the log for Failed to connect to meilisearch - the search engine runs as a separate service on port 7700, and nothing can be indexed or found while it is down.
Note
Maintenance acts only on assets and files within MediaHub storage and its database.