MediaWiki Installation Guide
- MediaWiki Installation Guide
This guide provides a comprehensive overview of installing and configuring MediaWiki 1.40 on a server environment. It's designed for newcomers and assumes a basic understanding of server administration and web technologies.
Prerequisites
Before beginning, ensure you have the following:
- A web server (Apache, Nginx, IIS)
- PHP version 7.3 or higher (recommended 7.4)
- A database server (MySQL/MariaDB, PostgreSQL, SQLite)
- Sufficient server resources (see "System Requirements" below)
- Access to the server's command line / shell
System Requirements
The minimum and recommended system requirements for running MediaWiki 1.40 are as follows:
Minimum Requirements | Recommended Requirements |
---|---|
PHP 7.3 | PHP 7.4 or higher |
MySQL 5.7 or MariaDB 10.3 | MySQL 8.0 or MariaDB 10.6 |
256 MB RAM | 1 GB RAM or higher |
500 MB Disk Space | 2 GB Disk Space or higher |
Apache 2.4 or Nginx 1.10 | Apache 2.4 or Nginx 1.18 |
These are baseline requirements. Performance will improve with increased resources, particularly for high-traffic wikis.
Installation Steps
1. Download MediaWiki: Obtain the latest stable release of MediaWiki 1.40 from the https://www.mediawiki.org/wiki/Download. 2. Upload Files: Extract the downloaded archive and upload all files to the web server's document root. This is often `public_html`, `www`, or `htdocs`. 3. Configure Web Server: Configure your web server to serve the MediaWiki files. This involves setting up a virtual host and ensuring PHP is properly configured. Details vary depending on your web server. See https://www.mediawiki.org/wiki/Manual:Configuration_form#Apache_configuration or https://www.mediawiki.org/wiki/Manual:Configuration_form#Nginx_configuration. 4. Database Setup: Create a new database and user account for MediaWiki. Grant the user account appropriate permissions to the database. Details depend on your database system. See https://www.mediawiki.org/wiki/Manual:MySQL_setup or https://www.mediawiki.org/wiki/Manual:PostgreSQL_setup. 5. Run the Installation Script: Access the MediaWiki installation script through your web browser (e.g., `http://yourdomain.com/mw/index.php?title=Special:Install`). 6. Follow the On-Screen Instructions: The installation script will guide you through the remaining steps, including database configuration, setting up the administrator account, and configuring site settings.
Database Configuration Details
Here's a table summarizing typical database configuration parameters:
Parameter | Description | Example |
---|---|---|
`$wgDBtype` | Database type (mysql, postgres, sqlite) | `mysql` |
`$wgDBserver` | Database server hostname | `localhost` |
`$wgDBname` | Database name | `mediawiki_db` |
`$wgDBuser` | Database username | `mediawiki_user` |
`$wgDBpassword` | Database password | `your_password` |
`$wgDBtableprefix` | Table prefix (optional) | `mw_` |
Ensure these parameters are correctly set in `LocalSettings.php`.
Configuring LocalSettings.php
The `LocalSettings.php` file is crucial for configuring MediaWiki. It's located in the root directory of your MediaWiki installation. You'll need to edit this file to configure database settings, site name, and other important options. See the https://www.mediawiki.org/wiki/Manual:LocalSettings.php for detailed information.
Here’s a table of commonly configured variables:
Variable | Description | Example |
---|---|---|
`$wgSitename` | The name of your wiki. | `MyWiki` |
`$wgScriptPath` | The path to the MediaWiki scripts. | `/mw` |
`$wgUploadDirectory` | The directory where uploaded files are stored. | `/images` |
`$wgEnableEmail` | Enables email functionality. | `true` |
`$wgSMTPPort` | SMTP port for sending emails. | `587` |
Post-Installation Tasks
- Configure Skin: Select and configure a skin for your wiki. See https://www.mediawiki.org/wiki/Manual:Skins.
- Install Extensions: Extend the functionality of MediaWiki by installing extensions. See https://www.mediawiki.org/wiki/Extension_directory.
- Configure Maintenance Scripts: Learn how to use maintenance scripts for tasks such as database updates and cache clearing. See https://www.mediawiki.org/wiki/Manual:Maintenance_scripts.
- Set up Security: Configure security settings to protect your wiki from unauthorized access. See https://www.mediawiki.org/wiki/Manual:Security_tips.
- Regular Backups: Implement a regular backup strategy for your database and files. https://www.mediawiki.org/wiki/Manual:Backups
- Monitor Logs: Regularly check the wiki's logs for errors or suspicious activity. https://www.mediawiki.org/wiki/Manual:Logs
Troubleshooting
- White Screen of Death: Often caused by errors in `LocalSettings.php`. Check the web server's error logs.
- Database Connection Errors: Verify that the database server is running and that the database credentials in `LocalSettings.php` are correct.
- Permissions Issues: Ensure that the web server has write access to the necessary directories.
- PHP Errors: Check the PHP error logs for detailed information about any PHP errors.
Special:Myuser is where you can manage your user profile. Help:Contents provides comprehensive help for wiki users. https://www.mediawiki.org/wiki/FAQ provides answers to frequently asked questions.
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.* ⚠️