Plugin Management
- Plugin Management
This article details the process of managing plugins (extensions) on our MediaWiki 1.40 installation. Proper plugin management is critical for maintaining a stable, secure, and feature-rich wiki. This guide is intended for newcomers to server administration tasks on this platform.
Understanding MediaWiki Plugins (Extensions)
MediaWiki's functionality is greatly extended through the use of plugins, officially called extensions. These are PHP scripts that add features like improved editing tools, new special pages, or integration with external services. Incorrectly installed or configured extensions can lead to site instability or security vulnerabilities. Therefore, a methodical approach to plugin management is essential. Refer to the configuration settings page for more general information.
Plugin Installation
The installation process generally involves these steps:
1. **Download the Extension:** Obtain the extension package from the MediaWiki extensions repository. Ensure the extension is compatible with MediaWiki 1.40. 2. **Upload the Extension Files:** Using SFTP or SSH, upload the extracted extension directory to the `extensions/` directory on the server. The full path is typically `/var/www/html/extensions/` but can vary based on your server setup. See How to install an extension for detailed instructions. 3. **Configure `LocalSettings.php`:** Edit the `LocalSettings.php` file (located in the main MediaWiki directory) to enable the extension. Add the following line, replacing `ExtensionName` with the actual directory name of the extension:
```php wfLoadExtension( 'ExtensionName' ); ``` Consult the extension's documentation for any additional configuration settings that need to be added to `LocalSettings.php`.
4. **Run `update.php`:** After modifying `LocalSettings.php`, run the `update.php` script (accessible via your web browser, e.g., `https://yourwiki.com/update.php`) to update the MediaWiki database schema and install any necessary database tables. This is a *crucial* step.
Important Configuration Details
Here's a table summarizing essential server details relevant to plugin management:
Parameter | Value | Description |
---|---|---|
Web Server | Apache 2.4 | The web server hosting the wiki. |
PHP Version | 7.4 | The PHP version used by MediaWiki. |
Database | MariaDB 10.5 | The database system storing wiki content. |
MediaWiki Version | 1.40 | The current version of MediaWiki. |
PHP Memory Limit | 256M | The maximum amount of memory PHP scripts can use. Increase if errors occur during plugin updates. |
Plugin Configuration Options
Many plugins require specific configuration options. These are typically set within the `LocalSettings.php` file, or through a special configuration page accessible within the wiki itself (often a Special: page, like Special:Configure. Always refer to the plugin's documentation for detailed instructions.
Here's a sample table illustrating common configuration variables:
Variable Name | Description | Example Value |
---|---|---|
`$wgEnableEmail` | Enables or disables email functionality. | `true` |
`$wgSMTPPort` | The port for the SMTP server. | `587` |
`$wgUploadDirectory` | Specifies the directory for uploaded files. | `/var/www/html/images` |
`$wgRateLimits` | Controls rate limits for actions like editing and creating pages. | `[ 'default' => [ 'actions' => 'edit,create', 'threshold' => 10, 'period' => 60 ] ]` |
Plugin Updates and Removal
- **Updates:** Regularly check for updates to installed plugins. Updates often include bug fixes, security patches, and new features. The best practice is to check the MediaWiki extensions repository periodically. The update process generally involves downloading the new version, replacing the old files, and running `update.php`.
- **Removal:** To remove a plugin, first disable it in `LocalSettings.php` by commenting out the `wfLoadExtension()` line. Then, remove the plugin directory from the `extensions/` directory. Finally, run `update.php` to remove any database tables or configuration settings associated with the plugin. Backups are highly recommended before removal. See Upgrading MediaWiki for more context.
Troubleshooting Plugin Issues
If you encounter issues after installing or updating a plugin:
1. **Check the Error Logs:** Examine the MediaWiki error logs (`errors/error.log` in the main MediaWiki directory) for PHP errors or warnings. 2. **Disable the Plugin:** Temporarily disable the plugin in `LocalSettings.php` to see if it resolves the issue. 3. **Check Plugin Documentation:** Refer to the plugin's documentation for troubleshooting tips. 4. **Consult the MediaWiki Community:** Seek help from the MediaWiki mailing lists or the MediaWiki forums.
Here’s a table of common error messages and potential solutions:
Error Message | Potential Solution |
---|---|
"Fatal error: Class '...' not found" | The extension is missing dependencies or is not fully loaded. Verify `LocalSettings.php` and PHP extensions. |
"Database error: Table '...' doesn't exist" | The `update.php` script was not run after installing or updating the extension. |
"PHP memory exhausted" | Increase the PHP memory limit in `php.ini`. |
"White screen of death" | Often caused by a PHP error. Check the error logs. |
Security Considerations
- **Only Install Trusted Plugins:** Download plugins only from the official MediaWiki extensions repository or other reputable sources.
- **Keep Plugins Updated:** Regularly update plugins to patch security vulnerabilities.
- **Review Plugin Code (if possible):** If you have the expertise, review the plugin code for potential security flaws.
- **Limit Plugin Permissions:** Grant plugins only the necessary permissions.
- **Regular Backups:** Maintain regular backups of your MediaWiki installation, including the database and files. Refer to Backups for more information.
Manual:Configuration settings
Manual:How to install an extension
MediaWiki extensions repository
Special:Configure
Manual:Upgrading MediaWiki
MediaWiki mailing lists
MediaWiki forums
Manual:Backups
Extension:Semantic MediaWiki
Extension:VisualEditor
Extension:Cite
Extension:CategoryTree
Extension:Interwiki
Extension:ParserHooks
Special:Version
Intel-Based Server Configurations
Configuration | Specifications | Benchmark |
---|---|---|
Core i7-6700K/7700 Server | 64 GB DDR4, NVMe SSD 2 x 512 GB | CPU Benchmark: 8046 |
Core i7-8700 Server | 64 GB DDR4, NVMe SSD 2x1 TB | CPU Benchmark: 13124 |
Core i9-9900K Server | 128 GB DDR4, NVMe SSD 2 x 1 TB | CPU Benchmark: 49969 |
Core i9-13900 Server (64GB) | 64 GB RAM, 2x2 TB NVMe SSD | |
Core i9-13900 Server (128GB) | 128 GB RAM, 2x2 TB NVMe SSD | |
Core i5-13500 Server (64GB) | 64 GB RAM, 2x500 GB NVMe SSD | |
Core i5-13500 Server (128GB) | 128 GB RAM, 2x500 GB NVMe SSD | |
Core i5-13500 Workstation | 64 GB DDR5 RAM, 2 NVMe SSD, NVIDIA RTX 4000 |
AMD-Based Server Configurations
Configuration | Specifications | Benchmark |
---|---|---|
Ryzen 5 3600 Server | 64 GB RAM, 2x480 GB NVMe | CPU Benchmark: 17849 |
Ryzen 7 7700 Server | 64 GB DDR5 RAM, 2x1 TB NVMe | CPU Benchmark: 35224 |
Ryzen 9 5950X Server | 128 GB RAM, 2x4 TB NVMe | CPU Benchmark: 46045 |
Ryzen 9 7950X Server | 128 GB DDR5 ECC, 2x2 TB NVMe | CPU Benchmark: 63561 |
EPYC 7502P Server (128GB/1TB) | 128 GB RAM, 1 TB NVMe | CPU Benchmark: 48021 |
EPYC 7502P Server (128GB/2TB) | 128 GB RAM, 2 TB NVMe | CPU Benchmark: 48021 |
EPYC 7502P Server (128GB/4TB) | 128 GB RAM, 2x2 TB NVMe | CPU Benchmark: 48021 |
EPYC 7502P Server (256GB/1TB) | 256 GB RAM, 1 TB NVMe | CPU Benchmark: 48021 |
EPYC 7502P Server (256GB/4TB) | 256 GB RAM, 2x2 TB NVMe | CPU Benchmark: 48021 |
EPYC 9454P Server | 256 GB RAM, 2x2 TB NVMe |
Order Your Dedicated Server
Configure and order your ideal server configuration
Need Assistance?
- Telegram: @powervps Servers at a discounted price
⚠️ *Note: All benchmark scores are approximate and may vary based on configuration. Server availability subject to stock.* ⚠️