Amazon Web Services
- Amazon Web Services (AWS) Server Configuration for MediaWiki 1.40
This article details configuring a MediaWiki 1.40 installation on Amazon Web Services (AWS). It's geared towards newcomers to both AWS and MediaWiki server administration. We will cover instance selection, database setup, storage, and basic security considerations.
1. Introduction to AWS for MediaWiki
AWS provides a scalable and reliable platform for hosting MediaWiki. Utilizing AWS allows for dynamic resource allocation, reducing the need for large upfront hardware investments. This guide focuses on a typical setup for small to medium-sized wikis. For very large wikis, consider more complex architectures involving load balancing, caching layers like Varnish, and database clustering. We will assume you have a basic AWS account and familiarity with the AWS Management Console. Understanding Networking concepts is also helpful.
2. Instance Selection (EC2)
Choosing the correct EC2 instance type is crucial. The following table outlines some suitable options, considering cost and performance. Remember to select an AWS Region geographically close to your user base to minimize latency. See Regions for available locations.
Instance Type | vCPUs | Memory (GiB) | Cost (USD/month - approximate) | Suitable For |
---|---|---|---|---|
t3.medium | 2 | 4 | $30 - $50 | Small to medium wikis with moderate traffic |
t3.large | 2 | 8 | $60 - $100 | Medium wikis with higher traffic, or those anticipating growth |
m5.large | 2 | 8 | $80 - $120 | Larger wikis, development/testing environments |
Consider using Amazon Linux 2 or Ubuntu Server as the operating system for your EC2 instance. Both are well-supported and have extensive documentation. Operating Systems are an important consideration.
3. Database Setup (RDS)
MediaWiki requires a database backend. Amazon Relational Database Service (RDS) is a managed database service that simplifies database administration. MySQL or MariaDB are the recommended database engines for MediaWiki 1.40.
Database Engine | Instance Type | Storage (GiB) | Cost (USD/month - approximate) | Notes |
---|---|---|---|---|
MySQL | db.t3.medium | 20 | $30 - $50 | Solid performance for medium-sized wikis. |
MariaDB | db.t3.medium | 20 | $30 - $50 | Generally faster than MySQL, good alternative. |
MySQL | db.r5.large | 80 | $120 - $180 | For larger wikis needing higher performance. |
Ensure you create a secure database user specifically for MediaWiki with limited privileges. Refer to the Security Best Practices section for more details. Backups should be enabled and regularly tested. Database Maintenance is essential.
4. Storage (EBS)
Amazon Elastic Block Storage (EBS) provides persistent block storage volumes for your EC2 instance. Use EBS for the MediaWiki installation directory and the `images` directory. General Purpose SSD (gp2 or gp3) volumes are recommended for good performance.
Volume Type | Size (GiB) | IOPS | Cost (USD/month - approximate) | Recommended Use |
---|---|---|---|---|
gp2 | 80 | 3,000 | $8 - $12 | MediaWiki installation and images directory |
gp3 | 80 | 3,000 (configurable) | $7 - $10 | Newer generation, provides more control over IOPS/throughput |
io1 | 100 | 1000+ | $20 - $30 | High-performance wikis requiring consistently high IOPS |
Mount the EBS volume to a suitable directory on your EC2 instance (e.g., `/var/www/html`). File Storage is a key component of any wiki.
5. Security Considerations
- **Security Groups:** Configure security groups to allow only necessary traffic to your EC2 instance (e.g., HTTP/HTTPS from the public internet, SSH from your IP address).
- **IAM Roles:** Use IAM roles to grant your EC2 instance permissions to access other AWS services (e.g., RDS). Avoid storing AWS credentials directly on the instance. See IAM Roles.
- **HTTPS:** Enable HTTPS using a certificate from AWS Certificate Manager (ACM). This encrypts traffic between your users and your MediaWiki instance. SSL/TLS Configuration is critical.
- **Firewall:** Consider using a web application firewall (WAF) to protect against common web attacks. Web Application Firewalls offer an extra layer of defense.
- **Regular Updates:** Keep your operating system and MediaWiki software up-to-date with the latest security patches. Software Updates are vital for security.
6. Basic Configuration Steps
1. Launch an EC2 instance with your chosen instance type and operating system. 2. Create an RDS database instance with MySQL or MariaDB. 3. Attach an EBS volume to your EC2 instance. 4. Install a web server (e.g., Apache or Nginx). 5. Install PHP and the necessary PHP extensions for MediaWiki. 6. Download and extract the MediaWiki 1.40 software. 7. Configure MediaWiki to connect to your RDS database. Edit `LocalSettings.php` with the correct database credentials. See Configuration Files. 8. Set the correct permissions on the MediaWiki files and directories. 9. Test your MediaWiki installation by accessing it through a web browser.
7. Further Resources
- AWS Documentation
- MediaWiki Installation Guide
- PHP Configuration
- Web Server Configuration
- Troubleshooting
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.* ⚠️