EDocman Check Missing Files Plugin
Overview
The EDocman Check Missing Files plugin identifies documents in the database whose physical files are missing from the server.
Plugin Group: system
Purpose: Database cleanup and file system synchronization
Execution: Manual trigger or scheduled cron job
Configuration
| Parameter | Description |
| Last Run Timestamp |
Read-only field showing when the check was last executed (for tracking and scheduling purposes) |
How It Works
- Plugin queries all document records from database
- Checks if physical file exists at stored path for each document
- Generates report of missing files with document details:
- Document ID and title
- Expected file path
- Category
- Upload date
- Administrator can take action on orphaned records:
- Delete database records (cleanup)
- Restore missing files from backup
- Re-upload files manually
Features
- File System Verification: Cross-check database vs actual files
- Detailed Reporting: Lists all documents with missing files
- Manual Execution: Run check on-demand from plugin settings
- Scheduled Execution: Integrate with cron for automated checking
- Database Cleanup: Identify orphaned records for removal
Use Cases
- Post-Migration Validation: Verify all files transferred after site migration
- Server Cleanup: Identify orphaned database records after file deletions
- Backup Verification: Confirm backup restore completed successfully
- Regular Maintenance: Schedule monthly checks for file system integrity
- Troubleshooting: Diagnose user reports of missing documents
Usage
Manual Execution
- Navigate to Extensions → Plugins in Joomla admin
- Search for "EDocman Check Missing Files"
- Enable the plugin
- Click plugin name to open configuration
- Trigger check (method varies - may be auto-run button or CLI command)
- Review report of missing files
- Take action on identified issues
Scheduled Execution (Cron)
Set up server cron job to run plugin periodically:
# Check for missing files weekly (Sunday at 2 AM)
0 2 * * 0 /usr/bin/php /path/to/joomla/cli/edocman-check-missing-files.php
Taking Action on Missing Files
Option 1: Delete Orphaned Records
If files were intentionally removed but database records remain:
- Note document IDs from report
- Navigate to Components → EDocman → Documents
- Filter/search for affected documents
- Select and delete orphaned records
Option 2: Restore Missing Files
If files were accidentally deleted:
- Restore files from backup to original paths shown in report
- Re-run check to verify restoration
- Verify documents accessible on frontend
Option 3: Re-Upload Files
If backups unavailable:
- Edit affected documents in admin
- Re-upload files using document editor
- Save documents
Best Practices
- Regular Checks: Schedule monthly or quarterly file checks
- Post-Migration: Always run check after site migration
- Before Major Changes: Run check before updating file paths or moving files
- Backup First: Back up database before deleting orphaned records
- Document Actions: Keep log of missing files and actions taken
- Investigate Causes: Determine why files went missing to prevent recurrence
Common Causes of Missing Files
- Manual file deletion via FTP without database update
- Server migration with incomplete file transfer
- Disk space issues causing file system corruption
- Incorrect file path configuration in component settings
- Accidental deletion of document storage directory
- Category folder structure changes without file moves
Troubleshooting
Plugin Not Running:
- Verify plugin is enabled
- Check Joomla error logs for PHP errors
- Ensure sufficient PHP memory and execution time limits
False Positives:
- Verify document path configuration is correct
- Check for case-sensitive file system issues (Linux/Unix)
- Confirm document storage directory is accessible
Performance Issues:
- For large document libraries, increase PHP max_execution_time
- Run during low-traffic periods
- Consider batch processing for thousands of documents
Updated: January 2026